Injecting a reference to a bean which is of a final class fails
---------------------------------------------------------------

                 Key: WICKET-603
                 URL: https://issues.apache.org/jira/browse/WICKET-603
             Project: Wicket
          Issue Type: Bug
          Components: wicket-spring
    Affects Versions: 1.2.6
            Reporter: Matthijs Wensveen


When using the @SpringBean annotation, injecting a bean that is of a final 
class such as String, fails. This is because LazyInitProxyFactory tries to 
create a subclass of the bean which will obviously fail when that class is 
marked final.

A possible fix would be to test the modifiers of the injected field for 
Modifier.isFinal(..), when this is true don't create a proxy but return the 
object directly.

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

Reply via email to