]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
rgw/sal: list_buckets() returns RGWBucketEnts
authorCasey Bodley <cbodley@redhat.com>
Tue, 21 Mar 2023 17:36:56 +0000 (13:36 -0400)
committerCasey Bodley <cbodley@redhat.com>
Fri, 22 Sep 2023 16:49:07 +0000 (12:49 -0400)
commit50836121a60f7b64dbd41aaceae134588d067701
treea7d6e8c9dc769e15d0f1a365babdd67546c4df50
parentb75cc5c10e5ee6f77a3ec2e78365497e9f8025a0
rgw/sal: list_buckets() returns RGWBucketEnts

`sal::User::list_buckets()` no longer returns a map of `sal::Bucket`
handles. it now uses `std::span<RGWBucketEnt>` for input and output.
`RGWBucketEnt` contains all of the information we need to satisfy
ListBuckets requests, and also stores the `rgw_bucket` key for use with
`Driver::get_bucket()` where a `sal::Bucket` handle is necessary

`sal::BucketList` contains the span of results and the `next_marker`.
the `is_truncated` flag was removed in favor of `!next_marker.empty()`

the checks for `user->get_max_buckets()` on bucket creation now use a
paginated `check_user_max_buckets()` helper function that limits the
number of allocated entries to `rgw_list_buckets_max_chunk`

Signed-off-by: Casey Bodley <cbodley@redhat.com>
16 files changed:
src/rgw/driver/posix/rgw_sal_posix.cc
src/rgw/driver/rados/rgw_bucket.cc
src/rgw/driver/rados/rgw_sal_rados.cc
src/rgw/driver/rados/rgw_user.cc
src/rgw/rgw_file_int.h
src/rgw/rgw_op.cc
src/rgw/rgw_op.h
src/rgw/rgw_rest_s3.cc
src/rgw/rgw_rest_s3.h
src/rgw/rgw_rest_swift.cc
src/rgw/rgw_rest_swift.h
src/rgw/rgw_sal.h
src/rgw/rgw_sal_dbstore.cc
src/rgw/rgw_sal_filter.cc
src/rgw/rgw_user.cc
src/test/rgw/test_rgw_lua.cc