[
https://issues.apache.org/jira/browse/CAMEL-13116?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16751055#comment-16751055
]
Aniol Massana commented on CAMEL-13116:
---------------------------------------
I'll edit the documentation and the test case of this class.
The use case is exactly the one mentioned: selectivelly allow some filters to
be sent, not the other way arround as the current implementation does. A minor
change in the class makes it more flexible.
When you have large route which must do several actions in sequence, you end up
with many headers in the Exchange. It's easier to known which headers you want
to forward to the component rather than to know exactly which ones you select
to be filtered out.
In general terms, I find this use safer and more natural than the current one -
that's my current view, though..
> DefaultHeaderFilterStrategy match action configurable
> -----------------------------------------------------
>
> Key: CAMEL-13116
> URL: https://issues.apache.org/jira/browse/CAMEL-13116
> Project: Camel
> Issue Type: Improvement
> Components: camel-core
> Reporter: Aniol Massana
> Priority: Minor
> Labels: pull-request-available
>
> The Exchange headers are sent to target systems in some components such as
> JMS (as JMS message headers), HTTP (as HTTP headers).
> In order to send only some of the existing Exchange headers, without removing
> the undesired ones so they are available later on on the route, a filter
> strategy kicks in.
> The current implementation of the DefaultHeaderFilterStrategy class match
> action removes the headers you configure, so is exactly the reverse of this
> use case.
> With this modification, you'd keep some headers and you'd avoid sending
> anything not matched, preventing any information to be leaked.
> The default value for this new setting keeps the current behaviour, so it
> should be safe to be introduced.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)