Documentation ¶
Index ¶
- Constants
- func GetFrameWorkID() (string, float64)
- func Run(...)
- type MrRedisScheduler
- func (S *MrRedisScheduler) Disconnected(sched.SchedulerDriver)
- func (S *MrRedisScheduler) Error(_ sched.SchedulerDriver, err string)
- func (S *MrRedisScheduler) ExecutorLost(_ sched.SchedulerDriver, eid *mesos.ExecutorID, sid *mesos.SlaveID, code int)
- func (S *MrRedisScheduler) FrameworkMessage(_ sched.SchedulerDriver, eid *mesos.ExecutorID, sid *mesos.SlaveID, msg string)
- func (S *MrRedisScheduler) OfferRescinded(_ sched.SchedulerDriver, oid *mesos.OfferID)
- func (S *MrRedisScheduler) Registered(driver sched.SchedulerDriver, frameworkID *mesos.FrameworkID, ...)
- func (S *MrRedisScheduler) Reregistered(driver sched.SchedulerDriver, masterInfo *mesos.MasterInfo)
- func (S *MrRedisScheduler) ResourceOffers(driver sched.SchedulerDriver, offers []*mesos.Offer)
- func (S *MrRedisScheduler) SlaveLost(_ sched.SchedulerDriver, sid *mesos.SlaveID)
- func (S *MrRedisScheduler) StatusUpdate(driver sched.SchedulerDriver, status *mesos.TaskStatus)
Constants ¶
const FailoverTime = 60 * 60 * 24 * 7
FailoverTime Frameowkr and its task will be terminated if the framework is not available for 1 week
const TimeFormat = "2006-01-02 15:04:05.999999999 -0700 MST"
TimeFormat we need to parse the Timestamp
Variables ¶
This section is empty.
Functions ¶
func GetFrameWorkID ¶
GetFrameWorkID If the framework was regiestered before the Failover timeout value then regiester as a new framework
Types ¶
type MrRedisScheduler ¶
type MrRedisScheduler struct {
// contains filtered or unexported fields
}
MrRedisScheduler scheudler struct
func NewMrRedisScheduler ¶
func NewMrRedisScheduler(exec *mesos.ExecutorInfo) *MrRedisScheduler
NewMrRedisScheduler Constructor
func (*MrRedisScheduler) Disconnected ¶
func (S *MrRedisScheduler) Disconnected(sched.SchedulerDriver)
Disconnected Not implemented call back
func (*MrRedisScheduler) Error ¶
func (S *MrRedisScheduler) Error(_ sched.SchedulerDriver, err string)
Error Not implemeted
func (*MrRedisScheduler) ExecutorLost ¶
func (S *MrRedisScheduler) ExecutorLost(_ sched.SchedulerDriver, eid *mesos.ExecutorID, sid *mesos.SlaveID, code int)
ExecutorLost Not implemented
func (*MrRedisScheduler) FrameworkMessage ¶
func (S *MrRedisScheduler) FrameworkMessage(_ sched.SchedulerDriver, eid *mesos.ExecutorID, sid *mesos.SlaveID, msg string)
FrameworkMessage not implemented
func (*MrRedisScheduler) OfferRescinded ¶
func (S *MrRedisScheduler) OfferRescinded(_ sched.SchedulerDriver, oid *mesos.OfferID)
OfferRescinded Not implemented
func (*MrRedisScheduler) Registered ¶
func (S *MrRedisScheduler) Registered(driver sched.SchedulerDriver, frameworkID *mesos.FrameworkID, masterInfo *mesos.MasterInfo)
Registered Scheduler register call back initializes the timestamp and framework id
func (*MrRedisScheduler) Reregistered ¶
func (S *MrRedisScheduler) Reregistered(driver sched.SchedulerDriver, masterInfo *mesos.MasterInfo)
Reregistered re-register call back simply updates the timestamp
func (*MrRedisScheduler) ResourceOffers ¶
func (S *MrRedisScheduler) ResourceOffers(driver sched.SchedulerDriver, offers []*mesos.Offer)
ResourceOffers The moment we recive some offers we loop through the OfferList (container/list) see if we have any task that will fit this offers being sent
func (*MrRedisScheduler) SlaveLost ¶
func (S *MrRedisScheduler) SlaveLost(_ sched.SchedulerDriver, sid *mesos.SlaveID)
SlaveLost Not implemented
func (*MrRedisScheduler) StatusUpdate ¶
func (S *MrRedisScheduler) StatusUpdate(driver sched.SchedulerDriver, status *mesos.TaskStatus)
StatusUpdate Simply recives the update and passes it to the Maintainer goroutine