Reputation: 191
I am using logback for my logging. I wanted to use syslog4j to natively log to syslog.(as I do not want to open up the udp port for logging into syslog) Can I use syslog4j as an appender to logback? If not, is there any other way of using logback to log into syslog without opening up the udp port i.e. using native unix sockets!
Thanks Sumanth
Upvotes: 5
Views: 1483
Reputation: 1452
i think you are looking for SyslogAppender
configuration example here logback-syslog.xml
Upvotes: 0
Reputation: 131
Unfortunately the SyslogAppender in Logback doesn't support anything other than UDP syslog protocol.
I haven't tried but it might be trivial to write a Syslog4jAppender for Logback (I'm surprised no-one else has already)
It hasn't been answered yet but the question "https://stackoverflow.com/questions/12905480/using-syslog4j-as-an-appender-to-logback" would cover what you want.
Upvotes: 1