Hello,
I'm trying to reuse WSDL files for WSRF services (that weren't using
Apache WSRF).
I'm only interested in the operations regarding the resource properties
for the moment. I have several of these services, so I would like to
avoid duplicating the same thing, in particular the port types for the
WS-ResourceProperties operations.
At the moment, I've written a common WSRF.wsdl file that contains a port
type of this form:
<wsdl:portType name="WSRFOperations">
<wsdl:operation name="GetResourceProperty">
<wsdl:input message="wsrp:GetResourcePropertyRequest"
name="GetResourcePropertyRequest"/>
<wsdl:output message="wsrp:GetResourcePropertyResponse"
name="GetResourcePropertyResponse"/>
<wsdl:fault message="wsrp:ResourceUnknownFault"
name="ResourceUnknownFault"/>
<wsdl:fault message="wsrp:InvalidResourcePropertyQNameFault"
name="InvalidResourcePropertyQNameFault"/>
</wsdl:operation>
<wsdl:operation name="GetMultipleResourceProperties">
<!-- ... -->
</wsdl:operation>
<!-- + other operations of WS-ResourceProperties ... -->
</wsdl:porttype>
In short, this is the same as
<http://docs.oasis-open.org/wsrf/rpw-2.wsdl>, except that I've merged
all the port types for all the operations into a single one.
Then, each resource WSDL uses:
<import location="WSRF.wsdl"
namespace="http://www.ibm.com/xmlns/stdwip/web-services/WS-ResourceProperties"/>
<service name="MyResource">
<port binding="tns:MyResourceSpecificSoapBinding"
name="MyResourcePort">
<soap:address location="http://localhost/.../"/>
</port>
<port binding="wsrf:WSRFOperationsSoapBinding"
name="MyResourceWSRFPort">
<soap:address location="http://localhost/.../"/>
</port>
</service>
(I'm using two ports because one is for the WSRF properties and the
other one is for operations specific to that resource.)
Unfortunately, WSDL2Java (in WSRF 1.0) generates two sets of classes,
one for each port, whereas I would really like just one set of classes
(one per service and not per port).
Is my way of writing the WSDL file incorrect or discouraged? I would
assume not, since if I took
<http://docs.oasis-open.org/wsrf/rpw-2.wsdl>, I would end up with even
more sets of classes.
Is there any way to avoid copying and pasting all the
WS-ResourceProperties entries into the WSDL file (to avoid what's done
in the Filesystem example)?
Perhaps one way around this would be to use a single back end object for
several instances of 'Resource' corresponding in fact to a single
resource, therefore the factory would have to create several resources
for a single back-end resource. This seems long and a bit hard to
maintain and synchronise.
Regards,
Bruno.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]