]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
osd/ReplicatedPG: fix promotion recency logic
authorSage Weil <sage@redhat.com>
Wed, 25 Nov 2015 19:39:08 +0000 (14:39 -0500)
committerRobert LeBlanc <rdleblanc@bluehost.com>
Fri, 29 Jan 2016 16:28:57 +0000 (09:28 -0700)
commit5cefcb975771f0c2efb7dfc77ce14a93a4ee7f1b
tree6a8ba347d3b5745eca9964fd4a5d61e8c8d45d84
parente1b92081c9e4b21eb30cc873c239083a08fce12f
osd/ReplicatedPG: fix promotion recency logic

Recency is defined as how many of the last N hitsets an object
must appear in in order to be promoted.  The previous logic did
nothing of the sort... it checked for the object in any one of
the last N hitsets, which led to way to many promotions and killed
any chance of the cache performing properly.

While we are here, we can simplify the code to drop the max_in_*
fields (no longer necessary).

Note that we may still want a notion of 'temperature' that does
tolerate the object missing in one of the recent hitsets.. but
that would be different than recency, and should probably be
modeled after the eviction temperature model.

Backport: infernalis, hammer
Reported-by: Nick Fisk <nick@fisk.me.uk>
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 180c8743addc5ae2f1db9c58cd2996ca6e7ac18b)

Conflicts:
src/osd/ReplicatedPG.cc
                    code section was moved to ReplicatedPG::maybe_promote
                    in master.
Signed-off-by: Robert LeBlanc <robert.leblanc@endurance.com>
src/osd/ReplicatedPG.cc