Repository navigation
feat(common): stateful workload support - #496
Conversation
Automated chart versioning after merge of PR #496. This PR updates Chart.yaml versions, packages updated charts into docs/interledger, and regenerates the Helm index. Co-authored-by: bosbaber <1615407+bosbaber@users.noreply.github.com>
There was a problem hiding this comment.
🟡 Changes recommended
Two newly added fields (revisionHistoryLimit, terminationGracePeriodSeconds) use with and silently drop a meaningful explicit 0, contradicting the PR's own zero-preservation design, and the new PVC template lacks the unit-test coverage the common chart otherwise maintains.
3 open issues
What changed in this PR
This PR extends the shared common Helm library chart to better support stateful and batch workloads. It adds a new PersistentVolumeClaim template, surfaces pod/deployment lifecycle fields (revisionHistoryLimit, terminationGracePeriodSeconds, automountServiceAccountToken), and hardens numeric-field handling so an explicit 0 is preserved rather than collapsed to a Kubernetes default. Documentation in the chart README is expanded to cover the new fields.
Changes:
- New
common.pvctemplate rendering aPersistentVolumeClaimwith requiredname/sizevalidation and optionalaccessModes/storageClassName/volumeMode/annotations. replicaCount,backoffLimit, andttlSecondsAfterFinishednow usehasKeyso an explicit0is emitted; newrevisionHistoryLimit,terminationGracePeriodSeconds, andautomountServiceAccountTokenfields added to the pod/deployment templates.- README updated with a deployment/pod fields table and a persistent-volume-claims section.
| File | Description |
|---|---|
| charts/common/templates/_pvc.yaml | New common.pvc helper emitting a PersistentVolumeClaim with validation and optional spec fields. |
| charts/common/templates/_pod.tpl | Adds explicit automountServiceAccountToken handling and terminationGracePeriodSeconds. |
| charts/common/templates/_job.yaml | Switches backoffLimit/ttlSecondsAfterFinished to hasKey so an explicit 0 is kept; doc comment updated. |
| charts/common/templates/_deployment.yaml | Adds revisionHistoryLimit and hasKey-based replicaCount to preserve an explicit 0. |
| charts/common/README.md | Documents the new deployment/pod fields and the persistent-volume-claims helper. |
Review effort: Balanced
| {{- with $deployment.revisionHistoryLimit }} | ||
| revisionHistoryLimit: {{ . }} |
| {{- with $pod.terminationGracePeriodSeconds }} | ||
| terminationGracePeriodSeconds: {{ . }} |
| A GitOps controller needs its own equivalent, such as Argo CD's | ||
| `argocd.argoproj.io/sync-options: Prune=false,Delete=false`. | ||
| */}} | ||
| {{- define "common.pvc.tpl" -}} |


No description provided.