[logback-dev] Question about LoggerContext.putProperty and putObject
Joern Huxhorn
jhuxhorn at googlemail.com
Fri Mar 13 18:59:58 CET 2009
Hi Ceki,
is there a similar way in case of AccessEvents? It seems like
AccessEvent does not have any information about something like a
LoggerContext - at least I couldn't find anything.
Joern.
Ceki Gulcu wrote:
>
> It is possible to set properties from a config file. This is
> documented at:
>
> http://logback.qos.ch/manual/configuration.html#variableSubstitution
> http://logback.qos.ch/manual/configuration.html#insertFromJNDI
>
> LoggerContext properties also survive serialization. However, in
> future releases I'd like to distinguish between "local" variables
> which do not survive serialization and "persistent" variables which do
> survive.
>
> You might also be interested to know that you can define your own
> parsing rules on the fly:
> http://logback.qos.ch/manual/configuration.html#insertFromJNDI
>
> HTH,
>
>
> Joern Huxhorn wrote:
>> Hi,
>>
>> I'd like to know if it's possible to set properties and/or objects of
>> the LoggerContext using a standard joran config file.
>>
>> At the moment, my own appender has a setApplicationIdentifier so I'm
>> able to easily identify different apps running on the same host.
>> Would it be possible to use the mentioned LoggerContext methods for
>> this?
>>
>> Joern.
>
More information about the logback-dev
mailing list