1 Reply Latest reply on Sep 17, 2012 7:42 AM by rafaelri

    Seam3 Scala Bean problem

    rafaelri

      Hi all,

       

      I tried to change this example (http://blogs.sourceallies.com/2010/02/java-ee-6-and-scala/) and make it a single EJB bean referenced from directly from the view using Seam and I am getting an strange exception.

      Instead of trying to create the proxy directly from the class it is trying to create it from scala mark up interface resulting that the bean method is not found (since scala mark up interface does not contain any methods at all).

       

      Below is the important part from the stacktrace:

      javax.servlet.ServletException: javax.el.MethodNotFoundException: /listBooks.xhtml @13,62 action="#{bookController.createNew}": Method not found: Proxy for view class: scala.ScalaObject of EJB: BookController.createNew()

       

      I've also decompiled the Bean class generated from scala and in fact it has that createNew method that returns a string.

      It is also interesting to note that this example works when Weld is looking up it as a bean and not an EJB (as Seam is able to do).

       

      regards,

      Rafael