3 Replies Latest reply on Dec 3, 2009 7:37 AM by tiago galvao

    does not contain port: null

    gigsvoo Newbie

      Hi there,

      I am able to load 2 web services and can see the listing thru http://localhost:8080/ws4ee/services

      One out of the two web services is working perfectly but the 2nd ones give me this funny error:

      does not contain port: null


      Any ideas?

        • 1. Re: does not contain port: null
          gigsvoo Newbie

          anyone care to know what is this problem? i am stucked here.

          • 2. Re: does not contain port: null
            gigsvoo Newbie

            Maybe can someone give me a third eye comparison between the working ones with non-working copies of configurations:

            1. ejb-jar.xml

            Working:

            <session>
             <display-name>PersistenceJAR</display-name>
             <ejb-name>PersistenceEJB</ejb-name>
             <service-endpoint>gov.mohr.ems.core.entity.logic.PersistenceServiceEndpoint</service-endpoint>
             <!--<home>gov.mohr.ems.core.entity.logic.PersistenceRemoteHome</home>
             <remote>gov.mohr.ems.core.entity.logic.PersistenceRemote</remote>-->
             <ejb-class>gov.mohr.ems.core.entity.logic.PersistenceBean</ejb-class>
             <session-type>Stateless</session-type>
             <transaction-type>Container</transaction-type>
             <env-entry>
             <env-entry-name>ejb/BeanFactoryPath</env-entry-name>
             <env-entry-type>java.lang.String</env-entry-type>
             <env-entry-value>/META-INF/applicationcontext-ejb.xml</env-entry-value>
             </env-entry>
             </session>


            NOT Working:

            <session>
             <display-name>ORMEngineJAR</display-name>
             <ejb-name>ORMEngineEJB</ejb-name>
             <service-endpoint>gov.mohr.ems.core.entity.logic.ORMEngineServiceEndpoint</service-endpoint>
             <!--<home>gov.mohr.ems.core.entity.logic.ORMEngineRemoteHome</home>
             <remote>gov.mohr.ems.core.entity.logic.ORMEngineRemote</remote>-->
             <ejb-class>gov.mohr.ems.core.entity.logic.ORMEngineBean</ejb-class>
             <session-type>Stateless</session-type>
             <transaction-type>Container</transaction-type>
             <env-entry>
             <env-entry-name>ejb/BeanFactoryPath</env-entry-name>
             <env-entry-type>java.lang.String</env-entry-type>
             <env-entry-value>/META-INF/applicationcontext-ejb.xml</env-entry-value>
             </env-entry>
             </session>


            2. webservices.xml

            Working:

            <webservice-description-name>PersistenceService</webservice-description-name>
             <wsdl-file>META-INF/wsdl/PersistenceService.wsdl</wsdl-file>
             <jaxrpc-mapping-file>META-INF/mapping-persistence.xml</jaxrpc-mapping-file>
             <port-component>
             <port-component-name>PersistencePort</port-component-name>
             <wsdl-port>PersistenceServiceEndpointPort</wsdl-port>
             <service-endpoint-interface>gov.mohr.ems.core.entity.logic.PersistenceServiceEndpoint</service-endpoint-interface>
             <service-impl-bean>
             <ejb-link>PersistenceEJB</ejb-link>
             </service-impl-bean>
             </port-component>
             </webservice-description>
            


            Not Working:

            <webservice-description>
             <webservice-description-name>ORMEngineService</webservice-description-name>
             <wsdl-file>META-INF/wsdl/ORMEngineService.wsdl</wsdl-file>
             <jaxrpc-mapping-file>META-INF/mapping-ormengine.xml</jaxrpc-mapping-file>
             <port-component>
             <port-component-name>ORMEnginePort</port-component-name>
             <wsdl-port>ORMEngineServiceEndpointPort</wsdl-port>
             <service-endpoint-interface>gov.mohr.ems.core.entity.logic.ORMEngineServiceEndpoint</service-endpoint-interface>
             <service-impl-bean>
             <ejb-link>ORMEngineEJB</ejb-link>
             </service-impl-bean>
             </port-component>
             </webservice-description>
            


            3. Mapping.xml

            Working:

            <?xml version="1.0" encoding="UTF-8"?>
            <java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
             <package-mapping>
             <package-type>gov.mohr.ems.core.entity.logic</package-type>
             <namespaceURI>http://localhost:8080/types</namespaceURI>
             </package-mapping>
             <package-mapping>
             <package-type>gov.mohr.ems.core.entity.logic</package-type>
             <namespaceURI>http://localhost:8080/</namespaceURI>
             </package-mapping>
             <service-interface-mapping>
             <service-interface>gov.mohr.ems.core.entity.logic.PersistenceService</service-interface>
             <wsdl-service-name xmlns:serviceNS="http://localhost:8080/">serviceNS:PersistenceService</wsdl-service-name>
             <port-mapping>
             <port-name>PersistenceServiceEndpointPort</port-name>
             <java-port-name>PersistenceServiceEndpointPort</java-port-name>
             </port-mapping>
             </service-interface-mapping>
             <service-endpoint-interface-mapping>
             <service-endpoint-interface>gov.mohr.ems.core.entity.logic.PersistenceServiceEndpoint</service-endpoint-interface>
             <wsdl-port-type xmlns:portTypeNS="http://localhost:8080/">portTypeNS:PersistenceServiceEndpoint</wsdl-port-type>
             <wsdl-binding xmlns:bindingNS="http://localhost:8080/">bindingNS:PersistenceServiceEndpointBinding</wsdl-binding>
             <service-endpoint-method-mapping>
             <java-method-name>upload</java-method-name>
             <wsdl-operation>upload</wsdl-operation>
             <method-param-parts-mapping>
             <param-position>0</param-position>
             <param-type>java.lang.String</param-type>
             <wsdl-message-mapping>
             <wsdl-message xmlns:wsdlMsgNS="http://localhost:8080/">wsdlMsgNS:PersistenceServiceEndpoint_upload</wsdl-message>
             <wsdl-message-part-name>String_1</wsdl-message-part-name>
             <parameter-mode>IN</parameter-mode>
             </wsdl-message-mapping>
             </method-param-parts-mapping>
             <wsdl-return-value-mapping>
             <method-return-value>java.lang.String</method-return-value>
             <wsdl-message xmlns:wsdlMsgNS="http://localhost:8080/">wsdlMsgNS:PersistenceServiceEndpoint_uploadResponse</wsdl-message>
             <wsdl-message-part-name>result</wsdl-message-part-name>
             </wsdl-return-value-mapping>
             </service-endpoint-method-mapping>
             </service-endpoint-interface-mapping>
            </java-wsdl-mapping>
            


            Not Working:

            <?xml version="1.0" encoding="UTF-8"?>
            <java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
             <package-mapping>
             <package-type>gov.mohr.ems.core.entity.logic</package-type>
             <namespaceURI>http://localhost:8080/types</namespaceURI>
             </package-mapping>
             <package-mapping>
             <package-type>gov.mohr.ems.core.entity.logic</package-type>
             <namespaceURI>http://localhost:8080/</namespaceURI>
             </package-mapping>
             <service-interface-mapping>
             <service-interface>gov.mohr.ems.core.entity.logic.ORMEngineService</service-interface>
             <wsdl-service-name xmlns:serviceNS="http://localhost:8080/">serviceNS:ORMEngineService</wsdl-service-name>
             <port-mapping>
             <port-name>ORMEngineServiceEndpointPort</port-name>
             <java-port-name>ORMEngineServiceEndpointPort</java-port-name>
             </port-mapping>
             </service-interface-mapping>
             <service-endpoint-interface-mapping>
             <service-endpoint-interface>gov.mohr.ems.core.entity.logic.ORMEngineServiceEndpoint</service-endpoint-interface>
             <wsdl-port-type xmlns:portTypeNS="http://localhost:8080/">portTypeNS:ORMEngineServiceEndpoint</wsdl-port-type>
             <wsdl-binding xmlns:bindingNS="http://localhost:8080/">bindingNS:ORMEngineServiceEndpointBinding</wsdl-binding>
             <service-endpoint-method-mapping>
             <java-method-name>executeQuery</java-method-name>
             <wsdl-operation>executeQuery</wsdl-operation>
             <method-param-parts-mapping>
             <param-position>0</param-position>
             <param-type>java.lang.String</param-type>
             <wsdl-message-mapping>
             <wsdl-message xmlns:wsdlMsgNS="http://localhost:8080/">wsdlMsgNS:ORMEngineServiceEndpoint_executeQuery</wsdl-message>
             <wsdl-message-part-name>String_1</wsdl-message-part-name>
             <parameter-mode>IN</parameter-mode>
             </wsdl-message-mapping>
             </method-param-parts-mapping>
             <wsdl-return-value-mapping>
             <method-return-value>java.lang.String</method-return-value>
             <wsdl-message xmlns:wsdlMsgNS="http://localhost:8080/">wsdlMsgNS:ORMEngineServiceEndpoint_executeQueryResponse</wsdl-message>
             <wsdl-message-part-name>result</wsdl-message-part-name>
             </wsdl-return-value-mapping>
             </service-endpoint-method-mapping>
             </service-endpoint-interface-mapping>
            </java-wsdl-mapping>
            


            4. jboss.xml

            Working:

            <session>
             <ejb-name>PersistenceEJB</ejb-name>
             <local-jndi-name>persistenceWebService</local-jndi-name>
             <port-component>
             <port-component-name>PersistencePort</port-component-name>
             <port-component-uri>ejb/EmsWebService/Persistence</port-component-uri>
             </port-component>
             </session>
            


            Not Working:

            <session>
             <ejb-name>ORMEngineEJB</ejb-name>
             <local-jndi-name>ormengineWebService</local-jndi-name>
             <port-component>
             <port-component-name>ORMEnginePort</port-component-name>
             <port-component-uri>ejb/EmsWebServices/ORMEngine</port-component-uri>
             </port-component>
             </session>
            


            5. WSDL

            Working:

            <?xml version="1.0" encoding="UTF-8"?>
            
            <definitions name="PersistenceService" targetNamespace="http://localhost:8080/" xmlns:tns="http://localhost:8080/" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
             <types/>
             <message name="PersistenceServiceEndpoint_upload">
             <part name="String_1" type="xsd:string"/></message>
             <message name="PersistenceServiceEndpoint_uploadResponse">
             <part name="result" type="xsd:string"/></message>
             <portType name="PersistenceServiceEndpoint">
             <operation name="upload" parameterOrder="String_1">
             <input message="tns:PersistenceServiceEndpoint_upload"/>
             <output message="tns:PersistenceServiceEndpoint_uploadResponse"/></operation></portType>
             <binding name="PersistenceServiceEndpointBinding" type="tns:PersistenceServiceEndpoint">
             <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"/>
             <operation name="upload">
             <soap:operation soapAction=""/>
             <input>
             <soap:body use="literal" namespace="http://localhost:8080/"/></input>
             <output>
             <soap:body use="literal" namespace="http://localhost:8080/"/></output></operation></binding>
             <service name="PersistenceService">
             <port name="PersistenceServiceEndpointPort" binding="tns:PersistenceServiceEndpointBinding">
             <soap:address location="REPLACE_WITH_ACTUAL_URL"/></port></service></definitions>
            


            Not Working:

            <?xml version="1.0" encoding="UTF-8"?>
            
            <definitions name="ORMEngineService" targetNamespace="http://localhost:8080/" xmlns:tns="http://localhost:8080/" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
             <types/>
             <message name="ORMEngineServiceEndpoint_executeQuery">
             <part name="String_1" type="xsd:string"/></message>
             <message name="ORMEngineServiceEndpoint_executeQueryResponse">
             <part name="result" type="xsd:string"/></message>
             <portType name="ORMEngineServiceEndpoint">
             <operation name="executeQuery" parameterOrder="String_1">
             <input message="tns:ORMEngineServiceEndpoint_executeQuery"/>
             <output message="tns:ORMEngineServiceEndpoint_executeQueryResponse"/></operation></portType>
             <binding name="ORMEngineServiceEndpointBinding" type="tns:ORMEngineServiceEndpoint">
             <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"/>
             <operation name="executeQuery">
             <soap:operation soapAction=""/>
             <input>
             <soap:body use="literal" namespace="http://localhost:8080/"/></input>
             <output>
             <soap:body use="literal" namespace="http://localhost:8080/"/></output></operation></binding>
             <service name="ORMEngineService">
             <port name="ORMEngineServiceEndpointPort" binding="tns:ORMEngineServiceEndpointBinding">
             <soap:address location="REPLACE_WITH_ACTUAL_URL"/></port></service></definitions>
            


            Many thanks!!

            • 3. Re: does not contain port: null
              tiago galvao Newbie

              i know this is quite an old topic but i'm having exactly the same problem

              did you get this to work?

              the wird thing is... at the development envirolment it works...

              but find what's wrong

              tks