Ganymede is an Eclipse plug-in that allows log4j messages to be displayed within a view. This view can be used to quickly and easily view and filter logging messages. The plug-in captures the log messages on a socket and displays them in a view that can be docked or hidden in a fast-view.
To access the update site for the Ganymede project create an update site for Ganymede and provide it the url: http://ganymede.sf.net/update .
Ganymede listens on a socket for log4j SocketAppenders. To use Ganymede you must have your log4j environment set up to append to such a SocketAppender. Ganymede listens by default on port 4445, so it is easiest to add a socket appender to your log4j configuration to write to 4445, but you may also change the port in the Ganymede preferences if you wish. Below are examples of appender stanzas.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
<appender name="Ganymede" class="org.apache.log4j.net.SocketAppender">
<param name="remoteHost" value="localhost"/>
<param name="port" value="4445"/>
<param name="locationInfo" value="true"/>
</appender>
<root>
<priority value="debug"/>
<appender-ref ref="Ganymede"/>
</root>
</log4j:configuration>
log4j.rootCategory=DEBUG, Ganymede
log4j.appender.Ganymede=org.apache.log4j.net.SocketAppender
log4j.appender.Ganymede.remoteHost=localhost
log4j.appender.Ganymede.port=4445
log4j.appender.Ganymede.locationInfo=true
Ganymede is a socket listener, and as such, is not something that can or should run automatically, although there is an outstanding request to have it start automatically. Currently it must be told to begin listening. To start and stop the socket listener, use the running man icons or the pull down menu. Ganymede must be started before it will begin to recieve logs.
Ganymede also has the ability to pull up more detail for a given
message. This is especially useful when there are associated
stack traces or long formatted debug messages. You can pull up a
message detail pop-up by double clicking on the pertanent
message. A message detail can look like the following:
The easiest, and by far the
most
powerful, way to use filters is to use the quick filter option.
The quick filter option will investigate all possible message fields for that
text string and only show you entries that include that string.
It will even inspect fields which you do not display. Hitting
"Ok" will refresh your table view with the appropriate entries.
Basic Filtering is done simply by double clicking on the text "No Filter" or the three arrows from the view:
Which brings up the dialog:
Ganymede includes the ability to set up complex filter rules, although there is no support yet to save these off. The easiest, and by far the most powerful, way to use filters is to use the quick filter option.
In order to create an advanced filter setup, go into the Ganymede
preferences, Filters:
You may then add and includes
or an excludes case to each
possible field in the Log message. For example: