Code example for LogManager

Methods: readConfiguration

0
  public static void main(String args[]) throws Exception {
    String tstSrc = System.getProperty("test.src");
    File   fname  = new File(tstSrc, "LoggingDeadlock3.props");
    String prop   = fname.getCanonicalPath();
    System.setProperty("java.util.logging.config.file", prop);
    logMgr.readConfiguration();
 
    Thread t1 = new Thread(new AddLogger());
    Thread t2 = new Thread(new GetLogger());
    t1.start(); t2.start();
    t1.join();  t2.join();
    out.println("\n" + MSG_PASSED);
  } 
 
  public static class MyLogger extends Logger {
    protected MyLogger(String name) { super(name, null); }
  } 
 
  public static class GetLogger implements Runnable {
    public void run() { 
      for (int cnt = 0; cnt < ITER_CNT * 8; cnt++) {