Active-Active Environments in a Cloudy World

389 VIEWS

·

When multiple copies of an application are run in an environment, the environment is known as an active-active environment. Active-active environments have long been the goal for application deployments. Traditionally, applications had to be built to support the concept, and had to be run using some of the most expensive combinations of software and hardware available on the market. But now, with the advent of cloud Infrastructure and related technology advances, active-active environments are much more feasible for companies of any size.

Introduction

The concept of multiple copies of an application run for scalability, capacity, and failover purposes in an active-active environment configuration has been viewed as a utopia in the infrastructure space for as long as teams have deployed applications. An active-active environment exists when multiple copies of all layers of an application stack are alive and answering requests. Whether in a single data center or geographically distributed around the globe, a truly active-active environment will allow any part of the environment to fault without causing an interruption in service.

Environment Scenarios

Active-active is the pinnacle of application-available configurations. Some of the other application environment scenarios are:

  • No Redundancy – Only one copy of each component is running with no spare capacity.
  • Cold Recovery – Network, servers, and OS are installed with basic configuration, and no application-specific configuration. In a world with cloud infrastructure, this is the new starting point.
  • Warm Standby – Everything is more or less in place for the application to run, and some last-minute configuration is required to go live. An example would be applying software licenses or deploying the latest build of the application.
  • Active-Passive (a.k.a. Hot Standby) – Everything is up and running and configured. There are no active user sessions, but it can go live at any moment either through automation or manual activation.

The single most important and most difficult part of any active-active environment is having the underpinning data available and current in all locations where the rest of the application stack is running.

Database Availability in Non-Cloud Environments

In traditional IT enterprises, where technology stacks are mission-critical in non-cloud environments, the investment in software could include top-tier commercial software combinations like Oracle Global Data Services, which leverages Golden gate, or Oracle Data Streams and Oracle Enterprise Databases, which cost hundreds of thousands of dollars per CPU to install and run, but they guarantee data is synchronized between multiple instances of a database.

In smaller or more open-source friendly shops, MySQL or PostgreSQL are options with replication capabilities, including active-active (multi-master) to achieve data availability.

NoSQL Databases have for the most part been designed and built from day one to operate in a distributed computing model across multiple locations. Cassandra, MongoDB, and Redis all have documentation on how to build distributed production deployments.

Key Cloud Technologies

The top-tier major cloud infrastructure providers all have managed database solutions which can handle database replication, at a fraction of the cost and complexity of rolling your own.

For NoSQL databases, cloud providers often rely on the technology built into MongoDB or Redis to handle multi-site. Some cloud providers have rolled (or bought) their own NoSQL technology, like IBM CloudAnt and AWS DynamoDB, which have multi-site replication as a core feature.

SQL (Relational Database Systems) databases typically run in a master-slave model, including when being managed by cloud infrastructure providers. This model handles writes in a single location, with reads handled in multiple other regions, which allows applications to run in multiple regions, and the platform takes care of managing where writes happen. AWS RDS, Alibaba RDS, Google SQL, and Azure SQL Server all run this way. This model is proven and works across wide geographies, and as part of the cloud platform, failovers and replication are seamless, so applications run effectively in active-active environments.

Within the last year, cloud providers have started offering true multi-master replication options. AWS Aurora Multi-Master is available in preview. Azure Cosmos DB is also multi-master and has the capability to do relational functionality, although it is mostly considered a NoSQL database.

Summary

Modern approaches to application development, including building cloud-native apps and microservices, take scaling into consideration as part of their core design principles. With the availability of cloud computing infrastructures and multiple sets of production-tested open source libraries, an active-active environment is cost-effective and available for both enterprises and whatever-as-a-service providers.

Do you think you can beat this Sweet post?

If so, you may have what it takes to become a Sweetcode contributor... Learn More.

Vince Power is an Enterprise Architect at Medavie Blue Cross. His focus is on cloud adoption and technology planning in key areas like core computing (IaaS), identity and access management, application platforms (PaaS), and continuous delivery.


Discussion

Click on a tab to select how you'd like to leave your comment

Leave a Comment

Your email address will not be published. Required fields are marked *

Menu