Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Hybrid Cloud for Developers

You're reading from   Hybrid Cloud for Developers Develop and deploy cost-effective applications on the AWS and OpenStack platforms with ease

Arrow left icon
Product type Paperback
Published in Apr 2018
Publisher Packt
ISBN-13 9781788830874
Length 280 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Manoj Hirway Manoj Hirway
Author Profile Icon Manoj Hirway
Manoj Hirway
Arrow right icon
View More author details
Toc

Table of Contents (11) Chapters Close

Preface 1. Introducing Hybrid Clouds FREE CHAPTER 2. Exploring AWS Cloud 3. Exploring OpenStack Private Cloud 4. Developing AWS Cloud Applications 5. Developing OpenStack Applications 6. Cloud Migration 7. Hybrid Cloud Best Practices 8. Monitoring and Troubleshooting Hybrid Cloud 9. Hybrid Cloud Security 10. Other Books You May Enjoy

Introducing hybrid cloud

As organizational business grows, there is a need to extend the enterprise operation along with the IT infrastructure. In other words,  the onsite data center needs to be extended by adding more servers and resources to fulfill business demands. There is also a need to optimize and perform efficient utilization of available resources. High-end servers can't be left underutilized, as this will be a waste of the available resources. Purchasing more and more IT equipment increases the organizational infrastructure costs. Also, large servers tend to occupy more and more space in data centers. This becomes a problem and there is a need for a flexible and scalable model that will allow on-demand infrastructure scale-up and scale-down.

One solution is to use a private cloud that provides on demand scaling up and scaling down of the infrastructure by spinning up virtual machines. A private cloud will certainly solve the problem of flexible scaling and efficient utilization of resources. However, since a private cloud resides within the data center, it still requires large amounts of physical resources, which must be owned by the organization. Despite efficient utilization of resources, if the organization needs more infrastructure, a private cloud doesn't completely solve the problem, as the cost of owning the infrastructure must still be borne by the organization.

So, the other solution is to migrate the entire data center to a public cloud such as AWS or Azure. A public cloud will ensure that we have ample resources that can be scaled up and down based on requirements. Organizations don't have to worry about purchasing large servers and arranging floor space for accommodating them in their private data centers. 

However, there are many downsides to using a public cloud. Migrating existing applications to the cloud is complex. There are portability problems as system architectures differ. Also, as the resources are scaled up and the data center expands, the costs can climb significantly. The overall costs of using a public cloud are high. Moreover, there are security concerns. Since organizational data could be confidential, putting it on a public network would not be liked by the IT security teams. Thus, using a public cloud alone doesn't solve the problem either.

Since both public and private cloud models have their pros and cons, there is a need to combine both the models and create a more suitable platform for the organization's needs. A cloud platform that is a combination of private and public clouds, and connected using an encrypted network, is referred to as a hybrid cloud. The National Institute of Standards and Technology (NIST) defines a hybrid cloud as follows: "A hybrid cloud is a combination of public and private clouds connected together using a standardized network link that enables portability of data and applications." It could be a combination of a private cloud inside an organization with one or more public cloud providers, or a private cloud hosted on third-party premises with one or more public cloud providers. 

A typical use case of the hybrid cloud model is a combination of customer facing systems (such as mobile phones) and systems of record management. For example, an e-commerce organizations might leverage their data center to manage transactions made by their customers using the frontend that is running on a public cloud. In other words, the frontend running on a public cloud will be connected to the datacenter. An organization might also use a third-party cloud service that verifies the credit of customers who choose to pay using the EMI option. They may also use the public cloud to expand their servers in case of high network traffic during online sales and holiday periods.

The hybrid cloud is  thus becoming a widely used cloud model that adapts to rapid changes in technology and business in terms of networking, storage, and computing requirements.

Hybrid cloud architecture

As discussed in the previous section, a hybrid cloud is a combination of public and private clouds connected together using a secure connection. The following diagram shows a high-level overview of a typical hybrid cloud architecture. A simple hybrid cloud model involves one private cloud that is tied to the organization's data center and one public cloud, which is located offsite.

Both these clouds are connected using an encrypted network connection by VPN. An encrypted connection can be established using any of the available VPN applications, such as OpenVPN:

Fig 1.2: A typical hybrid cloud architecture

The public cloud could be any of the available cloud providers, such as AWS Cloud, Microsoft Azure, and so on. Similarly, a private cloud could be one of the most widely used open source cloud platforms, OpenStack, or a custom-built private cloud.

