Skip to content

rgw: log_meta only for more than one zone - #15777

Merged
yuriw merged 4 commits into
ceph:masterfrom
oritwas:wip-rgw-no-log-meta
Jul 6, 2017
Merged

yuriw merged 4 commits into
ceph:masterfrom
oritwas:wip-rgw-no-log-meta

Conversation

@oritwas

@oritwas oritwas commented Jun 20, 2017

Copy link
Copy Markdown
Member

Comment thread src/rgw/rgw_rados.cc Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

i worry that this would cause problems for default configurations that are later extended with more zones (that's possible to do since #10477). ideally this check would be based on num_zonegroups == 1 && num_zones == 1, but that's tricky to do in a RGWZoneGroup member function during a zone[group] modify command

maybe it would be better to take the approach from #15613, and add logic to RGWRados::need_to_log_metadata() that could inspect the current_period to count zonegroups/zones?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

@cbodley ,another possibility is to check that the current period is empty (default zg and zone don't have a period or realm).
I will also update need_to_log_metadata.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Also post_process_params is called when updating placement group, I think we should update log_meta only if the zone was set to master and not touch it in other cases

@oritwas
oritwas force-pushed the wip-rgw-no-log-meta branch from 235a3da to ff16288 Compare June 21, 2017 09:43
@oritwas oritwas changed the title rgw: do not set log meta for default zone rgw: log_meta only for more than one zone Jun 21, 2017
@oritwas
oritwas force-pushed the wip-rgw-no-log-meta branch from ff16288 to 6bcd4c7 Compare June 21, 2017 11:23
Comment thread src/rgw/rgw_rados.h Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

we still want this to return true in a configuration that has two zonegroups, each with one zone. the secondary zonegroup would still sync metadata from the meta master

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

right , I will remove log_meta and fix this

@oritwas
oritwas force-pushed the wip-rgw-no-log-meta branch from 6bcd4c7 to ac8b007 Compare June 22, 2017 12:46

@cbodley cbodley left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

added a suggestion to simplify is_multi_zonegroups_with_zones(), but i'm happy with the pr as is 👍

Comment thread src/rgw/rgw_rados.h
}
}
return false;
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

what do you think about making a get_num_zones() that just counts the zones from all zonegroups? then you wouldn't need to split single-zonegroup and multi-zonegroup cases

need_to_log_metadata() could use get_num_zones() > 1 and is_syncing_bucket_meta() could use get_num_zones() == 1

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

+1

@yuriw
yuriw merged commit 5bbc50a into ceph:master Jul 6, 2017
cbodley added a commit that referenced this pull request Sep 2, 2026
the `RGWZone::log_meta` field has been ignored since 2017 after #15777

to avoid confusion, remove it from the json output of radosgw-admin
commands like 'zonegroup get' and 'period get'

Fixes: https://tracker.ceph.com/issues/79577

Signed-off-by: Casey Bodley <[email protected]>
kabicin pushed a commit to kabicin/ceph that referenced this pull request Sep 29, 2026
the `RGWZone::log_meta` field has been ignored since 2017 after ceph#15777

to avoid confusion, remove it from the json output of radosgw-admin
commands like 'zonegroup get' and 'period get'

Fixes: https://tracker.ceph.com/issues/79577

Signed-off-by: Casey Bodley <[email protected]>
dparmar18 pushed a commit to dparmar18/ceph that referenced this pull request Oct 5, 2026
the `RGWZone::log_meta` field has been ignored since 2017 after ceph#15777

to avoid confusion, remove it from the json output of radosgw-admin
commands like 'zonegroup get' and 'period get'

Fixes: https://tracker.ceph.com/issues/79577

Signed-off-by: Casey Bodley <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants