]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
rgw: ordered list map efficiency
authorJ. Eric Ivancich <ivancich@redhat.com>
Thu, 23 Jul 2020 20:54:14 +0000 (16:54 -0400)
committerJ. Eric Ivancich <ivancich@redhat.com>
Wed, 7 Apr 2021 17:31:50 +0000 (13:31 -0400)
commit0cfb4a51eff22cce1d8b4e8351101a2edf18dba9
tree06898da6b3935c1c551906ca7f76215afc6b142f
parent116ef52566c5fb8f7621439218fb492595e2d85a
rgw: ordered list map efficiency

Adding an object to the result map required two "find" operations
back-to-back, each of which was O(log n). By using
std::map::insert_or_assign function and getting an iterator, we can
avoid the second find.

Signed-off-by: J. Eric Ivancich <ivancich@redhat.com>
src/rgw/rgw_rados.cc