instance

package
v0.0.0-...-a355528 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 27, 2017 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Tracker

type Tracker struct {

	// Plugin is the instance plugin to use
	Plugin instance.Plugin

	// Name is the name of the plugin
	Name string
	// contains filtered or unexported fields
}

Tracker implements the event spi -- just just calls the Describe to get a list of known instances, and report anything it hasn't seen before, or if anything that disappeared.

func NewTracker

func NewTracker(name string, plugin instance.Plugin, tick <-chan time.Time, tags map[string]string) *Tracker

NewTracker returns an event plugin implementation that can generate events based on resources it trackers

func (*Tracker) List

func (m *Tracker) List(topic types.Path) ([]string, error)

List returns the nodes under the given topic

func (*Tracker) PublishOn

func (m *Tracker) PublishOn(events chan<- *event.Event)

PublishOn sets the channel to publish on

func (*Tracker) Stop

func (m *Tracker) Stop()

Stop stops the Tracker

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL