IT. Expert System.

Java Standard Edition (SE)

Tracing and Logging


Tracing and Logging

Java Rich Internet Applications Guide > Java Control Panel > Tracing and Logging

The following topics are covered:

Tracing

Tracing is a facility to redirect any output in the Java Console to a trace file.

Tracing for Java Plug-in and Java Web Start can be turned on by setting the property deployment.trace property to true. This property turns on all tracing facilities inside Java Plug-in and Java Web Start. To enable more fine-grained tracing, the deployment.trace.level property can be used. The deployment.trace.level property can have one of the following values:

  • basic
  • cache
  • net
  • security
  • ext
  • liveconnect
  • drs

To use all of the tracing levels, set deployment.trace.level to all.

To enable tracing on the fly, you can set trace-level options (0-5) in the Java Console, shown in the previous chapter, with the following meanings:

  • 0: off
  • 1: basic
  • 2: network, cache, and basic
  • 3: security, network and basic
  • 4: extension, security, network and basic
  • 5: LiveConnect, extension, security, network, temp, basic, and Deployment Rule Set

Another way to set fine-grained tracing is through the Java Control Panel. For instance, to enable tracing for everthing (option 5 above), enter the following in the "Java Run Time Parameters" textfield:

-Ddeployment.trace=true
-Ddeployment.trace.level=all

Tracing set through the Control Panel takes effect when Java Plug-in or Java Web Start is launched, but changes made through the Control Panel while Java Plug-in or Java Web Start is running has no effect until restarted.

Logging

Similar to tracing, logging is a facility to redirect any output in the Java Console to a log file using the Java Logging API. To enable logging perform the following actions:

  • Open Java Control Panel
  • Click Advanced tab.
  • Select Enable Logging under the Debugging option

Other Options

File Names

  • plugin<random-number>.trace - Name of the trace file for Java Plug-in.
  • plugin<random-number>.log - Name of the log file for Java Plug-in.
  • javaws<random-number>.trace - Name fo the trace file for Java Web Start.
  • javaws<random-number>.log - Name of the log file for Java Web Start.
  • jcp.trace - Name of the trace file that is created when the Java Control Panel is run.

<random-number> is a number that is generated when the file is created.

File Locations

The default location (directory) of the trace and log files is:

  • <user.home>/.java/deployment/log on UNIX, Linux
  • ~/Library/Application Support/Oracle/Java/Deployment/log on Mac OS X
  • <User Application Data Folder>\Sun\Java\Deployment\log on Windows

If the environment variable USER_JPI_PROFILE is set to <user plugin home> then the trace and log files will be written to:

  • <user plugin home>/.java/deployment/log on UNIX, Linux
  • <user plugin home>/Library/Application Support/Oracle/Java/Deployment/log on Mac OS X
  • <user plugin home>\Sun\Java\Deployment\log on Windows


Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 46 / 158770663. Delta: 0.02012 с