I've now experimented with the changes to the logging system. 
Before submitting patches etc, may I just confirm that the proposed changes
are OK?

==

All relevant files (except LoggingManager.java) are changed as follows:

import org.apache.log.Hierarchy;
  becomes
import org.apache.jorphan.logging.LoggingManager;
(some files already include this line, in which case the original import
just needs to be deleted)

Hierarchy.getDefaultHierarchy().getLoggerFor( ...
 becomes
LoggingManager.getLoggerFor( ...

I was unable to work out how to find out the enclosing class name
automatically.
Unfortunately all the methods seem to rely on using "this", which is not
available for static initialisation.

So as a temporary (?) measure, I changed LoggingManager.getLoggerFor() to
ignore the parameter, and use a Throwable and StackTrackElement to retrieve
the calling class name.

This relies on Java 1.4, but that is currently documented as a requirement
for 1.8.
Hope that is OK - if not, there are (messier) ways to extract the caller
name from the stack.

It then became clear that the log records and jmeter.properties lines were
becoming rather verbose, so I decided to remove the "org.apache." prefix
from the class name.

The minimal jmeter.properties configuration is now:

log_level.jmeter=INFO
log_level.jorphan=INFO

log_file=jmeter.log

Any complaints/ further suggestions?

-- 
The opinions expressed herein are my own, and are not necessarily endorsed
by my employer ...

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to