This document discusses various techniques for monitoring microservices including Circuit Breaker pattern, bulkheads, back pressure, Hystrix, Hystrix Dashboard, thread pools, Dynatrace, and memory analysis. Hystrix is a latency and fault tolerance library used for monitoring, controlling concurrency, and isolating points of access to remote systems. The Hystrix Dashboard provides real-time monitoring. Dynatrace allows deep profiling of applications through memory dumps and other techniques to identify performance issues and root causes. The workshops agenda covers setting up Hystrix commands, the dashboard, and connecting applications to Dynatrace for memory and GC monitoring.
5. Back pressure
4
https://github.com/Netflix/Hystrix/wiki
Circuit breaker, back pressure, bulkhead pattern, cascading failures, http 429 too many requests
10. Migrating a Library to Hystrix
19
- External service call should be wrapped into a HystrixCommand
- Configure thread pools
- Fine grained command names
Circuit breaker, Timeouts, queue size, thread pool size
11. Patterns and anti-patterns: naming convention
22
https://wiki.hybris.com/display/prodandtech/Hystrix+commands+naming+convention+-+draft
docu-repo-v2.deleteType.db
Service name
version Command name
External service
12. Patterns and anti-patterns: thread pools
22
https://github.com/Netflix/Hystrix/wiki/Configuration#threadpool-properties
- Netflix API has 30+ of its threadpools
set at 10, 2 at 20 and 1 at 25
- Queue size affect request times !
18. Dynatrace – advantages
Direct access to agent machine
Memory dumps
CPU sampling
Much more
JVM and system monitoring
Request tracing across services
Hot sensor placement – class instrumentation can be changed without restart
38
19. Dynatrace – disadvantages
Performance overhead
Sensor configuration affects all agents
Weak support for java 8 (although dynatrace version 6 is out)
Steep learning curve
41
20. Dynatrace patterns and anti-patterns
Do NOT use it for monitoring – utilize its profiling power
Much better tools available for monitoring (Graphite, hystrix dashboard)
Applications designed to be monitored does not need dynatrace
Only very simple alerts available
Turn off sensors by default to save performance
Configure separate service instance with extended number of sensors on
demand
Route part of the traffic through this service (canary testing)
44