daemon

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2020 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StartedEventPath = types.EventPath("daemon-started")
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseProvider

type BaseProvider struct {
	Factories       []worker.Factory
	OnDaemonStarted func(*Daemon)
}

func (BaseProvider) NewDaemon

func (provider BaseProvider) NewDaemon(tmCfg *cfg.Config, logger log.Logger, tmNode *node.Node, daemonApp *tm.DaemonApp, config common.DaemonConfig) *Daemon

type Daemon

type Daemon struct {
	// contains filtered or unexported fields
}

func NewDaemon

func NewDaemon(tmCfg *cfg.Config, logger log.Logger, tmNode *node.Node, config common.DaemonConfig, spaceRegistry types.SpaceRegistry) (dm *Daemon)

func (*Daemon) GetClient

func (dm *Daemon) GetClient() types.Client

func (*Daemon) GetCluster

func (dm *Daemon) GetCluster() *cluster.Cluster

func (*Daemon) GetContext

func (dm *Daemon) GetContext() common.Context

func (*Daemon) GetDaemonConfig

func (dm *Daemon) GetDaemonConfig() common.DaemonConfig

func (*Daemon) GetJobRepository

func (dm *Daemon) GetJobRepository() job.Repository

func (*Daemon) GetTMConfig

func (dm *Daemon) GetTMConfig() cfg.Config

func (*Daemon) ID

func (dm *Daemon) ID() string

func (*Daemon) IsLeaderNode

func (dm *Daemon) IsLeaderNode() bool

func (*Daemon) RegisterWorkerFactory

func (dm *Daemon) RegisterWorkerFactory(factory worker.Factory)

RegisterWorkerFactory register worker.Factory

func (*Daemon) SetJobOrganizer

func (dm *Daemon) SetJobOrganizer(organizer job.Organizer)

func (*Daemon) Start

func (dm *Daemon) Start()

type Provider

type Provider func(tmCfg *cfg.Config, logger log.Logger, tmNode *node.Node, daemonApp *tm.DaemonApp, config common.DaemonConfig) *Daemon

type StartedEvent

type StartedEvent struct {
	common.DaemonEvent
}

func (StartedEvent) Path

func (event StartedEvent) Path() types.EventPath

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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