Upload
mbild
View
74
Download
4
Embed Size (px)
Citation preview
DECOMPOSITION
Sales DistributionAccountingMarketing
RecommendationCampaignCoupon…
CatalogPriceCalculations…
PaymentInvoices…
AvailabilityShipping…
MICROSERVICE
The
UnixWay
Each APP only does one thing
Small enough to fit your head
Small enough to throw away
SELF-CONTAINED• lightweight communication
• independent development
• independent deployment (container, package manager)
• strict contracts & versions
• one process
• UI & (temporary) store included
12-FACTOR APP• log to stdout
• bundle config via ENV-Var
• explicit port bindings
• scale via processes
• share nothing
• prefer stateless / temporary states
• start fast / graceful shutdown
• decouple admin process
SYSTEM OF SYSTEMS• distributed
• integration
• dependencies
• state & consistency guarantees
• fast releases
• parallel development
• scale vertical & horizontal
• resilient
NOT A FREE LUNCH• what? learn &
improve
• discuss & agreement
• explicit failure strategies
• documentation
PRACTICE
• functional prototype
• ui, services & integration
• delivery & operations infrastructure
• resilient & scale
• monitoring & SLAs
MANAGE STATE
• trade off - explicit state
• relaxed consistency
• avoid persistent data
• prefer in-memory + expiry
• prefer replication
RESILIENT & SCALE• failure compensation (retry, fallback, cache, etc.)
• data correlation
• CQRS / ES / LOGS
• client side load balance
• algorithm for traffic distribution (e.g. shards)
• scoring per read and write operations
SERVICE TEMPLATE• rapid application development
• experimental & feasibility development
• batteries includes (UI, Storage, Streams, Tasks, etc.)
• simple to extend
• simple to deploy
SLA• 99,9% availability
• 90% < 500ms click performance
• 80% < 1s data processing performance
• 60% integration test errors