client

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 27, 2016 License: BSD-2-Clause Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	// Gets all registered minions
	MinionList() ([]uuid.UUID, error)

	// Gets the name of a minion
	MinionName(m uuid.UUID) (string, error)

	// Gets the time a minion was last seen
	MinionLastseen(m uuid.UUID) (int64, error)

	// Gets a classifier of a minion
	MinionClassifier(m uuid.UUID, key string) (*classifier.Classifier, error)

	// Gets all classifier keys of a minion
	MinionClassifierKeys(m uuid.UUID) ([]string, error)

	// Gets minions which are classified with a given classifier key
	MinionWithClassifierKey(key string) ([]uuid.UUID, error)

	// Gets the result of a task for a minion
	MinionTaskResult(m uuid.UUID, t uuid.UUID) (*task.Task, error)

	// Gets the minions which have a task result with the given uuid
	MinionWithTaskResult(t uuid.UUID) ([]uuid.UUID, error)

	// Gets the tasks which are currently pending in the queue
	MinionTaskQueue(m uuid.UUID) ([]*task.Task, error)

	// Gets the uuids of tasks which have already been processed
	MinionTaskLog(m uuid.UUID) ([]uuid.UUID, error)

	// Submits a new task to a minion
	MinionSubmitTask(m uuid.UUID, t *task.Task) error
}

Client interface for interacting with minions

func NewEtcdMinionClient

func NewEtcdMinionClient(cfg etcdclient.Config) Client

NewEtcdMinionClient creates a new client for interacting with minions using etcd as their interface implementation

Jump to

Keyboard shortcuts

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