camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Valeri (JIRA)" <>
Subject [jira] [Commented] (CAMEL-5310) Add more logging when using SSLContextConfiguration
Date Thu, 21 Jun 2012 14:26:42 GMT


David Valeri commented on CAMEL-5310:

The INFO log event will trigger once for each created SSLContext, which is typically once
per instance of the SSLContextParameters in your code / Spring XML.


For the ifXxxEnabled.  This is an unnecessary optimization in many cases when using token
replacement instead of string concat in the log statement.  I did a quick test and the if
statement saves 0.000208ms per invocation on average (tested over 100 million iterations).
 It also looks like the majority of that time difference is due to the method calls to the
SSLContext or SSLEngine and not in the array allocation or GC.  There is less GC when using
the ifXXXEnabled statements, but the performance impact appears largely negligible.  For cases
where the log arguments going into the array are cheap to calculate, I would save yourself
the typing unless you are looking to squeeze out every last fractional millisecond of performance.

I've put the ifXxxEnabled statements on the log statements that have expensive argument calculations
and occur at high frequency in regular use.
> Add more logging when using SSLContextConfiguration
> ---------------------------------------------------
>                 Key: CAMEL-5310
>                 URL:
>             Project: Camel
>          Issue Type: Improvement
>          Components: camel-core
>            Reporter: Claus Ibsen
>            Assignee: David Valeri
>             Fix For: 2.11
> When using SSL it can be a bit pain to see what chipters, protocols, algorithms, and
whatnot is available in the JVM. This can be different from SUN, Oracle, IBM, OpenJDK etc.
Also between JDK versions as well.
> And if you have bouncycastle installed or not etc.
> We should add more logging details in the org.apache.camel.util.jsse classes so people
can better see whats in use.
> Also it would be nice with some option to turn on the configuration, that logs a nice
summary of all those details at INFO level. This makes it much easier to troubleshoot.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message