0
votes

I have a flink job in which i am using logback as my logging framework. Apart from the file, console appenders, i am also using logstash-logback-appender to send my log to a logstash instance.

If i run the flink job from Eclipse, the logs are sent to the specified logstash server.

I can see the logs being sent to logstash if i package the application as jar and run it outside Eclipse.

However if run the flink application as job (by uploading the same jar as above) from flink dashboard, the logs are not sent to logstash.

My flink setup is running on windows as per the instructions here Running flink on windows. I start flink using start-cluster.bat

I think the logback configuration is ignored. I have placed the logback configuration at src/main/resources in my application. How can i get the logback configuration recognized by flink setup?

I have tried the steps mentioned in Best practices. Does this steps to replace log4j with logback are for the jobmanager & taskmanager logs or are they for application logs?

1
I've a similar situation, can you please suggest how did you solved this issue?Apollo

1 Answers

0
votes

Try adding logstash-logback-encoder lib in the lib/ folder along with logback jars.