v1alpha1

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 1, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the v1alpha1 API group +kubebuilder:object:generate=true +groupName=ys.jibudata.com

Index

Constants

View Source
const (
	// common params
	LockMethod   = "lock-method"
	BackupMethod = "backup-method"

	// mysql param
	MysqlTableLock    = "table"
	MysqlInstanceLock = "instance"

	// redis param
	RedisBackupMethodByRDB = "rdb"
	RedisBackupMethodByAOF = "aof"
)
View Source
const (
	// quiesce operation
	QUIESCE = "quiesce"
	// unquiesce operation
	UNQUIESCE = "unquiesce"
)

operation type

View Source
const (
	HookCreated             = "Created"
	HookReady               = "Ready"
	HookNotReady            = "NotReady"
	HookQUIESCEINPROGRESS   = "Quiesce In Progress"
	HookQUIESCED            = "Quiesced"
	HookUNQUIESCEINPROGRESS = "Unquiesce In Progress"
	HookUNQUIESCED          = "Unquiesced"
)

phase

View Source
const (
	QuiesceFromPrimary = "QuiesceFromPrimary"
)

Params key

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "ys.jibudata.com", Version: "v1alpha1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

This section is empty.

Types

type AppHook

type AppHook struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   AppHookSpec   `json:"spec,omitempty"`
	Status AppHookStatus `json:"status,omitempty"`
}

AppHook is the Schema for the apphooks API

func (*AppHook) DeepCopy

func (in *AppHook) DeepCopy() *AppHook

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppHook.

func (*AppHook) DeepCopyInto

func (in *AppHook) DeepCopyInto(out *AppHook)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*AppHook) DeepCopyObject

func (in *AppHook) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type AppHookList

type AppHookList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []AppHook `json:"items"`
}

AppHookList contains a list of AppHook

func (*AppHookList) DeepCopy

func (in *AppHookList) DeepCopy() *AppHookList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppHookList.

func (*AppHookList) DeepCopyInto

func (in *AppHookList) DeepCopyInto(out *AppHookList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*AppHookList) DeepCopyObject

func (in *AppHookList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type AppHookSpec

type AppHookSpec struct {
	// Name is a job for backup/restore/migration
	Name string `json:"name"`
	// AppProvider is the application identifier for different vendors, such as mysql
	AppProvider string `json:"appProvider,omitempty"`
	// Endpoint to connect the applicatio service
	EndPoint string `json:"endPoint,omitempty"`
	// Databases
	Databases []string `json:"databases,omitempty"`
	// OperationType is the operation executed in application
	//+kubebuilder:validation:Enum=quiesce;unquiesce
	OperationType string `json:"operationType,omitempty"`
	// TimeoutSeconds is the timeout of operation
	//+kubebuilder:validation:Minimum=0
	//+kubebuilder:default:0
	TimeoutSeconds *int32 `json:"timeoutSeconds,omitempty"`
	// Secret to access the application
	Secret corev1.SecretReference `json:"secret,omitempty"`
	// Other options
	Params map[string]string `json:"params,omitempty"`
}

AppHookSpec defines the desired state of AppHook

func (*AppHookSpec) DeepCopy

func (in *AppHookSpec) DeepCopy() *AppHookSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppHookSpec.

func (*AppHookSpec) DeepCopyInto

func (in *AppHookSpec) DeepCopyInto(out *AppHookSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type AppHookStatus

type AppHookStatus struct {
	Phase             string           `json:"phase,omitempty"`
	ErrMsg            string           `json:"errMsg,omitempty"`
	QuiescedTimestamp *metav1.Time     `json:"quiescedTimestamp,omitempty"`
	Result            *QuiesceResult   `json:"result,omitempty"`
	PreservedConfig   *PreservedConfig `json:"preservedConfig,omitempty"`
}

AppHookStatus defines the observed state of AppHook +kubebuilder:subresource:status

func (*AppHookStatus) DeepCopy

func (in *AppHookStatus) DeepCopy() *AppHookStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppHookStatus.

func (*AppHookStatus) DeepCopyInto

func (in *AppHookStatus) DeepCopyInto(out *AppHookStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MongoResult added in v0.0.7

type MongoResult struct {
	MongoEndpoint string `json:"mongoEndpoint,omitempty"`
	IsPrimary     bool   `json:"isPrimary,omitempty"`
}

func (*MongoResult) DeepCopy added in v0.0.7

func (in *MongoResult) DeepCopy() *MongoResult

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MongoResult.

func (*MongoResult) DeepCopyInto added in v0.0.7

func (in *MongoResult) DeepCopyInto(out *MongoResult)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MysqlResult added in v0.0.7

type MysqlResult struct {
}

func (*MysqlResult) DeepCopy added in v0.0.7

func (in *MysqlResult) DeepCopy() *MysqlResult

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MysqlResult.

func (*MysqlResult) DeepCopyInto added in v0.0.7

func (in *MysqlResult) DeepCopyInto(out *MysqlResult)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PgResult added in v0.0.7

type PgResult struct {
}

func (*PgResult) DeepCopy added in v0.0.7

func (in *PgResult) DeepCopy() *PgResult

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PgResult.

func (*PgResult) DeepCopyInto added in v0.0.7

func (in *PgResult) DeepCopyInto(out *PgResult)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PreservedConfig added in v0.1.0

type PreservedConfig struct {
	Params map[string]string `json:"params,omitempty"`
}

PreservedConfig saves the origin params before change by quiesce

func (*PreservedConfig) DeepCopy added in v0.1.0

func (in *PreservedConfig) DeepCopy() *PreservedConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PreservedConfig.

func (*PreservedConfig) DeepCopyInto added in v0.1.0

func (in *PreservedConfig) DeepCopyInto(out *PreservedConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type QuiesceResult added in v0.0.7

type QuiesceResult struct {
	Mongo *MongoResult `json:"mongo,omitempty"`
	Mysql *MysqlResult `json:"mysql,omitempty"`
	Pg    *PgResult    `json:"pg,omitempty"`
	Redis *RedisResult `json:"redis,omitempty"`
}

func (*QuiesceResult) DeepCopy added in v0.0.7

func (in *QuiesceResult) DeepCopy() *QuiesceResult

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new QuiesceResult.

func (*QuiesceResult) DeepCopyInto added in v0.0.7

func (in *QuiesceResult) DeepCopyInto(out *QuiesceResult)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type RedisResult added in v0.1.0

type RedisResult struct {
}

func (*RedisResult) DeepCopy added in v0.1.0

func (in *RedisResult) DeepCopy() *RedisResult

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisResult.

func (*RedisResult) DeepCopyInto added in v0.1.0

func (in *RedisResult) DeepCopyInto(out *RedisResult)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL