How do I configure Hibernate to use standard logging ?
Articles I read say to put the logging framework on your classpath, but I want to to just use the standard that comes with java so that doesnt make sense to be programtically.
Im trying to log SQL so in my code (before I use Hibernate) I have
Logger hibernateLogger = Logger.getLogger("org.hibernate.SQL");
hibernateLogger.setLevel(Level.ALL);
and attach my console handler that I use for my other debugging
ConsoleHandler ch = new ConsoleHandler();
ch.setFormatter(new com.jthink.songkong.logging.LogFormatter());
ch.setLevel(Level.FINEST);
MainWindow.logger.addHandler(ch);
hibernateLogger.addHandler(ch);
but It has no effect, no Hibernate logging gets written to the console.
So I assume the problem is defaulting to log4 or something, but I dont see how to change this behaviour. I include Hibernate as part of my application with maven (pom.xml), and I want to programtically select standard logging if possible.