Ce SOA& Web s 教育部-BM专业综合改革项目 SOAP RPC request- Example <?xml versional.0 encoding="UTE-8?> <soapenv: Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/ xmlns:xsd="http://www.w3.org/2001/xmlschema" xmlns:g0="http://calculator.ibm.com"> <soapenv: Body <a0: addo> <q0: inputl type=xsd: int" >5</q0:input1> <q0: input2 type=xsd: int" >3</g0: input2> </q0: adop> </soapenv: Body> </soapenv: Envelope> Lan Zhou University
SOA & Web Service Lan Zhou University 教育部-IBM专业综合改革项目 SOAP RPC request — Example
Ce SOA& Web s 教育部-BM专业综合改革项目 SOAP RPC response- Example <?xml version=1.0 encoding=UTE-8?> <soapenv: Envelope xmins:soapenv=http://schemas.xmlsoap.org/soap/envelope/ xmlns:xsd="http://www.w3.org/2001/xmlschema" xmins="Http://calculator.ibm.com"> <soapenv: Body> <addopResponse> <return>8</return> </addOpResponse> </soapenv: Body> </soapenv: Envelope> Lan Zhou University
SOA & Web Service Lan Zhou University 教育部-IBM专业综合改革项目 SOAP RPC response — Example
Ce SoA Web s 教育部-BM专业综合改革项目 SOAP Fault(env: Faults) Used to carry error andlor status information Four sub-elements faultcode aultstring faultactor detail Lan Zhou University
SOA & Web Service Lan Zhou University 教育部-IBM专业综合改革项目 SOAP Fault (<env:Fault>) ▪ Used to carry error and/or status information ▪ Four sub-elements – faultcode – faultstring – faultactor – detail
SoA Web s 教育部-BM专业综合改革项目 SOAP fault code values SOAP V1.1 SOAP V1.2 Description Version Mismatch Version Mismatch The namespace or local name for a SOAPEnvelope object was invalid MustUnderstand MustUnderstand An immediate child element of a sOAPHeader object had its mustUnderstand attribute set to true, and the processing party did not understand the element or did not obey it Client Sender The SoAPMessage object was not formed correctly or did not contain the information needed to succeed Server Receiver The soAPMessage object could not be processed because of a processing error, not because of a problem with the message itself N/A Data EncodingUnknown A SoAP header block or SoAP body child element information item targeted at the faulting SoAP node is scoped with a data encoding that the faulting node does not support. DTDNotSupported Generated when a received message contains a document type declaration. Lan Zhou University
SOA & Web Service Lan Zhou University 教育部-IBM专业综合改革项目 SOAP fault code values
Ce SOA& Web s 教育部-BM专业综合改革项目 SOAP Fault Example: Cause <env: Envelope xmins:env=http://www.w3.org/2001/06/soap-envelope'> <eny: Header <abc: Extension xmins:abc=http:/lexample.org/2001/06lext env: mustUnderstand=1> <def: Extension xmins:defhttp:lexample.com/stuff eny: mustUnderstand=1> </env: Header <env: Body> <lenv: Body> </env: Envelope> Lan Zhou University
SOA & Web Service Lan Zhou University 教育部-IBM专业综合改革项目 SOAP Fault Example: Cause <env:Envelope xmlns:env='http://www.w3.org/2001/06/soap-envelope'> <env:Header> <abc:Extension1 xmlns:abc='http://example.org/2001/06/ext' env:mustUnderstand='1' /> <def:Extension2 xmlns:def='http://example.com/stuff' env:mustUnderstand='1' /> </env:Header> <env:Body> . . . </env:Body> </env:Envelope>