Skip to content

squid: test/rgw/multisite: test_object_lock_sync() from secondary zones too - #71065

Draft
cbodley wants to merge 2 commits into
ceph:squidfrom
cbodley:wip-79490-squid
Draft

squid: test/rgw/multisite: test_object_lock_sync() from secondary zones too#71065
cbodley wants to merge 2 commits into
ceph:squidfrom
cbodley:wip-79490-squid

Conversation

@cbodley

@cbodley cbodley commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

backport tracker: https://tracker.ceph.com/issues/79490


backport of #71033
parent tracker: https://tracker.ceph.com/issues/68460

this backport was staged using ceph-backport.sh version 16.0.0.6848
find the latest version at https://github.com/ceph/ceph/blob/main/src/script/ceph-backport.sh

this test was only writing object lock configuration to the primary zone
and checking that it replicated to other zones

use create_bucket_per_zone_in_realm() to create a bucket for each zone
and issue put_object_lock_configuration() against that zone, so we cover
behavior on secondary zones as well

Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit 882c6aa)

Conflicts:
	src/test/rgw/rgw_multi/tests.py  ordering with lots of new tests
@cbodley
cbodley requested a review from a team as a code owner August 14, 2026 17:11
@cbodley cbodley added this to the squid milestone Aug 14, 2026
@cbodley cbodley added the rgw label Aug 14, 2026

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ceph Release Engineering Audit Report

Commit Parity Visualizer

BACKPORT PR #71065 SOURCE PR SOURCE STATUS
13939d6 test/rgw/multisite: test_object_lock_sync() from secondary zones too PR #71033 882c6aa test/rgw/multisite: test_object_lock_sync() from secondary zones too

Automated Backport Parity Review - Cherry-Pick Conflicts / Deviations

⚠️ WARNING: Cherry-pick conflicts or deviations were found that require component lead review.

A conflict or deviation was detected during the simulation of this backport. The code in this PR does not match a clean cherry-pick of the upstream commits.

This does not necessarily indicate an issue but a maintainer should review.

**Click to expand conflict summaries.**

Deviation in Backport 13939d6 (cherry-pick of 882c6aa)

Affected File(s)

Range Diff

Click to expand
--- Original (882c6aa9)
+++ Backport (13939d6e)
@@ -8,3 +8,7 @@
 behavior on secondary zones as well
 
 Signed-off-by: Casey Bodley <cbodley@redhat.com>
+(cherry picked from commit 882c6aa911279b66cd992fccdf67d0ddfbb14ec2)
+
+Conflicts:
+	src/test/rgw/rgw_multi/tests.py  ordering with lots of new tests

================================================================================
RANGE DIFF
================================================================================

