[
https://issues.apache.org/activemq/browse/CAMEL-267?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Claus Ibsen updated CAMEL-267:
------------------------------
Assignee: James Strachan
> Predicate cannot be used as BeanProcessor
> -----------------------------------------
>
> Key: CAMEL-267
> URL: https://issues.apache.org/activemq/browse/CAMEL-267
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-core
> Affects Versions: 1.3.0, 1.4.0
> Reporter: Aaron Crickenberger
> Assignee: James Strachan
> Priority: Minor
> Fix For: 1.4.0
>
> Attachments: PredicateAsBeanTest.java
>
>
> The current Bean Expression mechanism doesn't support the use of a Predicate
> as the Bean/POJO. The problem is that BeanInfo tries to use matches(Object)
> instead of matches(Exchange). If you use the extra "methodName" hint, this
> happens because BeanInfo uses operations.get(name), which will only return
> the most recently introspected method (potentially the Object one.) If you
> don't, then BeanInfo will try to find a method based on the inbound message
> body type, ignoring methods that take Exchange as a parameter.
> This may too esoteric to bother working around? It's relatively easy to
> workaround for the common case (match the incoming body), but it's still a
> little unexpected. The only thing I can see this preventing is the use of
> Predicates that are looking at multiple messages at once (eg: comparing delta
> between in & out messages in an exchange.)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.