Hybrid cloud using OpenStack and AWS/Azure/GCP

The following diagram shows a hybrid cloud architecture created using the OpenStack private cloud and public clouds such as AWS, Azure, or GCP. The combination of these two clouds creates a hybrid cloud environment:

Fig 1.3: Hybrid cloud architecture created using the OpenStack private cloud and public clouds

Combining public cloud services with private clouds services along with the data center, thus creating a hybrid model, is needed in modern computing. Many companies now combine public cloud and private cloud services to create value.

If you have more than one cloud environment (public and private), then it is a good approach to have a management platform that spans these environments. If each of these clouds is managed separately, there is a duplication of efforts and the operations are prone to human error.

There are several startups and established companies that have developed software that allows users to centrally manage both private datacenters and public cloud infrastructure and applications. Managing virtual machines, storage, databases, and other resources can be done using a single console, which makes it easy to administer the entire operations on a hybrid cloud.

The following diagram shows another perspective of a hybrid cloud architecture using OpenStack:

Here, the OpenStack components exist inside the boundaries of the organizational network. They use a proxy server for interfacing with the external public cloud providers. These proxy servers may act as a mediator between the public and private cloud environments. 

Various OpenStack components such as Cinder, Neutron, and Nova collaborate with each other and also interact with the external public cloud to create a hybrid cloud architecture. OpenStack will be discussed in detail in later chapters.

What qualifies as a hybrid cloud?

There are certain conditions that must be met for a cloud to be qualified as a hybrid cloud.

A cloud is hybrid if:

  • The organization data center is connected to the public cloud and sends/receives data from the public cloud
  • An organization leverages a number of SaaS applications and moves data between private or data center resources
  • An organizational business process is designed in such a way that it leverages the use of private and public clouds

A cloud is not hybrid if:

  • Only a handful of people in the organization use the public cloud for deploying or testing applications, and it is completely disconnected from the data center
  • An organization is using a SaaS application for a project, but there is no movement of data from that application into the organization's data center

The following diagram summarizes the characteristics of public, private, and hybrid clouds:

Cloud bursting in a hybrid cloud

Cloud bursting is one of the most important features of a hybrid cloud. It helps in scaling applications across public clouds.

Consider an application that is running in a private cloud or a local computing environment. Suppose a  situation arises where the application needs additional resources such as computing power, storage, memory, and so on. In such a scenario, the application can burst into the public cloud and use the resources available there to ensure continuity and smooth operations. In other words, the application can expand itself to start using the resources of the public cloud on demand. This is called cloud bursting.

However, this can add complexity to the application design and special skills are required to design the application to leverage cloud bursting capabilities. There are vendors that provide hybrid cloud solutions that facilitate taking advantage of cloud bursting.

Advantages of using hybrid cloud

As discussed in the previous sections, a hybrid cloud offers the cost and scale benefits of public clouds, while also offering the security and control of private clouds. In this section, we will highlight some of the business benefits of hybrid clouds.

Cost savings

Since the high-end infrastructure is outsourced to the public cloud provider, there is a cost saving.

Temporary IT and development projects require temporary resources. For example, IT companies keep performing several Proof of Concepts (POC), which requires IT resources only till the duration of the project. These resources can be easily created and destroyed in the private or private cloud without spending too much.

An application may require different kinds and levels of resources during its life cycle. For a production grade environment, a public cloud can be used, whereas, for testing phases, a private cloud will suffice.

High-end servers have maintenance costs and their vendor contracts must be renewed periodically. Large applications that require high-end servers can be migrated to the public cloud and thus maintenance costs and effort can be saved.

Flexibility

A hybrid cloud offers the flexibility of control of a private cloud and at the same time, the agility of a public cloud. The private cloud component of the hybrid cloud can be customized as per the needs of the organization.

Also, when an organization requires additional computing resources, a public cloud can easily scale-up and satisfy additional needs.

Speed

High-end servers and computing resources can be spun up in a matter of minutes to satisfy  organizational needs quickly on public clouds. High-speed internet links can also be established between data centers, thus delivering high performance.

Portability

By leveraging container technology such as Docker, applications can be containerized and made portable across several cloud platforms. For example, a containerized application can be easily migrated from the OpenStack private cloud to the AWS public cloud.

Security

Since an encrypted link or VPN is established between the public and private cloud of the organizational data center, confidential network data can be safely transferred across clouds.

Factors to consider before moving to a hybrid cloud 

