[slf4j-user] Regarding SLF4J API which takes messageFormat, arguments and exception instance. All the three, But!

Ceki Gülcü ceki at qos.ch
Thu Mar 26 12:28:03 CET 2015


Try

logger.debug( "I am message with {} and {}", "arg1", "arg2", new 
RuntimeException());

On 3/26/2015 12:18, Adax Adarsh wrote:
> Hi All,
> In the previous email I asked about SLF4J API at any logging level which
> takes all the three parameters.
>
> I was said to use, http://www.slf4j.org/faq.html#exception_message
>
> The above link shows an API which works happily when the scenario is as
> mentioned below,
>
> logger.debug("I am message with {}", "arg1", new RuntimeException());
>
> It do not handles scenario where messageFormat parameter takes more than
> one place holder, as shown below
>
> logger.debug( "I am message with {} and {}", new Object[]{"arg1",
> "arg2"}, new RuntimeException());
>
> Let me know your thoughts on how can we take it forward,
>
>
> Thanks,
> Adarsh
>
>
> _______________________________________________
> slf4j-user mailing list
> slf4j-user at qos.ch
> http://mailman.qos.ch/mailman/listinfo/slf4j-user
>


More information about the slf4j-user mailing list