Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

13
Microservices vs. Monolithic Architectures By Sergey Sverchkov, Solutions Architect www.altoros.com @altoros Pros, Cons, and How Cloud Foundry (PaaS) Can Help

Transcript of Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

Page 1: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

Microservices vs. Monolithic Architectures

By Sergey Sverchkov, Solutions Architect

www.altoros.com

@altoros

Pros, Cons, and How Cloud Foundry (PaaS) Can Help

Page 2: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros@altoros

Table of Contents

2

• Monolithic Architectures: an Example

• Issues with Monoliths

• Microservices: an Alternative

• 4 Pros of Microservices

• 4 Cons of Microservices

• How a PaaS (such as Cloud Foundry) Can Help

Page 3: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros@altoros

Monolithic Architectures: an Example

3

• Several components share a domain model with entities such as Device, Signal, and User

• Device Listener: Receives data from devices

• Data Processor: Processes and stores data in a database

• Authenticator module: Provides authentication of devices and users

• Load Balancer: Distributes workload between several instances of a monolithic app

Page 4: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros

Issues with Monoliths

4

• Longer development cycles

• Quick deployments are hardly possible with frequent

changes.

• Long-term commitment to a particular technology stack

• May need to re-write the code of the entire application!

(For instance, if you want to change an underlying technology for one or

several components—e.g., from Java to JavaScript.)

• Scaling logic requires significant resources in terms of

budget and time.

Page 5: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros@altoros

Microservices: an Alternative

5

• With the microservices approach, complex apps are divided into

smaller parts that are loosely coupled.

• System comprises relatively simple services that communicate with

each other through a message broker, a database, and a REST API.

• Built for the cloud!

Page 6: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros

4 Pros of Microservices

6

• Independence of services

• Focus on business

capabilities of apps

• Simplicity of adding new

features

• Fault tolerance

Each service contains its own business logic

and is deployed separately, making it possible to

gradually add new features.

The development process becomes more

flexible. Each service is a separate app with its

own business logic, UI, persistent storage, and

functionality.

Implementing microservices, dev teams deal

with smaller apps and simpler architectures. So,

it is easy to introduce changes or add another

service.

Even if any of the units fail, these small units are

loosely coupled and can be automatically

restored. Developers can increase availability of

each unit, which results in a more stable system.

Page 7: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros

4 Cons of Microservices

7

• Implicit interfaces

• Operational overhead

• Require DevOps skills

• Operational complexity

Components of the system communicate via

interfaces. All components are interrelated, so

modification of one interface means

adjustment of other interfaces.

More resources are needed, with increased

operational overhead.

E.g., various tools for different services of the

system may need different data stores. A DBA

may need to have DevOp skills with

experience in deploying and optimizing NoSQL

dbs.

Microservices comprise multiple instances and

services that must be managed in production.

Addressing this requires a high level of

automation.

Page 8: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros

How a PaaS (such as Cloud Foundry) Can Help

8

• No need to create additional scripts to automate

operations monitoring and scaling

• Development, testing, and production release

processes are identical in terms of deployment.

• Enables adding new component instances without

affecting the rest of the system

• Scalable runtime environment support most

frameworks and languages that run on Linux.

• Simplifies deployment and release of microservices

apps

• Automates scaling, health monitoring, load

balancing, and many more

Page 9: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros

Summary of the Microservices Model

• With microservices, complex apps are divided into smaller pieces

(services).

• These services can be scaled and deployed separately.

• Different languages can be used for different parts of the system to

implement the best solution/tool for a particular case.

• Dev teams can deliver updates independently and roll out new

releases more frequently—while keeping the rest of the system

available and stable.

• A platform-as-a-service (such as Cloud Foundry) can address the

issues that may arise.

9

Page 10: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros

Want More? Download This Tech Study!

10

“Microservices vs. Monolithic Architectures:

The Pros, Cons, and Cloud Foundry Examples”

Get the Comparison

• 6 diagrams, 3 tables, 15 pages

• IaaS vs. PaaS for microservies: top 6 differences

• How a PaaS addresses the challenges of microservices

• How to run and scale microservices on Cloud Foundry

• Code samples for Cloud Foundryhttp://paas.ly/11Ptshh

Page 11: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros

Altoros, a Silver member of the CF Foundation,

deploys and integrates solutions offered by the Cloud Foundry ecosystem

Training Managed ServicesConsulting Integration

Delivered by Altoros Delivered by the Cloud Foundry ecosystem

With 250+ employees across 9 countries, Altoros is the company

behind some of the world's largest Cloud Foundry deployments.

In Case You Need Assistance

11

Page 12: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros

Altoros Fact Sheet

2001

Established in

Buenos Aires

Oslo

London

Zürich

Sunnyvale, CA

Copenhagen

Minsk

Santa Fe

Boston

Stockholm

250+Employees

600+Implemented projects

98%of customers recommend Altoros

30%Female

70%Male

50+Workshops organized

12

Page 13: Microservices vs. Monolithic Architectures: Pros, Cons, and How Cloud Foundry (PaaS) Can Help

@altoros

Thank You!

13

www.altoros.com/research-papers

Questions?.. [email protected]

Further Reading (Benchmarks and Tech Studies):

Subscribe

to new research: blog.altoros.com

Daily tech insights: @altoros