Cloud Application Integration (On-Premises) : Service Development : Building Services : Specifying the Default Format for an XML Document Received by the Service
Specifying the Default Format for an XML Document Received by the Service
For a service that receives an XML document, you can specify the format for the XML document that Integration Server passes to the service. The XML format that you select determines:
*Whether Integration Server parses the XML document automatically before passing it to the service
*Which XML parser Integration Server uses. When parsing an XML document, Integration Server uses either the legacy XML parser or the enhanced XML parser. For more information about the XML parsers, see webMethods Integration Server Administrator’s Guide.
*The name and data type of the variable that Integration Server adds to the pipeline with the contents of the XML document
The Default xmlFormat property specifies the default handling for XML documents received by the service. Keep the following points in mind when setting the Default xmlFormat property value for a service:
*You can specify a default XML format for flow services and Java services only. The Default xmlFormat property is not available for C/C++ services, .NET services, or web service connectors.
*The default XML format specified for a service by the Default xmlFormat property can be overridden by the value of the xmlFormat argument in the URL of an individual client request. However, the client request should specify the xmlFormat argument only when it is recommended in the documentation for the service. A client should specify the xmlFormat only when knowing how the service will respond. For more information see Submitting and Receiving XML via HTTP
*The XML format determines whether or not Integration Server parses the document. If parsing is not needed, it can unnecessarily slow down the execution of a service. For example, an application might handle the XML as a simple String. In this case, the automatic parsing is unnecessary and should be avoided.
*Make sure the input signature of the service contains an input parameter that matches the variable name and data type that Integration Server produces for the default format.
To specify the default XML format for a service
1. In the Package Navigator view of the Service Development perspective, open the service for which you want to set the default XML format.
2. In the Run time category in the Properties view, next to Default xmlFormat, specify one of the following:
Select...
To specify that the default XML format is...
<blank>
Determined by the value of the watt.server.http.xmlFormat server configuration parameter. This is the default.
For more information about the watt.server.http.xmlFormat server configuration parameter, see webMethods Integration Server Administrator’s Guide.
bytes
A byte array. Integration Server passes the XML document directly to the service as a byte array without parsing the XML. Integration Server places the byte array in the input pipeline of the target service in a variable named xmlBytes.
enhanced
A node parsed by the enhanced XML parser. Integration Server parses the XML automatically using the enhanced XML parser. Integration Server uses the default options specified for enhanced XML parsing on the Settings > Enhanced XML Parsing page in Integration Server Administrator. Integration Server passes the XML document to the target service as an enhanced node that implements the org.w3c.dom.Node interface. Integration Server places the node in the input pipeline of the target service in a variable named node.
node
A node parsed by the legacy XML parser. Integration Server parses the XML automatically using the legacy parser and passes it to the target service as a node of type com.wm.lang.xml.Node. Integration Server places the node in the input pipeline of the target service in a variable named node
stream
An InputStream. Integration Server passes the XML document directly to the service as an XML stream without parsing the XML. Integration Server places the XML stream in the input pipeline of the target service as an InputStream named xmlStream.
3. Click File > Save.
Submitting and Receiving XML via HTTP
About the xmlFormat Value
Copyright © 2015- 2016 Software AG, Darmstadt, Germany.

Product LogoContact Support   |   Community   |   Feedback