zookeeper

package module
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: May 17, 2021 License: BSD-3-Clause Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ZookeeperStore

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

func New

func New(basePath, addr string, port int) *ZookeeperStore

func NewFromConfig

func NewFromConfig(config *ZookeeperStoreConfig) *ZookeeperStore

func (*ZookeeperStore) Close

func (s *ZookeeperStore) Close() error

func (*ZookeeperStore) CreateStrategy

func (s *ZookeeperStore) CreateStrategy(strategy *definition.Strategy) error

func (*ZookeeperStore) CreateTask

func (s *ZookeeperStore) CreateTask(task *definition.Task) error

func (*ZookeeperStore) Dump

func (s *ZookeeperStore) Dump() string

func (*ZookeeperStore) GetScheduler

func (s *ZookeeperStore) GetScheduler(id string) (*definition.Scheduler, error)

func (*ZookeeperStore) GetSchedulers

func (s *ZookeeperStore) GetSchedulers() ([]*definition.Scheduler, error)

func (*ZookeeperStore) GetStrategies

func (s *ZookeeperStore) GetStrategies() ([]*definition.Strategy, error)

func (*ZookeeperStore) GetStrategy

func (s *ZookeeperStore) GetStrategy(id string) (*definition.Strategy, error)

func (*ZookeeperStore) GetStrategyRuntime

func (s *ZookeeperStore) GetStrategyRuntime(strategyId, schedulerId string) (*definition.StrategyRuntime, error)

func (*ZookeeperStore) GetStrategyRuntimes

func (s *ZookeeperStore) GetStrategyRuntimes(strategyId string) ([]*definition.StrategyRuntime, error)

func (*ZookeeperStore) GetTask

func (s *ZookeeperStore) GetTask(id string) (*definition.Task, error)

func (*ZookeeperStore) GetTaskAssignment

func (s *ZookeeperStore) GetTaskAssignment(strategyId, taskId, itemId string) (*definition.TaskAssignment, error)

func (*ZookeeperStore) GetTaskAssignments

func (s *ZookeeperStore) GetTaskAssignments(strategyId, taskId string) ([]*definition.TaskAssignment, error)

func (*ZookeeperStore) GetTaskItemsConfigVersion

func (s *ZookeeperStore) GetTaskItemsConfigVersion(strategyId, taskId string) (int64, error)

func (*ZookeeperStore) GetTaskRuntime

func (s *ZookeeperStore) GetTaskRuntime(strategyId, taskId, id string) (*definition.TaskRuntime, error)

func (*ZookeeperStore) GetTaskRuntimes

func (s *ZookeeperStore) GetTaskRuntimes(strategyId, taskId string) ([]*definition.TaskRuntime, error)

func (*ZookeeperStore) GetTasks

func (s *ZookeeperStore) GetTasks() ([]*definition.Task, error)

func (*ZookeeperStore) IncreaseTaskItemsConfigVersion

func (s *ZookeeperStore) IncreaseTaskItemsConfigVersion(strategyId, taskId string) error

func (*ZookeeperStore) Name

func (s *ZookeeperStore) Name() string

func (*ZookeeperStore) RegisterScheduler

func (s *ZookeeperStore) RegisterScheduler(scheduler *definition.Scheduler) error

func (*ZookeeperStore) RemoveStrategy

func (s *ZookeeperStore) RemoveStrategy(id string) error

func (*ZookeeperStore) RemoveStrategyRuntime

func (s *ZookeeperStore) RemoveStrategyRuntime(strategyId, schedulerId string) error

func (*ZookeeperStore) RemoveTask

func (s *ZookeeperStore) RemoveTask(id string) error

func (*ZookeeperStore) RemoveTaskAssignment

func (s *ZookeeperStore) RemoveTaskAssignment(strategyId, taskId, itemId string) error

func (*ZookeeperStore) RemoveTaskRuntime

func (s *ZookeeperStore) RemoveTaskRuntime(strategyId, taskId, id string) error

func (*ZookeeperStore) Sequence

func (s *ZookeeperStore) Sequence() (uint64, error)

func (*ZookeeperStore) SetStrategyRuntime

func (s *ZookeeperStore) SetStrategyRuntime(runtime *definition.StrategyRuntime) error

func (*ZookeeperStore) SetTaskAssignment

func (s *ZookeeperStore) SetTaskAssignment(assignment *definition.TaskAssignment) error

func (*ZookeeperStore) SetTaskRuntime

func (s *ZookeeperStore) SetTaskRuntime(runtime *definition.TaskRuntime) error

func (*ZookeeperStore) Time

func (s *ZookeeperStore) Time() int64

func (*ZookeeperStore) UnregisterScheduler

func (s *ZookeeperStore) UnregisterScheduler(id string) error

func (*ZookeeperStore) UpdateStrategy

func (s *ZookeeperStore) UpdateStrategy(strategy *definition.Strategy) error

func (*ZookeeperStore) UpdateTask

func (s *ZookeeperStore) UpdateTask(task *definition.Task) error

type ZookeeperStoreConfig

type ZookeeperStoreConfig struct {
	// nodes/cluster nodes addresses
	Addrs []string
	// prefix which can isolate different applciations in same instance/cluster
	BasePath string
	Username string
	Password string
}

Jump to

Keyboard shortcuts

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