This discussion is archived
2 Replies Latest reply: Jun 13, 2012 11:08 PM by 804487 RSS

tpstrerror: 'TPEITYPE - type and/or subtype do not match service's'

804487 Newbie
Currently Being Moderated
Hi,

I have a problem with reciving data from webservice by Salt while there is no inner xml tags in it. In response I got this:

tpcall (iResult:'-1', tpstrerror: 'TPEITYPE - type and/or subtype do not match service's')


Response in WSDL looks like this (fundAsset has minOccurs=0, and it is done the same in MIF file by automatic generation in wsdlcvt command):

     <xs:element name="getFundAssets">
                    <xs:complexType>
                         <xs:sequence>
                              <xs:element name="clientCode" type="xs:string"/>
                         </xs:sequence>
                    </xs:complexType>
               </xs:element>
               <xs:element name="getFundAssetsResponse">
                    <xs:complexType>
                         <xs:sequence>
                              <xs:element name="fundAssets" type="ns:FundAssets"/>
                         </xs:sequence>
                    </xs:complexType>
               </xs:element>
               <xs:complexType name="FundAssets">
                    <xs:sequence>
                         <xs:element maxOccurs="unbounded" minOccurs="0" name="fundAsset" nillable="true" type="ns:FundAsset"/>
                    </xs:sequence>
               </xs:complexType>
               <xs:complexType name="FundAsset">
                    <xs:sequence>
                         <xs:element name="name" type="xs:string"/>
                         <xs:element name="valuation" type="xs:double"/>
                         <xs:element name="currency" type="xs:string"/>
                    </xs:sequence>
               </xs:complexType>

Output data in WSDL looks like beneath. Service is used to get records from database. While there are no records only empty <fundAssets/> tag is returned. When there are records sets of <fundAsset/> are returned.

The problem with TPEITYPE occures only while there are no records in response. While there are <foundAsset> tags inside <fundAssets>- unparsing goes OK and I can easly take data after tpcall in my tuxedo service.

The return data (in ULOG) looks like this (while error):

<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<ns1:getFundAssetsResponse xmlns:ns1="http://www.aaa.com/webservices/types">
<fundAssets />
</ns1:getFundAssetsResponse>


Logs from ULOG:

180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:parse_header_field() return 4
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: NotFound>Receive
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: WAKEUP>Receive
180450.ibmwbk!ud32.1978594.1.-2: TRACE:at: { tpgetrply(0xfffffffffffe390, 0xfffffffffffe3a0, 0xfffffffffffe398, 0x80)
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: WAKEUP>Receive
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: WAKEUP>Receive
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: WAKEUP>Receive
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: WAKEUP>Receive
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: WAKEUP>Receive
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: WAKEUP>Receive
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: Found>ParseHTTP
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:HTTP Parsing: Buffer length 5 -- 0


180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: OK>HTTPDispatch
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:A HTTP message is received, SCO index=4095
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: HTTPOK>ParseSOAPHeader
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: Default>ParseHeaderRoot
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:A SOAP message is received, SCO index=4095
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: None>ParseSOAPBody
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: Default>ParseBodyRoot
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: OK>ParseBodyElement
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: OK>WSSEPolicyCheck1
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: OK>WSRMHandle1
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: Default>FindService
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: OK>XML2Tux
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: OBFail>Error
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: Outbound>EnTuxedoQ
180450.ibmwbk!GWWS.3584208.1036.0: TRACE:ms:SCO[4095] FSM State Transition: Default>PutToCallingQ
180450.ibmwbk!GWWS.3584208.1291.0: TRACE:ms:SCO[4095] FSM State Transition: WAKEUP>EnTuxedoQ
180450.ibmwbk!WSSopoi.3518604.1.0: TRACE:at: } tpcall = -1 [tperrno TPEITYPE]
180450.ibmwbk!GWWS.3584208.1291.0: TRACE:ms:SCO[4095] FSM State Transition: WAKEUP>ReadyDeletion
180450.ibmwbk!WSSopoi.3518604.1.0: TRACE:at: { tpcall("inwLogSerwer", 0x1100dcdd8, 0, 0x110000e08, 0xfffffffffffe280, 0x0)
180450.ibmwbk!GWWS.3584208.1291.0: TRACE:ms:SCO[4095] FSM State Transition: OK>Delete


Where is the problem?

MIF file (as you can see there are requiredcount and count set to '0' so there should be no need to send <fundAsset> tag):

          param=fundAssets
          access=out
          paramschema=XSD_E:fundAssets@http://www.aaa.com/webservices/types
          type=fml32
          (
               param=fundAsset
               access=out
               paramschema=XSD_E:fundAsset@http://www.aaa.com/webservices/types
               requiredcount=0
               count=0
               type=fml32
               (
                    param=name
                    access=out
                    paramschema=XSD_E:name@http://www.aaa.com/webservices/types
                    type=string
                    primetype=string

                    param=valuation
                    access=out
                    paramschema=XSD_E:valuation@http://www.aaa.com/webservices/types
                    type=double
                    primetype=double

                    param=currency
                    access=out
                    paramschema=XSD_E:currency@http://www.aaa.com/webservices/types
                    type=string
                    primetype=string
               )
          )


FML file:

clientCode     1     string     -     fullname=clientCode, schema=xs:string
currency     2     string     -     fullname=currency, schema=xs:string
fundAsset     3     fml32     -     fullname=fundAsset, schema=ns:FundAsset
fundAssets     4     fml32     -     fullname=fundAssets, schema=ns:FundAssets
name     7     string     -     fullname=name, schema=xs:string
valuation     8     double     -     fullname=valuation, schema=xs:double



Maybe some fields are not recognized... Is there a diference between: <fundAssets /> and <fundAssets></fundAssets> ?
I got no more ideas... because while I got all data with <fundAsset> inside everything is OK.

Edited by: user9100925 on 2012-06-12 23:47

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points