btw. It bugs me a bit that Connect logs to console and not to file by default. I think tools should log to console, but Connect is more of a service / daemon and should log to file like the brokers do. So when you get your log4j config to work, perhaps submit a PR to Apache Kafka so we'll all enjoy this? :)
On Tue, Jan 10, 2017 at 10:23 PM, Gwen Shapira <g...@confluent.io> wrote: > Is your goal to simply log connect to file rather than to the console? > In this case your configuration is almost right. Just change the first > line in connect-log4j.properties to: > > log4j.rootLogger=INFO, stdout, connectAppender > > and then add the lines you have in your email. > > Or you can get rid of stdout appender completely if you prefer. > > You may find the log4j primer useful: > https://logging.apache.org/log4j/1.2/manual.html > > On Tue, Jan 10, 2017 at 7:42 AM, Berryman, Eric <berry...@frib.msu.edu> wrote: >> Hello! >> >> Is there a log4j.appender.connectAppender? >> >> I noticed there is a log4j.appender.kafkaAppender. >> I was hoping to setup the connect-log4j.properties like kafka's. >> >> log4j.appender.connectAppender=org.apache.log4j.DailyRollingFileAppender >> log4j.appender.connectAppender.DatePattern='.'yyyy-MM-dd-HH >> log4j.appender.connectAppender.File=${kafka.logs.dir}/connect.log >> log4j.appender.connectAppender.layout=org.apache.log4j.PatternLayout >> log4j.appender.connectAppender.layout.ConversionPattern=[%d] %p %m (%c:%L)%n >> >> Thank you! >> Eric > > > > -- > Gwen Shapira > Product Manager | Confluent > 650.450.2760 | @gwenshap > Follow us: Twitter | blog -- Gwen Shapira Product Manager | Confluent 650.450.2760 | @gwenshap Follow us: Twitter | blog