You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by cmathrusse <Ch...@sybase.com> on 2008/03/26 17:09:43 UTC
@SOAPBinding not behaving as expected
I'm replacing an existing Axis WebService with CXF and I am attempting to
duplicate the definition as much as possible. (where reasonable)
I've defined my SOAPBinding on both my SEI and the Impl as follows:
SEI:
@WebService(targetNamespace = "session.ejb.cosmos.it.sybase.com", name =
"CosmosBroker")
@SOAPBinding(parameterStyle = ParameterStyle.WRAPPED, style = Style.RPC, use
= Use.ENCODED)
public interface CosmosBroker {
Impl:
@WebService(endpointInterface = "com.sybase.it.cosmos.CosmosBroker",
portName = "CosmosBroker", targetNamespace =
"session.ejb.cosmos.it.sybase.com", name = "CosmosBroker")
@SOAPBinding(parameterStyle = ParameterStyle.WRAPPED, style = Style.RPC, use
= Use.ENCODED)
public class CosmosBrokerImpl implements CosmosBroker {
But the generated WSDL does not look as I expected. I expected to see
use="encoded" but instead got use="literal"
Existing WebService operation:
<wsdl:operation name="isCustomerActive">
<wsdlsoap:operation soapAction=""/>
<wsdl:input name="isCustomerActiveRequest">
<wsdlsoap:body use="encoded"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="http://session.ejb.cosmos.it.sybase.com"/>
</wsdl:input>
<wsdl:output name="isCustomerActiveResponse">
<wsdlsoap:body use="encoded"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="http://session.ejb.cosmos.it.sybase.com"/>
</wsdl:output>
</wsdl:operation>
New CFX operation:
<wsdl:operation name="isCustomerActive">
<soap:operation soapAction="" style="rpc"/>
<wsdl:input name="isCustomerActive">
<soap:body namespace="session.ejb.cosmos.it.sybase.com"
use="literal"/>
</wsdl:input>
<wsdl:output name="isCustomerActiveResponse">
<soap:body namespace="session.ejb.cosmos.it.sybase.com"
use="literal"/>
</wsdl:output>
</wsdl:operation>
So what am I missing?
Thanks for the help....
--
View this message in context: http://www.nabble.com/%40SOAPBinding-not-behaving-as-expected-tp16304549p16304549.html
Sent from the cxf-user mailing list archive at Nabble.com.
Re: @SOAPBinding not behaving as expected
Posted by cmathrusse <Ch...@sybase.com>.
Found my own answer:
JAX-WS 2.0 does not support rpc/encoded.
--
View this message in context: http://www.nabble.com/%40SOAPBinding-not-behaving-as-expected-tp16304549p16304807.html
Sent from the cxf-user mailing list archive at Nabble.com.
Re: @SOAPBinding not behaving as expected
Posted by cmathrusse <Ch...@sybase.com>.
Yeah, I figured that out. The existing WebService was Axis 1 so it doesn't
surprise me that it was generated this way.
Onto bigger and better implementations....
--
View this message in context: http://www.nabble.com/%40SOAPBinding-not-behaving-as-expected-tp16304549p16309283.html
Sent from the cxf-user mailing list archive at Nabble.com.
Re: @SOAPBinding not behaving as expected
Posted by Daniel Kulp <dk...@apache.org>.
Umm.... CXF doesn't support encoded. (Neither does Axis2 either so I'm
surprised it works for them as well) At this point, since we don't
support it, I don't think we even bother saving the "use = Use.ENCODED"
stuff anywhere so it's not available at wsdl creation time.
Dan
On Wednesday 26 March 2008, cmathrusse wrote:
> I'm replacing an existing Axis WebService with CXF and I am attempting
> to duplicate the definition as much as possible. (where reasonable)
> I've defined my SOAPBinding on both my SEI and the Impl as follows:
>
> SEI:
> @WebService(targetNamespace = "session.ejb.cosmos.it.sybase.com", name
> = "CosmosBroker")
> @SOAPBinding(parameterStyle = ParameterStyle.WRAPPED, style =
> Style.RPC, use = Use.ENCODED)
> public interface CosmosBroker {
>
> Impl:
> @WebService(endpointInterface = "com.sybase.it.cosmos.CosmosBroker",
> portName = "CosmosBroker", targetNamespace =
> "session.ejb.cosmos.it.sybase.com", name = "CosmosBroker")
> @SOAPBinding(parameterStyle = ParameterStyle.WRAPPED, style =
> Style.RPC, use = Use.ENCODED)
> public class CosmosBrokerImpl implements CosmosBroker {
>
> But the generated WSDL does not look as I expected. I expected to see
> use="encoded" but instead got use="literal"
>
> Existing WebService operation:
> <wsdl:operation name="isCustomerActive">
> <wsdlsoap:operation soapAction=""/>
> <wsdl:input name="isCustomerActiveRequest">
> <wsdlsoap:body use="encoded"
> encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
> namespace="http://session.ejb.cosmos.it.sybase.com"/>
> </wsdl:input>
> <wsdl:output name="isCustomerActiveResponse">
> <wsdlsoap:body use="encoded"
> encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
> namespace="http://session.ejb.cosmos.it.sybase.com"/>
> </wsdl:output>
> </wsdl:operation>
>
> New CFX operation:
> <wsdl:operation name="isCustomerActive">
> <soap:operation soapAction="" style="rpc"/>
> <wsdl:input name="isCustomerActive">
> <soap:body namespace="session.ejb.cosmos.it.sybase.com"
> use="literal"/>
> </wsdl:input>
> <wsdl:output name="isCustomerActiveResponse">
> <soap:body namespace="session.ejb.cosmos.it.sybase.com"
> use="literal"/>
> </wsdl:output>
> </wsdl:operation>
>
>
> So what am I missing?
>
> Thanks for the help....
--
J. Daniel Kulp
Principal Engineer, IONA
dkulp@apache.org
http://www.dankulp.com/blog