Cling Core logging

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Cling Core logging

Crosbie
Logging again: I hope I'm not asking the painfully obvious, but how do I get the Cling API to log all requests, incoming and outgoing?    Setting .level=FINEST in my logging properties file doesn't seem to have done anything, but I can see plenty of log.finest statements in the source,at least in trunk.

I'm trying to get a media server to log incoming requests from my Roku Soundbridge.
Reply | Threaded
Open this post in threaded view
|

Re: Cling Core logging

Christian Bauer
Administrator
I'm assuming you are using trunk (beta3) of the workbench. Your -Djava.util.logging.config.file=logging.properties startup option will be ignored in beta2 and you'd indeed see no change at all.

This logging.properties file will set the startup log level to FINEST for all of Cling:

.level=INFO
org.teleal.cling.level=FINEST

You will see the log output in the Workbench log monitor, in the GUI.

This logging.properties file will set the startup log level to FINEST and also output the log on the command-line (System.out):

handlers=org.teleal.common.logging.SystemOutLoggingHandler
.level=INFO
org.teleal.cling.level=FINEST
Reply | Threaded
Open this post in threaded view
|

Re: Cling Core logging

Crosbie
This was specifically about getting log information from the Cling Core API, not from the workbench.  I'm trying to see detailed messages on the action requests hitting my own test server, not the workbench.

Having said that, I think I need to go to somewhere with air conditioning, so I may have misunderstood your response.   I'll try to make sure I have everything set up correctly.  Thank-you for the reply.

- Crosbie

Reply | Threaded
Open this post in threaded view
|

Re: Cling Core logging

Christian Bauer
Administrator
Cling Core uses plain java.util.logging, no extra configuration, handlers, wrappers, etc. That means you will see INFO level messages by default, printed over two lines on System.out for each message. This is the Sun JDK default behavior.

Cling Core generates some INFO messages on startup and shutdown. If you do not even see those messages without any extra logging configuration, something else on your machine is wrong.  So any documentation you will find on how to configure JUL is applicable. You can use my teleal-common handler for System.out if you want one line per message.