Configure liquibase log destination?

I am using liquibase 1.9.5 started via LiquibaseServletListener in a JBoss 5 server.

liquibase seems to write all log messages to System.err. The problem is that JBoss captures all output to System.err and writes it as ERROR messages in it’s log file. Therefore, even the log output from a successfull liquibase run appear as errors.

Is there a way to configure the destination liquibase logs to to prevent these ERROR messages?

Thanks in advance for any feedback!

2011-01-12 14:24:08,160 ERROR [STDERR] (main:) 12.01.2011 14:24:08 liquibase.database.template.JdbcTemplate comment
INFO: Lock Database
2011-01-12 14:24:08,181 ERROR [STDERR] (main:) 12.01.2011 14:24:08 liquibase.lock.LockHandler acquireLock
INFO: Successfully acquired change log lock
2011-01-12 14:24:08,242 ERROR [STDERR] (main:) 12.01.2011 14:24:08 liquibase.database.AbstractDatabase getRanChangeSetList
INFO: Reading from DATABASECHANGELOG
2011-01-12 14:24:08,260 ERROR [STDERR] (main:) 12.01.2011 14:24:08 liquibase.database.template.JdbcTemplate comment
INFO: Release Database Lock
2011-01-12 14:24:08,263 ERROR [STDERR] (main:) 12.01.2011 14:24:08 liquibase.lock.LockHandler releaseLock
INFO: Successfully released change log lock

Unfortunately, it is not configurable in 1.9, but it is in 2.0.  With 2.0, the logging system is pluggable you so can better integrate it with your logging system.

Nathan

Nice - thanks for the quick reply!

What logger do you use?


There are extensions for various loggers in maven central (JUL, SLF4J, etc) and at the Liquibase extension portal. I believe all you need to do is stick the jar on your classpath and the new logger overrides the default logger.

I’am using org.liquibase:liquibase-core:2.0.3. It’s still use System.err to print logs.

Can I configure it or set my own logger implementation?