You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by Behrooz Nobakht <no...@gmail.com> on 2015/01/05 12:01:05 UTC

API to read a log file to a Collection of LogEvent?

Hi,

For example, I have an audit log file with certain structure (pattern
layout).
I want to replay the log that can be turned into certain domain objects.
I am interested to read the log file knowing the pattern layout
into a Collection or Stream of LogEvent using Apache Log4j 2?

I understand that LogEvent may be an overkill for such purpose and
potentially
simple string processing per line would do the job. Just want to make sure
we can take advantage of an existing API if any.

Thanks,
Behrooz