uCosminexus Service Platform, Basic Development Guide

[Contents][Glossary][Index][Back][Next]

8.5.9 Acquiring Response Messages

Acquire the response message from the extracted response. The response message to be acquired is one of the following:

Organization of this subsection
(1) Response message from a service component
(2) Error information (fault information) from a service component, business process, or custom adapter

(1) Response message from a service component

The response message to be acquired is an XML message that has the same message format as the service component side. For details about XML response messages, see 8.2.7 Acquiring Response Messages.

When there is no response message from a synchronous service component (Web Services or SessionBean), TextMessage without payload is received.

For an asynchronous service component, there is no response.

(2) Error information (fault information) from a service component, business process, or custom adapter

The message (error information) to be acquired is the XML message that was sent by the asynchronous reception (MDB (WS-R)) to the response queue.

Output format of error information is different for SOAP1.2 and for other than SOAP1.2.

(a) Other than SOAP1.2

The following table shows the format of the XML message (error information) to be acquired while using other than SOAP1.2.

Table 8-15 Format of the XML message (error information) to be acquired (other than SOAP1.2)

Tag Explanation
errorcode Error code indicating an error from a service component, business process, or custom adapter
errorstring Error message indicating an error from a service component, business process, or custom adapter
Processinstanceid Instance ID information of a business process
cscmsgcode FaultCode information from a service component (Web Services), business process, or custom adapter
cscmsgstring FaultString information from a service component (Web Services), business process, or custom adapter
cscmsgactor FaultActor information from a service component (Web Services), business process, or custom adapter
cscmsgdetail Detail information from a service component (Web Services), business process, or custom adapter
 

The schema of the XML message (error information) to be acquired while using other than SOAP1.2 is shown below.

 
<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <xsd:element name="cscmsgerror">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element name="errorcode" type="xsd:string"/>
        <xsd:element name="errorstring" type="xsd:string"/>
        <xsd:element name="processinstanceid" type="xsd:string"/>
        <xsd:element ref="errordetail"/>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
 
  <xsd:element name="errordetail">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element name="cscmsgcode" type="xsd:string"/>
        <xsd:element name="cscmsgstring" type="xsd:string"/>
        <xsd:element name="cscmsgactor" type="xsd:string"/>
        <xsd:element name="cscmsgdetail" type="xsd:string"/>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
</xsd:schema>
 
 
(b) In SOAP1.2

The following shows the format of the XML message (error information) to be acquired while using SOAP1.2:

Table 8-16 Format of XML message (error information) to be acquired (in SOAP1.2)

Tag Description
errorcode Error code indicating existence of error from service component, business process and custom adapter.
errorstring Error message indicating existence of error from service component, business process and custom adapter.
processinstanceid Information of business process instance ID.
cscmsgcode Code information from service component (Web Service), business process or custom adapter.
cscmsgvalue Value information containing Code from service component (Web Service), business process or custom adapter.
cscmsgreason Reason information from service component (Web service), business process or custom adapter.
cscmsgtext Text information containing Reason from service component (Web Service), business process or custom adapter.
cscmsgrole Role information from service component (Web Service), business process or custom adapter.
cscmsgnode Node information from service component (Web Service), business process or custom adapter.
cscmsgdetail Detail information from service component (Web Service), business process or custom adapter.
 

The following shows the schema of the XML message (error information) to be acquired while using SOAP1.2:

<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <xsd:element name="cscmsgerror">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element name="errorcode" type="xsd:string"/>
        <xsd:element name="errorstring" type="xsd:string"/>
        <xsd:element name="processinstanceid" type="xsd:string"/>
        <xsd:element ref="errordetail"/>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
 
  <xsd:element name="errordetail">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element ref="cscmsgcode"/>
        <xsd:element ref="cscmsgreason"/>
        <xsd:element name="cscmsgrole" type="xsd:string"/>
        <xsd:element name="cscmsgnode" type="xsd:string"/>
        <xsd:element name="cscmsgdetail" type="xsd:string"/>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
 
  <xsd:element name="cscmsgcode" nillable="true">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element name="cscmsgvalue" type="xsd:string" maxOccurs="unbounded" nillable="true"/>
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
 
  <xsd:element name="cscmsgreason" nillable="true">
    <xsd:complexType>
      <xsd:sequence>
      <xsd:element name="cscmsgtext" type="tns:cscmsgFaultReasonText" maxOccurs="unbounded" nillable="true" />
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>
  <xs:complexType name="cscmsgFaultReasonText">
    <xs:sequence>
      <xs:element name="locale" type="xs:string" nillable="true" />
      <xs:element name="text" type="xs:string" nillable="true" />
    </xs:sequence>
  </xs:complexType>
</xsd:schema>