Documentation
¶
Overview ¶
Package consul provides a consul client from which data will be queried to know the health status of a service based in its tags
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DefaultClientConfig ¶
DefaultClientConfig returns the default consul config
Types ¶
type Check ¶
type Check struct {
// Consul Client object from our custom Consul client wrapper
Consul *Consul
// CheckConfig
Config *CheckConfig
// QueryOptions is a consulapi struct that allows us to to blocking queries
QueryOptions *consulapi.QueryOptions
}
Check is used to represent a single service check
type CheckConfig ¶
type CheckConfig struct {
// Service the name of the service we'll check
Service string
// Tags is a filter applied to the service we'll check
Tag string
// PassingOnly will show only passing services or not
PassingOnly bool
// BlockTime Consul blocking query time
BlockTime time.Duration
}
CheckConfig is used to represent a basic Check configuration
func DefaultCheckConfig ¶
func DefaultCheckConfig() *CheckConfig
DefaultCheckConfig retruns a valid check configuration
Click to show internal directories.
Click to hide internal directories.