As discussed previously, moving the organization's data center to a hybrid cloud offers several advantages. However, changing the IT infrastructure of the organization could be a complex task. It may also be expensive. Hence, the following factors should be considered before choosing to migrate the infrastructure to a hybrid cloud environment:  

  • Skilled engineers: A hybrid cloud setup can become very complex, depending on the organization's IT infrastructure and customization. Highly skilled and experienced IT engineers must be available to perform the cloud migration and maintenance. 
  • High bandwidth for data transfer: To set up a hybrid cloud, a large amount of data may have to be moved from the private cloud to the public. This may involve high bandwidth utilization and may also affect the productivity of the existing engineers. Organizations should also be prepared to incur higher costs involved in large amount of data transfer.
  • Resource management: Since hybrid cloud resources are scalable, all the resources must be utilized efficiently. The usage of CPU, memory, and storage should be monitored to ensure resources are not wasted. 
  • Compliance: Organizations that deal with sensitive and critical data have their own compliance policies. When moving to the hybrid cloud, periodic audits should be done to ensure that the cloud platform meets requirements.
  • Load balancing: Appropriate load balancing techniques should be considered so that a single machine doesn't get overloaded with resource requests. 

Now that we know the fundamentals of hybrid clouds, lets turn our attention to the software development methodologies that are suitable for working on cloud platforms.

Understanding DevOps methodology

Historically, many software companies followed the waterfall model of software development. The waterfall model involved the following stages:

  1. Requirement analysis
  2. System design
  3. Implementation
  4. Testing
  5. Deployment
  6. Maintenance

In this, each stage was virtually isolated and was mostly performed by a different set of people. It had poor integration between development, infrastructure, security, and support teams. Moreover, the teams working on each stage would report to different organizational structures with different corporate goals and philosophies. The primary goal of developers was to build the software, whereas the operations team had the goal of deploying software and ensure stability and reliability. This mismatch of goals would cause conflicts and ultimately the business would also suffer. Hence, there was a need to have more collaboration and communication between the software development teams and the operations teams.

The Agile software methodology addresses these concerns, and a modification to the agile model gave rise to DevOps.

DevOps is a faily new methodology that primarily focuses on improved collaboration, communication, and integration between software developers and IT operations. It is not a system, but a  philosophy, cultural change, and paradigm shift in the way organizations' work.

The following diagram depicts a DevOps approach to software development.

The different between the Agile model and DevOps is that Agile software development primarily focuses on the collaboration between the business and its developers, whereas the DevOps model focuses on the collaboration between developers, IT operations, and security teams.

IT operations include system administrators, database administrators, network engineers, infrastructure architects, and support engineers. The DevOps methodology means different things to different teams. For application developers, DevOps focuses on code building, code coverage, unit testing, packaging, and deployment. For IT operations teams, DevOps focuses on provisioning, configuration, orchestration, and deployment. But the basic principles of DevOps remain the same, irrespective of the teams and tasks being worked on.

The following are six important DevOps practices that are widely used by organizations who have chosen to adopt this methodology:

  • Collaboration
  • Automation
  • Continuous integration
  • Continuous testing
  • Continuous delivery
  • Continuous monitoring

Collaboration

As we discussed, the fundamental need from which the DevOps model arose is the lack of collaboration between software development teams and IT operations  teams. The DevOps methodology not only implements effective collaboration between these two teams, but also to every other stakeholder of the software. 

Automation

DevOps puts a heavy emphasis on automation. All possible tasks, such as software testing, infrastructure provisioning, software deployment, and so on, must be automated. This can be achieved using automation tools. There are several automation tools available in the market. Jenkins is one such tool, which can be used to automate several tasks such as code compilation, software testing, and so on.

Continuous integration

Continuous integration forces software developers to integrate their work with other developers. This exposes any integration issues much earlier than the release date and hence helps in fixing problems earlier. This approach definitely requires developers to communicate with each other and discuss their work and integration approaches. 

Continuous testing

Continuous testing involves testing of the software code with every code change that is merged into the codebase. Developers should not only make sure that they deliver error-free code, but also provide test datasets to the testing teams and help them in configuring the testing environment so it is as close to the production environment as possible.

Use of automation testing tools reduces the cost and time of testing and frees up engineers to use their time more effectively.

Thus, in order to make the journey to the cloud efficient and effective, software companies must adapt the DevOps methodology for their software development and IT infrastructure deployment strategies.

You have been reading a chapter from
Hybrid Cloud for Developers
Published in: Apr 2018
Publisher: Packt
ISBN-13: 9781788830874
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime