Presentation is loading. Please wait.

Presentation is loading. Please wait.

Handling SOAP Faults. Simplify your business Handling SOAP Faults 2 Overview When you complete this lesson you should be able to: n Describe what a SOAP.

Similar presentations


Presentation on theme: "Handling SOAP Faults. Simplify your business Handling SOAP Faults 2 Overview When you complete this lesson you should be able to: n Describe what a SOAP."— Presentation transcript:

1 Handling SOAP Faults

2 Simplify your business Handling SOAP Faults 2 Overview When you complete this lesson you should be able to: n Describe what a SOAP Fault is n Describe the parts of a SOAP message n Describe the elements of a SOAP Fault n Implement the 4GL code to handle a SOAP Fault

3 Simplify your business Handling SOAP Faults 3 Ignoring a SOAP Fault 4GL application RUN GetInvoice IN hPortType (INPUT iInvoiceNum, OUTPUT cInvoice). GetInvoice_Response ( ) SOAP Fault GetInvoice_Request (iInvoiceNum) Web service operations:... GetInvoice: {... RETURN ERROR “Invoice not found”.... } NO-ERROR was not used

4 Simplify your business Handling SOAP Faults 4 The SOAP Message SOAP Envelope SOAP Body SOAP Envelope To Web service From Web service (success) From Web service (failure) operation name input parameters SOAP Body SOAP Fault SOAP Body operation name output parameters

5 Simplify your business Handling SOAP Faults 5 SOAP Fault element SOAP-ENV:Server An error was detected while executing the Web Service request. (10893)... using urn:OpenEdgeServices:NewCoService

6 Simplify your business Handling SOAP Faults 6 SOAP Fault detail element msg=The server application returned the error: Invoice not found; targetException=ERROR condition: The Server application has returned an error. (7243) (7211)] e5b58beb30:5bb966:fb5df25c30:-7fff#8c

7 Simplify your business Handling SOAP Faults 7 Lab 7-1: Generating and viewing a SOAP Fault

8 Simplify your business Handling SOAP Faults 8 Handling a SOAP Fault RUN SendOrders IN hPortType ( INPUT cOrders, OUTPUT iInvoiceNum) NO-ERROR. IF ERROR-STATUS:NUM-MESSAGES > 0 THEN DO: /* now look into what the content is for the SOAP Fault */ END. 1 2

9 Simplify your business Handling SOAP Faults 9 ERROR-STATUS object hierarchy ERROR-STATUS ERROR-OBJECT-DETAIL SOAP-FAULT-DETAIL

10 Simplify your business Handling SOAP Faults 10 The faultstring in a SOAP message SOAP-ENV:Server An error was detected while executing the Web Service request. (10893) msg=The server application returned the error: Invoice not found; targetException=ERROR condition: The Server application has returned an error. (7243) (7211)] e5b58beb30:5bb966:fb4fdb744a:- 7fff#9

11 Simplify your business Handling SOAP Faults 11 The detail in a SOAP message SOAP-ENV:Server An error was detected while executing the Web Service request. (10893) msg=The server application returned the error: Invoice not found; targetException=ERROR condition: The Server application has returned an error. (7243) (7211)] e5b58beb30:5bb966:fb4fdb744a:- 7fff#9

12 Simplify your business Handling SOAP Faults 12 Accessing the SOAP-FAULT-DETAIL SOAP-FAULT-DETAIL GET-NODE() GET-SERIALIZED() X-NODEREF LONGCHAR

13 Simplify your business Handling SOAP Faults 13 Content used for SOAP-FAULT-DETAIL SOAP-ENV:Server An error was detected while executing the Web Service request. (10893) msg=The server application returned the error: Invoice not found; targetException=ERROR condition: The Server application has returned an error. (7243) (7211)] e5b58beb30:5bb966:fb4fdb744a:- 7fff#9

14 Simplify your business Handling SOAP Faults 14 Lab 7-2: Handling a SOAP Fault

15 Simplify your business Handling SOAP Faults 15 Summary You should now be able to: n Describe what a SOAP Fault is n Describe the parts of a SOAP message n Describe the elements of a SOAP Fault n Implement the 4GL code to handle a SOAP Fault

16 Simplify your business Handling SOAP Faults 16 Review


Download ppt "Handling SOAP Faults. Simplify your business Handling SOAP Faults 2 Overview When you complete this lesson you should be able to: n Describe what a SOAP."

Similar presentations


Ads by Google