代码拉取完成,页面将自动刷新
package scheduler
import (
"github.com/gogo/protobuf/proto"
mesos "github.com/mesos/mesos-go/mesosproto"
"github.com/mesos/mesos-go/upid"
"golang.org/x/net/context"
)
type TestDriver struct {
*MesosSchedulerDriver
}
func (t *TestDriver) SetConnected(b bool) {
t.eventLock.Lock()
defer t.eventLock.Unlock()
t.connected = b
}
func (t *TestDriver) Started() <-chan struct{} {
return t.started
}
func (t *TestDriver) Stopped() <-chan struct{} {
return t.stopCh
}
func (t *TestDriver) Done() <-chan struct{} {
return t.done
}
func (t *TestDriver) Framework() *mesos.FrameworkInfo {
return t.frameworkInfo
}
func (t *TestDriver) UPID() *upid.UPID {
return t.self
}
func (t *TestDriver) MasterPID() *upid.UPID {
return t.masterPid
}
func (t *TestDriver) Fatal(ctx context.Context, msg string) {
t.eventLock.Lock()
defer t.eventLock.Unlock()
t.fatal(ctx, msg)
}
func (t *TestDriver) OnDispatch(f func(ctx context.Context, upid *upid.UPID, msg proto.Message) error) {
t.dispatch = f
}
func (t *TestDriver) HandleMasterChanged(ctx context.Context, from *upid.UPID, msg proto.Message) {
t.eventLock.Lock()
defer t.eventLock.Unlock()
t.handleMasterChanged(ctx, from, msg)
}
func (t *TestDriver) CacheOffer(offer *mesos.Offer, pid *upid.UPID) {
t.cache.putOffer(offer, pid)
}
func (t *TestDriver) Context() context.Context {
return t.context()
}
func (t *TestDriver) FrameworkRegistered(ctx context.Context, from *upid.UPID, msg proto.Message) {
t.eventLock.Lock()
defer t.eventLock.Unlock()
t.frameworkRegistered(ctx, from, msg)
}
func (t *TestDriver) FrameworkReregistered(ctx context.Context, from *upid.UPID, msg proto.Message) {
t.eventLock.Lock()
defer t.eventLock.Unlock()
t.frameworkReregistered(ctx, from, msg)
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。