HDDS-14347. Handle upgrades to support S3 lifecycle#9614
HDDS-14347. Handle upgrades to support S3 lifecycle#9614YutaLin wants to merge 6 commits intoapache:HDDS-8342from
Conversation
…cycleConfigurationSetRequest
…cycleConfigurationDeleteRequest
chungen0126
left a comment
There was a problem hiding this comment.
Thanks @YutaLin. Please add some tests for these changes. Also, HDDS-14359 might block this PR because the smoke tests require environment updates for the 2.1.0 to 2.2.0 upgrade.
|
@YutaLin Thanks for your patch. I may be missing something, but do we need to upgrade the framework for the lifecycle feature? My understanding is the lifecycle feature only adds a few DB definition and interfaces without altering the existing DB field. If we roll back after upgrading, it might leave some useless data in the DB, but it shouldn't cause data to become unreadable. |
Thanks @xichen01 for the review. You are right that we don't change existing fields, but I'm concerned about skipping the upgrade process for a couple of reasons:
I think it's safer to follow the upgrade framework here. Let me know your thoughts! |
|
Hi @chungen0126 @xichen01, thanks for the review, i've add the tests. |
What changes were proposed in this pull request?
To ensure safe upgrades and downgrades (rollback) when introducing lifecycle, we need to integrate with the OM Upgrade Framework.
Add OM Layout Feature: Introduce a new OMLayoutFeature (e.g., LIFECYCLE_SUPPORT) to manage the versioning of new lifecycle table.
Block APIs in Pre-finalized State: Reject requests to new lifecycle APIs if the OM is not yet finalized. This prevents state corruption if a rollback occurs
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-14347
How was this patch tested?
CI Pass: https://github.com/YutaLin/ozone/actions/runs/20869524864