Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

how to store failure as logs in a particular directory or mail with in Nifi?

Solved Go to solution

how to store failure as logs in a particular directory or mail with in Nifi?

Explorer

I have flow like get files from FTP to HDFS.

1.In Each process i need to store failure as log and store in a particular location

2.In Each process i need to store failure as log and mail to admin(mail id)

Thanks In Advance

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: how to store failure as logs in a particular directory or mail with in Nifi?

Master Guru

There are a few things you can do here if i am understanding correctly what you are trying to accomplish.

1. The logback.xml can be modified so specific processor component logs could be redirected to a specific new log file. You can specify where that new log is written. You could also specify the specific log level of those components (WARN level would get you just WARN and ERROR messages). 2. In your dataflow you could use the TailFile processor to monitor that new log and route any generated FlowFiles to a putEmail processor to send them to your Admin. In addition to email you can route those FlowFiles to a processor of your choice to put a copy to a specific location as well either locally or remotely.

Thanks,

Matt

View solution in original post

1 REPLY 1
Highlighted

Re: how to store failure as logs in a particular directory or mail with in Nifi?

Master Guru

There are a few things you can do here if i am understanding correctly what you are trying to accomplish.

1. The logback.xml can be modified so specific processor component logs could be redirected to a specific new log file. You can specify where that new log is written. You could also specify the specific log level of those components (WARN level would get you just WARN and ERROR messages). 2. In your dataflow you could use the TailFile processor to monitor that new log and route any generated FlowFiles to a putEmail processor to send them to your Admin. In addition to email you can route those FlowFiles to a processor of your choice to put a copy to a specific location as well either locally or remotely.

Thanks,

Matt

View solution in original post

Don't have an account?
Coming from Hortonworks? Activate your account here