Documentation
¶
Index ¶
- Constants
- func DirectCSIDriveTypeMeta() metav1.TypeMeta
- func DirectCSIVolumeTypeMeta() metav1.TypeMeta
- func DriveClient() typeddirectcsi.DirectCSIDriveInterface
- func FakeInit()
- func GetGroupVersion(k8sClient *k8s.Client, kind string) (version, group string, err error)
- func GetLatestDirectCSIRESTClient(k8sClient *k8s.Client) rest.Interface
- func Init()
- func SetDriveClient(clientset *legacyclientsetfake.Clientset)
- func SetVolumeClient(clientset *legacyclientsetfake.Clientset)
- func VolumeClient() typeddirectcsi.DirectCSIVolumeInterface
- type Client
- func (client Client) Discovery() discovery.DiscoveryInterface
- func (client Client) Drive() typeddirectcsi.DirectCSIDriveInterface
- func (client Client) ListDrives(ctx context.Context) <-chan ListDriveResult
- func (client Client) ListVolumes(ctx context.Context) <-chan ListVolumeResult
- func (client Client) RemoveAllDrives(ctx context.Context, backupFile string) (backupCreated bool, err error)
- func (client Client) RemoveAllVolumes(ctx context.Context, backupFile string) (backupCreated bool, err error)
- func (client Client) Volume() typeddirectcsi.DirectCSIVolumeInterface
- type DirectCSIDriveInterface
- func (d *DirectCSIDriveInterface) APIVersion() schema.GroupVersion
- func (d *DirectCSIDriveInterface) Create(ctx context.Context, directCSIDrive *directcsi.DirectCSIDrive, ...) (*directcsi.DirectCSIDrive, error)
- func (d *DirectCSIDriveInterface) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error
- func (d *DirectCSIDriveInterface) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error
- func (d *DirectCSIDriveInterface) Get(ctx context.Context, name string, opts metav1.GetOptions) (*directcsi.DirectCSIDrive, error)
- func (d *DirectCSIDriveInterface) List(ctx context.Context, opts metav1.ListOptions) (*directcsi.DirectCSIDriveList, error)
- func (d *DirectCSIDriveInterface) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, ...) (result *directcsi.DirectCSIDrive, err error)
- func (d *DirectCSIDriveInterface) Update(ctx context.Context, directCSIDrive *directcsi.DirectCSIDrive, ...) (*directcsi.DirectCSIDrive, error)
- func (d *DirectCSIDriveInterface) UpdateStatus(ctx context.Context, directCSIDrive *directcsi.DirectCSIDrive, ...) (*directcsi.DirectCSIDrive, error)
- func (d *DirectCSIDriveInterface) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error)
- type DirectCSIVolumeInterface
- func (d *DirectCSIVolumeInterface) APIVersion() schema.GroupVersion
- func (d *DirectCSIVolumeInterface) Create(ctx context.Context, directCSIVolume *directcsi.DirectCSIVolume, ...) (*directcsi.DirectCSIVolume, error)
- func (d *DirectCSIVolumeInterface) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error
- func (d *DirectCSIVolumeInterface) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error
- func (d *DirectCSIVolumeInterface) Get(ctx context.Context, name string, opts metav1.GetOptions) (*directcsi.DirectCSIVolume, error)
- func (d *DirectCSIVolumeInterface) List(ctx context.Context, opts metav1.ListOptions) (*directcsi.DirectCSIVolumeList, error)
- func (d *DirectCSIVolumeInterface) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, ...) (result *directcsi.DirectCSIVolume, err error)
- func (d *DirectCSIVolumeInterface) Update(ctx context.Context, directCSIVolume *directcsi.DirectCSIVolume, ...) (*directcsi.DirectCSIVolume, error)
- func (d *DirectCSIVolumeInterface) UpdateStatus(ctx context.Context, directCSIVolume *directcsi.DirectCSIVolume, ...) (*directcsi.DirectCSIVolume, error)
- func (d *DirectCSIVolumeInterface) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error)
- type ListDriveResult
- type ListVolumeResult
Constants ¶
const ( GroupName = "direct.csi.min.io" Identity = "direct-csi-min-io" )
DirectCSI group and identity names.
const DirectCSIVersionLabelKey = directcsi.Group + "/" + directcsi.Version
DirectCSIVersionLabelKey is the version with group and version ...
Variables ¶
This section is empty.
Functions ¶
func DirectCSIDriveTypeMeta ¶
DirectCSIDriveTypeMeta gets new direct-csi drive meta.
func DirectCSIVolumeTypeMeta ¶
DirectCSIVolumeTypeMeta gets new direct-csi volume meta.
func DriveClient ¶
func DriveClient() typeddirectcsi.DirectCSIDriveInterface
DriveClient gets latest versioned drive interface.
func GetGroupVersion ¶
GetGroupVersion probes group and version of given resource kind.
func GetLatestDirectCSIRESTClient ¶
GetLatestDirectCSIRESTClient gets REST client of the latest direct-csi.
func SetDriveClient ¶
func SetDriveClient(clientset *legacyclientsetfake.Clientset)
SetDriveClient sets drive interface from fake clientset. Note: To be used for writing test cases only
func SetVolumeClient ¶
func SetVolumeClient(clientset *legacyclientsetfake.Clientset)
SetVolumeClient sets volume interface from fake clientset. Note: To be used for writing test cases only
func VolumeClient ¶
func VolumeClient() typeddirectcsi.DirectCSIVolumeInterface
VolumeClient gets latest versioned volume interface.
Types ¶
type Client ¶
type Client struct { DriveClient typeddirectcsi.DirectCSIDriveInterface VolumeClient typeddirectcsi.DirectCSIVolumeInterface K8sClient *k8s.Client }
Client represents the legacy client
func (Client) Discovery ¶
func (client Client) Discovery() discovery.DiscoveryInterface
Discovery returns the discovery client
func (Client) Drive ¶
func (client Client) Drive() typeddirectcsi.DirectCSIDriveInterface
Drive returns the legacy drive client
func (Client) ListDrives ¶
func (client Client) ListDrives(ctx context.Context) <-chan ListDriveResult
ListDrives returns channel to loop through drive items.
func (Client) ListVolumes ¶
func (client Client) ListVolumes(ctx context.Context) <-chan ListVolumeResult
ListVolumes returns channel to loop through volume items.
func (Client) RemoveAllDrives ¶
func (client Client) RemoveAllDrives(ctx context.Context, backupFile string) (backupCreated bool, err error)
RemoveAllDrives removes legacy drive CRDs.
func (Client) RemoveAllVolumes ¶
func (client Client) RemoveAllVolumes(ctx context.Context, backupFile string) (backupCreated bool, err error)
RemoveAllVolumes removes legacy volume CRDs.
func (Client) Volume ¶
func (client Client) Volume() typeddirectcsi.DirectCSIVolumeInterface
Volume returns the volume client
type DirectCSIDriveInterface ¶
type DirectCSIDriveInterface struct {
// contains filtered or unexported fields
}
DirectCSIDriveInterface is a dynamic client interface for DirectCSIDrives
func DirectCSIDriveInterfaceForConfig ¶
func DirectCSIDriveInterfaceForConfig(k8sClient *k8s.Client) (*DirectCSIDriveInterface, error)
DirectCSIDriveInterfaceForConfig provides a dynamic client interface for DirectCSIDrives
func (*DirectCSIDriveInterface) APIVersion ¶
func (d *DirectCSIDriveInterface) APIVersion() schema.GroupVersion
APIVersion returns the APIVersion this RESTClient is expected to use.
func (*DirectCSIDriveInterface) Create ¶
func (d *DirectCSIDriveInterface) Create(ctx context.Context, directCSIDrive *directcsi.DirectCSIDrive, opts metav1.CreateOptions) (*directcsi.DirectCSIDrive, error)
Create takes the representation of a directCSIDrive and creates it. Returns the server's representation of the directCSIDrive, and an error, if there is any.
func (*DirectCSIDriveInterface) Delete ¶
func (d *DirectCSIDriveInterface) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error
Delete takes name of the resource object and deletes it. Returns an error if one occurs.
func (*DirectCSIDriveInterface) DeleteCollection ¶
func (d *DirectCSIDriveInterface) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error
DeleteCollection deletes a collection of resource objects.
func (*DirectCSIDriveInterface) Get ¶
func (d *DirectCSIDriveInterface) Get(ctx context.Context, name string, opts metav1.GetOptions) (*directcsi.DirectCSIDrive, error)
Get takes name of the directCSIDrive, and returns the corresponding directCSIDrive object, and an error if there is any.
func (*DirectCSIDriveInterface) List ¶
func (d *DirectCSIDriveInterface) List(ctx context.Context, opts metav1.ListOptions) (*directcsi.DirectCSIDriveList, error)
List takes label and field selectors, and returns the list of DirectCSIDrives that match those selectors.
func (*DirectCSIDriveInterface) Patch ¶
func (d *DirectCSIDriveInterface) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *directcsi.DirectCSIDrive, err error)
Patch applies the patch and returns the patched directCSIDrive.
func (*DirectCSIDriveInterface) Update ¶
func (d *DirectCSIDriveInterface) Update(ctx context.Context, directCSIDrive *directcsi.DirectCSIDrive, opts metav1.UpdateOptions) (*directcsi.DirectCSIDrive, error)
Update takes the representation of a directCSIDrive and updates it. Returns the server's representation of the directCSIDrive, and an error, if there is any.
func (*DirectCSIDriveInterface) UpdateStatus ¶
func (d *DirectCSIDriveInterface) UpdateStatus(ctx context.Context, directCSIDrive *directcsi.DirectCSIDrive, opts metav1.UpdateOptions) (*directcsi.DirectCSIDrive, error)
UpdateStatus was generated because the type contains a Status member. Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
type DirectCSIVolumeInterface ¶
type DirectCSIVolumeInterface struct {
// contains filtered or unexported fields
}
DirectCSIVolumeInterface is a dynamic client interface for DirectCSIVolumes
func DirectCSIVolumeInterfaceForConfig ¶
func DirectCSIVolumeInterfaceForConfig(k8sClient *k8s.Client) (*DirectCSIVolumeInterface, error)
DirectCSIVolumeInterfaceForConfig provides a dynamic client interface for DirectCSIVolumes
func (*DirectCSIVolumeInterface) APIVersion ¶
func (d *DirectCSIVolumeInterface) APIVersion() schema.GroupVersion
APIVersion returns the APIVersion this RESTClient is expected to use.
func (*DirectCSIVolumeInterface) Create ¶
func (d *DirectCSIVolumeInterface) Create(ctx context.Context, directCSIVolume *directcsi.DirectCSIVolume, opts metav1.CreateOptions) (*directcsi.DirectCSIVolume, error)
Create takes the representation of a directCSIVolume and creates it. Returns the server's representation of the directCSIVolume, and an error, if there is any.
func (*DirectCSIVolumeInterface) Delete ¶
func (d *DirectCSIVolumeInterface) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error
Delete takes name of the resource object and deletes it. Returns an error if one occurs.
func (*DirectCSIVolumeInterface) DeleteCollection ¶
func (d *DirectCSIVolumeInterface) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error
DeleteCollection deletes a collection of resource objects.
func (*DirectCSIVolumeInterface) Get ¶
func (d *DirectCSIVolumeInterface) Get(ctx context.Context, name string, opts metav1.GetOptions) (*directcsi.DirectCSIVolume, error)
Get takes name of the directCSIVolume, and returns the corresponding directCSIVolume object, and an error if there is any.
func (*DirectCSIVolumeInterface) List ¶
func (d *DirectCSIVolumeInterface) List(ctx context.Context, opts metav1.ListOptions) (*directcsi.DirectCSIVolumeList, error)
List takes label and field selectors, and returns the list of DirectCSIVolumes that match those selectors.
func (*DirectCSIVolumeInterface) Patch ¶
func (d *DirectCSIVolumeInterface) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *directcsi.DirectCSIVolume, err error)
Patch applies the patch and returns the patched directCSIVolume.
func (*DirectCSIVolumeInterface) Update ¶
func (d *DirectCSIVolumeInterface) Update(ctx context.Context, directCSIVolume *directcsi.DirectCSIVolume, opts metav1.UpdateOptions) (*directcsi.DirectCSIVolume, error)
Update takes the representation of a directCSIVolume and updates it. Returns the server's representation of the directCSIVolume, and an error, if there is any.
func (*DirectCSIVolumeInterface) UpdateStatus ¶
func (d *DirectCSIVolumeInterface) UpdateStatus(ctx context.Context, directCSIVolume *directcsi.DirectCSIVolume, opts metav1.UpdateOptions) (*directcsi.DirectCSIVolume, error)
UpdateStatus was generated because the type contains a Status member. Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
type ListDriveResult ¶
type ListDriveResult struct { Drive directv1beta5.DirectCSIDrive Err error }
ListDriveResult denotes list of drive result.
type ListVolumeResult ¶
type ListVolumeResult struct { Volume directv1beta5.DirectCSIVolume Err error }
ListVolumeResult denotes list of volume result.