Todd Lipcon has submitted this change and it was merged. Change subject: compaction_policy: fix bound calculation ......................................................................
compaction_policy: fix bound calculation The upper-bound calculator for the knapsack problem maintains a heap which is supposed to keep no more than one item beyond the maximum weight allowed. This invariant got broken in some cases when an item was added to the heap -- in some cases a single addition actually requires removing multiple old items. A regression test for this fix is included in the following commit ("Optimize budgeted compaction policy with an approximation") Change-Id: I76364c17debd7293b36884d64c7747f8c604ae12 Reviewed-on: http://gerrit.cloudera.org:8080/4152 Reviewed-by: David Ribeiro Alves <dral...@apache.org> Tested-by: Kudu Jenkins --- M src/kudu/tablet/compaction_policy.cc 1 file changed, 6 insertions(+), 5 deletions(-) Approvals: David Ribeiro Alves: Looks good to me, approved Kudu Jenkins: Verified -- To view, visit http://gerrit.cloudera.org:8080/4152 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: merged Gerrit-Change-Id: I76364c17debd7293b36884d64c7747f8c604ae12 Gerrit-PatchSet: 4 Gerrit-Project: kudu Gerrit-Branch: master Gerrit-Owner: Todd Lipcon <t...@apache.org> Gerrit-Reviewer: Alexey Serbin <aser...@cloudera.com> Gerrit-Reviewer: Anonymous Coward #174 Gerrit-Reviewer: David Ribeiro Alves <dral...@apache.org> Gerrit-Reviewer: Kudu Jenkins Gerrit-Reviewer: Todd Lipcon <t...@apache.org> Gerrit-Reviewer: Will Berkeley <wdberke...@gmail.com>