Skip to content

TASK: Preserve PostgreSQL PVC labels across chart upgrades #217

Closed
digital-bank-java/infra-sit
#32

Description

@ramioooz

Objective

Prevent Helm chart version changes from modifying immutable PostgreSQL StatefulSet volumeClaimTemplates fields during local SIT upgrades.

Root Cause

The merged infra-sit#31 chart bumped the PostgreSQL chart version from 0.1.0 to 0.2.0. The shared labels helper includes helm.sh/chart, and that label is rendered inside the immutable PVC template. Helm 4 server-side apply therefore rejected the upgrade before the database reconciliation Job ran.

Scope

  • Keep the existing PVC template label value stable while allowing chart metadata to evolve.
  • Preserve the existing StatefulSet, PVC, and data; do not use helm --force or delete storage.
  • Add a rendered-chart regression check for the stable PVC label.
  • Document the upgrade-safe behavior.

Dependencies

  • Parent: .github#214
  • Related merged implementation: infra-sit#31

Acceptance Criteria

  • PostgreSQL Helm upgrade renders the current immutable PVC template labels unchanged.
  • Chart version changes do not alter the PVC template label.
  • Helm lint, rendering, and Kubernetes client-side dry-run pass.
  • The next SIT upgrade runs the database reconciliation Job without replacing the StatefulSet or PVC.

This is a local SIT chart hardening task; AWS database infrastructure remains deferred to Sprint 7.

Activity

  1. self-assigned this
    on Sep 4, 2026
  2. added theissue type on Sep 4, 2026
  3. ramioooz commented on Sep 4, 2026

    @ramioooz
    MemberAuthor

    Implementation PR: digital-bank-java/infra-sit#32

    The PostgreSQL rollout failure was traced to the chart-version label being rendered inside the immutable StatefulSet volumeClaimTemplates. The repair preserves the existing postgres-0.1.0 PVC-template label, adds a CI stability assertion, and documents the current database inventory.

    PR #32 is ready for review. Merge order: infra-sit#31 is already merged; merge #32, then retry the PostgreSQL Helm upgrade. No deliberate delay is required beyond CI completion and branch visibility. No PVCs or data are deleted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions