The database and application work hand in hand. When a client interacts with features on your website the application calls back to the database, and the database responds by giving it the right information or action. It’s a well-orchestrated conversation. When something happens that stops the conversation the application doesn’t get what it needs and the customer receives an error. This is where application continuity comes in. The idea is to enable maximum continuous communication between the application and your database instances even if there is an outage. This is a massive step in maintaining data integrity and improving the end user experience.
The first step in understanding continuity is virtualization. This means that your database layers are virtualized in the stack and your infrastructure can create multiple nodes and instances for your workload, shuffling transaction and processing usage as needed. It is useful for scaling up and down easily and allows more redundancy to protect in case of outages. When one node goes down, whether for scheduled maintenance or unexpected failure, the other nodes are there to take its place and your customer is never the wiser. There are some software products that can help you design this virtualization for continuity, but if you happen to be using Oracle 12c or 18c you can access application continuity drivers that will do the work for you.
The classic COMMIT call problem
Oracle’s team wanted to devise a solution to the classic COMMIT call problem. Let’s say you are interested in purchasing theater tickets, you select your criteria, enter your card information, and push the Buy Now button. That button creates a COMMIT call back to the database which should then take the appropriate action. In this case that would be to reserve the selected seats, charge your card, and send you a confirmation. But what happens when you get an error instead? Has the charge gone through? Should you reload and try again? These are frustrating questions for your customers to encounter. Sometimes it results in more than frustration, sometimes it results in duplicate purchases. The team at Oracle developed Application continuity as a tool in Oracle’s 12c and 18c database versions. This tool prevents errors for your end users, basically masking downtime and saving everyone a lot of headache. Scheduled maintenance windows and unplanned outages can frustrate your clients and developers, especially if they result in accidental duplicate purchases.
This specialized Oracle driver is a step up from high availability. It helps maintain your application functionality in the case of a database outage. When you have a database down, the Application Continuity driver spreads out your application connections across the remaining available database instances. This helps protect you from lost data or consistency issues. It also identifies and resubmits the last in-flight transaction, helping preserve any open calls so that your clients are never the wiser. They may experience a slight delay, but most work completes swiftly.
Failover and Replay
The application continuity drivers capture transaction information, tag it with a unique ID, and are ready to replay in the event of a node failure. In a typical example, your application calls to a specific database instance and waits for a response. If, for whatever reason, that response doesn’t come, the driver will then recognize the failure and attempt to reestablish a connection with a different node. It recreates the exact state of the transactional call, and then replays the call. The application then receives the information and is none the wiser. If the driver cannot recreate the exact database state, it will not continue with the replay, to make sure it does not provide inconsistent responses.
When It Helps
Application Continuity can help mask database outages as a result of timeouts, network storage issues, and recoverable errors with hardware or software. It won’t magically fix all issues, outages resulting from unrecoverable errors must still be addressed. It can help to maintain data integrity and mask maintenance or outage issues from your end users. Encountering errors on your website reduces client confidence and could become costly. Reducing those errors might be worth a second look.
Dobler Consulting is a full spectrum database service with 10 years of experiencing helping companies strategize and execute workload management solutions. Dobler Consulting is an Oracle Gold Partner and can help you plan or execute your database strategies no matter where you are in the process. For more information about how Dobler Consulting can help you understand Oracle’s database capabilities and Application Continuity, visit www.doblerconsulting.com or call us at +1 (813) 322-3240 (US) /+1 (416) 646-0651 (Canada).