Wiring Up
Microservices with
Istio
Ant Weiss, Otomato Software
whoami: Anton Weiss
@antweiss
Otomato Software Delivery
http://otomato.link
microservices !!!
API
gateway
User
mgmt
Product
Service
Pricing
Service
Orders
Service
Billing
Service
Payment
Service
microservices !!!
https://github.com/adrianco/spigo
microservices !!!
The 8 Fallacies of distributed systems
● The network is reliable.
● Latency is zero.
● Bandwidth is infinite.
● The network is secure.
● Topology doesn't change.
● There is one administrator.
● Transport cost is zero.
● The network is homogeneous.
The Reality
● RPC instead of local communication
● Network is unreliable
● Latency is unpredictable
● Call stack depth is unknown
● Dependency on other services(and teams)
● Services are ephemeral
● Unpredictable load
TYPES of Failures in Massively distributed Systems
● improper fallback settings when a service is unavailable
● retry storms from improperly tuned timeouts
● outages when a downstream dependency receives too much
traffic
● cascading failures when a single point of failure crashes
Example - retry Storm
frontend
auth
users
DB
timeout=200s
retries=3
timeout=400s
retries=2
timeout=400s
retries=3
Example - retry Storm
frontend
auth
users
DB
timeout=200s
retries=3
timeout=600ms
timeout=400s
retries=2
timeout=800ms
timeout=400s
retries=3
Resilience Patterns
● connection pools
● failure detectors, to identify slow or crashed hosts
● failover strategies:
○ circuit breaking
○ exponential back-offs
● load-balancers
● back-pressure techniques
○ rate limiting, etc.
Additional Concerns
Service Discovery
Observability
● Distributed tracing
● Log aggregation
Security
● Point-to-point mutual TLS
Continuous Deployments
● Traffic splitting
● Rolling updates
Solving with Libraries
Finagle
Ribbon
Hystrix
Zipkin
Spring-sleuth
Polly (for .NET)
Modern Day Solution - Service Mesh!
Istio
Istio Features
● Intelligent routing and load balancing
● In-depth telemetry
● Language- and platform-agnostic
● Built-in Security
● Fleet-wide policy enforcement
Keeping all these out of your application code
Istio Architecture
Sample App
front
bethaleph
envoy envoy
envoy
istio-ingress-gateway
envoy

Wiring up microservices with Istio