Portlet Factory, Version 6.1.2


 

Web Service Enable builder: method type "all"

This topic describes the method type "all" in the Web Service Enable builder.

 

Limitations of method type "all"

You can choose all for the Method input to expose all the methods in a model as Web services. However, this is not a recommended practice because you cannot add information about the arguments for each method and you might inadvertently expose a method to the public. In addition, since XML arguments require schema typing to be usable, all will not expose any methods that have XML args or responses. Method type all has several additional limitations including:

  • Type "all" should only be used for methods that return simple datatypes (byte, string, boolean), and not XML.

  • Specifying "all" in the Web Service Enable builder will automatically set the service type to rpc-encoded (there is no way to change this).

  • Selecting type "all" (to web-service enable all available methods) will not properly handle methods that return XML data. Since there is no way to specify a schema for the XML that is either being sent as an argument, or returned back to the service, the Service Call builder will fail and display the following error message:
Deserializing parameter xxxxx: could not find deserializer for type {http://ww.w3.org/2001/XMLSchema}any.

 

Method type "all" and namespaces

If a model contains two methods, one web-service-enabled explicitly with a Web Service Enable builder, and the other web-service-enabled implicitly by a Web Service Enable "all" builder, WebSphere Portlet Factory's WSDL generator can associate the specific namespaces as the method namespace of those methods, and will use the "all" namespace as the method namespace of the other methods. The service call will pick up the method namespace of the target method, and that is what Axis inbound routing will use to find a model. So specifying the two namespaces in the external properties is not a problem since the model can be located in both cases.

Parent topic: Web Service Enable builder


Library | Support |