You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@karaf.apache.org by "Markus Rathgeb (JIRA)" <ji...@apache.org> on 2019/07/08 14:46:00 UTC
[jira] [Commented] (KARAF-6355) improve usage for "log collector" +
"mail alerter" usecases
[ https://issues.apache.org/jira/browse/KARAF-6355?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16880425#comment-16880425 ]
Markus Rathgeb commented on KARAF-6355:
---------------------------------------
For me a usecase would be, create an alert / sent email for:
* log message level is WARN or ERROR
* log message contains the word (case insensitive): stacktrace
* log message contains the word (case insensitive): exception
and as the log message properties already contain the fields loc.class, loc.method, loc.line, I would like to be able to filter special log message that should not be alerted fore (so, the above list is a logic or and the loc properties would be used for an exclusion).
> improve usage for "log collector" + "mail alerter" usecases
> -----------------------------------------------------------
>
> Key: KARAF-6355
> URL: https://issues.apache.org/jira/browse/KARAF-6355
> Project: Karaf
> Issue Type: Bug
> Components: decanter
> Affects Versions: decanter-2.2.0
> Reporter: Markus Rathgeb
> Assignee: Jean-Baptiste Onofré
> Priority: Major
> Fix For: decanter-2.3.0
>
>
> If you would like to be informed per mail about special log events (e.g. log level warn) the current implementation does not work as (perhaps) expected.
> Assume you would like to be informed about every log message of level WARN.
> The current implementation will notify you about the first log message of level WARN and the next alert that is triggered is for a log message not using the WARN level.
> I would like to be informed about every WARN log message and not about any other (so not loosing multiple WARN messages that are followed immediately and not informed about a log message that is not WARN).
> Another improvement would about the combination of multiple patterns.
> E.g. keep me informed about
> type = log
> priority = WARN | ERROR
> not ( loc.class = Foo.class & loc.method = magic)
>
> Perhaps we could reuse [https://osgi.org/javadoc/r2/org/osgi/framework/Filter.html]
> log.warn.filter = "(&((|(priority=WARN)(priority=ERROR))(loc.class=Foo.class)(loc.method=magic)))"
> (do not assume the filter above is correct)
>
> Perhaps we could already reuse the current implementation and its match method.
> Just need to think about substring matching...
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)