Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric...

18

Transcript of Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric...

Page 1: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service
Page 2: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

2

Azure Architecture Center (aka.ms/mspnp)

Page 3: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

3

Decision tree for Azure compute services

Page 4: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

4

Reference architectures

Page 5: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

5

Choosing architecture style

• Business domain (Functional, Non-functional)

• Prerequisites

• Benefits

• Challenges

Page 6: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

6

Choosing architecture stylesDependency management Domain type/complexity

N-Tier Horizontal layers (open/close) Majority of business logic is CRUD

Web-Queue-Worker Front/Backend jobsDecoupled by async messaging

Relatively simple domain with some resource intensive tasks

Microservices Vertical (functional) decouplingService calls via API

Complicated domain logic that requires each service to encapsulate domain knowledge

CQRS R/W segregationSchema/Scale are optimized separately

Collaborative domain where lots of users access the same data

EDA(IoT) Data ingested into streaming Independent view per sub-system

Internet of things

Big data Divide huge dataset into small chunksParallel processing on local dataset

Batch and real-time data analysisPredictive analysis using ML

Big compute Data allocation to thousands of cores Compute intensive domain such as simulation, number crunching

Page 7: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

7

N-Tier

Page 8: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

8

N-Tier

Page 9: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

9

N-Tier+DMZ

Page 10: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

10

Web-Queue-Worker

Page 11: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

11

Web-Queue-Worker

Page 12: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

12

Throttling Circuit breakerCache asideFederated authentication

Sharding

Static content hosting

Competing consumersLoad leveling Valet key

Retry

Page 13: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

13

Micoservices

Page 14: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

14

When to choose Microservices?

Benefits- Independent deployment - Fault isolation- Diverse technology- Small focused team- Separate scalability/availability

Challenges- Complexity- Network congestion- Data integrity/consistency- Testing- Reliability

Business domain- Complex domain- Frequent update- Many independent teams

Prerequisites- Skill set for distributed system- Domain knowledge- DevOps culture- Monitoring capability

Page 15: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

15

Microservices

DevOps

User

ApplicationGateway

Application Host

Master

Image Registry

Nginx HA proxyApp GW

Docker HubACR

Docker engine on Virtual Machines

KubernetesMarathon

SwarmService Fabric

Request

RepositoryValidation

Cluster statestore

EtcdConsul

ZookeeperService Fabric

Administor

Docker imageDocker

image

Node state trackingDiscoveryLeader election

DeploymentCluster management

RoutingLoad balancingOffloading

Run services

Page 16: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

16

Process of designing microservices using DDD

Accounts

Dronemanagement

3rd partytransportation

Callcenter

Videosurveillance

Dronesharing

Dronemanagement

Dronesharing

3rd partytransportation

Shipping(Core)

Callcenter

Shipping

Surveillance

Accounts

Boundedcontext

Aggregate Aggregate

Aggregate DomainService

DomainServiceAggregate

ApplicationService

Aggregate

Event

Domain model Domain building blocks

Service mapping

Shipping

Drone Package

Delivery DeliveryScheduler

DeliverySupervisor

Account

3rd partytransportation

Authentication

ServiceinBC

ServiceinBC

ServiceInBC

ServiceInBC

Serviceoutside

Serviceoutside

Serviceoutside

Serviceoutside

Further refinement

Breakdown per BC

Service interaction design

DeliveryScheduler

Package

Drone

Delivery

Mobileapp

Query

DeliveryHistory

DeliveryEvents

RequestEvents

GW

Status

3rd partyService

AccountService

DroneMgmtService

AAD

AccountService

AuthService

3rd partytransportation

Account

RequestHandler

DeliveryAnalysis

Archive

Supervisor

Failedops

Droneevents

Page 17: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

17

https://aka.ms/mspnp

Page 18: Azure Architecture Center (aka.ms/mspnp) Application... · Kubernetes Marathon Swarm Service Fabric Request Repository Validation Cluster state store Etcd Consul Zookeeper Service

© Copyright Microsoft Corporation. All rights reserved.