You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: operator/CHANGELOG.md
+4Lines changed: 4 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,6 +15,10 @@ We structure this changelog in accordance with [Keep a Changelog](https://keepac
15
15
- Fixed syncPodTemplate not syncing env var removals when the desired env slice was a prefix of the current, causing rollout loops on config changes such as clearing `authNSecretName`.
16
16
- Invalidate the AIStore API client on authentication failure, not just on failure to acquire initial token.
17
17
- Mount path size is now optional to better support hostPath data mounts.
18
+
- On cluster decommission, data PVCs are now deleted whenever `cleanupMetadata` is enabled, regardless of `cleanupData`.
19
+
- Clarifies the purpose of `cleanupData` as an API option to AIS for cleaning data on disk.
20
+
- Use node selectors for host path cleanup jobs rather than querying existing pods by label.
21
+
- Validate CRD only allows `cleanupData` if `cleanupMetadata` is enabled.
Copy file name to clipboardExpand all lines: operator/api/v1beta1/aistore_types.go
+12-5Lines changed: 12 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -301,6 +301,7 @@ type CertIssuerRef struct {
301
301
// AIStoreSpec defines the desired state of AIStore
302
302
// +kubebuilder:validation:XValidation:rule="(has(self.targetSpec.size) && has(self.proxySpec.size)) || has(self.size)",message="Invalid cluster size, it is either not specified or value is not valid"
303
303
// +kubebuilder:validation:XValidation:rule="[has(self.tls), has(self.tlsCertificate), has(self.tlsCertManagerIssuerName), has(self.tlsSecretName)].filter(x, x).size() <= 1",message="specify only one TLS option: tls, tlsCertificate, tlsCertManagerIssuerName, or tlsSecretName"
304
+
// +kubebuilder:validation:XValidation:rule="!has(self.cleanupData) || !self.cleanupData || (has(self.cleanupMetadata) && self.cleanupMetadata)",message="cleanupData requires cleanupMetadata to be enabled"
304
305
typeAIStoreSpecstruct {
305
306
// Size of the cluster i.e. number of proxies and number of targets.
306
307
// This can be changed by specifying size in either `proxySpec` or `targetSpec`.
// CleanupMetadata determines whether to clean up cluster and bucket metadata when the cluster is decommissioned.
366
-
// When enabled, the cluster will fully decommission, removing metadata and optionally deleting user data.
367
+
// When enabled, the cluster will fully decommission, removing metadata and optionally deleting user data according to the CleanupData option.
367
368
// When disabled, the operator will call the AIS shutdown API to preserve metadata before deleting other k8s resources.
368
-
// The metadata stored in the state PVCs will be preserved to be usable in a future AIS deployment.
369
+
// State cleanup:
370
+
// - All state PVCs will be deleted and cleaned up according to the storage class
371
+
// - Any state host paths will be cleaned with operator-managed jobs
372
+
// Data cleanup:
373
+
// - Data PVCs will be deleted but data on disk will remain unless specified by CleanupData
374
+
// - The reclamation behavior for PVs bound to the PVCs depends on the PVC's reclaim policy, or, if the PV was dynamically provisioned, on the reclaim policy of the associated StorageClass.
Copy file name to clipboardExpand all lines: operator/config/base/crd/ais.nvidia.com_aistores.yaml
+14-5Lines changed: 14 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -1374,16 +1374,22 @@ spec:
1374
1374
type: string
1375
1375
cleanupData:
1376
1376
description: |-
1377
-
CleanupData determines whether to clean up PVCs and user data (including buckets and objects) when the cluster is decommissioned.
1378
-
The reclamation of PVs linked to the PVCs depends on the PV reclaim policy or the default policy of the associated StorageClass.
1379
-
This field is relevant only if you are deleting the CR (leading to decommissioning of the cluster).
1377
+
CleanupData determines whether to clean up user data (including buckets and objects) when the cluster is decommissioned.
1378
+
This field is relevant only if CleanupMetadata is true when deleting the AIStore CR (leading to decommissioning of the cluster).
1379
+
If this option is enabled, AIStore itself will delete user data on cluster decommission.
1380
+
If not enabled, user data cleanup will be left to the PV reclaim policy.
1380
1381
type: boolean
1381
1382
cleanupMetadata:
1382
1383
description: |-
1383
1384
CleanupMetadata determines whether to clean up cluster and bucket metadata when the cluster is decommissioned.
1384
-
When enabled, the cluster will fully decommission, removing metadata and optionally deleting user data.
1385
+
When enabled, the cluster will fully decommission, removing metadata and optionally deleting user data according to the CleanupData option.
1385
1386
When disabled, the operator will call the AIS shutdown API to preserve metadata before deleting other k8s resources.
1386
-
The metadata stored in the state PVCs will be preserved to be usable in a future AIS deployment.
1387
+
State cleanup:
1388
+
- All state PVCs will be deleted and cleaned up according to the storage class
1389
+
- Any state host paths will be cleaned with operator-managed jobs
1390
+
Data cleanup:
1391
+
- Data PVCs will be deleted but data on disk will remain unless specified by CleanupData
1392
+
- The reclamation behavior for PVs bound to the PVCs depends on the PVC's reclaim policy, or, if the PV was dynamically provisioned, on the reclaim policy of the associated StorageClass.
1387
1393
type: boolean
1388
1394
clusterDomain:
1389
1395
description: 'Defines the cluster domain name for DNS. Default: cluster.local.'
Copy file name to clipboardExpand all lines: operator/helm/ais-operator/templates/aistore-crd.yaml
+14-5Lines changed: 14 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -1376,16 +1376,22 @@ spec:
1376
1376
type: string
1377
1377
cleanupData:
1378
1378
description: |-
1379
-
CleanupData determines whether to clean up PVCs and user data (including buckets and objects) when the cluster is decommissioned.
1380
-
The reclamation of PVs linked to the PVCs depends on the PV reclaim policy or the default policy of the associated StorageClass.
1381
-
This field is relevant only if you are deleting the CR (leading to decommissioning of the cluster).
1379
+
CleanupData determines whether to clean up user data (including buckets and objects) when the cluster is decommissioned.
1380
+
This field is relevant only if CleanupMetadata is true when deleting the AIStore CR (leading to decommissioning of the cluster).
1381
+
If this option is enabled, AIStore itself will delete user data on cluster decommission.
1382
+
If not enabled, user data cleanup will be left to the PV reclaim policy.
1382
1383
type: boolean
1383
1384
cleanupMetadata:
1384
1385
description: |-
1385
1386
CleanupMetadata determines whether to clean up cluster and bucket metadata when the cluster is decommissioned.
1386
-
When enabled, the cluster will fully decommission, removing metadata and optionally deleting user data.
1387
+
When enabled, the cluster will fully decommission, removing metadata and optionally deleting user data according to the CleanupData option.
1387
1388
When disabled, the operator will call the AIS shutdown API to preserve metadata before deleting other k8s resources.
1388
-
The metadata stored in the state PVCs will be preserved to be usable in a future AIS deployment.
1389
+
State cleanup:
1390
+
- All state PVCs will be deleted and cleaned up according to the storage class
1391
+
- Any state host paths will be cleaned with operator-managed jobs
1392
+
Data cleanup:
1393
+
- Data PVCs will be deleted but data on disk will remain unless specified by CleanupData
1394
+
- The reclamation behavior for PVs bound to the PVCs depends on the PVC's reclaim policy, or, if the PV was dynamically provisioned, on the reclaim policy of the associated StorageClass.
1389
1395
type: boolean
1390
1396
clusterDomain:
1391
1397
description: 'Defines the cluster domain name for DNS. Default: cluster.local.'
0 commit comments