The Artima Developer Community
Sponsored Link

Java Answers Forum
Java Logging API

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
razneesh

Posts: 1
Nickname: raz
Registered: Jul, 2003

Java Logging API Posted: Jul 21, 2003 11:52 AM
Reply to this message Reply
Advertisement
Hi All,

My logger out put is getting appended every time i run my application through a java scheduler ( TimerTask).This would fine if i call my app thru a main method .
Please find the details below...

1. scheduler{
.....
.....
private static Logger theLog = Logger.getLogger("test");
fileHandler = new FileHandler("testlog%g", 30000, 3,false);
timer = new Timer();
testTimeTask = new TestTimeTask();
timer.scheduleAtFixedRate(testTimeTask,startNow,3mins);
}

2.TestTimeTask extends TimerTask {
....
....
MyApp app = new MyApp();
......
}

3.MyApp{
private static Logger theLog = Logger.getLogger("test");
........
.........
}

Above code suppose to rotate the log output between 3 log files with no append. It is not happening instead output is getting appended to file "testLog0.log" .



raz

Topic: enable disable JFrame Previous Topic   Next Topic Topic: What is the significance of Primary key class in Entity bean?

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use