DEV Community

Cover image for Cloud native - a Beginner guide
Ornélio Chaúque
Ornélio Chaúque

Posted on • Edited on

Cloud native - a Beginner guide

If you are the type of person who likes to be updated on the current technology industry and watch video conferences about software development and follow IT gurus on social media like twitter you certainly have heard about cloud native application, cloud native architecture and cloud native infrastructure.

Nowadays there is a lot of data and information about cloud native ones that are more clear and understandable than others, with this post, I want to contribute with some useful information (I hope so) about the subject here in discussion.

Before all other aspects, like what cloud native are and how to implement it, we must answer what I think is the genesis, root or basic question: the Why?

It is crucial and important to understand the motivation behind the implementation and development of cloud native applications. Although there might exist many other motivations and reasons for implementation and development, the need to develop applications that take advantage and inherit the cloud computing feature and capabilities was the key factor.

Those features and capabilities are:

  • Scalability
  • Availability
  • Security
  • Fault tolerance
  • Portability

There are many other features and capabilities that cloud provides to us but the one listed above might be the ones which were the key.

The cloud gives us infrastructure and resources that allow good scalability, availability, security, portability, fault tolerance, etc. Why not create an architecture and infrastructure that will allow us to take full advantage of all those features and capabilities? So, simply saying, the main reason behind the implementation and adoption of cloud native applications was to create applications with an architecture that takes advantage and inherits those cloud features and capabilities.

After talking about the why? is important to understand what cloud native applications are.

Before we dive deep into cloud native itself, let's have a brief understanding of what native applications are.

When we talk about native applications we look to applications that are designed to a specific environment or infrastructure. The native applications are the ones that capitalize and take the advantage of the component and resources of the underline environment or infrastructure. This happens when we talk about developing native mobile applications with java, kotlin or developing desktop applications for example with C++ or C. As those tools are designed for those environments, they take full advantage of the existence resources like processing hardware, network and storage.

On other hand, non native applications mostly known as hybrid applications are those developed to run in more than one specific environment or infrastructure and they are developed with tools and technologies that are not designed with the goal to run on some specific environment or infrastructure. Most of the time, hybrid applications don’t take full advantage of the available resource and component and suffer with performance issues because of the need of some middleware component that stands in between the application itself and the environment or infrastructure and this indirection has a cost (performance).

As we said before, we can create desktop and mobile applications that are not desktop or mobile native, so the same happens on cloud, meaning, we can develop cloud applications that are not cloud native applications.

There is two main aspect to note in the explanation above about native applications:

  1. The main aspect is, to be considered native application, the application must be developed with tools and technologies designed to that environment;
  2. The application must take the advantage of the resources and components of that specific environment and infrastructure. This second aspect is deeply dependent on the first aspect.

With all that said, is far to conclude that:

Cloud native applications are those applications designed to run specifically in cloud native infrastructure, developed using tools and technologies that are designed specifically to develop those types of applications and must take full advantage of cloud resources and infrastructure features.

Now we know Why and what cloud native applications are, it is time to understand and to know How they can be implemented.

For Cloud native applications it is important to understand that it is not only about how we develop the applications, it is about how we deploy it too.
When we talk about how we develop it, we are talking about cloud native architecture, which specifies the way the applications are designed and by how we deploy it, we are talking about Cloud native infrastructure, which specifies how the applications should be deployed, a how the components talk and communicate with each other.

Cloud native architecture

Before cloud native architecture and all aspects related to cloud native applications, we used to develop cloud applications using “legacy architecture” like monolithic. In monolithic when a component on the application crashes, the entire application crashes. Another aspect that monolithic applications don’t capitalize very well is the scalability features. Suppose we have monolithic application with many modules, its possible to happen that some module have many request than others and for performance reason we take the action to scale, in monolithic we will have scale the entire application instead of only the modules really need to scale the one that create need for that scale action. With those and other reasons, the need of creation and implementation of a new way and architecture to develop cloud applications had a relevance and importance.

To develop cloud native applications that take advantage of the cloud feature and capabilities, we must take another approach and take a new way of thinking and developing cloud applications, like the former service oriented applications (SOA) and the new one, more robust and more granular implementation of SOA known as Microservice architecture.

In service oriented architecture, the applications are segmented in small components called service, which work together to accomplish a specific goal, the communication between them are made by API or message bus solutions implementations. This architecture allows isolated scaling, isolated failure which makes them better than monolithics.

Cloud native applications are developed using microservice architecture which is a more granular implementation of SOA and another important aspect is that in microservice architecture each micro service is self contained, meaning that these services hold all needed resources to work in isolation which may include on database. By self contained we are not saying that all the application runs in a single container, we are saying that the micro service holds all needed resources to their task without sharing that with other microservice.

Cloud native infrastructure

As we say before, to take advantage and inherit the cloud native features and capabilities is not only about defining a new way of developing and architecting cloud applications, it's about creating and implementing an environment and infrastructure to deploy and run cloud native applications. We will not have much gain in developing cloud applications and run a legacy infrastructure, that is way cloud native infrastructure is important in cloud native world.

Nowaday, cloud native infrastructure provides lots of resources that allow pack and distribute cloud native applications(containerization like Docker), deployment and management/orchestration (Kubernete), communication (Consul), monitoring (prometheus), logging (fluentd)etc. For each type of resource you will find more than one option. Choose which use is up to you.
The Cloud Native Computing Foundation is the entity that manages all those cloud native infrastructure components. I really advise you to take a look at their website to have more information about.

To finish this article, it is important to note that although the best way to develop cloud native applications is by implementing microservices architecture, it is still possible to use legacy architecture like monolithic to develop cloud application and deploy then in a cloud native infrastructure, but there's a price to pay, for example the scalability and failure or crashes issues that we mention early.

References:
https://searchcloudcomputing.techtarget.com/definition/cloud-native-application
https://www.redhat.com/en/topics/cloud-native-apps
https://www.cncf.io/

Top comments (0)