Category has a method called l7dlog to help with parameterization and
localization. But it doesn't quite do what I would like it to do.
If I have a resource bundle that has the following entry
ERROR_101=some error in the system
then if I call
l7dlog(Priority.ERROR, ERROR_101, null);
the output would be
"some error in the system"
instead I would like it to print the error code along with the message,
something like
"ERROR_101: some error in the system"
I know of two solutions to this...
1. change the resource bundle entry to
ERROR_101=ERROR_101:some error in the system
but, this is erorr prone, since developers could always enter the wrong id
in the message.
2. Hack the Category class' l7dlog method to do customize it.
In this case, every upgrade to log4j, I need to change my Category class,
which could be a pain.
Are there any other solutions to this?
Help appreciated.
Thanks
Van
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]