Discover Packages
github.com/Jille/raft-grpc-leader-rpc
leaderhealth
package
Version:
v1.1.0
Opens a new window with list of versions in this module.
Published: Sep 9, 2020
License: BSD-2-Clause
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 18
Opens a new window with list of known importers.
Documentation
Documentation
¶
Package leaderhealth is included in your Raft nodes to expose whether this node is the leader.
Report starts a goroutine that updates the given health.Server with whether we are the Raft leader.
It will set the given services as SERVING if we are the leader, and as NOT_SERVING otherwise.
Setup creates a new health.Server for you and registers it on s.
It's a convenience wrapper around Report.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.