At Wednesday, April 28, 2004 2:40 PM, Ceki G�lc� wrote:
>At 03:35 PM 4/27/2004, Danko Mannhaupt wrote:
>
>>I think that most users create their own custom logging table with custom
>>columns and types. It is sometimes even required to write custom log
>>objects, not just Strings, to the database. Consequently, IMHO the
appender
>>should offer flexibility and extensibility, at least to provide custom
>>column names.
>
>Hello Danko,
>
>Our knowledge on this area is lacking at best and your experience of the
>topic can be very valuable. Could you kindly describe why a user would need
>to have a custom logging table with custom columns and types?
Custom columns refer to particular column names. One reason could be
"enterprise standards" as pointed out before. Sometimes a DBAppender is used
to write trace information that requires column names such as "order_date",
"order_id". I do not think views are a solution as suggested before. Not
every database supports them.
>What can be
>the use of custom message types if no existing tool can display them?
With custom message type I mean for example:
- choose between db datatypes timestamp/date/varchar to store log time
- choose between char/varchar to store messages
In addition, some users want to log data for different columns, for example
/** custom log object class **/
class MyLogObject {public String att1; public String att2; ... }
// log statement
logger.info( new MyLogObject("aaa", "bbb"));
could result in
insert into my_log_table (att1, att2) values ('aaa', 'bbb');
May be that this is beyond the scope of the standard log4j package. I
understand the overall goal to maintain a simple, portable logging package
with similar functions on different platforms.
Danko
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]