Skip to content

feat(upgrade): add Cleanup upgrade for Helm pre-delete infrastructure teardown#16619

Open
pedro93 wants to merge 3 commits intomasterfrom
feat/cleanup-upgrade
Open

feat(upgrade): add Cleanup upgrade for Helm pre-delete infrastructure teardown#16619
pedro93 wants to merge 3 commits intomasterfrom
feat/cleanup-upgrade

Conversation

@pedro93
Copy link
Collaborator

@pedro93 pedro93 commented Mar 16, 2026

Summary

Test plan

  • ./gradlew :datahub-upgrade:compileJava passes
  • Run datahub-upgrade -u Cleanup against a local docker-compose instance and verify topics, indices, and database are removed
  • Unit tests for each step with mocked clients

… teardown

Adds a new `Cleanup` upgrade type to the datahub-upgrade module that
tears down all DataHub infrastructure resources (Elasticsearch indices,
Kafka topics, SQL database) when invoked via `-u Cleanup`.

This enables clean `helm uninstall` by running as a pre-delete hook,
leaving no DataHub-specific state in shared infrastructure.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Contributor

Linear: PFP-2984

@codecov
Copy link

codecov bot commented Mar 16, 2026

pedro93 and others added 2 commits March 19, 2026 11:14
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add DeleteElasticsearchIndicesStepTest covering ES and OpenSearch
  paths, safeDelete 404/non-404 handling, and failure propagation
- Add CleanupUpgradeConfigTest verifying step inclusion/exclusion based
  on bean availability and feature flag system properties
- Add GeneralUpgradeConditionTest covering all arg combinations
- Fix GeneralUpgradeCondition to null-guard getNonOptionArgs() for
  consistency with CleanupCondition

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@alwaysmeticulous
Copy link

alwaysmeticulous bot commented Mar 24, 2026

🔴 Meticulous spotted visual differences in 697 of 1625 screens tested: view and approve differences detected.

Meticulous evaluated ~8 hours of user flows against your PR.

Last updated for commit b5d4462. This comment will update as new commits are pushed.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant