3 Replies Latest reply on Aug 31, 2006 9:07 AM by Scott Huffman

    Seam Remoting in 1.0.1

    Scott Huffman Newbie

      I had two Ajax calls working with jboss-seam-1.0.0.GA.

      I downloaded the latest from cvs today jboss-seam-1.0.1.GA and now I'm getting:

      2006-08-30 11:05:49,406 DEBUG [org.jboss.seam.contexts.Lifecycle] >>> Begin web request
      2006-08-30 11:05:49,406 DEBUG [org.jboss.seam.Component] seam component not found: org.jboss.seam.security.authenticator
      2006-08-30 11:05:49,406 ERROR [org.jboss.seam.servlet.SeamServletFilter] Error
      java.lang.RuntimeException: Type cannot be determined for component [Component(showFilterAction)]. Please ensure that it has a local interface.
       at org.jboss.seam.remoting.InterfaceGenerator.appendComponentSource(InterfaceGenerator.java:281)
       at org.jboss.seam.remoting.InterfaceGenerator.generateComponentInterface(InterfaceGenerator.java:127)
       at org.jboss.seam.remoting.InterfaceGenerator.handle(InterfaceGenerator.java:97)
       at org.jboss.seam.remoting.SeamRemotingServlet.doPost(SeamRemotingServlet.java:76)
       at org.jboss.seam.remoting.SeamRemotingServlet.doGet(SeamRemotingServlet.java:62)
       at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
       at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:45)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
       at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
       at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
       at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
       at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
       at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
       at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
       at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
       at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
       at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
       at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
       at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
       at java.lang.Thread.run(Thread.java:595)
      2006-08-30 11:05:49,416 DEBUG [org.jboss.seam.util.Naming] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
      2006-08-30 11:05:49,416 DEBUG [org.jboss.seam.servlet.SeamExceptionFilter] ended request


      Did something change with remoting in 1.0.1.GA?

        • 1. Re: Seam Remoting in 1.0.1
          Scott Huffman Newbie

          Should have included this earlier. Here's what my code looks like. Again, this worked with jboss-seam-1.0.0.GA.

          Javascript in the web page

          Seam.Component.getInstance("showFilterAction").getFilterList(reportID, displayCorrectFiltersCallback);


          Local Interface
          @Local
          public interface ShowFilterLocal {
           @WebRemote
           public String getFilterList(String id);
          }


          Action class
          @Stateless
          @Name("showFilterAction")
          @Interceptors(SeamInterceptor.class)
          public class ShowFilterAction implements ShowFilterLocal {
          
           public String getFilterList(String id)
           {
           StringBuffer out = new StringBuffer();
           // do some stuff
           return out.toString();
           }
          }
          
          


          • 2. Re: Seam Remoting in 1.0.1
            Shane Bryzak Master

            Your code all looks good. Any chance you can set a breakpoint in the for-loop just before the exception is thrown, or send me a code sample? The only thing I can think of is that component.getBusinessInterfaces() is not including the local interface for your component, but I highly doubt that.

            • 3. Re: Seam Remoting in 1.0.1
              Scott Huffman Newbie

              You can test it using examples.remoting.helloworld bundled within the seam distribution. Simply use jboss-seam.jar from 1.0.1.GA.

              I'd post my project here but there's no file upload capability.

              The error occurs as soon as I access the page.