log configuration for existing application
I have to disable the log for the application that is at my han开发者_如何学Cds now. Application is composed of its own source and number of other components imported by means of jars, It uses hibernate, and when hibernate functionality executes, it prints everything to the console. Now, I think Log4J is in use there somehow, but only through commons-logging, that comes with hibernate distribution. I see no log4j.properties file anywhere. And there is no xml coniguration for hibernate that has loging settings. How can I disable the log output going to console, but keeping that going into file. I got this application to update it's build system, so technically I didn't introduce anything source code works with,- no new properties, no new setting. Just updated some build.xml and other xml files which are part of build process. I am told, that it wasn't directing output to the screen before. Could it be that I included some library that is not needed and that is causing this to happen?
Thanks fo t
Some libraries ship with their own log4j configuration, and that will clash with other libraries. This is specially true in AppServers environments. The only way I have found to override this behavior is to (re)configure log4j in my application.
精彩评论