SOA40 Getting Rejected on the Bus How Open
SOA-40: Getting Rejected on the Bus How Open. Edge® Developers Deal with Failure David Cleary Principal Software Engineer
“It is possible to fail in many ways… while to succeed is possible in only one way” Aristotle – Greek philosopher 2 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Open. Edge and Sonic™ ESB § You can align business and IT goals using § § 3 Sonic and Open. Edge in your SOA You can create robust and flexible business applications You can handle failures in your infrastructure, applications, or data SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Agenda Dealing with rejection on the bus § Sonic ESB Endpoints § Faults and rejected messages § Quality of Service (QOS) and Message Time § § § 4 To Live (TTL) Application architecture and App. Server™ operating modes Fault processing options App. Server Down!!!! SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Terminology § Service • Your Open. Edge based application exposed to Sonic ESB through the Sonic Adapter § Process • A Sonic ESB process that uses an itinerary to execute 1 or more operations on 1 or more services § Container • A Sonic managed executable process that hosts processes and services 5 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Sonic ESB Endpoints § Destination where ESB services and § § processes send and receive messages Can be associated with a Queue or Topic 4 defined Endpoint types for Services • • 6 Entry (required for services) Exit (usually Reply. To) Fault RME SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Open. Edge ESB Adapter Architecture Entry Endpoint Fault Endpoint Adapter App. Server Rejected Endpoint Exit Endpoint 7 SOA-40: Getting Rejected on the Bus Database © 2008 Progress Software Corporation
Faults and Rejected Messages § Rejected Messages • • Invalid message types Invalid data Adapter exceptions Failure to send result § Fault Messages • Infrastructure issues • Applications errors (RETURN ERROR) § Service has Fault and Rejected Message endpoints 8 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Anatomy of a Rejected Message <SOAP-ENV: Body> <xq: rejected. Message. Info xmlns: xq=“…"> <rejected. Code>OPENEDGE_INVOCATION_ERROR</rejected. Code> <rejected. Location container="dev_Open. Edge. Test" host="pcdcleary" process="Check. Customer" service. Application="dev. Open. Edge" step="Find Customer" top. Level. Process="Check. Customer"/> <rejected. Details> {Error message and stack trace} </rejected. Details> 9 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Anatomy of a Fault Message <exception xmlns=“…"> <message>Fault String: Session. Pool : No. Available. Sessions[Could not connect to the App. Server: <fault. Details < message> General Error: Connection refused: connect. container="dev_Open. Edge. Test" (7203)]</message> <class> Fault String: Session. Pool : host="pcdcleary" <class>com. progress. open 4 gl. dynamicapi. Session. Pool. No. Available. Sessions[Could not connect com. progress. open 4 gl. dynamicapi. Sessio process="Check. Customer" ailable. Sessions. Exception</class> to the App. Server: General Error: n. Pool. No. Available. Sessions. Exception service. Application="dev. Open. Edge" <detail> Connection refused: connect. (7203)] step="Find Customer" <fault. Details </class> container="dev_Open. Edge. Test" host="pcdcleary" process="Check. Customer" top. Level. Process="Check. Customer" /> </message> service. Application="dev. Open. Edge" step="Find Customer" top. Level. Process="Check. Customer" /> </detail> 10 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Quality of Service § Best Effort • Default • Messages may be lost or redelivered § At Least Once • No lost messages • May be redelivered § Exactly Once • Most reliable • No lost or redelivered messages 11 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Message Time To Live § Specifies a timeout on a process § Messages that timeout sent to RME § Default is 0 (no timeout) 12 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Configuring Properties § Service • Fault and Rejected Message endpoints • Can be overridden by process § Endpoint • Entry endpoint specifies QOS • Process sets minimum QOS § Process • Time to Live 13 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Application Architecture and Operating Modes § Sonic container and Open. Edge App. Server treated as single unit • Sonic provides networking • Fewer faults due to App. Server availability • ESB Service and Open. Edge App. Service same § Session-free operating mode recommended • Each operation does complete unit of work • No state saved on App. Server • Persistent procedures defeat this architecture 14 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Session-managed and Persistent Procedure Issues § Requires three calls for a single operation § Saves state on App. Server even with Session§ § § 15 free App. Server still bound due to fault or rejected message Limits scalability Enable Intra-Container messaging to mitigate issues SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Fault Processing Options § Settable per operation § Fault Only (Default) • Original message lost § Fault and Original message • Original message can be remediated and resubmitted § Rejected and Original message • Same as above, but rejected format § Continue process with Fault 16 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Fault Processing Options 17 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Booking a Vacation Coordinator Service Client 18 Flight Booking SOA-40: Getting Rejected on the Bus Hotel Booking Car Booking © 2008 Progress Software Corporation
Book Hotel Room Process 19 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Checking Availability § Yes, there are rooms available • Process/transaction continues § No, there are not rooms available • Entire transaction fails § I don’t know if rooms are available • App. Server down • No available agents 20 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Fix problem and resubmit 21 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
App. Server Down Demo!!! 22 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Agenda Dealing with rejection on the bus § Sonic ESB Endpoints § Faults and rejected messages § Quality of Service (QOS) and Message Time § § § 23 To Live (TTL) Application architecture and App. Server operating modes Fault processing options App. Server Down!!!! SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
In Summary § You can align business and IT § § 24 goals using Sonic and Open. Edge You can create robust and flexible business applications You can handle failures in your infrastructure, applications, or data SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
For More Information, go to… § PSDN • Introducing Native Invocation with the Open. Edge Adapter for Sonic ESB • Progress Sonic ESB Developers Guide Resubmit Sample § Progress e. Learning Community: • Open. Edge Development with Sonic ESB • Designing ESB Processes • Orchestrating Services with Sonic BPEL Server 25 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Relevant Exchange Sessions § SOA-11: Common Applications for Sonic § § § 26 ESB SOA-23: Enterprise Integration Patterns in Sonic ESB SOA-30: Getting the Most Out of Sonic Workbench SOA-33: Transactions in an SOA World SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
? Questions 27 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
Thank You 28 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
29 SOA-40: Getting Rejected on the Bus © 2008 Progress Software Corporation
- Slides: 29