Cloud-Native Landscape and Best Practices
The ideal cloud-native landscape described by the CFNC is comprised of a number of standardizations of technologies, services, and tools.
Join the DZone community and get the full member experience.Join For Free
The cloud-native approach enables organizations to build modern applications by leveraging the advantage of cloud computing primarily based on PAYG (pay-as-you-go) pricing model. Cloud-native applications are designed loosely coupled & scalable which run on containerized and orchestrated platforms. They are hosted in dynamic environments such as public, private, and hybrid clouds.
This approach offers the following benefits:
- Faster time-to-market.
- Maximizing profitability.
- Better Service/Product.
- Flexibility to adopt industry best practices.
- Open source adoption.
- Enhanced Elasticity, Observability, Reliability, Resiliency, and Maintainability.
- SDLC automation.
- Environmental agnostic.
Cloud-Native Computing Foundation (CNCF) is an open-source software foundation that encourages the tech communities to adopt the Cloud Native computing to build and support cloud-ready ecosystems.
The CNCF collaboration with Redpoint Ventures and Amplify Partners developed a cloud-native landscape map. It standardizes technologies, services, and tools such as containerization, orchestration, CI/CD and provisioning, etc. Organizations can take advantage of this referenced map to design and develop the technology ecosystem around cloud-native computing.The cloud-native landscape consists of four main layers and two supportive layers. Each layer further classifies into respective areas of the cloud-native application development life cycle that consists of tools and services. CNCF technology stack enables cloud portability without vendor lock-in.
Application Definition and Development
This layer emphasizes technologies and tools under application development, which involves build/deployment automation, image building, data publication, and storage. It enables the team to develop reactive, resilient, and scalable apps. Let’s first simplify some general-purpose applications, which fulfill the specific requirement.
These applications expose business functionalities via service API using microservices architecture as a common approach. Each service contains independent persistence storage like database, cache, etc.
These are short-lived executable which processes data with minimum input. These can be triggered by events or scheduled to run from other applications. Use cases can be data processing, time-based notification/updates, etc.
These applications use an asynchronous communication pattern where data can be published & subscribed. The event-driven architecture is a common approach used across such applications. The infrastructure services provider helps in achieving resiliency, performance, and scalability.
Such applications are distributed into multiple physical/virtual tiers. An application can have multiple logical layers depending upon application architecture. The application can take advantage of infrastructure as service (IaaS), Platform as a service (Paas), CI/CD, etc.
CNCF recommends a vast range of technology, products, and services under each area, such as:
- Continuous integration (CI) and continuous delivery (CD) automate the process of build, package, test, and deployment. It enables development teams to be more agile and deliver changes more frequently and reliably. Tools are Jenkin, Bamboo, AWS code pipeline, etc.
- Streaming and messaging are the middleware services based on the pub/sub model that enables asynchronous communication between different nodes. Some of the widely used products are RabbitMQ, Kafka, Beam, Amazon Kinesis, etc.
- Image building is a core building block that plays a significant role in the automatic deployment pipeline. It involves the packaging of application, docker instructions, environmental info, etc. Some of the popular tools are Helm, Packer, Chef, etc.
- There are wide ranges of open source and commercial DB products available in various categories (NoSQL, Relational, Distributed) such as Cassandra, Couchbase, Redis, MongoDB, etc.
Orchestration and Management
Orchestration helps to achieve the scalability and resiliency by triggering and managing workflow automatically using the right set of tools and services. This layer will cover communication and container orchestration related technologies, services, and tools.
- Scheduling and Orchestration come into the picture when managing the containers become tedious tasks. Orchestrated platform and tools enable operational agility, help in managing clusters of containers by providing automatic scaling, rollback, load balancing, monitoring, etc. Kubernetes, Docker Swarm, Amazon ECS, are some of the popular Orchestrated platforms and services.
- The cloud-native application can have several microservices, so it’s crucial to configure and discover them dynamically. There are tools (such as Eureka, ZooKeeper, Nacos, etc.) that can help in dynamic configuration and discovery of microservices.
- Remote Procedural Call enables an application to call procedure/function remotely that use in client-server applications. There are tools (such as Apache Thrift, gRPC, and TARS, etc.) that help in achieving this technique.
- Service Proxy is an intercessor that handles communication between services. It isolates the issues of network & application and improves overall traceability. There are tools (such as NGINX, envoy, NOVA, etc.) help in implementing service proxy.
- API Gateways provides a single point of entry for API calls, redirects the request to the corresponding service, and returns the appropriate result. It makes authentication, load balancing, security, and monitoring easy to handle. MuleSoft, Kong, 3SSCALE are popular API gateway.
- Service Mess manages the network between the service’s proxy(sidecar). It helps in securing and monitoring the microservices. Istio, Consul, and Linkerd are some commonly used Service Mess tools.
Run TimeIn the cloud-native space, run time resources like compute, storage, and networking should get provisioned dynamically depending upon usability. There are a set of tools, platform & services recommended by CNCF which cater the requirement of cloud-native and offer properties such as scalability, high-performance, and fault-tolerant.
- Cloud-native storage provides distributed, virtualized, resilient storage capacity. Various open-source and commercial products available such as Minio, Rook, Rind, NetApp, Amazon S3, etc.
- Container Runtime runs the containers and manages container images. There are multiple containers runtime software available such as Docker, Containerd, Firecracker, lxd, etc
- Cloud-Native Networking tools enable orchestration & management of network resources. It includes scaling, allocation, and deallocation of network resources. Tolls are CNI, Network Service Mess, Kube-OVN, Ligato, etc.
Infrastructure as code enables auto-scaling & on-demand resource provisioning. That helps in faster provisioning, development, deployment, and testing. There are provisioning tools that assist in maintaining standards, compliance, policies, and security across the application landscape.
- Automation and Configuration Management in provisioning space help in automating infrastructure and deployment. Tools such as Terraform that uses configuration files to automate multi-cloud infrastructure provisioning. Ansible tool that provides configuration management, application deployment & intra-service orchestration.
- Container Registry is a centralized repository of docker images, where the application can store & retrieve images from such a repository. Organizations use public (Docker Hub) or private repository to manage images securely. There are some commonly used container registries such as Docker Registry, Kraken, Amazon ECR, etc.
- Security and Compliance are the shared responsibility of cloud vendors and cloud-native application team. There are best practices and tools where the application team can take advantage to secure the application and data such as TUF, Clair, kube-hunter, terrascan, etc.
- Key Management is an approach to manage cryptographic keys used in identity and access management (IAM). There are useful IAM tools that help in securing encryption across a cloud-native application landscape such as CyberArk, ORY, Keycloak
Observability and Analysis
The application should provide appropriate data to make the system observable. Data such as logs, metrics, health checks, distributed tracing is used for analysis, automated issue detection, and alerting. The right kinds of tool enable the team to monitor the system and help in triggering actions based on events that make a system robust and responsive.
Some of the observability and analysis tools for cloud-native under the following area are.
- Monitoring – Prometheus, ZABBIX, Dynatrace, Nagios.
- Logging - logStash, Splunk, LOGIQ
- Tracing – Spring Cloud Sleuth, Zipkin
- Chaos Engineering – Litmus, Chaos Mesh, Gremlin
Please refer CNCF landscape link to check the complete list of tools under each category.
Cloud-Native Best Practice
There are wide ranges of methodologies, patterns, and approaches to designing and developing the cloud-native application Such as DevOps, Agile, microservices, etc. Let us cover some of them.
- Twelve-Factor Application is a methodology to design and develop a modern application. It factors out the core concept of building software-as-a-service apps. Apart from the twelve-factor, three more factors are also included that add the perceptive to application development such as security, API, and telemetry.
- Take advantage of architectural concepts like microservices, containers, orchestration, and cloud vendor-provided services that help in achieving on-demand provisioning of resources, faster development, scaling, automating the application life cycle from development to deployment.
- Leverage the power of serverless technologies that allow us to build and run applications without managing servers. The team can focus on developing the application rather than infrastructure management such as server provisioning, scaling, back end components.
The benefits of serverless technology are:
- No provisioning/maintenance of servers.
- Automatic and Flexible scaling.
- Pay for value.
- High availability and fault tolerance.
- Reduce vendor lock-in by using multi-cloud compatible tools that helps applications to be portable and to support multi-cloud infrastructure migration. The advantage of this approach is of better pricing models and meet compliance regulations.
- Design Pattern plays a significant role in offering solutions to common design & development issues in cloud Native Application. Here are links to some useful pattern resources.
Opinions expressed by DZone contributors are their own.