users@glassfish.java.net

Re: Logging in JSON

From: Alexander Schell <DealeyLama_at_gmx.de>
Date: Thu, 07 Nov 2013 20:17:10 +0100

Hello Oliver

It's a few years ago and I cannot remember quite exactly...
What kind of logging framework are you using? I used Log4J back then.

If I remember right, I didn't wrote a formatter; forget what I said
before... :)

I tried it, but then I put all the logic in a custom appender. This
appender created the json represantations as also sent them over a
message queue to mdbean on a glassfish application server...

I hope that I'll find the time to reimplement it. It was a nice - Well,
at least in my opinion - solution to log into a database, which enabled
me to use all the nice sql-stuff to seachr for entries.


Best regards

Alex


Am 06.11.2013 23:07, schrieb Oliver B. Fischer:
> Hello Alexander,
>
> I implemented a very simple formatter today. But the first message is
> still handled by the default formatter. I think it is because the setup
> of the formatter is done in the postConstruct() method of the
> GFFileHandler.
>
> Did you replace the default GFFileHandler or added additional handlers?
>
> Bye,
>
> Oliver
>
> Am 06.11.13 20:40, schrieb Alexander Schell:
>> Hello
>>
>> I did so, but unfortunately I do not own the code. And an MQ-Appender
>> also, so you can send your log entries to an application server to store
>> them in a database...
>>
>> It's not this difficult, really.
>>
>> Maybe I have a solution for you in a couple of days. I was thinking
>> about re-implementing this stuff... :)
>>
>>
>> Have a nice evening
>>
>> Alex
>>
>>
>> Am 06.11.2013 12:26, schrieb Oliver B. Fischer:
>>> Hi,
>>>
>>> has anyone of you written a log formatter for JSON? I would like to
>>> write the log records as JSON document.
>>>
>>> It would be nice not to do the same work twice ;-)
>>>
>>> Bye,
>>>
>>> Oliver
>>>
>>
>