To containerize or not to containerize - Approach and Considerations
Sandeep Ghildiyal
Industry Leader| Cloud Enthusiast| Talent & Capability Builder| Managing Director & Global Lead- Cloud Transformation & Migration Studio & Infrastructure Engineering for Financial Services at Accenture India
Advantages of moving to containers are well known and widely accepted in the industry. Apart from other advantages, containers allow applications to be abstracted from the environment in which they run thus providing portability across hybrid cloud environment and reducing the risk of vendor lock-in. Compared to VMs, containers are far more lightweight start much faster, and use a fraction of the memory compared to booting an entire OS.
However, this article is not to discuss the pros and cons of containers but to discuss the options and considerations for migrating applications to containers. The three options for migrating applications to containers are:
- Lift and Shift - Run an existing monolithic application within a single container. Lift and Shift is a misnomer as even though you may want to lift and shift your monolithic application to containers, it will require some bit of re-architecting and optimization. Also, while you most likely can package that application in a single container and then run it in Kubernetes, it’s rarely the best way to get it to the cloud though it adds much needed speed and agility to applications that still need to be changed.
- Re-Architecture - Augment and reshape applications so they can take advantage of the new distributed architecture. This approach provides application the ability to leverage the cloud features at a lower cost and time compared to rewriting/refactoring the application.
- Refactor - Entirely redesign and re-write your legacy applications. Refactoring an application for containers leveraging micro-services architecture is a cleaner way to adopt containers and leverage the full potential of cloud. However, it is a more expensive and time-consuming exercise which requires the participation from the business.
Having considered the options, lets look at the considerations to decide what should and what should not be containerized.
Most of the custom-built applications used across industries today were designed and built before the container evolved as a technology. Application migration to containers requires reinstalling/redeploying every time you build a new version of the container image. Since application deployment needs a good collaboration and efforts between Business and IT during installation and integration, it’s important to perform a thorough application assessment to decide what should and what should not be containerized. Accenture myNav is a new cloud platform designed to assess, disposition, architect and simulate cloud solutions (including migrations to containers) at scale to determine which will best fit your business requirements. Right application assessment and disposition using tools like myNav is very important as the clients today are struggling in deriving value from cloud as they are not able to deeply assess what will work for them.
Below table provides a view of a few characteristics of applications in a client’s environment which helps decide the complexity of migrating applications to containers.
Looking at above considerations, it is easier to containerize applications which have good separation of code, configuration, and data. A good example here would be applications using Apache and MySQL where the binaries are provided via RPMs or packages and the configuration and data is by default located in /etc/my.cnf or /etc/httpd.conf. and in /var/lib/mysql or /var/www/html respectively.
The second factor is the availability of a packaged and well documented installation process. Since application migration to containers requires reinstalling every time you build a new version of the container image, a clean and well documented installation process will greatly simplify the migration. Apart from the well written documentation, it is easy to containerize the application when it is delivered as binaries in a package format or a source code.
Based on above considerations, it is easier to containerize applications like web servers and applications built on application and Middleware platforms like JBoss, Tomcat etc.
On the other hand, propriety and COTS applications like ERP and CRM with restrictive licensing is difficult to containerize.
Conclusion
The benefits of containerizing micro-services applications are immediate and well known. However not all applications are fit for migrating to containers and may not provide much business benefits. Before embarking on your containerization journey, it is necessary to evaluate and identify the right candidates and approach which can give you the true business benefits.
For Lift and Shift of monolith Applications, containerization may noty be the best option and you may want to look at other options like Re-platforming, Virtualization etc. as alternatives. Good article for bringing out the benefits of containorization.
Global Director Cloud Managed Services
4 年Nice and simple representation. Sandeep
Head - Enterprise Systems and Platforms - CIO Office
4 年Good one Sandeep Ghildiyal
Partner at Everest Group | Cloud, Infra & Cybersecurity | Technology cost optimization | Benchmarking
4 年Very insightful. Thanks for sharing.