-
Jun 17th, 2011, 02:44 PM
#1
Basic Logging Problems
I'm using tc Server 2.5 running within STS and I'm having some real trouble getting basic logging funcationality, can anyone help me get started with this?
For starters, I just want all log messages to go to a log file, but they don't appear to; they only seem to go to the console. I've search my entire springsource (tc Server + STS) and workspace directories, and cannot find any catalina.out or catalina.log file anywhere, after executing some requests in my app within tc Server.
Also, I want to enable logging of all messages (e.g. ALL or FINEST) from my app. I've put a local logging.properties file in my application classpath root (verified it's copied over to the tc app directory when published):
handlers = org.apache.juli.FileHandler, java.util.logging.ConsoleHandler
.level = FINEST
org.apache.juli.FileHandler.level = FINEST
org.apache.juli.FileHandler.directory = ${catalina.base}/logs
org.apache.juli.FileHandler.prefix = WsStub.
java.util.logging.ConsoleHandler.level = FINEST
java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
Out of frustration I've also tried changing all "FINE" and "INFO" level settings in $(catalina}/conf/logging.properties to "FINEST", as well as putting a generic ".level = FINEST" entry at the top. But none of this seems to make any difference.
When I run my app, as I'm stepping through it, I have a org.apache.commons.logging.Log.isDebugEnabled() test on a Logger, and stepping into, down into the java.util.logging Log class, I can see that the logger is configured at INFO level, not FINEST as I want. How do I get the loggers to be created with level FINEST?
It makes me wonder if the logging.properties file(s) that I'm modifying are even read by the server, but I don't know any simple way to determine this. Especially the properties file in my application, as this seems (according to the documentation I've been reading) to be a custom TC logging package that allow for app-level logging configuration in the container... is there any way I can confirm this is working at all?
Any help would be greatly appreciated, as I surely must be missing a few basic concepts here...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules