当前位置: 首页>>代码示例>>Golang>>正文


Golang watch.NewBroadcaster函数代码示例

本文整理汇总了Golang中k8s/io/kubernetes/pkg/watch.NewBroadcaster函数的典型用法代码示例。如果您正苦于以下问题:Golang NewBroadcaster函数的具体用法?Golang NewBroadcaster怎么用?Golang NewBroadcaster使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了NewBroadcaster函数的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。

示例1: NewFakePVCControllerSource

func NewFakePVCControllerSource() *FakePVCControllerSource {
	return &FakePVCControllerSource{
		FakeControllerSource{
			Items:       map[nnu]runtime.Object{},
			Broadcaster: watch.NewBroadcaster(100, watch.WaitIfChannelFull),
		}}
}
开发者ID:CodeJuan,项目名称:kubernetes,代码行数:7,代码来源:fake_controller_source.go

示例2: NewBroadcaster

// Creates a new event broadcaster.
func NewBroadcaster() EventBroadcaster {
	return &eventBroadcasterImpl{watch.NewBroadcaster(maxQueuedEvents, watch.DropIfChannelFull)}
}
开发者ID:liuhewei,项目名称:kubernetes,代码行数:4,代码来源:event.go

示例3: NewBroadcasterForTests

func NewBroadcasterForTests(sleepDuration time.Duration) EventBroadcaster {
	return &eventBroadcasterImpl{watch.NewBroadcaster(maxQueuedEvents, watch.DropIfChannelFull), sleepDuration}
}
开发者ID:RyanBinfeng,项目名称:kubernetes,代码行数:3,代码来源:event.go

示例4: NewBroadcaster

// Creates a new event broadcaster.
func NewBroadcaster() EventBroadcaster {
	return &eventBroadcasterImpl{watch.NewBroadcaster(maxQueuedEvents, watch.DropIfChannelFull), defaultSleepDuration}
}
开发者ID:RyanBinfeng,项目名称:kubernetes,代码行数:4,代码来源:event.go

示例5: NewGeneric

func NewGeneric(list runtime.Object) *GenericRegistry {
	return &GenericRegistry{
		ObjectList:  list,
		Broadcaster: watch.NewBroadcaster(0, watch.WaitIfChannelFull),
	}
}
开发者ID:MarWestermann,项目名称:gofabric8,代码行数:6,代码来源:generic.go

示例6: NewPodRegistry

func NewPodRegistry(pods *api.PodList) *PodRegistry {
	return &PodRegistry{
		Pods:        pods,
		broadcaster: watch.NewBroadcaster(0, watch.WaitIfChannelFull),
	}
}
开发者ID:MarWestermann,项目名称:gofabric8,代码行数:6,代码来源:pod.go

示例7: NewFake

// NewFake makes a new fake MasterElector.
func NewFake() *Fake {
	// 0 means block for clients.
	return &Fake{mux: watch.NewBroadcaster(0, watch.WaitIfChannelFull)}
}
开发者ID:40a,项目名称:bootkube,代码行数:5,代码来源:fake.go


注:本文中的k8s/io/kubernetes/pkg/watch.NewBroadcaster函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。