Troubleshooting and profiling microservices

Troubleshooting and profiling microservices

5c3807aaaf0ffefe6c75e3dbbb8588b5?s=128

Michael Hausenblas

April 26, 2018
Tweet

Transcript

  1. Troubleshooting and profiling microservices Michael Hausenblas @mhausenblas
 Developer Advocate, Red

    Hat
 2018-04-26, Dublin Microservices User Group
  2. Hit me up on Twitter: @mhausenblas 2 • Developer Advocate

    @ Red Hat (Go, Kubernetes, OpenShift) • Developer Advocate @ Mesosphere (Mesos, DC/OS, Kubernetes) • Chief Data Engineer @ MapR (HDFS, HBase, Drill, etc.) • Applied research (4y in Ireland, 7y in Austria) • Nowadays mainly developing tools in Go (Python, Node, Java, C++) • Kinda developer turned ops (aka appops) $ whois mhausenblas
  3. Hit me up on Twitter: @mhausenblas 3 admin SRE developer

    QA architect PM PHB
  4. Containerized microservices

  5. Hit me up on Twitter: @mhausenblas 5 • containerized setup

    • observability • troubleshooting • profiling Terminology
  6. Hit me up on Twitter: @mhausenblas 6 A note on

    operational aspects monolith v1 monolith v2 time µS1
 v1 µS2
 v1 µS3
 v1 µS2
 v2 µS3
 v2 µS1
 v2 µS2
 v3 µS3
 v3 µS1
 v3 µS3
 v4 µS2
 v4 µS3
 v5 µS1
 v4 µS2
 v5 µS3
 v6
  7. Hit me up on Twitter: @mhausenblas 7 Challenges • Aligning

    incentives (dev vs. ops) • Fallacies of distributed computing • Where to look when things go sideways
  8. Tooling

  9. Hit me up on Twitter: @mhausenblas 9 Kubernetes kubernetes.io •

    Container lifecycle management • Declarative, state-driven • Extensible, modular API • Robust, flexible, scalable Kudos to Lucas Käldström for this figure (source)
  10. Hit me up on Twitter: @mhausenblas 10 telepresence.io vapor-ware.github.io/ksync/ www.openshift.org

    kubed.sh kedgeproject.org ksonnet.io Minikube Minishift Docker Community Edition for Mac & Windows github.com/GoogleCloudPlatform/skaffold draft.sh forge.sh gitkube.sh github.com/weaveworks/flux github.com/MinikubeAddon/watchpod Developing on Kubernetes
  11. Hit me up on Twitter: @mhausenblas 11 • Monitoring •

    Logging • Distributed tracing Observability
  12. Hit me up on Twitter: @mhausenblas 12 Monitoring node container

    app alerts dashboards storage event router
  13. Hit me up on Twitter: @mhausenblas 13 Logging

  14. Hit me up on Twitter: @mhausenblas 14 Distributed tracing opentracing.io

    • Roots ~ “time-synced logs” • Standardized • Must-have in a microservices setup • Examples: Zipkin, Jaeger
  15. … demo time!

  16. Hit me up on Twitter: @mhausenblas 16 Demo 1: debugging

    a minimal µS-based app • App consists of two microservices: • a stock generator written in Go • a stock consumer written in Node.js • Source code of demo app:
 github.com/kubernauts/dok-example-us stock-gen stock-con
  17. Hit me up on Twitter: @mhausenblas 17 stock-gen :9876/stockdata stock-con

    :9898/average/NYSE:RHT
  18. Hit me up on Twitter: @mhausenblas 18 Demo 2: distributed

    tracing in action
  19. Resources

  20. Hit me up on Twitter: @mhausenblas 20

  21. Hit me up on Twitter: @mhausenblas 21 • medium.com/@copyconstruct/monitoring-and- observability-8417d1952e1c

    • infoq.com/articles/charity-majors-observability-failure • blog.treasuredata.com/blog/2016/08/03/distributed-logging-architecture- in-the-container-era/ • mhausenblas.info/kubectl-in-action Resources
  22. plus.google.com/+RedHat linkedin.com/company/red-hat youtube.com/user/RedHatVideos facebook.com/redhatinc twitter.com/RedHatNews learn.openshift.com