3 Replies Latest reply on Jul 11, 2006 3:38 AM by warren crossing

    session bean access with soap

    Rubén Lagar Newbie

      hello

      I have a session bean and want to generate
      a SOAP Web Service for this bean.

      I know that I have to write a webservices.xml file.
      is there any documentation on this ? what exactly to put in
      this file and what else is necessary to export a session bean (stateless)
      as a soap service ??

      a step by step tutorial would be great .

      thanks in advance

        • 1. Re: session bean access with soap
          Rubén Lagar Newbie

          I have found out that Axis has to be installed, and a .wsdd file has to be created.

          This is my file

          <deployment xmlns="http://xml.apache.org/axis/wsdd/" xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">












          I have executed

          java org.apache.axis.client.AdminClient webservice.wsdd

          And it seems that the WebService is created. But when I go to

          http://localhost:8080/axis/servlet/AxisServlet

          It says java.lang.ClassNotFoundException: com.redsoftsolutions.interactiveforms.ejb.control.ControlRemote

          This class has been deployed within a ear file.

          Does anybody know what I am doing wrong?

          Thanks!!

          • 2. Re: session bean access with soap
            warren crossing Newbie

            remember to package your remote with the client ie axis/WEB-INF/classes or in axis/WEB-INF/lib

            the wsdd should look like



















            <!--


            -->







            • 3. Re: session bean access with soap
              warren crossing Newbie

              remember to package your remote with the client ie axis/WEB-INF/classes or in axis/WEB-INF/lib

              the wsdd should look like

              service name="myendpoint" provider="java:EJB" style="rpc" use="encoded">
              parameter name="wsdlFile" value="name.wsdl"/>

              parameter name="wsdlTargetNamespace" value="urn:http://blah"/>
              parameter name="wsdlServiceElement" value="BlahInterfaceService"/>
              parameter name="wsdlServicePort" value="BlahEndpoint"/>
              parameter name="wsdlPortType" value="BlahInterface"/>
              parameter name="typeMappingVersion" value="1.2"/>
              parameter name="allowedMethods" value="*"/>

              parameter name="beanJndiName" value="Blah"/>
              parameter name="homeInterfaceName" value="blahRemoteHome"/>
              parameter name="remoteInterfaceName" value="BlahRemote"/>
              parameter name="localHomeInterfaceName" value="BlahLocalHome"/>
              parameter name="localInterfaceName" value="BlahLocal"/>
              parameter name="jndiContextClass" value="org.jboss.security.jndi.JndiLoginInitialContextFactory"/>

              parameter name="jndiURL" value="jnp://localhost:1099"/>
              <!--
              parameter name="jndiUser" value="admin"/>
              parameter name="jndiPassword" value="admin"/>
              -->
              requestFlow>
              handler type="session"/>
              /requestFlow>

              responseFlow>
              handler type="session"/>
              /responseFlow>
              /service>