Dev Intern Study Notes: Cloud Infrastructure

Sharing notes from our second dev intern study topic, cloud infrastructure. It’s a very big topic to cover in a couple of weeks and the notes might seem a bit unstructured. We are still editing it and adding some diagrams, links, etc. Use it as a collection of key concepts in the cloud computing topic. (Probably best for beginners who haven’t even installed Windows Server or Linux).

Our interns, William and Eleanor, both CompSci undergrads, spent a week researching into the topic with some starting questions, we met to discuss the topic for an hour or so, and then a week or so to write up the topic.

OnDemandWorld team, we are working on a new blockchain and AI based recruitment solution with tokenomics. TechHub Jobs. MVP already on App Store and Google Play. We are building the first scalable version now. Looking for new junior devs, blockchain devs, full-stack devs, etc. Contact us for more information. Remote working mostly in 2021 unless you are in Shanghai already.

Tech Topic 2: Cloud Infrastructure

Cloud Computing. What is it and why is it important?

  • Which are the biggest cloud providers and how best to choose one?
  • Is it worth it? How to calculate the ROI and TCO?
  • How does it compare with pre-Cloud, traditional IT infrastructure? Take a look at traditional 3-tier architecture.
  • Understanding the following: PaaS, SaaS, IaaS, DBaaS, etc, Serverless Computing; list out some of the major players, etc.

Digging deeper:

  • Computer Networking
  • What is computer network? Why is it important?
  • What are the common communication protocols? UDP, TCP/IP, HTTP/S, FTP, NTP, SMTP, IMAP, ETC.
  • What is REST API?
  • What is OAuth? (Also learn about 2FA too)
  • How secure is Cloud Computing? How about multi-cloud?
  • Cloud T&C
  • Amazon Price Calculator

Cloud Computing 101

Cloud is a model of computing where servers, networks, storage, development tools, and even applications (apps) are enabled through the internet. Cloud computing offers on demand computing services and it’s usually a pay-as-you-go service.

For a real world example, when you are using a messenger app your phone, the text you send goes to the cloud and it handles all the processing. Your friend receives your text from the cloud and reply a text. The reply goes to the cloud and then back to your phone so you could see what your friend’s reply is. And you could think of the cloud as a server the messenger app company rent from one of those big cloud providers, so it runs 24/7 and the company does not to hire people to maintain this server (The company could use their own cloud as well, if it is a big company like Amazon, Microsoft, etc). In one sentence: Cloud does anything that is not personal to you.

