[PD+PP] Honor PP consensus for bootstrap and prealloc (#31869)

Co-authored-by: Chao Shi <chao.shi@alibaba-inc.com>
This commit is contained in:
ziang663
2026-07-30 01:19:17 +08:00
committed by GitHub
co-authored by Chao Shi
parent 62d0f81f16
commit eefb434d17
7 changed files with 106 additions and 31 deletions
@@ -40,6 +40,7 @@ class TestDecodeQueueCleanup(CustomTestCase):
decode_req = SimpleNamespace(req=req, kv_receiver=receiver)
queue = DecodePreallocQueue.__new__(DecodePreallocQueue)
queue.pp_size = 1
queue.queue = [decode_req]
queue.pending_reqs = []
queue.retracted_queue = []
@@ -86,6 +87,7 @@ class TestDecodeQueueCleanup(CustomTestCase):
decode_req = SimpleNamespace(req=req, kv_receiver=receiver)
queue = DecodePreallocQueue.__new__(DecodePreallocQueue)
queue.pp_size = 1
queue.queue = [decode_req]
queue.pending_reqs = [decode_req] # same object, dual ownership
queue.retracted_queue = []
@@ -119,6 +119,7 @@ class TestDecodePreallocQueuePriority(unittest.TestCase):
def _new_queue(self, decode_reqs, *, low_priority_values_first: bool = False):
queue = DecodePreallocQueue.__new__(DecodePreallocQueue)
queue.pp_size = 1
queue.queue = list(decode_reqs)
queue.pending_reqs = []
queue.retracted_queue = []
@@ -294,6 +294,7 @@ class TestDecodeLockRefScenarios(unittest.TestCase):
def test_pop_preallocated_rechecks_budget_after_lock(self):
queue = DecodePreallocQueue.__new__(DecodePreallocQueue)
queue.pp_size = 1
req = MagicMock()
req.rid = "req-1"