Documentation
¶
Index ¶
- func Dequeue(s cache.Store, w workqueue.RateLimitingInterface, dispatch ControllerDispatch) bool
- func Get() (*kubernetes.Clientset, error)
- func GetFromFlags(master string, kubeconfig string) (*kubernetes.Clientset, error)
- func GetRESTClient() (*rest.RESTClient, error)
- func GetRESTClientFromFlags(master string, kubeconfig string) (*rest.RESTClient, error)
- func HandlePanic()
- func NewListWatchFromClient(c cache.Getter, resource string, namespace string, ...) *cache.ListWatch
- func NewResourceEventHandlerFuncsForWorkqueue(queue workqueue.RateLimitingInterface) cache.ResourceEventHandlerFuncs
- type Controller
- type ControllerDispatch
- type ControllerFunc
- type KubevirtClient
- type MockKubevirtClient
- type MockVMInterface
- func (_m *MockVMInterface) Create(_param0 *v11.VM) (*v11.VM, error)
- func (_m *MockVMInterface) Delete(name string, options *v1.DeleteOptions) error
- func (_m *MockVMInterface) EXPECT() *_MockVMInterfaceRecorder
- func (_m *MockVMInterface) Get(name string, options v10.GetOptions) (*v11.VM, bool, error)
- func (_m *MockVMInterface) List(opts v1.ListOptions) (*v11.VMList, error)
- func (_m *MockVMInterface) Update(_param0 *v11.VM) (*v11.VM, error)
- type VMInterface
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Dequeue ¶
func Dequeue(s cache.Store, w workqueue.RateLimitingInterface, dispatch ControllerDispatch) bool
func GetFromFlags ¶
func GetFromFlags(master string, kubeconfig string) (*kubernetes.Clientset, error)
func GetRESTClient ¶
func GetRESTClient() (*rest.RESTClient, error)
func GetRESTClientFromFlags ¶
func GetRESTClientFromFlags(master string, kubeconfig string) (*rest.RESTClient, error)
func HandlePanic ¶
func HandlePanic()
func NewListWatchFromClient ¶
func NewListWatchFromClient(c cache.Getter, resource string, namespace string, fieldSelector fields.Selector, labelSelector labels.Selector) *cache.ListWatch
NewListWatchFromClient creates a new ListWatch from the specified client, resource, namespace and field selector.
func NewResourceEventHandlerFuncsForWorkqueue ¶
func NewResourceEventHandlerFuncsForWorkqueue(queue workqueue.RateLimitingInterface) cache.ResourceEventHandlerFuncs
Types ¶
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
func NewController ¶
func NewController(lw cache.ListerWatcher, queue workqueue.RateLimitingInterface, objType runtime.Object, dispatch ControllerDispatch) (cache.Store, *Controller)
func NewControllerFromInformer ¶
func NewControllerFromInformer(indexer cache.Store, informer cache.ControllerInterface, queue workqueue.RateLimitingInterface, dispatch ControllerDispatch) (cache.Store, *Controller)
func (*Controller) ShutDownQueue ¶
func (c *Controller) ShutDownQueue()
Shut down the embedded queue. After the shutdown was issued, all items already in the queue will be processed but no new items will be accepted. It is possible to wait via #WaitUntilDone() until the last item was processed.
func (*Controller) StartInformer ¶
func (c *Controller) StartInformer(stopCh chan struct{})
func (*Controller) WaitForSync ¶
func (c *Controller) WaitForSync(stopCh chan struct{})
func (*Controller) WaitUntilDone ¶
func (c *Controller) WaitUntilDone()
type ControllerDispatch ¶
type ControllerDispatch interface {
Execute(cache.Store, workqueue.RateLimitingInterface, interface{})
}
type ControllerFunc ¶
type ControllerFunc func(cache.Store, workqueue.RateLimitingInterface, interface{})
type KubevirtClient ¶
type KubevirtClient interface {
VM(namespace string) VMInterface
}
func GetKubevirtClient ¶
func GetKubevirtClient() (KubevirtClient, error)
func GetKubevirtClientFromFlags ¶
func GetKubevirtClientFromFlags(master string, kubeconfig string) (KubevirtClient, error)
type MockKubevirtClient ¶
type MockKubevirtClient struct {
// contains filtered or unexported fields
}
Mock of KubevirtClient interface
func NewMockKubevirtClient ¶
func NewMockKubevirtClient(ctrl *gomock.Controller) *MockKubevirtClient
type MockVMInterface ¶
type MockVMInterface struct {
// contains filtered or unexported fields
}
Mock of VMInterface interface
func NewMockVMInterface ¶
func NewMockVMInterface(ctrl *gomock.Controller) *MockVMInterface
func (*MockVMInterface) Create ¶
func (_m *MockVMInterface) Create(_param0 *v11.VM) (*v11.VM, error)
func (*MockVMInterface) Delete ¶
func (_m *MockVMInterface) Delete(name string, options *v1.DeleteOptions) error
func (*MockVMInterface) Get ¶
func (_m *MockVMInterface) Get(name string, options v10.GetOptions) (*v11.VM, bool, error)
type VMInterface ¶
type VMInterface interface {
Get(name string, options k8smetav1.GetOptions) (*v1.VM, bool, error)
List(opts k8sv1.ListOptions) (*v1.VMList, error)
Create(*v1.VM) (*v1.VM, error)
Update(*v1.VM) (*v1.VM, error)
Delete(name string, options *k8sv1.DeleteOptions) error
}
Click to show internal directories.
Click to hide internal directories.