open-nomad/scheduler/service_sched.go

33 lines
803 B
Go
Raw Normal View History

package scheduler
import (
"log"
"github.com/hashicorp/nomad/nomad/structs"
)
// ServiceScheduler is used for 'service' type jobs. This scheduler is
// designed for long-lived services, and as such spends more time attemping
// to make a high quality placement. This is the primary scheduler for
// most workloads.
type ServiceScheduler struct {
logger *log.Logger
state State
planner Planner
}
// NewServiceScheduler is a factory function to instantiate a new service scheduler
func NewServiceScheduler(logger *log.Logger, state State, planner Planner) Scheduler {
s := &ServiceScheduler{
logger: logger,
state: state,
planner: planner,
}
return s
}
// Process is used to handle a single evaluation
func (s *ServiceScheduler) Process(*structs.Evaluation) error {
return nil
}