Support Questions

Find answers, ask questions, and share your expertise

sending as mail attachment the nifi log or customized log

avatar
Contributor

I trying to capture log details and sending as an mail or as an attachment through nifi process.

Please help me out,

1 ACCEPTED SOLUTION

avatar
Super Guru

@Gurpreet Singh

You need to use "GetFile" to get the log file. Then use split text or some filter process based on your requirements to parse log file (or simply just send the whole file) and then send to PutEmail processor to send the emil.

https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi.processors.standard.PutEmail/

View solution in original post

3 REPLIES 3

avatar
Super Guru

@Gurpreet Singh

You need to use "GetFile" to get the log file. Then use split text or some filter process based on your requirements to parse log file (or simply just send the whole file) and then send to PutEmail processor to send the emil.

https://nifi.apache.org/docs/nifi-docs/components/org.apache.nifi.processors.standard.PutEmail/

avatar
Guru

Minor sidenote: can use TailFile with polling interval as alternative to GetFile.

avatar
Contributor

Thanks Greg, I had tried with Tailfile and its working fine, thanks for the solution and idea to do it