4 Replies Latest reply on Jun 22, 2009 7:30 AM by Bjoern Nebe

    Call WebService in EJB 3.0 (Differences to EJB 2.1)

    Bjoern Nebe Newbie

      Hi,
      I had an EJB 2.1 Bean containing a WebService-Method:

      /** @jboss.port-component name="WebServiceControllerService" uri="/VERSION-ejb/WebServiceController"
       * auth-method="BASIC" transport-guarantee="NONE"
       * @ejb.bean name="WebServiceController" display-name="WebServiceController" generate="true"
       * jndi-name="ejb/WebServiceController" local-jndi-name="ejb/WebServiceControllerLocal"
       * view-type="all" type="Stateless"
       *
       * @ejb.home generate="local,remote"
       *
       * @ejb.interface generate="local,remote,service-endpoint"
       * remote-class="de.cursor.jevi.server.web.WebServiceController"
       * local-class="de.cursor.jevi.server.web.WebServiceControllerLocal"
       * service-endpoint-class="de.cursor.jevi.server.web.WebServiceControllerService"
       */
      public class WebServiceControllerBean implements SessionBean
      {
       public String search(String xmlSearch)
       {
       }
      }


      I called this method using SOAPUI with the following URI:
      http://Nebelos-C2Q:18080/CARMEN-ejb/WebServiceController
      which is "MyServer" + "MyJar" + "MyWebServiceClassRemoteInterface".

      Now I migrated my class to EJB 3.0:

      @Stateless(name = "ejbWebServiceController")
      @TransactionManagement(TransactionManagementType.CONTAINER)
      @TransactionAttribute(TransactionAttributeType.SUPPORTS)
      @PermitAll
      @WebService
      @SOAPBinding(style = SOAPBinding.Style.RPC)
      @SecurityDomain(value = "VERSION")
      @Clustered(loadBalancePolicy = de.cursor.jboss.cluster.JBossLoadBalancer.class, partition = "DefaultPartition")
      public class WebServiceControllerBean implements WebServiceControllerLocal, WebServiceController
      {
       @WebMethod(operationName = "search")
       public String search(String xmlSearch)
       {
       }
      }


      My SOAP-UI call doesn't work any more telling me "The requested resource (/CARMEN-ejb/WebServiceController) is not available.". Can somebody tell me how the new uri would be or (better) how to get the old one?

      thanking you in anticipation