Skip to content

Bug fixed for ceph RGW diff fix - #248

Open
sarwottamdev wants to merge 1 commit into
clyso:mainfrom
sarwottamdev:bug-diff-fix-ceph-RGW
Open

Bug fixed for ceph RGW diff fix#248
sarwottamdev wants to merge 1 commit into
clyso:mainfrom
sarwottamdev:bug-diff-fix-ceph-RGW

Conversation

@sarwottamdev

Copy link
Copy Markdown

Diff Fix for Ceph RGW

Description

This PR addresses issues identified during diff migrations against Ceph RGW and fixes cases where valid copy operations were not executed.

1. Object Key Normalization Fix

Updated the normalizeOutputName and normalizeInputName functions to stop prepending a leading / to object keys.

Previously, object keys for non-MinIO providers (such as Ceph RGW) were normalized with a leading slash, causing S3 operations including:

  • StatObject
  • GetObject
  • PutObject

to fail with errors such as:

object missing in source

Object keys are now preserved as-is, ensuring compatibility with Ceph RGW object lookups.

2. Diff Pipeline Fix

File: service/worker/handler/diff_handlers.go

Changes:

  • Removed the len(objectsToRemove) == 0 early return from EnsureObjectsDeleted()
  • Ensured diff-fix copy tasks are always enqueued, even when there are no objects to delete
  • Added fixCopySetStore.Drop() to clean up stale Redis state before creating new diff-fix copy tasks

This prevents scenarios where the diff-fix workflow exits prematurely and skips required copy operations.

3. Diff Fix Copy Version Check Bypass

File: service/worker/handler/migration_obj_copy_handler.go

Added an isDiffFix check to bypass the version validation below for diff-fix copy tasks:

fromVer != 0 && fromVer <= toVer

This prevents valid diff-fix copy operations from being skipped due to version comparison logic that is intended for normal migration workflows rather than repair or reconciliation tasks.

Checklist

  • I have read the CONTRIBUTING.md file.
  • My commits include a Signed-off-by line to certify agreement with the pdated documentation in README.md if applicable.

Note: By submitting this PR, you agree to license your contributions under the Apache 2.0 License _CONDUCT.md.

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