Search icon
Subscription
0
Cart icon
Close icon
You have no products in your basket yet
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Simplifying Service Management with Consul

You're reading from  Simplifying Service Management with Consul

Product type Book
Published in Nov 2021
Publisher Packt
ISBN-13 9781800202627
Pages 234 pages
Edition 1st Edition
Languages
Concepts
Author (1):
Robert E. Jackson Robert E. Jackson
Profile icon Robert E. Jackson

Table of Contents (12) Chapters

Preface 1. Section 1: Consul Use Cases and Architecture
2. Chapter 1: Consul Overview – Operation and Use Cases 3. Chapter 2: Architecture – How Does It Work? 4. Chapter 3: Keep It Safe, Stupid, and Secure Your Cluster! 5. Chapter 4: Data Center (Not Trade) Federation 6. Section 2: Use Cases Deep Dive
7. Chapter 5: Little Bo Peep Lost Her Service 8. Chapter 6: Connect Four or More 9. Chapter 7: Animate Me 10. Chapter 8: Where Do We Go Now? 11. Other Books You May Enjoy

Watching your handlers

Way back in Chapter 5, Little Bo Peep Lost Her Service, where Little Bo Peep lost her service, we touched on the functionality of Consul watches and handlers. Recall that a Consul watch observes any number of parameters within Consul, and based on value changes, can execute a handler to perform some function. Within Chapter 5, Little Bo Peep Lost Her Service, we focused on being able to watch the status of a service, in order to inform a third party about service health. We can use this same functionality, but instead of watching service status, we can watch the status of a parameter within the KV store.

For example, if we wanted to watch our key, using the direct command line, we would execute the following:

$ consul watch -type=key -key=son/seventh/gift
{
    "Key": "son/seventh/gift",
    "CreateIndex": 194,
    "ModifyIndex": 237,
   &...
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}