• Post Reply Bookmark Topic Watch Topic
  • New Topic

Logs - System.err.println  RSS feed

 
Anand Gondhiya
Ranch Hand
Posts: 155
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ,

My current code (developed by Other developers) uses System.err.println(),System.err.print, System.out.println() and I can see all the statement going to Logs on production server.

however , on my local m/c , I see all these information on WSAD console. How do I set up my system so that I can redirect these info to go to Logs.

Thanks.
-Anand
 
Henry Wong
author
Sheriff
Posts: 23295
125
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
From Java, you can "redirect" standard out and error, with the System.setOut() and System.setErr() methods.

Henry
 
Leoo yu
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why you still use 'System.err.println(),System.err.print, System.out.println()' , use logger instend .
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!