Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] Redirect/Copy Jetty 9 Commandline output to file

The default Jetty logging implementation writes to STDERR (aka System.err) via the StdErrLog implementation.

You have 3 choices.

1) Do nothing, and be happy with the default. :-)
2) Enable the options for stderr/stdout redirection logging found in the ${jetty.home}/start.ini (just uncomment the the appropriate lines)
3) Use a 3rd party logging framework and configure your logging output in that frameworks perferred way.
 a) like log4j
 b) or java.util.logging built into the JVM
 c) or everything logging framework that can produce logging and is supported by slf4j .

If you use any 3rd party libraries, then option #3c will be your best choice.
If you are going to use JSP then option #3b and #3c are good choices
If you are going to be simple and use servlets you've created and don't really care do much, then option #2 is probably sufficient.


--
Joakim Erdfelt <joakim@xxxxxxxxxxx>
Developer advice, services and support
from the Jetty & CometD experts


On Wed, May 29, 2013 at 10:10 AM, O. Olson <olson_ot@xxxxxxxxx> wrote:
Hi,
 
I am new to Jetty and I just downloaded Jetty 9 for Windows.
I start it simply on the command line using:
 
java -jar start.jar
 
Do the logging messages I see on the command line also get directed
to a file? I don’t see anything in the logs subdirectory. If no, is there
someway I can send a copy of these log messages that appear on the commandline
to a file? I am sure it must be some setting, but I have no clue where to
start.
 
I looked at http://www.eclipse.org/jetty/documentation/current/configuring-logging.html and it seems to be more about the logging level (warn, info, debug etc. )
rather than where to redirect/copy the logging messages.
 
Thank you for your help.
O. O.
_______________________________________________
jetty-users mailing list
jetty-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jetty-users


Back to the top