Before diving into the cloud architecture, there are some concepts that are important.

  • Computer networking: Computer networking is basically linking computers together. Cloud is built upon computer networking because cloud is some linked computers that work together through the internet, to provide various kinds of resources. Network protocols are rules that determine how data are transmitted in the network. Cloud uses those protocols to build connections among computers. Cloud use the internet as a medium of communication and the internet uses Internet Protocol/Transfer Control Protocol (IP/TCP) for communications over different computers. The graph below shows how data transfer happen using protocols (Reference:
  • Common Communication Protocols: Other than the high level layers, it is also crucial to understand some important communication protocols.
  • TCP and UDP: they are the two important protocols in the transport layer.
  • TCP stands for transmission control protocol, it is a connection-oriented protocol. It provides error checking and guarantees the data is delivered. Also, TCP has flow control and it ensure the data in the send buffer is the same order as it appears in the receive buffer
  • UDP stands for user datagram protocol, it is a connectionless protocol. There is not error checking and UDP continuously sends datagrams to the recipient with no guarantee if the recipient receives it.
  • TCP is best suited to be used for applications that require high reliability where timing is less of a concern.
  • World Wide Web (HTTP, HTTPS)
  • Secure Shell (SSH)
  • File Transfer Protocol (FTP)
  • Email (SMTP, IMAP/POP)
  • UDP is best suited for applications that require speed and efficiency.
  • VPN tunneling
  • Streaming videos
  • Online games
  • Live broadcasts
  • Domain Name System (DNS)
  • Voice over Internet Protocol (VoIP)
  • Trivial File Transfer Protocol (TFTP)
  • TCP is established using “3-way handshake”, which you could read more about,
  • TCP is terminated using “4-way handshake”:
  • Example, protocols used in a video call:
  • Client-server model: In this model, the client is the user of the service and the server is what serves this service. When client request something from the server, the server would process the request and return something to the client. (To read more about the client-server model:
  • 3-tier architecture: There are the presentation layer, the application layer, and the data layer. The presentation layer is a user interface where all the front end code resides. For example, you could use React as front end. The application layer is where the back end logic is implemented. And the data layer is the database where you store the data. The benefits is that the model modularized user interface, business logic and data storage. So is it easier to update the software by focusing on the specific layer rather than make changes to the code all over the place. And you could replace one of the layers without affecting the other part. However, the traditional 3-layer model has problems that after an application becomes too large and complex, it requires a lot of efforts to provide maintenance of the 3 layers of hardware and software. This would cause inefficiency for some businesses. After we entered the cloud era, the concept of 3-layer architecture is still important that some architectures still have the 3-layer model involved.

(Read more about the 3-tier model: (

So how did cloud develop gradually in the first place? Cloud started after CPU virtualization is developed. CPU virtualization allows a CPU to run different virtual machines at the same time. This allows a computer to partition its memory and CPU power to run multiple virtual machines so one server could serve different clients corresponding to its virtual machine. In short, CPU virtualization made hardware strong enough to support cloud computing.

Cloud computing’s architecture could be divided into two parts: the front end and the back end ( The front end is the interface that users can see. The back end is the program that handles everything that happens in the background which users cannot see, and it manages all the clients that runs in the front end. And there are different components in the backend, including application, service, storage, management and security. And under the umbrella of cloud computing, there are different architecture models. Note that these architectures are not mutually exclusive as they could work together to build programs in many occasions.

Microservices: it is a collection of services. “Each service can be written in a different programming language and tested separately. They are independently deployable and organized around business capabilities.” ( For example, when using a recruitment site, the different components could be different microservices: the search bar, the window to submit a resume, the advance search filter, etc. The structure has the advantage that each team could build every micro service independently with the programming language and architecture that the team likes, and all microservice will eventually work together to provide a full service.

Event-driven serverless architecture: Event-driven serverless architecture is based on systems that run when events happen. For “event driven”, unlike traditional server, an event-driven architecture system, like AWS lambda, does not run all the time, and the functions/code are only trigger by events. An event is a change in state, or an update. For example, if you submit your resume to a recruitment site, an event happens, and the event router push the event to the event consumer who handles the event. The even consumer could the database that stores your resume, the backend program that parse the words on your resume to push more suitable jobs, or even the HR who would respond to your job application. For “serverless”, it does not mean developers do not need a server anymore. Rather, it refers to the fact that developers don’t need to spend time and energy on server maintenance, provisioning, capacity planning, etc. One of the benefits is that you pay for execution duration rather than by server unit. So businesses do not need to pay for idle resources.

Cloud-based architecture: cloud based applications are often legacy applications that were designed to run on the company’s own server but modified to run on cloud. This design is easier and cheaper compared to rewriting an application that is the ground up for cloud. A traditional cloud-based application architecture involves load balancers, web servers, application servers, and databases. It can benefit from cloud features such as resource elasticity, software-defined networking, auto-provisioning, high availability, and scalability. However, since cloud based application are not designed specifically to benefit from cloud’s advantage, there are certain limitations. For example, sometimes the application is not 100% run on web, and users might need to download and install some package on their local machine, so if the the user has an older machine, the user might not be able to run the application. A good example is mobile games. Players are connected through the cloud but there are still significantly amount of packages that have to run locally.

Cloud native architecture: The cloud native architecture are from the ground up to take full advantage of cloud computing, and they exhibit many of the attributes of applications deployed in cloud-based infrastructures, such as elastic scalability and high availability. A single instance of the software can serve multiple clients, so clients could be added very quickly and they could begin using this new software in seconds or minutes. Another important advantage is that the application could be updated by the vendor rapidly. Once the application is updated, it is available to all users at once. So it is easier for businesses to update and provide new feature on their applications.

Now, after discussing the architecture of cloud, let’s look at some different types of cloud services. There are different types of cloud computing service and they serve different purposes.

  1. Infrastructure as a Service (IaaS): This is the most comprehensive and flexible type of cloud service. Basically it is renting infrastructures including networking feature, computers and data storage from a cloud provider. And you could use those resource whatever you like, which giving you the maximum amount of flexibility.
  2. Platform as a Service (PaaS): This service allows you to have a on-demand platform to develop a software, without the need to worry about the managing the underlying infrastructure.
  3. Software as a Service (SaaS): This service provide you with a software service through the cloud, and you could use this service on a subscription basis.

Now we know that there are different types of cloud computing architecture and services. Let’s consider some benefits of the cloud:


The first advantage of cloud infrastructure is cost. Cloud computing eliminates the cost of hardwares completely. This cost not only includes buying hardwares, but also includes the constant expenditures of keeping the servers running (and cooling) and the repairing and replacements of hardwares that are no longer functioning. For traditional IT infrastructures, there are usually a team of experts in charge of maintaining the hardware and software, but cloud infrastructure is maintained by the provider, so the client needn’t worry about the cost of hiring experts.


Most cloud services are provided self-service and on-demand. For this reason, vast computing resources can be provided instantly, ensuring better speed for users.


Cloud computing allows more flexibility in the allocation of IT resources. If using on-premise computing, everything needs to be set up at the front. This setup includes the deciding of how much computing power to ask for, how much storage is needed, brandwidth, and geographic locations. Moving to cloud computing will add flexibility to all aspects above, allowing the client to move around the IT resources to the right place. Additionally, scaling up when using on-premise infrastructure means buyings hardwares and allocating more space for heavy machines, and once scaled up, it would be difficult to scale back down. However, cloud computing uses the billing model of pay-as-you-go, meaning that you pay for how much you are currently using. This adds flexibility to scaling up and back down, if the client figures that not that much memory space is needed, he can just stop paying for the extra and wouldn’t need to get rid of the hardwares that he would have bought if he is using traditional IT infrastructure.


Firstly, as talked about, cloud setup frees IT teams from spending time maintaining hardwares and softwares, so that they can better focus on their own tasks. Secondly, cloud computing also ensures more efficient collaboration between individuals or teams. Imagine a team that needs constant data sharing with each other, and team members might be spread around the globe and can not have access to the same computer that stores data. For on-premise setup, the team would need regular sending of data to one another and combing and restoring. But with cloud computing, as long as all team members have access to the internet, data sharing is no longer a problem.


Cloud services are connected to worldwide networks and are upgraded regularly, ensuring the computing power of the latest generations of hardware, thus, maximizing performances.

Security & Reliability

Traditional IT infrastructure usually has lower data security, because for individual company owners, they do not devote as much as cloud infrastructure providers to better secure data. The security standards are usually higher with cloud infrastructure. Moreover, cloud infrastructure takes care of data security, so users don’t need to be constantly monitoring the security of the system themselves. In events of data loss, on-premise setup also have lower chance of data recovery, while cloud provides better chance of and faster ways of data recovery.

Top benefits of cloud computing:

Not all cloud providers do the same thing, and it is definitely worse taking time to consider which cloud services to choose, so that the chance of switching to different cloud services or using a piece of service here and another piece there will be low. First and foremost, the client should identify their own needs, ie. their expectations for the cloud service. Is the need running their own server, or is it only looking to utilize software from the cloud? The first would point to the path of finding some services that include server hosting, while the second would point to something like Microsoft office 365 that does exactly that. There are also other aspects that need to be considered, such as short-term operating cost, long term cost of ownership, and services the business might need to use in the future.

Once identified all key services that are needed, the client can move on to comparing the main cloud providers today, and further identify which better satisfies the need of the business.

Amazon web services (AWS) is provided by Amazon and offers a mixture of all Iaas, Paas, and Saas. As the market leader, the strength lies in the breadth and depth of the services which lead to better developer functionality.

Microsoft Azure is provided by microsoft, also offers all Iaas, Paas, and Saas, but specializes in software cloud services. It supports building, testing, deploying, and managing applications on cloud and supports most programming languages.

Google cloud platform is provided by Google and offers services such as computing, data storage, data analytics, and machine learning. The key advantages of google cloud is its deep expertise around open source technologies, especially containers. It is suggested by Ray Wang, founder and principal analyst at Constellation Research, that businesses looking for good AI and machine learning capabilities, along with translation, search, and security should choose Google cloud platform have been gravitating towards Google Cloud Platform.

IBM cloud is offered by IBM and contains all Iaas, Paas, and Saas. It is offered through all public, private, and hybrid cloud delivery models. IBM cloud dedicates exclusive hardware to each user, ensuring security and reliability.

Alibaba cloud, also known as Aliyun, like others, offer all Iaas, Paas, Saas. Alibaba cloud service has a higher number of VM processors and is suitable for businesses with higher server workloads. It also has better pricing terms and more cloud storage options. It provides all types of cloud storage, making sure that the client can find the best type that fits their needs.

Other important topics:

After discussing the technical aspect of cloud computing, it is also important to note the financial aspect of it.

ROI (return on investment) is used to calculate the percentage of money earned from an investment. It shows the efficiency of certain investment, and is calculated as:

ROI = Net Profit / Investment * 100%.

Zero percent of ROI is the break even point of investments. At zero, it suggests that the net profit is zero, and what is earned exactly equals to the initial investment.

TOC (total cost of ownership) is the sum of all costs associated with owning and maintaining a product or service. In other words, it is the price of the initial purchase plus the costs of operation:

TOC = Hardware + software + life cycles + labor + power + …

In summary, ROI measure how much money you make back from investments in cloud computing, and TCO measures the total cost related to your cloud investments. These two numbers are valuable because it allow users to understand the cost and return of using cloud and make sound decisions.


AWS vs Azure vs Google Cloud: What’s the best cloud platform for enterprise?

5 advantages of Alibaba Cloud hosting over traditional & other cloud providers

I hope you find these notes useful in getting to know a bit about what cloud infrastructure is. It is a rather high level concept. You can easily say that whatever you don’t own, or anything not within your home, school or office local network are part of “the cloud”.

As a developer, it is important to know that even though you no longer have to consider the upfront cost of setting up some physical hardware servers in data centres, it doesn’t mean it is cheap to use the cloud. (Cloud providers are making good money from these services.) It is now much easier to waste money on cloud pay-as-you-go costs as you are no longer limited by upfront hardware costs.

A little about us: OnDemandWorld Team, currently building a blockchain & AI based recruitment platform with tokenomics called TechHub Jobs, early prototype already on App Store and Google Play. We will be releasing these on Github soon. Stay tuned.




Experienced technologist, focused on selective combinations of blockchain and AI. I am not a writer, I use Medium like an online notepad to share my thoughts.

Love podcasts or audiobooks? Learn on the go with our new app.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Edward Tsang

Edward Tsang

Experienced technologist, focused on selective combinations of blockchain and AI. I am not a writer, I use Medium like an online notepad to share my thoughts.

More from Medium

Digital Business to Digital Human — Why DevOps Matters?

The ever-expanding cloud — How to transform to cloud native?

Using Google PubSub with Strapi

Users and Organizations in Multi-Tenant SaaS