Академический Документы
Профессиональный Документы
Культура Документы
Uwe Friedrichsen codecentric AG 2014-2016
@ufried
Uwe Friedrichsen | uwe.friedrichsen@codecentric.de | http://slideshare.net/ufried | http://ufried.tumblr.com
http://www.thefreedictionary.com/resilience
Business
Production
Availability
MTTF
Availability
MTTF + MTTR
MTTF
Availability
MTTF + MTTR
Maximize MTTF
Underlying assumption
reliability
ISO/IEC 25010:2011(en)
https://www.iso.org/obp/ui/#iso:std:iso-iec:25010:ed-1:v1:en
https://blogs.oracle.com/jag/resource/Fallacies.html
Cloud-based systems
Microservices
Zero Downtime
Social
Resilience approach
MTTF
Availability
MTTF + MTTR
Minimize MTTR
resilience (IT)
Isolation
Isolation
System must not fail as a whole
Split system in parts and isolate parts against each other
Avoid cascading failures
Requires set of measures to implement
Isolation
Bulkheads
Bulkheads
Isolation
Bulkheads
Complete
Parameter
Checking
Loose Coupling
Isolation
Bulkheads
Complete
Parameter
Checking
Loose Coupling
Complements isolation
Reduce coupling between failure units
Avoid cascading failures
Different approaches and patterns available
Loose Coupling
Isolation
Asynchronous
Communication
Bulkheads
Complete
Parameter
Checking
Asynchronous Communication
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Bulkheads
Complete
Parameter
Checking
Location Transparency
Loose Coupling
Asynchronous
Communication
Event-Driven
Isolation
Location
Transparency
Bulkheads
Complete
Parameter
Checking
Event-Driven
Request/response
Event-driven
without broker
Sender
Sender
Sender
Send
Request/
Response
Lookup
Event-driven
with broker
Send
Broker
Subscribe
Receive
Receiver
Lookup
Receiver
// from sender
receiver = lookup()
// from sender
queue.send(msg)
// from sender
result =
receiver.call()
// from receiver
queue =
sender.subscribe()
msg = queue.receive()
Subscribe
Receive
Receiver
// from sender
broker = lookup()
broker.send(msg)
// from receiver
queue =
broker.subscribe()
msg = queue.receive()
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Stateless
Relaxed
Temporal
Constraints
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Idempotency
Relaxed
Temporal
Constraints
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Idempotency
// Server/Receiver part
// Receive request
request = receive()
// Process request only if token is unknown
if (!lookup(request.token)) // needs to implemented in a CAS way to be safe
process(request)
store(token) // Store token for lookup (can be garbage collected eventually)
Idempotency
Relaxed
Temporal
Constraints
Self-Containment
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Self-Containment
Use a framework
Spring Boot
Jackson
Metrics
Dropwizard
or do it yourself
Idempotency
Relaxed
Temporal
Constraints
Self-Containment
Latency Control
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Latency control
Complements isolation
Detection and handling of non-timely responses
Avoid cascading temporal failures
Different approaches and patterns available
Idempotency
Relaxed
Temporal
Constraints
Self-Containment
Latency Control
Loose Coupling
Asynchronous
Communication
Timeouts
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Timeouts
Idempotency
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Loose Coupling
Asynchronous
Communication
Timeouts
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Circuit Breaker
Source: https://github.com/Netflix/Hystrix/wiki/How-it-Works
Idempotency
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Fail Fast
Timeouts
Fail Fast
Idempotency
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Fail Fast
Timeouts
Idempotency
Bounded Queues
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Fail Fast
Timeouts
Bounded Queues
Idempotency
Bounded Queues
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Shed Load
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Fail Fast
Timeouts
Shed Load
Idempotency
Bounded Queues
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Shed Load
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Fail Fast
Supervision
Timeouts
Supervision
Idempotency
Bounded Queues
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Shed Load
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Fail Fast
Supervision
Monitor
Timeouts
Monitor
Idempotency
Bounded Queues
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Shed Load
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Fail Fast
Timeouts
Supervision
Error Handler
Monitor
Error Handler
Idempotency
Bounded Queues
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Shed Load
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Timeouts
Fail Fast
Supervision
Error Handler
Monitor
Escalation
Escalation
Escalation implementation
using Worker/Supervisor
Escalation
Flow / Process
Idempotency
Bounded Queues
Relaxed
Temporal
Constraints
Self-Containment
Circuit Breaker
Latency Control
Shed Load
Loose Coupling
Asynchronous
Communication
Isolation
Location
Transparency
Event-Driven
Stateless
Bulkheads
Complete
Parameter
Checking
Timeouts
Fail Fast
Supervision
Error Handler
Monitor
Escalation
Architectural patterns
Anti-fragility patterns
Wrap-up
@ufried
Uwe Friedrichsen | uwe.friedrichsen@codecentric.de | http://slideshare.net/ufried | http://ufried.tumblr.com