For a long time, we’ve been hearing that migrating to the cloud can result in savings ranging from tens of thousands to even millions of dollars, depending on the project’s scale. Cloud providers are competing by introducing new services that increasingly automate the migration process, thereby helping to reduce its costs. But is it always worth migrating your system to the cloud? Is it cost-effective in every case? When is it better to opt for a hybrid solution, and when is it best to avoid the cloud altogether? What does the title’s “pitfall” refer to, which is easy to step on, and how can you steer clear of it?
This won’t be a guide in the style of “when this happens…, you must do…”. Unfortunately, it doesn’t work that way because systems are built with different technologies, have unique architectures, and face varied requirements. Creating a universal guide for everyone is simply not possible. However, in this article, I will highlight what to consider during cloud migration and when it might be worth exploring alternatives to full migration, such as hybrid cloud solutions.
Why we need the cloud?
Depending on the stage of development your company and system are at, the cloud can offer you various benefits. I intentionally use the word “offer” instead of “give” because these possibilities need to be properly utilized, ideally in an optimal manner.
AI solutions
Nowadays, it’s hard to imagine development without AI models, which increasingly automate many aspects of business operations. Public clouds provide many AI- and ML-powered solutions. They also offer mechanisms that facilitate managing the model lifecycle, known as MLOps.
Deploying models in an on-premises environment is possible, but it requires substantial financial investment due to the need for using graphics cards.
Cloud scalability
It’s one of the main benefits of public clouds, as from our perspective, we have access to nearly unlimited resources. We can dynamically adjust the number of resources according to our current needs. As a result, the system’s operational costs are lower because there’s no need to purchase hardware in advance.
Cloud scalability proves very useful in the following cases:
- seasonality,
- quick market entry with a new product/service,
- cost optimization by scaling down.
Cost savings
Apart from the savings resulting from the ability to scale according to needs, savings related to software licenses can also be achieved, including licenses for databases, container platforms, network firewalls, and others.
During cloud migration, for relational databases, one can opt for PostgreSQL. However, this is not a typical open-source database, but a cloud provider’s implementation based on open-source specifications. Similarly, the situation applies to container runtime platforms – in public clouds, one can opt for Kubernetes service, with the cloud provider handling all control plane and worker management.
Ensuring business continuity
Depending on the type of business, IT system failures can lead to smaller or larger damages in terms of the scale of opportunity lost.
Ensuring high availability in an on-premises environment is costly, as it involves duplicating hardware, cooling systems, power protections, etc. In larger companies, the costs of the server rooms can be distributed across multiple departments, but for smaller companies, building such a solution from scratch is very expensive.
In the case of public clouds, high availability is somewhat built into the infrastructure and cloud platform.
Global exposure
Cloud providers have many data centers and even more PoPs (Points of Presence). When deploying a system in the cloud, we can choose in which region it will be physically hosted. We can run the system regionally or globally. The chosen solution affects the latency in delivering data to the end customer.
In this chapter, I intentionally omitted security and compliance aspects, as they should be seen more as a requirement to meet the demands imposed by regulators in a given market or region rather than as tangible benefits they bring.
What is the titular “pitfall” and how to avoid it?
Before I discuss the best reasons for migrating to the cloud and when it can be profitable, I must first address the titular “pitfall” and explain what I mean by it.
From the previous chapter, one might get the impression that the public cloud is nearly perfect and that migrating a system to the cloud offers only benefits. However, as I mentioned at the beginning, the public cloud provides various advantages that require the right approach to be truly effective.
By “pitfall,” I mean a situation where our expectations or assumptions diverge from reality. It happens when cloud migration doesn’t yield the expected results and adapting a system to the cloud proves more expensive than anticipated.
Starting a cloud migration requires creating a so-called “Landing Zone”. It includes preparing the outline of the future organizational structure in the cloud – branches/projects, defining user groups, assigning them appropriate permissions, and configuring automation and restriction policies, and much more. Once it’s done, especially in the case of large and complex organizations, we might feel that the worst is over. In truth, though, the bulk of the work is yet to come.
Cloud migration – Clear business objective
Setting business goals that we aim to achieve through cloud migration is a fundamental step that must be taken at the very beginning. These clearly defined objectives will determine the strategy and direction of the entire migration process.
For example, if the business goal is to expand into South America, the initial focus will be on tasks that ensure the system is available on the targeted continent. Improving other parameters such as performance, scalability, or cost optimization will be less prioritized.
Another example: if the business goal is to reduce maintenance costs by 20% annually, we will start by identifying the systems with the highest maintenance costs and analyzing their sources. The solution might involve better utilization of hardware resources, improving software development processes, or even changing the system architecture using native cloud components.
Cloud migration without clearly defined, measurable business goals makes it impossible to assess whether the project has succeeded or failed. During the project’s execution, there will be no way to verify assumptions and evaluate whether the work is going according to plan.
Another aspect is ensuring that both the investor and the contractor have a shared understanding of the defined business goals. Specifying success metrics may prove helpful.
Measuring implementation
In order to assess the achievement of business goals objectively, metrics must be defined, allowing for quantifiable determination of their effectiveness.
In the case of cost optimization, the metric could be the amount on the monthly invoice for system operation in the cloud. For performance, a key measure could be, for instance, the maximum capacity for handling traffic.
Cloud migration plan
With defined business objectives and metrics to determine whether the business goal has been achieved, it’s time for the migration plan.
It’s definitely the most challenging task, and very often such a plan either doesn’t materialize or is very superficial. To develop a migration plan, an analysis must be conducted beforehand to answer questions such as:
- Which systems will be migrated and in what order?
- How will the migration affect the business operations?
- What will the transition process look like?
- Which migration strategy to choose?
- Will native cloud services be used?
- How will the Software Development Lifecycle (SDLC) process be managed?
- Is the current system architecture suitable for efficient operation in the cloud, or does it require refactoring or architectural changes?
- What will be the costs of architectural changes?
- What will be the total migration costs?
- What will be the anticipated costs of operating the system in the cloud?
- Does my organization have the necessary competencies to perform the migration and later maintain the system in the cloud?
- Are there any legal/regulatory restrictions to migrating a particular system to the cloud?
A lack of a precise migration plan likely indicates a lack of analysis and defined architecture for the target solution.
When is it worth migrating to the cloud?
Knowing the capabilities, risks, and threats associated with the cloud, we can now get to the essence of this article, addressing the question posed in the title: when is it beneficial to leverage cloud possibilities?
Dividing this topic into two parts, I will discuss the criteria to consider when migrating the entire system to the cloud. Additionally, in cases where this option isn’t available, I will explore alternative cloud utilization methods.
Moving the entire system
There are many strategies for migrating a system to the cloud, but all can be reduced to three key approaches:
- lift & shift,
- replatform,
- rearchitecture.
The cost of migration and operating in the cloud depends on the current system architecture and the chosen migration strategy.
The cheapest strategy will be lift & shift because the system will literally be transferred to the cloud in its current state. Conversely, the most expensive option will be changing the system architecture because it will likely involve rewriting many of its functionalities.
Lift & shift may appear to be the optimal choice, but considering the costs of cloud operation, the situation is more nuanced:
As shown in the above diagram, the system based on cloud-native architecture is the cheapest to maintain due to several factors:
- Cloud-native architecture often consists of many small services (microservices), which makes it easier to allocate the necessary resources effectively. Additionally, when scaling up is needed, it involves fewer services compared to monolithic systems, leading to more efficient resource utilization.
- The closer the architecture is to cloud-native, the more the responsibility for the overall infrastructure shifts to the cloud provider.
- Managing the lifecycle of a cloud-native architecture system and the entire CI/CD process is more cost-effective than with monolithic systems.
In general, when deciding about migration, it’s important to consider what level of cloud services we’ll be able to utilize. As shown in the illustration above, the further to the right, potentially the greater the savings and flexibility.
When is full system migration to the cloud cost-effective?
- For new systems developed in cloud-native technology. The cost of their migration is low, while the benefits are numerous.
- For solutions with uncertain market reception. There’s no need to invest in hardware.
- For legacy systems with an existing and implemented plan for modernizing the technology stack to leverage PaaS/SaaS services.
Partial migration – hybrid cloud
Migration to the cloud doesn’t necessarily mean the need to transfer the entire system, which can sometimes be very costly. A good solution is to identify individual needs that can be addressed using cloud services.
Data archiving and backup storage
Storing data in the cloud can be a very cost-effective solution. Additionally, it doesn’t require continuous planning for the expansion of our infrastructure.
A suitable solution for these applications is object storage, which is theoretically infinitely scalable. Moreover, it has several layers, differing in terms of data storage costs and data access costs. For data archiving, the ideal solution is to use the archival layer, whose storage cost is the lowest and the need to access data is very rare.
Disaster Recovery Plan (DRP)
Employing the public cloud can prove beneficial for disaster recovery purposes. In such scenario, all or the most critical services of a system can be temporarily launched in the cloud.
While preparing the cloud setup naturally requires investment and running system tests, maintenance costs mainly revolve around data synchronization and support for a small set of services.
Expanding data center capabilities for seasonality and unforeseen traffic spikes
The cloud is a solid solution to expand data center capabilities and protect against seasonal traffic spikes or those resulting from planned marketing campaigns. Spot Virtual Machines can be used for this purpose, bringing substantial cost savings, often exceeding 80%. Unfortunately, there is a risk that the cloud provider may reclaim them at any time as they’re part of its inventory.