servicemix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ioannis Canellos (JIRA)" <>
Subject [jira] Updated: (SMXCOMP-789) Bean Endpoint does not properly handle CGLIB enhanced beans (Crosscutting issue)
Date Thu, 12 Aug 2010 11:20:48 GMT


Ioannis Canellos updated SMXCOMP-789:

    Attachment: cglib-bean-issue.txt

The patch can be applied in the trunk of the bean endpoint.

This patch adds a test case of a bean endpoint that is passed a @Transactional annotated MessageExhcangeListener.
The endpoint is properly initialized, but when a message is sent to the endpoint it results
in NPE due to the fact that the DeliveryChannel is not properly injected to the bean.

> Bean Endpoint does not properly handle CGLIB enhanced beans (Crosscutting issue)
> --------------------------------------------------------------------------------
>                 Key: SMXCOMP-789
>                 URL:
>             Project: ServiceMix Components
>          Issue Type: Bug
>          Components: servicemix-bean
>    Affects Versions: servicemix-bean-2008.01, servicemix-bean-2009.01, servicemix-bean-2009.02,
>            Reporter: Ioannis Canellos
>         Attachments: cglib-bean-issue.txt
> If I pass to the bean endpoint a bean that is enhanced by cglib (e.g. a bean annotated
with spring's @Transactional annotation), then the Delivery Channel is not properly injected
to the bean.
> After digging a lot I realized that the root of the problem is in the combination of
CGLIB & Reflection, which can cause tons of issues and apparently that have not been taken
into consideration on the bean endpoint. 
> This issue probably affects other service mix components too (I've also encountered similar
behavior in camel). I think that either a global solution needs to be applied or a section
needs to be added in the documentation.
> I am attaching a patch that contains a unit test that reproduces this issue.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message