cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gary Tully (JIRA)" <>
Subject [jira] Created: (CXF-1192) Jsr250BeanPostProcessor, non reentrant ResourceInjector results in IllegalArgumentException
Date Fri, 09 Nov 2007 11:59:50 GMT
Jsr250BeanPostProcessor, non reentrant ResourceInjector results in IllegalArgumentException

                 Key: CXF-1192
             Project: CXF
          Issue Type: Bug
          Components: Core
    Affects Versions: 2.0.3
            Reporter: Gary Tully
            Priority: Minor

The Jsr250BeanPostProcessor[1], uses a single instance of the  non reentrant ResourceInjector.
If the bean has two postConstruct methods and the first results in another bean creation which
has a postConstruct method we have trouble. For a postConstruct method, the ResourceInjector
sets a Target reference member variable and invokes the method. If the postConstrcut method
results in another bean being created that has a postConstrcut annotation the single ResourceInjector
gets it's target reference changed and the result is an IllegalArgumentException on calling
a subsequent postConstruct method.

The simplest fix is to have the Jsr250BeanPostProcessor use a new ResourceInjector for every

The scenario that showed this bug has been worked around so I don't have an easy test case
but one can be fabricated around the spring tests in core by following the description and
adding the  Jsr250BeanPostProcessor to the configuration.


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

View raw message