1:  882c6aa9112 ! 1:  13939d6e7c0 test/rgw/multisite: test_object_lock_sync() from secondary zones too
    @@ Commit message
         behavior on secondary zones as well
     
         Signed-off-by: Casey Bodley <cbodley@redhat.com>
    +    (cherry picked from commit 882c6aa911279b66cd992fccdf67d0ddfbb14ec2)
    +
    +    Conflicts:
    +            src/test/rgw/rgw_multi/tests.py  ordering with lots of new tests
     
      ## src/test/rgw/rgw_multi/tests.py ##
    -@@ src/test/rgw/rgw_multi/tests.py: def test_copy_obj_perm_check_between_zonegroups(zonegroup):
    - 
    +@@ src/test/rgw/rgw_multi/tests.py: def test_bucket_full_sync_when_the_bucket_is_deleted_in_the_meantime():
    +         raise
      
      def test_object_lock_sync():
    +-
     -    zonegroup = realm.master_zonegroup()
     -    zonegroup_conns = ZonegroupConns(zonegroup)
     -    primary = zonegroup_conns.rw_zones[0]
    @@ src/test/rgw/rgw_multi/tests.py: def test_copy_obj_perm_check_between_zonegroups
     -    # enable versioning
     -    primary.s3_client.put_bucket_versioning(
     -        Bucket=bucket.name,
    --        VersioningConfiguration={'Status': 'Enabled'}
    --    )
    +-        VersioningConfiguration={'Status': 'Enabled'})
     -    zonegroup_meta_checkpoint(zonegroup)
     -
          lock_config = {
    -         'ObjectLockEnabled': 'Enabled',
    -         'Rule': {
    -@@ src/test/rgw/rgw_multi/tests.py: def test_object_lock_sync():
    +-    'ObjectLockEnabled': 'Enabled',
    +-    'Rule': {
    +-        'DefaultRetention': {
    +-            'Mode': 'COMPLIANCE',
    +-            'Days': 1
    ++        'ObjectLockEnabled': 'Enabled',
    ++        'Rule': {
    ++            'DefaultRetention': {
    ++                'Mode': 'COMPLIANCE',
    ++                'Days': 1
    +             }
              }
          }
      
    +-    # enable object lock on bucket
     -    primary.s3_client.put_object_lock_configuration(
     -        Bucket=bucket.name,
    --        ObjectLockConfiguration=lock_config
    --    )
    --
    --    zonegroup_meta_checkpoint(zonegroup)
    --    zone_data_checkpoint(secondary.zone, primary.zone)
    +-        ObjectLockConfiguration = lock_config)
     +    buckets, zone_bucket = create_bucket_per_zone_in_realm()
     +    for zone, bucket in zone_bucket:
     +        # enable versioning
    @@ src/test/rgw/rgw_multi/tests.py: def test_object_lock_sync():
     +            ObjectLockConfiguration=lock_config
     +        )
      
    --    response = secondary.s3_client.get_object_lock_configuration(Bucket=bucket.name)
    --    assert response['ObjectLockConfiguration'] == lock_config
    +-    zonegroup_meta_checkpoint(zonegroup)
    +-    zone_data_checkpoint(secondary.zone, primary.zone)
     +    realm_meta_checkpoint(realm)
      
    +-    response = secondary.s3_client.get_object_lock_configuration(Bucket=bucket.name)
    +-    assert(response['ObjectLockConfiguration'] == lock_config)
    + \ No newline at end of file
     +    for zone, bucket in zone_bucket:
     +        # cross-zonegroup redirects don't work, so we only test zones in the bucket's zonegroup
     +        for z in zone.zone.zonegroup.zones:
     +            conn = z.get_conn(user.credentials)
     +            response = conn.s3_client.get_object_lock_configuration(Bucket=bucket.name)
     +            assert response['ObjectLockConfiguration'] == lock_config
    - 
    - def test_period_update_commit():
    -     wkld_concurrency = 10

How to proceed:

  • Authors (Genuine Conflicts): If this is a genuine conflict requiring manual resolution, ensure your resolution is correct. You must explain the conflict resolution in the commit message (e.g., leave the standard Git Conflicts: block intact) and include an explanation for changes.
  • Authors (Need Help?): Reach out to the Component Lead for technical guidance on complex code conflicts.
  • Component Leads (Review): Please review the Range Diff(s) above to verify the author's manual conflict resolution is correct for this release branch. If the deviation is intentional, documented, and approved then the component lead or @ceph/ceph-release-manager can bypass this check by commenting /audit override.

Be familiar with the rules and guidelines for writing backports.


🛟 Need Help?

If you need technical help resolving these issues, please consult with the Component Lead. If you need administrative overrides, please see the #ceph-upstream-releases channel on Slack and request a review from the @ceph/ceph-release-manager.

📋 Component Lead / Release Manager

To override the audit failure, apply releng-audit-override label or comment /audit override.


⚠️ Note: Automated audit checks will be suspended on future pushes to prevent comment spam while you work.

When you are ready for a new audit, please remove the releng-audit-fail label or comment /audit retest.

View workflow run

@github-actions github-actions Bot added the releng-audit-fail Release engineering: failed backport verification audit. label Aug 14, 2026
@cbodley
cbodley marked this pull request as draft August 14, 2026 17:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

releng-audit-fail Release engineering: failed backport verification audit. rgw wip-cbodley-testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant