bbs

package
v0.0.0-...-a17cc88 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2014 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuctioneerBBS

type AuctioneerBBS interface {
	//services
	GetAllExecutors() ([]models.ExecutorPresence, error)

	//start auction
	WatchForLRPStartAuction() (<-chan models.LRPStartAuction, chan<- bool, <-chan error)
	ClaimLRPStartAuction(models.LRPStartAuction) error
	ResolveLRPStartAuction(models.LRPStartAuction) error

	//stop auction
	WatchForLRPStopAuction() (<-chan models.LRPStopAuction, chan<- bool, <-chan error)
	ClaimLRPStopAuction(models.LRPStopAuction) error
	ResolveLRPStopAuction(models.LRPStopAuction) error

	//lock
	MaintainAuctioneerLock(interval time.Duration, auctioneerID string) (<-chan bool, chan<- chan bool, error)
}

func NewAuctioneerBBS

func NewAuctioneerBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) AuctioneerBBS

type ConvergerBBS

type ConvergerBBS interface {
	//lrp
	ConvergeLRPs()
	GetActualLRPsByProcessGuid(string) ([]models.ActualLRP, error)
	RequestStopLRPInstance(stopInstance models.StopLRPInstance) error
	WatchForDesiredLRPChanges() (<-chan models.DesiredLRPChange, chan<- bool, <-chan error)

	//start auction
	ConvergeLRPStartAuctions(kickPendingDuration time.Duration, expireClaimedDuration time.Duration)
	RequestLRPStartAuction(models.LRPStartAuction) error

	//stop auction
	ConvergeLRPStopAuctions(kickPendingDuration time.Duration, expireClaimedDuration time.Duration)
	RequestLRPStopAuction(models.LRPStopAuction) error

	//task
	ConvergeTask(timeToClaim time.Duration, converganceInterval time.Duration)

	//lock
	MaintainConvergeLock(interval time.Duration, executorID string) (disappeared <-chan bool, stop chan<- chan bool, err error)

	//services
	GetAvailableFileServer() (string, error)
}

func NewConvergerBBS

func NewConvergerBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) ConvergerBBS

type FileServerBBS

type FileServerBBS interface {
	//services
	MaintainFileServerPresence(
		heartbeatInterval time.Duration,
		fileServerURL string,
		fileServerId string,
	) (presence services_bbs.Presence, disappeared <-chan bool, err error)
}

func NewFileServerBBS

func NewFileServerBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) FileServerBBS

type MetricsBBS

type MetricsBBS interface {
	//task
	GetAllTasks() ([]models.Task, error)

	//services
	GetServiceRegistrations() (models.ServiceRegistrations, error)
}

func NewMetricsBBS

func NewMetricsBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) MetricsBBS

type NsyncBBS

type NsyncBBS interface {
	// lrp
	DesireLRP(models.DesiredLRP) error
	RemoveDesiredLRPByProcessGuid(guid string) error
	GetAllDesiredLRPsByDomain(domain string) ([]models.DesiredLRP, error)
	ChangeDesiredLRP(change models.DesiredLRPChange) error
}

func NewNsyncBBS

func NewNsyncBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) NsyncBBS

type RepBBS

type RepBBS interface {
	//services
	MaintainExecutorPresence(heartbeatInterval time.Duration, executorPresence models.ExecutorPresence) (services_bbs.Presence, <-chan bool, error)

	//task
	WatchForDesiredTask() (<-chan models.Task, chan<- bool, <-chan error)
	ClaimTask(taskGuid string, executorID string) error
	StartTask(taskGuid string, executorID string, containerHandle string) error
	CompleteTask(taskGuid string, failed bool, failureReason string, result string) error

	///lrp
	ReportActualLRPAsStarting(lrp models.ActualLRP, executorID string) error
	ReportActualLRPAsRunning(lrp models.ActualLRP, executorId string) error
	RemoveActualLRP(lrp models.ActualLRP) error
	RemoveActualLRPForIndex(processGuid string, index int, instanceGuid string) error
	WatchForStopLRPInstance() (<-chan models.StopLRPInstance, chan<- bool, <-chan error)
	ResolveStopLRPInstance(stopInstance models.StopLRPInstance) error
}

func NewRepBBS

func NewRepBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) RepBBS

type RouteEmitterBBS

type RouteEmitterBBS interface {
	// lrp
	WatchForDesiredLRPChanges() (<-chan models.DesiredLRPChange, chan<- bool, <-chan error)
	WatchForActualLRPChanges() (<-chan models.ActualLRPChange, chan<- bool, <-chan error)
	GetAllDesiredLRPs() ([]models.DesiredLRP, error)
	GetRunningActualLRPs() ([]models.ActualLRP, error)
	GetDesiredLRPByProcessGuid(processGuid string) (models.DesiredLRP, error)
	GetRunningActualLRPsByProcessGuid(processGuid string) ([]models.ActualLRP, error)
}

func NewRouteEmitterBBS

func NewRouteEmitterBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) RouteEmitterBBS

type StagerBBS

type StagerBBS interface {
	//task
	WatchForCompletedTask() (<-chan models.Task, chan<- bool, <-chan error)
	DesireTask(models.Task) error
	ResolvingTask(taskGuid string) error
	ResolveTask(taskGuid string) error

	//services
	GetAvailableFileServer() (string, error)
}

func NewStagerBBS

func NewStagerBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) StagerBBS

type TPSBBS

type TPSBBS interface {
	//lrp
	GetActualLRPsByProcessGuid(string) ([]models.ActualLRP, error)
}

func NewTPSBBS

func NewTPSBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) TPSBBS

type VeritasBBS

type VeritasBBS interface {
	//task
	GetAllTasks() ([]models.Task, error)

	//lrp
	GetAllDesiredLRPs() ([]models.DesiredLRP, error)
	GetAllActualLRPs() ([]models.ActualLRP, error)
	GetAllStopLRPInstances() ([]models.StopLRPInstance, error)

	//start auctions
	GetAllLRPStartAuctions() ([]models.LRPStartAuction, error)

	//stop auctions
	GetAllLRPStopAuctions() ([]models.LRPStopAuction, error)

	//services
	GetAllExecutors() ([]models.ExecutorPresence, error)
	GetAllFileServers() ([]string, error)
}

func NewVeritasBBS

func NewVeritasBBS(store storeadapter.StoreAdapter, timeProvider timeprovider.TimeProvider, logger lager.Logger) VeritasBBS

Directories

Path Synopsis
This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter
This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter

Jump to

Keyboard shortcuts

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