gkopff / logback-raygun

A logback appender that emits details to raygun.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Make stack for log without an exception configurable

connec opened this issue · comments

We are using logback-raygun in an Akka project. Akka provides a logging interface that wraps SLF4J, meaning that calling log in an akka project results in stack traces containing only the SLF4J call from inside Akka. For us this looks like:

akka.event.slf4j.Slf4jLogger$$anonfun$receive$1$$anonfun$applyOrElse$2.apply$mcV$sp in Slf4jLogger.scala:71

It would be good if there was some means to configure RaygunAppender.locateCallSite, either to return the full stack trace or to alter the filters. This is non-urgent for us just now so I've not started working on anything.

Do you think this would be useful? How would you like to see it implemented?

commented

Would it be sufficient, do you think, to add to the configuration a set of classname prefixes that simply also get examined in the for (StackTraceElement ... loop within locateCallSite()?

Class names (or prefixes) for all of the Akka logging glue code would have to be included in your configuration file - when we hit the first stack trace element that wasn't flagged, we'd declare that the call site ...

Effectively, instead of the static if statements for FBI and LOGBACK, we iterate over the set of (FBI, LOGBACK, custom).

I'm going to close this to clear it from my context. Clearly there's not a demand for it!