Building cloud agnostic applications
As a consultant, I am often asked “What is the cloud solution we need to use and why?” Another common question is: “What is your favorite cloud provider?”
Well, a general question deserves general answer, like “all of them have their pros and cons.” Unfortunately, that doesn’t really help, right? So, my real answer is the following:
- 1. It’s OK to maintain a multi-cloud environment. Having all your eggs in one basket never helped.
- 2. Architect your workloads to be cloud-agnostic.
Let’s drill into it deeper.
Why do companies use multi-cloud environments?
Companies choose multi-cloud environments for multiple reasons. One common scenario is that different groups within an organization had their own journeys with unique software, long before the company even realized that they had a multi-cloud environment. Another scenario is that a company is in transition from one cloud service to another. Perhaps one team has vast experience in a particular cloud offering and convinced management to leverage that solution instead of another. You got the idea! There are multiple reasons for multi-cloud environments, and most of them can’t be controlled. The bottom line: multi-cloud environments are common—and a reality most organizations need to face.
The good news is: it’s OK! You can handle a multi-cloud landscape.
Best practices for working in a multi-cloud environment
For a large-scale solution, you might want to consider a CMP (cloud management platform) to get visibility across all cloud services involved. The downside? These tools might be costly, somewhat defeating the purpose of the changes you’re making.
Let’s talk about cloud agnostic architecture.
What is cloud agnostic architecture?
Cloud agnostic architecture is a unicorn. It’s hard to find. Luckily, you can get pretty close, especially if you think about your application as a cloud agnostic from the very beginning. You should build a tool while keeping in mind that some common components can be easily replaced. In practice, this requires some discipline in your coding style: build interfaces, abstraction layers, and use dependency injections.
Best practices for building cloud agnostic applications
- • Use containers wherever possible. Then you guaranteed that you application will run as expected assuming the inputs are the same.
- • Kubernetes is your friend. It’s easy to migrate application from one Kubernetes cluster to another. Use Kubernetes serverless functionality. Leverage K8 persistent storage capability.
- • Build CI/CD pipelines and automate environment creation. This will save time when migrating from one cloud to another.
- • Leverage managed offerings. Cloud providers provide prepacked solutions. Using these can save you time and money.
Difficulties moving between cloud solutions
One hand, some solutions require proximity to the compute, and in the other hand, solutions are better managed by the cloud provider. Therefore, it’s hard to move them from one cloud to another. This involves key management, DNS, and database layers. There are companies who claim they do it, but we have not seen that being widely used.
Cloud agnostic applications for the future
I anticipate seeing new solutions and providers in the market that will manage this infrastructure for you within any cloud provider. Once that niche is fulfilled, public clouds will become interchangeable, at least to a certain degree.
Looking for a new cloud solution?
See how Logic20/20 can help.
Ilya Tsapin is the Architecture Practice Area Lead at Logic20/20. He has experience in project management, architecture, Agile methodologies, and more. He has written about diverse topics including machine learning, IoT, cloud workload reliability, and Agile management.
Follow Ilya on LinkedIn