I have a server application using CXF as a framework. I setup CXF via Spring, just by XML files, without any Java code.
I would like to log some internals of my server application to the application server's log file. Currently I do this just by calling System.out.println()
, but I would like to use a logging framework/library like java.util.logging
(since CXF already uses java.util.logging
).
What is the recommended way to do this? How can I configure my java.util.logging
Logger
? Is it possible to use the same logging.properties as CXF uses?
I currently receive my Logger
instance by calling Logger.getLogger(Server.class.getName())
. Is this a good way to do this?
I tried to search the Internet about this, but I can only find ways to enable logging of the CXF framework itself, but I want to use logging in my own code.