Search icon
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Mastering Prometheus

You're reading from  Mastering Prometheus

Product type Book
Published in Apr 2024
Publisher Packt
ISBN-13 9781805125662
Pages 310 pages
Edition 1st Edition
Languages
Concepts
Author (1):
William Hegedus William Hegedus
Profile icon William Hegedus

Table of Contents (21) Chapters

Preface 1. Part 1: Fundamentals of Prometheus
2. Chapter 1: Observability, Monitoring, and Prometheus 3. Chapter 2: Deploying Prometheus 4. Chapter 3: The Prometheus Data Model and PromQL 5. Chapter 4: Using Service Discovery 6. Chapter 5: Effective Alerting with Prometheus 7. Part 2: Scaling Prometheus
8. Chapter 6: Advancing Prometheus: Sharding, Federation, and High Availability 9. Chapter 7: Optimizing and Debugging Prometheus 10. Chapter 8: Enabling Systems Monitoring with the Node Exporter 11. Part 3: Extending Prometheus
12. Chapter 9: Utilizing Remote Storage Systems with Prometheus 13. Chapter 10: Extending Prometheus Globally with Thanos 14. Chapter 11: Jsonnet and Monitoring Mixins 15. Chapter 12: Utilizing Continuous Integration (CI) Pipelines with Prometheus 16. Chapter 13: Defining and Alerting on SLOs 17. Chapter 14: Integrating Prometheus with OpenTelemetry 18. Chapter 15: Beyond Prometheus 19. Index 20. Other Books You May Enjoy

PromQL basics

With all this talk of how data gets into Prometheus’s database and how it’s stored there, I reckon it’s about time we look at how we get that data out and make use of it. To do this, Prometheus has its own query language: PromQL.

PromQL is a vast topic, and you can craft some cool queries with it, especially concerning alerting (covered in Chapter 5).

Note

Most PromQL queries provided as examples will work in your Prometheus environment from Chapter 2!

Feel free to tweak them and experiment with them as you go along by using kubectl port-forward svc/mastering-prometheus-kube-prometheus 9090 and opening http://localhost:9090 in your browser to connect to Prometheus.

Syntax overview

PromQL is pretty straightforward and does not have a litany of different data types you need to concern yourself with. The matching operators for label filters are intuitive, and there are only four possible types that PromQL expressions can be evaluated...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}