Camel Log - Karaf

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Camel Log - Karaf

ychawla
Hello All,
I have a log statement in a camel route that is at the DEBUG loggingLevel:

<camel:log message="This is the ${body}" loggingLevel="DEBUG"/>

From the karaf console, how can I set the logging level for the camel context?

I know that I can run a karaf command like this to set the logging level for a java package:

log:set DEBUG org.packagename.here

However, I am not sure what to use for the package name for a camel route or camel context.  Any ideas on how I can change the logging level for a camel route?

Thanks,
Yogesh
Reply | Threaded
Open this post in threaded view
|

RE: Camel Log - Karaf

shuston
Try log:set DEBUG


> -----Original Message-----
> From: ychawla [mailto:[hidden email]]
> Sent: Thursday, October 20, 2016 11:34 AM
> To: [hidden email]
> Subject: Camel Log - Karaf
>
> Hello All,
> I have a log statement in a camel route that is at the DEBUG loggingLevel:
>
> <camel:log message="This is the ${body}" loggingLevel="DEBUG"/>
>
> From the karaf console, how can I set the logging level for the camel context?
>
> I know that I can run a karaf command like this to set the logging level for a
> java package:
>
> log:set DEBUG org.packagename.here
>
> However, I am not sure what to use for the package name for a camel route
> or camel context.  Any ideas on how I can change the logging level for a camel
> route?
>
> Thanks,
> Yogesh
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Camel-
> Log-Karaf-tp5789034.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
Reply | Threaded
Open this post in threaded view
|

RE: Camel Log - Karaf

ychawla
Hi Shuston,
I can do log:set DEBUG but then I log everything.  I have a file endpoint that I poll from and that generates too much logging for it to be useful.  Is there a way to isolate it to the route or context level?

Thanks,
Yogesh
Reply | Threaded
Open this post in threaded view
|

RE: Camel Log - Karaf

shuston
I'm only guessing sort of, but try the camel context id.

You could get a more definitive answer by letting it log DEBUG everything, find the lines you want from your route(s) and note the name they're logged under, then just use that.

-Steve

> -----Original Message-----
> From: ychawla [mailto:[hidden email]]
> Sent: Thursday, October 20, 2016 2:09 PM
> To: [hidden email]
> Subject: RE: Camel Log - Karaf
>
> Hi Shuston,
> I can do log:set DEBUG but then I log everything.  I have a file endpoint that I
> poll from and that generates too much logging for it to be useful.
> Is there a way to isolate it to the route or context level?
>
> Thanks,
> Yogesh
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Camel-
> Log-Karaf-tp5789034p5789046.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
Reply | Threaded
Open this post in threaded view
|

Re: Camel Log - Karaf

Claus Ibsen-2
In reply to this post by ychawla
Camel uses the id of the route as the logger name by default. If you
want to use a different name you can specify the logger name in the
<log>

On Thu, Oct 20, 2016 at 8:08 PM, ychawla <[hidden email]> wrote:

> Hi Shuston,
> I can do log:set DEBUG but then I log everything.  I have a file endpoint
> that I poll from and that generates too much logging for it to be useful.
> Is there a way to isolate it to the route or context level?
>
> Thanks,
> Yogesh
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/Camel-Log-Karaf-tp5789034p5789046.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2