Erich Mauerböck created CAMEL-23662:
---------------------------------------
Summary: logMask of camel context not overridden in route
Key: CAMEL-23662
URL: https://issues.apache.org/jira/browse/CAMEL-23662
Project: Camel
Issue Type: Bug
Affects Versions: 4.20.0
Environment: Spring Boot 4
OpenJDK 21
Reporter: Erich Mauerböck
When registering a "CamelCustomLogMask" and using it by setting "logMask"
property to "true" on a camel context like so, log endpoints are masked as
expected:
{code:xml}
<camelContext xmlns="http://camel.apache.org/schema/spring" logMask="true">
...
</camelContext>{code}
When trying to override that setting on a specific route inside the camel
context by setting "logMask" to "false" there, there is no effect, logs are
still masked:
{code:xml}
<route id="my/route" streamCache="true" logMask="false">
...
<to
uri="log:com.company.my.out?level=INFO&showAll=true&showStreams=true&multiline=true"
/>
</route>
{code}
What actually DOES work is setting it as a query parameter on the endpoint
inside the route like so:
{code:xml}
<to
uri="log:com.company.my.out?level=INFO&showAll=true&showStreams=true&multiline=true&logMask=false"
/>{code}
I would expect the setting on the route overriding the global one of the camel
context.
see also [#camel > probable bug in log masking
configuration|https://camel.zulipchat.com/#narrow/channel/257298-camel/topic/probable.20bug.20in.20log.20masking.20configuration/with/599130635]
--
This message was sent by Atlassian Jira
(v8.20.10#820010)