...
Code Block | ||||
---|---|---|---|---|
| ||||
<camelContext id="camel" xmlns="http://camel.apache.org/schema/spring"> <jmxAgent id="agent" statisticsLevel="RoutesOnly"/> ... </camelContext> |
Hiding sensitive information
Available as of Camel 2.12
By default Camel enlist MBeans in JMX such as endpoints configured using URIs. In these configuration there may be sensitive information such as passwords.
These information can be hidden by enabling the sanitize option as shown below:
Using Java DSL you turn this on by:
Code Block |
---|
// only enable routes when Camel starts
context.getManagementStrategy().getManagementAgent().setSanitize(true);
|
And from Spring DSL you do:
Code Block | ||||
---|---|---|---|---|
| ||||
<camelContext id="camel" xmlns="http://camel.apache.org/schema/spring">
<jmxAgent id="agent" sanitize="true"/>
...
</camelContext>
|
This will mask URIs having options such as password and passphrase, and use xxxxxx
as the replacement value.
Info |
---|
Setting sanitize=true will only mask password and passphrase configured in URIs. If any custom Camel Component exposes custom JMX attributes then these attributes is shown as is. |