IT 20 052 Examensarbete 15 hp Augusti 2020 A proposal for a cloud-based microservice architecture for the Skolrutiner system Nhat Minh Pham Institutionen för informationsteknologi Department of Information Technology Abstract A proposal for a cloud-based microservice architecture for the Skolrutiner system Nhat Minh Pham Teknisk- naturvetenskaplig fakultet UTH-enheten Skolrutiner, a fast-moving startup company, has a great idea of a platform for handling documents. However, they do not have a scalable Besöksadress: and modular system architecture since all the current services are Ångströmlaboratoriet Lägerhyddsvägen 1 centralized and running on a single virtual machine. The main purpose Hus 4, Plan 0 of this thesis is to study and design a cloud-based microservice system for the platform of the company. This new microservice Postadress: approach, with the help of many modern features of cloud computing, Box 536 751 21 Uppsala is expected to resolve the major issues of the current system. The proposed architecture might be costly and challenging to implement, Telefon: but it could help the company to have a general knowledge about cloud 018 – 471 30 03 computing, microservices, and how to apply these technologies to the Telefax: expanding business. The re-implementation of the Skolrutiner system 018 – 471 30 00 based on the given architecture is out of the scope of this thesis work. Hemsida: http://www.teknat.uu.se/student Handledare: Johannes Lundström Ämnesgranskare: Karl Marklund Examinator: Johannes Borgström IT 20 052 Tryckt av: Reprocentralen ITC Contents 1 Introduction 1 1.1 Motivation . .1 1.2 Contribution . .1 1.3 Overview . .2 2 Cloud computing 2 2.1 Definitions . .2 2.2 Service models . .3 2.3 Deployment models . .5 2.4 Characteristics . .5 3 Microservices 6 3.1 Monolithic architecture . .6 3.2 Microservices . .8 3.3 Key benefits . .9 3.4 Communication mechanisms . 10 3.5 Inter-service communication . 12 3.6 Drawbacks . 13 4 Current system design 13 4.1 Current system design . 13 4.2 About the Skolrutiner application . 14 4.3 Current design . 14 5 Proposal of the new design 16 5.1 Requirements for the new design . 16 5.2 The new design . 16 5.2.1 Overall architecture . 17 5.2.2 API gateway and service design . 18 5.2.3 Authentication and authorization in the system . 23 5.2.4 File uploading in the new design . 25 5.3 Evaluation . 26 6 Conclusion 27 6.1 Contribution . 28 6.2 Future work . 28 1 Introduction This section will give you an overview of what motivates me to write the thesis, what this thesis contributes and a summary of the work that each section will cover. 1.1 Motivation While the term \cloud" might seem quite abstract, the benefits of cloud computing are very tangible [4]. Since the cloud has gained popularity in the computing world, there is no doubt that moving to the cloud nowadays is a natural evolution. More and more businesses are making the switch by shifting their applications from self-hosted servers into the cloud, and so is my client company, Skolrutiner. By cloud, we mean any computing environment in which computing, networking, and storage resources can be provisioned and released elastically in an on-demand, self-service manner [21]. With all the great advantages and profits that cloud computing brings about, sometimes it is the only choice for modern companies with large and complex systems. The term "microservice architecture", which describes a particular way of designing an application system as a collection of independently deploy- able services [11], is also a very hot topic in recent years. Many development teams take it as the top-tier approach to traditional monolithic architecture. Most of them are doing the shifting work from their code-heavy monoliths to the smaller, self-contained microservices. However, like any architectural style, microservices comes with both benefits and costs, which you should understand in depth when designing any microservice system. The goal of this thesis project is to design a microservice system based on cloud computing, which could meet the requirements from the company Skolrutiner of a system having high availability, flexible scalability and easy of executing on a cloud platform [19]. The proposed architecture could be useful for the company, Skolrutiner, to help them to have a better vision of how to apply cloud computing and microservices to their specific context. 1.2 Contribution The focused contributions of this thesis are to: • provide a comprehensive definition of cloud computing, its character- istics and advantages over maintaining physical infrastructure • compare microservices with the traditional monolithic architecture and discuss the advantages and drawbacks of implementing a microservice system over a monolithic one 1 • provide the client, Skolrutiner, with a comprehensive description of their curren system architecture, discuss the disadvantages of the cur- rent design and the company's requirements for the design of the new system • propose a new cloud-based microservice design for the Skolrutiner sys- tem, explain and evaluate it. 1.3 Overview The thesis is divided into sections in a way that I hope will make it easier to read from beginning to end. Here is an overview of what would be covered: • Section 2: Background provides background theory of cloud com- puting and microservices. • Section 3: Architecture introduces the company's current system, its drawbacks, propose new design for the company and evaluates the new design. • Section 4: Conclusion summarizes the thesis work and discusses potential future work. 2 Cloud computing This section brings up basic knowledge about cloud computing, its charac- teristics, service models and deployment models. 2.1 Definitions At the early stage of the internet era, physical servers where the only so- lution for web infrastructure of every company. However, things change and now, cloud computing underpins a huge number of services. This in- cludes consumer services like Gmail or the cloud back-up of the photos on your smartphone [14]. Cloud computing, in simple terms, is the delivery of computing services over the internet. According to the National Institute of Standards and Technology (NIST) in the United States of America, Cloud computing is "a model for enabling ubiquitous, convenient, on-demand network access to a shared pool of con- figurable computing resources (e.g., networks, servers, storage, applications, and services) that can be rapidly provisioned and released with minimal management effort or service provider interaction" [17]. This cloud model is composed of five essential characteristics, three service models, and four deployment models [17]. 2 2.2 Service models The service models of cloud computing are categorized into three basic mod- els which are built on top of one another: Software (application) as a Ser- vice (SaaS), Platform as a Service (PaaS) and Infrastructure as a Service (IaaS), as shown in figure 1. Understanding these models and the differ- ences between them could enable a company like the client - Skolrutiner to accomplish business goals and effectively support business changes. Figure 1: Service models in cloud computing Software as a Service (SaaS): SaaS provides the capability for users to connect to and use applications running on a cloud infrastructure. All the setup of the underlying infrastructure, platform, application software and data is handled by the service provider, which is responsible for managing hardware and software, ensuring the availability and security of the app as well as its data. Tenants can access their applications through a program interface, or commonly through a web browser. Some example of SaaS products might be web-based email services (Gmail, Outlook, ...), online office services (Office365, Google Docs, ...) for personal use or for organisation use like MailChimp, Twilio, Elastic stack, etc. 3 Platform as a Service (PaaS): PaaS provides to the consumer a complete development and deployment environment in the cloud, to deliver everything from simple cloud-based applications to sophisticated, cloud- enabled enterprise applications [16] using programming languages, libraries, frameworks and tools supported by the provider. The consumers do not need to manage the underlying infrastructure including servers, operating system, network or storage, but has control over the deployed applications and possibly configuration settings for the application-hosting environment [17]. PaaS is often used by organisations for some scenarios such as devel- opment framework, analytics, business intelligence, etc. Infrastructure as a Service (IaaS): IaaS is the lowest level of the three cloud service models, providing the instant computing infrastructure, provisioned and managed over the internet. IaaS offers the capability to scale up and down quickly and pay- as-you-go payment. With infrastructure being available in the cloud, you can avoid the expense and complexity of buying and managing your own physical servers and other data-center infrastructure [15]. In addition to the three main models above, serverless computing is recently a popular service model supported by many service providers. The major difference seems to be that Serverless computing makes applications scale automatically while with PaaS, applications must be configured to scale automatically. To be more precise, the figure 2 will illuminate the similarities and differences between serverless computing. Figure 2: Similarities and differences between Platform-as-a-Service and Serverless computing 4 2.3 Deployment models There are different ways to deploy cloud resources. The options for deploy- ment are public, private and hybrid cloud. Public cloud: Public cloud is the most popular way of deploying cloud computing. The cloud resource is provisioned for open use by the general public. It is owned, managed and operated by a third-party cloud service provider and delivered over the internet. Using the public cloud, different cloud tenants share the same hardware, network and storage. Web mail services, office applications, online storage, development and testing envi- ronments are usually deployed on a public cloud.
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages35 Page
-
File Size-