Reputation: 23
The websphere 7 only supports Java EE 5, but JSF2 is contained in Java EE 6, is there any tricks to implement @EJB annotation in ManagedBean?
Upvotes: 2
Views: 970
Reputation: 48
JSF2 can be in Java EE 5 as well. The reason why annotations do not work is about Websphere. See the following link for details: http://www.java.net/node/701374#comment-813807
This issue seems to be fixed in Websphere 7.0.0.19 : http://wasbehindtheglass.blogspot.co.uk/
Upvotes: 0
Reputation: 1109532
The @EJB
annotation is part of EJB 3.0 which is part of Java EE 5. It is not part of JSF 2.0 nor Java EE 6. It should work just fine on JSF 1.x managed beans in a Java EE 5 environment. The only difference with JSF 2.x managed beans in Java EE 6 is that you can't annotate JSF managed beans with @ManagedBean
, but have to register them in faces-config.xml
. That shouldn't make difference for the @EJB
annotation.
Upvotes: 1