James,
have a look at Log4J ( http://jakarta.apache.org/log4j/ ), it is a very
effective logging package that includes a JDBCAppender for logging to a
database. Similar in concept/design as the 1.4 logging package, but more
mature and will work with pre-1.4 JVMs.
Log4j layouts have various attributes that you can pull from the machines
environment, and can be easily extended to include items like machine name
see (http://www.ingrid.org/jajakarta/log4j/jakarta-log4j-1.1.3
/docs/deepExtension.html ).
Ciao,
Nik
Nickolas Kwiatkowski
IT Architect
AMS Solutions Enablement (ASE)
Application Management Services
IBM Global Services Australia
phone: 07 3887 6304, mobile: 0412 121 276, email: [EMAIL PROTECTED]
"In the middle of difficulty lies opportunity" - Albert Einstein
Greg Nudelman
<[EMAIL PROTECTED] To: "jdjlist" <[EMAIL
PROTECTED]>
x.com> cc:
Subject: [jdjlist] RE: Logging to a
Database
06/09/2003 04:03
AM
Please respond to
"jdjlist"
Dear James,
1) Why not just use plain JDBC? you will need a special recording DB schema
if you're serious. I would suggest using a star-schema arrangement that
allows you to calculate transaction speed, track entry on the per-item
basis, and make all kinds of useful reports ("How long did it take on
average to ship items this month when John Doe is the shipping clerk on
duty?")
See more articles on that type of schema on intelligententreprise.com. They
have a wealth of info in the "Articles" section.
Alternatively, just use a single table with a 255 "context" column, and
maybe CLOB/BLOB column to hold transaction-related XML/binary files. But
that is much less flexible, more for just record-keeping. This is what we
have, but it's hard to do reports with this arrangement.
2) Specify each machine with a unique name in some sort of a config file on
each machine. 1.4 has great Properties support, so you can use that class
to read it at start up time.
Greg
-----Original Message-----
From: James Stauffer [mailto:[EMAIL PROTECTED]
Sent: Friday, September 05, 2003 10:33 AM
To: jdjlist
Subject: [jdjlist] RE: Logging to a Database
Also it doesn't look like the 1.4 logging has a good way to record
the machine. We have 10 load-balanced servlet engines and I would
also like to record the machine. Ideas?
James Stauffer
-----Original Message-----
From: James Stauffer [mailto:[EMAIL PROTECTED]
Sent: Friday, September 05, 2003 12:24 PM
To: jdjlist
Subject: [jdjlist] Logging to a Database
Does anyone have suggestions for logging to a database? Is
java.util.logging.SocketHandler the best way? What would be used to
read on the other side? Can I set it up to normally log to the
Database and if that errors use FileHandler?
James Stauffer
---
You are currently subscribed to jdjlist as: [EMAIL PROTECTED]
To unsubscribe send a blank email to
[EMAIL PROTECTED]
http://www.sys-con.com/fusetalk ---
You are currently subscribed to jdjlist as: [EMAIL PROTECTED]
To unsubscribe send a blank email to
[EMAIL PROTECTED]
http://www.sys-con.com/fusetalk
---
You are currently subscribed to jdjlist as: [EMAIL PROTECTED]
To unsubscribe send a blank email to
[EMAIL PROTECTED]
http://www.sys-con.com/fusetalk
---
You are currently subscribed to jdjlist as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]
http://www.sys-con.com/fusetalk