Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Monitor ¶
type Monitor struct { ID int Alias string URL url.URL Method string Headers []string Client *http.Client Interval time.Duration Timeout time.Duration Validators []rule.Validator Ticker *time.Ticker Labels map[string]string }
Monitor is a go routine in charge of the monitoring work.
func NewMonitor ¶
NewMonitor create a new monitor
type Monitoring ¶ added in v1.1.0
type Monitoring struct {
// contains filtered or unexported fields
}
Monitoring structure
func NewMonitoring ¶ added in v1.1.0
func NewMonitoring(conf config.Config) *Monitoring
NewMonitoring creates new monitoring instance
func (*Monitoring) RestartOnSDConfigChange ¶ added in v1.1.0
func (m *Monitoring) RestartOnSDConfigChange()
RestartOnSDConfigChange restart monitoring when Service Discover configuration change
func (*Monitoring) Start ¶ added in v1.1.0
func (m *Monitoring) Start() error
Start is charged to start all monitors
Click to show internal directories.
Click to hide internal directories.