]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
ReplicatedPG: replace map iterators with SharedPtrRegistry::get_next
authorLoic Dachary <loic@dachary.org>
Tue, 13 Aug 2013 14:40:06 +0000 (16:40 +0200)
committerLoic Dachary <loic@dachary.org>
Thu, 22 Aug 2013 00:10:59 +0000 (02:10 +0200)
commit833a225008115ef87884791dafa3797dbae9f9fd
treed8e57b557f599d07f8692813a40068926f9e3176
parent8c745944c9984414a3787c044ebd62c6efbd9e30
ReplicatedPG: replace map iterators with SharedPtrRegistry::get_next

SharedPtrRegistry does not provide an iterator equivalent to

    map<hobject_t, ObjectContext*>::iterator i

It is replaced with a thread safe get_next method roughly used
as follows:

    pair<hobject_t, ObjectContextRef> i;
    while (object_contexts.get_next(i.first, &i))

All occurences of the iterator are replaced with get_next style
traversal.

http://tracker.ceph.com/issues/5510 refs #5510

Signed-off-by: Loic Dachary <loic@dachary.org>
src/osd/ReplicatedPG.cc