Documentation ¶
Index ¶
- Constants
- func Setup(mgr ctrl.Manager, _ controller.Args) error
- type Reconcile
- type VolumeHandler
- func (c *VolumeHandler) Create(evt event.CreateEvent, q workqueue.RateLimitingInterface)
- func (c *VolumeHandler) Delete(evt event.DeleteEvent, q workqueue.RateLimitingInterface)
- func (c *VolumeHandler) Generic(_ event.GenericEvent, _ workqueue.RateLimitingInterface)
- func (c *VolumeHandler) Update(evt event.UpdateEvent, q workqueue.RateLimitingInterface)
Constants ¶
const ( HostPath = "HostPath" StorageClass = "StorageClass" )
Reconcile error strings.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Reconcile ¶
type Reconcile struct { client.Client discovery.DiscoveryClient Scheme *runtime.Scheme // contains filtered or unexported fields }
Reconcile reconciles a VolumeTrait object
func (*Reconcile) Reconcile ¶
Reconcile to reconcile volume trait. +kubebuilder:rbac:groups=core.oam.dev,resources=volumetraits,verbs=get;list;watch +kubebuilder:rbac:groups=core.oam.dev,resources=volumetraits/status,verbs=get;update;patch +kubebuilder:rbac:groups=core.oam.dev,resources=containerizedworkloads,verbs=get;list; +kubebuilder:rbac:groups=core.oam.dev,resources=containerizedworkloads/status,verbs=get; +kubebuilder:rbac:groups=core.oam.dev,resources=workloaddefinition,verbs=get;list; +kubebuilder:rbac:groups=apps,resources=deployments,verbs=get;list;watch;update;patch;delete +kubebuilder:rbac:groups=apps,resources=statefulsets,verbs=get;list;watch;update;patch;delete +kubebuilder:rbac:groups=core,resources=services,verbs=get;list;watch;create;update;patch;delete
type VolumeHandler ¶
type VolumeHandler struct { ClientSet *kubernetes.Clientset Client client.Client AppsClient clientappv1.AppsV1Interface // contains filtered or unexported fields }
VolumeHandler will watch volume change and delete pvc automatically.
func (*VolumeHandler) Create ¶
func (c *VolumeHandler) Create(evt event.CreateEvent, q workqueue.RateLimitingInterface)
Create implements EventHandler
func (*VolumeHandler) Delete ¶
func (c *VolumeHandler) Delete(evt event.DeleteEvent, q workqueue.RateLimitingInterface)
Delete implements EventHandler
func (*VolumeHandler) Generic ¶
func (c *VolumeHandler) Generic(_ event.GenericEvent, _ workqueue.RateLimitingInterface)
Generic implements EventHandler
func (*VolumeHandler) Update ¶
func (c *VolumeHandler) Update(evt event.UpdateEvent, q workqueue.RateLimitingInterface)
Update implements EventHandler