juju-vmware: github.com/Altoros/juju-vmware/worker/envworkermanager Index | Files

package envworkermanager

import "github.com/Altoros/juju-vmware/worker/envworkermanager"

Index

Package Files

envworkermanager.go

func NewEnvWorkerManager Uses

func NewEnvWorkerManager(
    st InitialState,
    startEnvWorkers func(InitialState, *state.State) (worker.Runner, error),
) worker.Worker

NewEnvWorkerManager returns a Worker which manages the workers which need to run on a per environment basis. It takes a function which will be called to start workers for a new environment. These workers will be killed when an environment goes away.

type InitialState Uses

type InitialState interface {
    WatchEnvironments() state.StringsWatcher
    ForEnviron(names.EnvironTag) (*state.State, error)
    GetEnvironment(names.EnvironTag) (*state.Environment, error)
    EnvironUUID() string
    Machine(string) (*state.Machine, error)
    MongoSession() *mgo.Session
}

InitialState defines the State functionality used by envWorkerManager and/or could be useful to startEnvWorkers funcs. It mainly exists to support testing.

Package envworkermanager imports 8 packages (graph). Updated 2016-07-22. Refresh now. Tools for package owners. This is an inactive package (no imports and no commits in at least two years).