I thought Vamsi was illustrating a scenario and asking a question.   I agree
with you as well, on the service side the spec does indicate some hosting
environments cannot support endpoints defined in wsdl.  Still trying to nail
down the semantics of this attribute.  The example above with the three http
ports doesn't work for me.



On 5/6/08, Simon Nash <[EMAIL PROTECTED]> wrote:
>
> Vamsavardhana Reddy wrote:
>
> > I have my AService with wsdl given below:
> > <?xml version="1.0" encoding="UTF-8"?>
> > <wsdl:definitions targetNamespace="
> > http://wsbinding.vtest.sca.tuscany.apache.org"; xmlns:soap12="
> > http://schemas.xmlsoap.org/wsdl/soap12/"; xmlns:ns0="
> > http://wsbinding.vtest.sca.tuscany.apache.org"; xmlns:mime="
> > http://schemas.xmlsoap.org/wsdl/mime/"; xmlns:http="
> > http://schemas.xmlsoap.org/wsdl/http/"; xmlns:ns1="
> > http://org.apache.axis2/xsd"; xmlns:wsaw="
> > http://www.w3.org/2006/05/addressing/wsdl"; xmlns:xs="
> > http://www.w3.org/2001/XMLSchema"; xmlns:soap="
> > http://schemas.xmlsoap.org/wsdl/soap/"; xmlns:wsdl="
> > http://schemas.xmlsoap.org/wsdl/";>
> >  <wsdl:types>
> >    <xs:schema attributeFormDefault="qualified"
> > elementFormDefault="qualified" targetNamespace="
> > http://wsbinding.vtest.sca.tuscany.apache.org"; xmlns:ns="
> > http://wsbinding.vtest.sca.tuscany.apache.org";>
> >            <xs:element name="getGreetings">
> >                <xs:complexType>
> >                    <xs:sequence>
> >                        <xs:element minOccurs="0" name="param0"
> > nillable="true" type="xs:string"/>
> >                    </xs:sequence>
> >                </xs:complexType>
> >
> >            </xs:element>
> >            <xs:element name="getGreetingsResponse">
> >                <xs:complexType>
> >                    <xs:sequence>
> >                        <xs:element minOccurs="0" name="return"
> > nillable="true" type="xs:string"/>
> >                    </xs:sequence>
> >                </xs:complexType>
> >            </xs:element>
> >        </xs:schema>
> >
> >  </wsdl:types>
> >  <wsdl:message name="getGreetingsRequest">
> >    <wsdl:part name="parameters" element="ns0:getGreetings">
> >    </wsdl:part>
> >  </wsdl:message>
> >  <wsdl:message name="getGreetingsResponse">
> >    <wsdl:part name="parameters" element="ns0:getGreetingsResponse">
> >    </wsdl:part>
> >  </wsdl:message>
> >
> >  <wsdl:portType name="AServicePortType">
> >    <wsdl:operation name="getGreetings">
> >      <wsdl:input message="ns0:getGreetingsRequest"
> > wsaw:Action="urn:getGreetings">
> >    </wsdl:input>
> >      <wsdl:output message="ns0:getGreetingsResponse"
> > wsaw:Action="urn:getGreetingsResponse">
> >    </wsdl:output>
> >    </wsdl:operation>
> >  </wsdl:portType>
> >  <wsdl:binding name="AServiceSOAP12Binding" type="ns0:AServicePortType">
> >
> >    <soap12:binding style="document" transport="
> > http://schemas.xmlsoap.org/soap/http"/>
> >    <wsdl:operation name="getGreetings">
> >      <soap12:operation soapAction="urn:getGreetings" style="document"/>
> >      <wsdl:input>
> >        <soap12:body use="literal"/>
> >      </wsdl:input>
> >      <wsdl:output>
> >        <soap12:body use="literal"/>
> >      </wsdl:output>
> >
> >    </wsdl:operation>
> >  </wsdl:binding>
> >  <wsdl:binding name="AServicePortTypeBinding"
> > type="ns0:AServicePortType">
> >    <soap:binding style="document" transport="
> > http://schemas.xmlsoap.org/soap/http"/>
> >    <wsdl:operation name="getGreetings">
> >      <soap:operation soapAction=""/>
> >      <wsdl:input>
> >        <soap:body use="literal"/>
> >      </wsdl:input>
> >
> >      <wsdl:output>
> >        <soap:body use="literal"/>
> >      </wsdl:output>
> >    </wsdl:operation>
> >  </wsdl:binding>
> >  <wsdl:binding name="AServiceHttpBinding" type="ns0:AServicePortType">
> >    <http:binding verb="POST"/>
> >    <wsdl:operation name="getGreetings">
> >      <http:operation location="AService/getGreetings"/>
> >
> >      <wsdl:input>
> >        <mime:content part="getGreetings" type="text/xml"/>
> >      </wsdl:input>
> >      <wsdl:output>
> >        <mime:content part="getGreetings" type="text/xml"/>
> >      </wsdl:output>
> >    </wsdl:operation>
> >  </wsdl:binding>
> >  <wsdl:binding name="AServiceSOAP11Binding" type="ns0:AServicePortType">
> >
> >    <soap:binding style="document" transport="
> > http://schemas.xmlsoap.org/soap/http"/>
> >    <wsdl:operation name="getGreetings">
> >      <soap:operation soapAction="urn:getGreetings" style="document"/>
> >      <wsdl:input>
> >        <soap:body use="literal"/>
> >      </wsdl:input>
> >      <wsdl:output>
> >        <soap:body use="literal"/>
> >      </wsdl:output>
> >
> >    </wsdl:operation>
> >  </wsdl:binding>
> >  <wsdl:service name="AServicePortTypeService">
> >    <wsdl:port name="AServicePortTypePort"
> > binding="ns0:AServicePortTypeBinding">
> >      <soap:address location="http://localhost:8090/AService"/>
> >    </wsdl:port>
> >  </wsdl:service>
> >  <wsdl:service name="AService">
> >    <wsdl:port name="AServiceHttpport" binding="ns0:AServiceHttpBinding">
> >
> >      <http:address location="http://localhost:8080/AService"/>
> >    </wsdl:port>
> >    <wsdl:port name="AServiceSOAP12port_http"
> > binding="ns0:AServiceSOAP12Binding">
> >      <soap12:address location="http://localhost:8012/AService"/>
> >    </wsdl:port>
> >    <wsdl:port name="AServiceSOAP11port_http"
> > binding="ns0:AServiceSOAP11Binding">
> >      <soap:address location="http://localhost:8011/AService"/>
> >    </wsdl:port>
> >  </wsdl:service>
> >
> > </wsdl:definitions>
> > --------
> >
> > I have my composite one.composite as given below:
> > <?xml version="1.0" encoding="UTF-8"?>
> > <composite xmlns="http://www.osoa.org/xmlns/sca/1.0";
> >    targetNamespace="http://vtest";
> >    name="one">
> >
> >    <component name="AComponent">
> >        <implementation.java
> > class="org.apache.tuscany.sca.vtest.wsbinding.impl.AServiceImpl"/>
> >        <service name="AService">
> >            <binding.ws wsdlElement="
> > http://wsbinding.vtest.sca.tuscany.apache.org#wsdl.service(AService)<http://wsbinding.vtest.sca.tuscany.apache.org/#wsdl.service(AService)>
> > "/>
> >        </service>
> >    </component>
> > </composite>
> > --------
> > Should the service be available on http://localhost:8080/AService,
> > http://localhost:8012/AService and http://localhost:8011/AService ?
> >  With
> > the current implementation, the service is available on
> > http://localhost:8080/AComponent.
> >
> > This seems like a bug to me.  The endpoints in the WSDL should
> take precedence over those calculated using the default algorithm
> (this seems be where http://localhost:8080/AComponent is coming
> from).  However, I'm not sure if the port numbers in the WSDL
> can always be exposed as written.  This would depend on what
> hosting environment is used, and what ports it is able to open.
>
>  Simon
>
> ++Vamsi
> >
> >
> > On Tue, May 6, 2008 at 10:50 PM, Simon Nash <[EMAIL PROTECTED]> wrote:
> >
> > Lou Amodeo wrote:
> > >
> > > I am reading the WS Binding Specification and am trying to understand
> > > > the
> > > > meaning of the wsdl.service form of the WSDL Element's URI and to
> > > > what
> > > > extent and how it is supported in Tuscany?   Thanks for your help.
> > > >
> > > > Service:
> > > >
> > > > 39 <WSDL-namespace-URI>#wsdl.service(<service-name>)
> > > >
> > > > 40 In this case, all the endpoints in the WSDL Service that have
> > > > equivalent
> > > > PortTypes with
> > > >
> > > > 41 the SCA service or reference must be available to the SCA service
> > > > or
> > > > reference.
> > > >
> > > >  To answer this, I'll start by talking about SCA services, as
> > > >
> > > the meaning in this case seems clearer.
> > >
> > > Suppose the WSDL document for an SCA service refers to a WSDL
> > > service Service1 that has WSDL ports Port1, Port2 and Port3.
> > > Port1 and Port3 use bindings that refer to PortType1, and Port2
> > > uses a binding that refers to PortType2.  The interface of the
> > > SCA service is either the WSDL interface PortType1, or a Java
> > > interface that's equivalent to PortType1.  In this case, the
> > > SCA service would be listening on both Port1 and Port3 (but
> > > not Port2).
> > >
> > > I'm having trouble applying this to references, though.  A
> > > reference would normally only invoke via one port.  I'm not sure
> > > how an SCA reference that specifies the WSDL service described
> > > above could make use of both Port1 amd Port3.
> > >
> > >  Simon
> > >
> > >
> >
>

Reply via email to