Skip to content

Commit 5bb83a5

Browse files
author
Peng Zhou
committed
change persistence API
1 parent 980b110 commit 5bb83a5

File tree

8 files changed

+521
-6109
lines changed

8 files changed

+521
-6109
lines changed

api/v1alpha1/common_types.go

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,12 @@ type ContainerProbe struct {
2121
}
2222

2323
// Storage is the inteface to add pvc and pv support in marklogic
24-
type Storage struct {
25-
Size string `json:"size,omitempty"`
26-
VolumeMount VolumeMountWrapper `json:"volumeMount,omitempty"`
27-
StorageClassName string `json:"storageClassName,omitempty"`
24+
type Persistence struct {
25+
Enabled bool `json:"enabled,omitempty"`
26+
Size string `json:"size,omitempty"`
27+
StorageClassName string `json:"storageClassName,omitempty"`
28+
AccessModes []corev1.PersistentVolumeAccessMode `json:"accessModes,omitempty"`
29+
Annotations map[string]string `json:"annotations,omitempty"`
2830
}
2931

3032
type HugePages struct {

api/v1alpha1/marklogiccluster_types.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ type MarklogicClusterSpec struct {
4242
ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"`
4343

4444
Auth *AdminAuth `json:"auth,omitempty"`
45-
Storage *Storage `json:"storage,omitempty"`
45+
Persistence *Persistence `json:"persistence,omitempty"`
4646
Resources *corev1.ResourceRequirements `json:"resources,omitempty"`
4747
TerminationGracePeriodSeconds *int64 `json:"terminationGracePeriodSeconds,omitempty"`
4848
// +kubebuilder:validation:Enum=OnDelete;RollingUpdate
@@ -79,7 +79,7 @@ type MarklogicGroups struct {
7979
Image string `json:"image,omitempty"`
8080
ImagePullPolicy string `json:"imagePullPolicy,omitempty"`
8181
ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"`
82-
Storage *Storage `json:"storage,omitempty"`
82+
Persistence *Persistence `json:"persistence,omitempty"`
8383
Service Service `json:"service,omitempty"`
8484
Resources *corev1.ResourceRequirements `json:"resources,omitempty"`
8585
Affinity *corev1.Affinity `json:"affinity,omitempty"`

api/v1alpha1/marklogicgroup_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ type MarklogicGroupSpec struct {
4141
ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"`
4242

4343
Auth *AdminAuth `json:"auth,omitempty"`
44-
Storage *Storage `json:"storage,omitempty"`
44+
Persistence *Persistence `json:"persistence,omitempty"`
4545
Resources *corev1.ResourceRequirements `json:"resources,omitempty"`
4646
TerminationGracePeriodSeconds *int64 `json:"terminationGracePeriodSeconds,omitempty"`
4747
// +kubebuilder:validation:Enum=OnDelete;RollingUpdate

api/v1alpha1/zz_generated.deepcopy.go

Lines changed: 36 additions & 25 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)