jcabi-aspects icon indicating copy to clipboard operation
jcabi-aspects copied to clipboard

Make the corresponding SLF4J method for @Loggable chooseable

Open jondoe1337 opened this issue 9 years ago • 3 comments

Iam currently working on an own slf4j implementation where it would be useful to get, for example, the invocation time of a method produced by @Loggable in an argument that are passed over to the slf4j-api.

As far as i see, the LogHelper of jcabi invokes constantly the single String argument methods with the respective LogLevel of the slf4j-Logger.

My current workaround is to parse the string inside of the Logger implementation to check wether it contains the Log-Messages produced by @Loggable and transform it in my format.

jondoe1337 avatar May 30 '16 13:05 jondoe1337

@yegor256 please do something about this issue

dmarkov avatar Jun 03 '16 09:06 dmarkov

@jondoe1337 I see the problem, but how do you think we can do that? how can we make that method configurable? technically

yegor256 avatar Jun 22 '16 23:06 yegor256

How about doing Reflection with a given class/method String parameter that it set in the annotation @Loggable?

jondoe1337 avatar Jun 27 '16 13:06 jondoe1337