Your trace file will also contain info and above. From Peter's question I
understood him to mean he only wants events at that level. We don't have a
filter that does that specifically so I used two threshold filters to do it.
Ralph
On Apr 23, 2013, at 5:42 PM, Remko Popma wrote:
> I don't think the docs have an example yet. This one worked for me:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <configuration status="WARN">
> <appenders>
> <File name="InfoFile" fileName="level-info.log">
> <PatternLayout>
> <pattern>%d %-5p %c{1.} [%t] %m %ex%n</pattern>
> </PatternLayout>
> </File>
> <File name="TraceFile" fileName="level-trace.log">
> <PatternLayout>
> <pattern>%d %-5p %c{1.} [%t] %m %ex%n</pattern>
> </PatternLayout>
> </File>
> </appenders>
> <loggers>
> <root level="trace">
> <appender-ref ref="InfoFile" level="info" />
> <appender-ref ref="TraceFile"/>
> </root>
> </loggers>
> </configuration>
>
>
> Sent from my iPhone
>
> On 2013/04/24, at 9:22, Peter DePasquale <[email protected]> wrote:
>
>> Can you point me to an example in the documentation? I didn't see anything
>> like that in there, that I recall...
>>
>>
>> On Tue, Apr 23, 2013 at 6:28 PM, Ralph Goers
>> <[email protected]>wrote:
>>
>>> You cannot have two root loggers but you can have multiple appender-refs
>>> on them. Each appender-ref can have its own log level so I believe you get
>>> the same behavior that you are looking for.
>>>
>>> Ralph
>>>
>>> On Apr 23, 2013, at 12:37 PM, Peter DePasquale wrote:
>>>
>>>> Is it possible to use two root loggers, one to capture trace and one to
>>>> capture errors (or more generally, two different levels)? If so, can
>>>> someone please provide a simple config example? Thanks.
>>>>
>>>> --
>>>> Peter J. DePasquale, Ph.D.
>>>> Department of Computer Science
>>>> The College of New Jersey
>>>> (e) depasqua [at] tcnj [dot] edu
>>>> (p) 609-771-2806
>>>> (f) 609-637-5190
>>>> (o) Holman Hall - Room 238
>>>> (l) Holman Hall - Room 255
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: [email protected]
>>> For additional commands, e-mail: [email protected]
>>
>>
>> --
>> Peter J. DePasquale, Ph.D.
>> Department of Computer Science
>> The College of New Jersey
>> (e) depasqua [at] tcnj [dot] edu
>> (p) 609-771-2806
>> (f) 609-637-5190
>> (o) Holman Hall - Room 238
>> (l) Holman Hall - Room 255
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]