Versions in this module Expand all Collapse all v0 v0.1.0 Sep 28, 2015 Changes in this version + const DefaultDC + const DefaultDequeueTimeout + const DefaultRegion + const DefaultSerfPort + const ProtocolVersionMax + const ProtocolVersionMin + const StatusReap + var DefaultRPCAddr = &net.TCPAddr + func NewCoreScheduler(srv *Server, snap *state.StateSnapshot) scheduler.Scheduler + func NewFSM(evalBroker *EvalBroker, logOutput io.Writer) (*nomadFSM, error) + func RuntimeStats() map[string]string + type Alloc struct + func (a *Alloc) GetAlloc(args *structs.AllocSpecificRequest, reply *structs.SingleAllocResponse) error + func (a *Alloc) List(args *structs.AllocListRequest, reply *structs.AllocListResponse) error + type BrokerStats struct + ByScheduler map[string]*SchedulerStats + TotalBlocked int + TotalReady int + TotalUnacked int + TotalWaiting int + type Config struct + Bootstrap bool + BootstrapExpect int + Build string + DataDir string + Datacenter string + DevDisableBootstrap bool + DevMode bool + EnabledSchedulers []string + EvalDeliveryLimit int + EvalGCInterval time.Duration + EvalGCThreshold time.Duration + EvalNackTimeout time.Duration + FailoverHeartbeatTTL time.Duration + HeartbeatGrace time.Duration + LogOutput io.Writer + MaxHeartbeatsPerSecond float64 + MinHeartbeatTTL time.Duration + NodeGCInterval time.Duration + NodeGCThreshold time.Duration + NodeName string + NumSchedulers int + ProtocolVersion uint8 + RPCAddr *net.TCPAddr + RPCAdvertise *net.TCPAddr + RaftConfig *raft.Config + RaftTimeout time.Duration + ReconcileInterval time.Duration + Region string + RequireTLS bool + SerfConfig *serf.Config + func DefaultConfig() *Config + func (c *Config) CheckVersion() error + type Conn struct + func (c *Conn) Close() error + type ConnPool struct + func NewPool(logOutput io.Writer, maxTime time.Duration, maxStreams int, ...) *ConnPool + func (p *ConnPool) RPC(region string, addr net.Addr, version int, method string, args interface{}, ...) error + func (p *ConnPool) Shutdown() error + type CoreScheduler struct + func (s *CoreScheduler) Process(eval *structs.Evaluation) error + type Eval struct + func (e *Eval) Ack(args *structs.EvalAckRequest, reply *structs.GenericResponse) error + func (e *Eval) Allocations(args *structs.EvalSpecificRequest, reply *structs.EvalAllocationsResponse) error + func (e *Eval) Create(args *structs.EvalUpdateRequest, reply *structs.GenericResponse) error + func (e *Eval) Dequeue(args *structs.EvalDequeueRequest, reply *structs.EvalDequeueResponse) error + func (e *Eval) GetEval(args *structs.EvalSpecificRequest, reply *structs.SingleEvalResponse) error + func (e *Eval) List(args *structs.EvalListRequest, reply *structs.EvalListResponse) error + func (e *Eval) Nack(args *structs.EvalAckRequest, reply *structs.GenericResponse) error + func (e *Eval) Reap(args *structs.EvalDeleteRequest, reply *structs.GenericResponse) error + func (e *Eval) Update(args *structs.EvalUpdateRequest, reply *structs.GenericResponse) error + type EvalBroker struct + func NewEvalBroker(timeout time.Duration, deliveryLimit int) (*EvalBroker, error) + func (b *EvalBroker) Ack(evalID, token string) error + func (b *EvalBroker) Dequeue(schedulers []string, timeout time.Duration) (*structs.Evaluation, string, error) + func (b *EvalBroker) EmitStats(period time.Duration, stopCh chan struct{}) + func (b *EvalBroker) Enabled() bool + func (b *EvalBroker) Enqueue(eval *structs.Evaluation) error + func (b *EvalBroker) Flush() + func (b *EvalBroker) Nack(evalID, token string) error + func (b *EvalBroker) Outstanding(evalID string) (string, bool) + func (b *EvalBroker) SetEnabled(enabled bool) + func (b *EvalBroker) Stats() *BrokerStats + type Job struct + func (j *Job) Allocations(args *structs.JobSpecificRequest, reply *structs.JobAllocationsResponse) error + func (j *Job) Deregister(args *structs.JobDeregisterRequest, reply *structs.JobDeregisterResponse) error + func (j *Job) Evaluate(args *structs.JobEvaluateRequest, reply *structs.JobRegisterResponse) error + func (j *Job) Evaluations(args *structs.JobSpecificRequest, reply *structs.JobEvaluationsResponse) error + func (j *Job) GetJob(args *structs.JobSpecificRequest, reply *structs.SingleJobResponse) error + func (j *Job) List(args *structs.JobListRequest, reply *structs.JobListResponse) error + func (j *Job) Register(args *structs.JobRegisterRequest, reply *structs.JobRegisterResponse) error + type Node struct + func (n *Node) Deregister(args *structs.NodeDeregisterRequest, reply *structs.NodeUpdateResponse) error + func (n *Node) Evaluate(args *structs.NodeEvaluateRequest, reply *structs.NodeUpdateResponse) error + func (n *Node) GetAllocs(args *structs.NodeSpecificRequest, reply *structs.NodeAllocsResponse) error + func (n *Node) GetNode(args *structs.NodeSpecificRequest, reply *structs.SingleNodeResponse) error + func (n *Node) List(args *structs.NodeListRequest, reply *structs.NodeListResponse) error + func (n *Node) Register(args *structs.NodeRegisterRequest, reply *structs.NodeUpdateResponse) error + func (n *Node) UpdateAlloc(args *structs.AllocUpdateRequest, reply *structs.GenericResponse) error + func (n *Node) UpdateDrain(args *structs.NodeUpdateDrainRequest, reply *structs.NodeDrainUpdateResponse) error + func (n *Node) UpdateStatus(args *structs.NodeUpdateStatusRequest, reply *structs.NodeUpdateResponse) error + type PendingEvaluations []*structs.Evaluation + func (p *PendingEvaluations) Pop() interface{} + func (p *PendingEvaluations) Push(e interface{}) + func (p PendingEvaluations) Len() int + func (p PendingEvaluations) Less(i, j int) bool + func (p PendingEvaluations) Peek() *structs.Evaluation + func (p PendingEvaluations) Swap(i, j int) + type PendingPlans []*pendingPlan + func (p *PendingPlans) Pop() interface{} + func (p *PendingPlans) Push(e interface{}) + func (p PendingPlans) Len() int + func (p PendingPlans) Less(i, j int) bool + func (p PendingPlans) Peek() *pendingPlan + func (p PendingPlans) Swap(i, j int) + type Plan struct + func (p *Plan) Submit(args *structs.PlanRequest, reply *structs.PlanResponse) error + type PlanFuture interface + Wait func() (*structs.PlanResult, error) + type PlanQueue struct + func NewPlanQueue() (*PlanQueue, error) + func (q *PlanQueue) Dequeue(timeout time.Duration) (*pendingPlan, error) + func (q *PlanQueue) EmitStats(period time.Duration, stopCh chan struct{}) + func (q *PlanQueue) Enabled() bool + func (q *PlanQueue) Enqueue(plan *structs.Plan) (PlanFuture, error) + func (q *PlanQueue) Flush() + func (q *PlanQueue) SetEnabled(enabled bool) + func (q *PlanQueue) Stats() *QueueStats + type QueueStats struct + Depth int + type RPCType byte + type RaftLayer struct + func NewRaftLayer(addr net.Addr, tlsWrap tlsutil.Wrapper) *RaftLayer + func (l *RaftLayer) Accept() (net.Conn, error) + func (l *RaftLayer) Addr() net.Addr + func (l *RaftLayer) Close() error + func (l *RaftLayer) Dial(address string, timeout time.Duration) (net.Conn, error) + func (l *RaftLayer) Handoff(c net.Conn) error + type SchedulerStats struct + Ready int + Unacked int + type Server struct + func NewServer(config *Config) (*Server, error) + func (c *Server) LocalMember() serf.Member + func (s *Server) Encrypted() bool + func (s *Server) IsLeader() bool + func (s *Server) IsShutdown() bool + func (s *Server) Join(addrs []string) (int, error) + func (s *Server) KeyManager() *serf.KeyManager + func (s *Server) Leave() error + func (s *Server) Members() []serf.Member + func (s *Server) RPC(method string, args interface{}, reply interface{}) error + func (s *Server) RemoveFailedNode(node string) error + func (s *Server) Shutdown() error + func (s *Server) State() *state.StateStore + func (s *Server) Stats() map[string]map[string]string + type SnapshotType byte + const AllocSnapshot + const EvalSnapshot + const IndexSnapshot + const JobSnapshot + const NodeSnapshot + const TimeTableSnapshot + type Status struct + func (s *Status) Leader(args *structs.GenericRequest, reply *string) error + func (s *Status) Peers(args *structs.GenericRequest, reply *[]string) error + func (s *Status) Ping(args struct{}, reply *struct{}) error + func (s *Status) Version(args *structs.GenericRequest, reply *structs.VersionResponse) error + type StreamClient struct + func (sc *StreamClient) Close() + type TimeTable struct + func NewTimeTable(granularity time.Duration, limit time.Duration) *TimeTable + func (t *TimeTable) Deserialize(dec *codec.Decoder) error + func (t *TimeTable) NearestIndex(when time.Time) uint64 + func (t *TimeTable) NearestTime(index uint64) time.Time + func (t *TimeTable) Serialize(enc *codec.Encoder) error + func (t *TimeTable) Witness(index uint64, when time.Time) + type TimeTableEntry struct + Index uint64 + Time time.Time + type Worker struct + func NewWorker(srv *Server) (*Worker, error) + func (w *Worker) CreateEval(eval *structs.Evaluation) error + func (w *Worker) SetPause(p bool) + func (w *Worker) SubmitPlan(plan *structs.Plan) (*structs.PlanResult, scheduler.State, error) + func (w *Worker) UpdateEval(eval *structs.Evaluation) error