1 Reply Latest reply on Jul 24, 2011 10:25 PM by John Ament

    how it works ? @Stateful + @RequestedScoped on same bean

    Samuel Cheng Newbie

      I am studying CDI by reading through Weld - JSR-299 Reference Implementation on docs.jboss.org. There is a translator example on chapter 7. In the TranslatorControllerBean.java, there are 3 annotation: @Stateful
      @RequestScoped
      @Named(translator)


      How does @Stateful and @RequestScoped work on the same bean ? As I realized, Steteful session bean lives  for multiple requests until a method annotated @Remove is called, on the other hand,RequestScoped bean is instantiated for every request.