Documentation ¶
Index ¶
- func GetPatchData(oldObj, newObj interface{}) ([]byte, error)
- type CSPCPatch
- type CSPCPatchOptions
- type CSPIPatch
- type CSPIPatchOptions
- type CStorVolumePatch
- type CStorVolumePatchOptions
- type CVRPatch
- type CVRPatchOptions
- type Client
- type ResourcePatch
- type ResourcePatchOptions
- func FromVersion(from string) ResourcePatchOptions
- func ToVersion(to string) ResourcePatchOptions
- func WithBaseURL(url string) ResourcePatchOptions
- func WithImageTag(imagetag string) ResourcePatchOptions
- func WithName(name string) ResourcePatchOptions
- func WithOpenebsNamespace(namespace string) ResourcePatchOptions
- type Upgrade
- type UpgradeOptions
- type Upgrader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetPatchData ¶
GetPatchData returns patch data by marshalling and taking diff of two objects
Types ¶
type CSPCPatch ¶
type CSPCPatch struct { *ResourcePatch Namespace string CSPC *patch.CSPC *Client }
CSPCPatch is the patch required to upgrade CSPC
type CSPCPatchOptions ¶
type CSPCPatchOptions func(*CSPCPatch)
CSPCPatchOptions ...
func WithCSPCResorcePatch ¶
func WithCSPCResorcePatch(r *ResourcePatch) CSPCPatchOptions
WithCSPCResorcePatch ...
type CSPIPatch ¶
type CSPIPatch struct { *ResourcePatch Namespace string Deploy *patch.Deployment CSPI *patch.CSPI Utask *v1Alpha1API.UpgradeTask *Client }
CSPIPatch is the patch required to upgrade cspi
func (*CSPIPatch) DeployUpgrade ¶
DeployUpgrade ...
type CSPIPatchOptions ¶
type CSPIPatchOptions func(*CSPIPatch)
CSPIPatchOptions ...
func WithCSPIResorcePatch ¶
func WithCSPIResorcePatch(r *ResourcePatch) CSPIPatchOptions
WithCSPIResorcePatch ...
type CStorVolumePatch ¶
type CStorVolumePatch struct { *ResourcePatch Namespace string CVC *patch.CVC CV *patch.CV Deploy *patch.Deployment Service *patch.Service Utask *v1Alpha1API.UpgradeTask *Client }
CStorVolumePatch is the patch required to upgrade CStorVolume
func NewCStorVolumePatch ¶
func NewCStorVolumePatch(opts ...CStorVolumePatchOptions) *CStorVolumePatch
NewCStorVolumePatch ...
func (*CStorVolumePatch) CStorVolumeUpgrade ¶
func (obj *CStorVolumePatch) CStorVolumeUpgrade() (string, error)
CStorVolumeUpgrade ...
func (*CStorVolumePatch) Init ¶
func (obj *CStorVolumePatch) Init() (string, error)
Init initializes all the fields of the CStorVolumePatch
func (*CStorVolumePatch) PreUpgrade ¶
func (obj *CStorVolumePatch) PreUpgrade() (string, error)
PreUpgrade ...
func (*CStorVolumePatch) Upgrade ¶
func (obj *CStorVolumePatch) Upgrade() error
Upgrade execute the steps to upgrade CStorVolume
type CStorVolumePatchOptions ¶
type CStorVolumePatchOptions func(*CStorVolumePatch)
CStorVolumePatchOptions ...
func WithCStorVolumeClient ¶
func WithCStorVolumeClient(c *Client) CStorVolumePatchOptions
WithCStorVolumeClient ...
func WithCStorVolumeResorcePatch ¶
func WithCStorVolumeResorcePatch(r *ResourcePatch) CStorVolumePatchOptions
WithCStorVolumeResorcePatch ...
type CVRPatch ¶
type CVRPatch struct { *ResourcePatch Namespace string CVR *patch.CVR *Client }
CVRPatch is the patch required to upgrade cvr
type CVRPatchOptions ¶
type CVRPatchOptions func(*CVRPatch)
CVRPatchOptions ...
func WithCVRResorcePatch ¶
func WithCVRResorcePatch(r *ResourcePatch) CVRPatchOptions
WithCVRResorcePatch ...
type Client ¶
type Client struct { // kubeclientset is a standard kubernetes clientset KubeClientset kubernetes.Interface // openebsclientset is a openebs custom resource package generated for custom API group. OpenebsClientset openebsclientset.Interface }
Client ...
type ResourcePatch ¶
type ResourcePatch struct { Name string OpenebsNamespace string From, To string ImageTag, BaseURL string }
ResourcePatch has all the patches required to upgrade a resource
func NewResourcePatch ¶
func NewResourcePatch(opts ...ResourcePatchOptions) *ResourcePatch
NewResourcePatch returns a new instance of ResourcePatch
type ResourcePatchOptions ¶
type ResourcePatchOptions func(*ResourcePatch)
ResourcePatchOptions ...
func WithOpenebsNamespace ¶
func WithOpenebsNamespace(namespace string) ResourcePatchOptions
WithOpenebsNamespace ...
type Upgrader ¶
type Upgrader interface {
Upgrade() error
}
Upgrader abstracts the upgrade of a resource
func RegisterCstorPoolCluster ¶
func RegisterCstorPoolCluster(r *ResourcePatch, c *Client) Upgrader
RegisterCstorPoolCluster ...
func RegisterCstorPoolInstance ¶
func RegisterCstorPoolInstance(r *ResourcePatch, c *Client) Upgrader
RegisterCstorPoolInstance ....
func RegisterCstorVolume ¶
func RegisterCstorVolume(r *ResourcePatch, c *Client) Upgrader
RegisterCstorVolume ....