...
The CRD volumeClaimTemplate can be null to maintain compatibility with the released 1.1.0 and before version.
References
- [1].FLIP-225: Implement standalone mode support in the kubernetes operator - Apache Flink - Apache Software Foundation
- [2].Use StatefulSet instead of Deployment for TMs and JM · Issue #353 · GoogleCloudPlatform/flink-on-k8s-operator (github.com)
Test Plan
We can test the creation of the dynamic PVC by creating a Flink standalone cluster in a real k8s clusters, And kill one TaskManager pod and wait for it recovered and mount previous existed PVC successfully.
CR Example with name flink-standalone-pvc-statefulset and in namespace: flink-application-system
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
###check all pvcs dynamic-created by cr. kubectl get pvcs -n flink-application-system kubectl kill ###delete one taskmanager pod. kubectl delete pod {pod_name} -n flink-application-system |
Delete the CR, all created PVCs will be retained, those can be deleted manually and permanently.
...
Or using other operator like flink-on-k8s-operator to mount one-to-one PVC for each TMs.
References
- [1].FLIP-225: Implement standalone mode support in the kubernetes operator - Apache Flink - Apache Software Foundation
- [2].Use StatefulSet instead of Deployment for TMs and JM · Issue #353 · GoogleCloudPlatform/flink-on-k8s-operator (github.com)