Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FetchStateAndBuildZones ¶
func New ¶
func New( delegate auctiontypes.AuctionRunnerDelegate, metricEmitter auctiontypes.AuctionMetricEmitterDelegate, clock clock.Clock, workPool *workpool.WorkPool, logger lager.Logger, ) *auctionRunner
Types ¶
type Batch ¶
type Batch struct { HasWork chan struct{} // contains filtered or unexported fields }
func (*Batch) AddLRPStarts ¶
func (b *Batch) AddLRPStarts(starts []auctioneer.LRPStartRequest)
func (*Batch) AddTasks ¶
func (b *Batch) AddTasks(tasks []auctioneer.TaskStartRequest)
func (*Batch) DedupeAndDrain ¶
func (b *Batch) DedupeAndDrain() ([]auctiontypes.LRPAuction, []auctiontypes.TaskAuction)
type Cell ¶
type Cell struct { Guid string // contains filtered or unexported fields }
func (*Cell) MatchRootFS ¶
type Scheduler ¶
type Scheduler struct {
// contains filtered or unexported fields
}
func NewScheduler ¶
func (*Scheduler) Schedule ¶
func (s *Scheduler) Schedule(auctionRequest auctiontypes.AuctionRequest) auctiontypes.AuctionResults
Schedule takes in a set of job requests (LRP start auctions and task starts) and assigns the work to available cells according to the diego scoring algorithm. The scheduler is single-threaded. It determines scheduling of jobs one at a time so that each calculation reflects available resources correctly. It commits the work in batches at the end, for better network performance. Schedule returns AuctionResults, indicating the success or failure of each requested job.
type SortableLRPAuctions ¶
type SortableLRPAuctions []auctiontypes.LRPAuction
func (SortableLRPAuctions) Len ¶
func (a SortableLRPAuctions) Len() int
func (SortableLRPAuctions) Less ¶
func (a SortableLRPAuctions) Less(i, j int) bool
func (SortableLRPAuctions) Swap ¶
func (a SortableLRPAuctions) Swap(i, j int)
type SortableTaskAuctions ¶
type SortableTaskAuctions []auctiontypes.TaskAuction
func (SortableTaskAuctions) Len ¶
func (a SortableTaskAuctions) Len() int
func (SortableTaskAuctions) Less ¶
func (a SortableTaskAuctions) Less(i, j int) bool
func (SortableTaskAuctions) Swap ¶
func (a SortableTaskAuctions) Swap(i, j int)
Click to show internal directories.
Click to hide internal directories.