test(grpc-data): H06 held legs start right after a deploy (idle projection authority lapses)
The review re-run showed a re-browse served from the cached page does not renew an idle projected node's 15 s metadata lease (value Read is refused the same way; pre-existing v1 projection behaviour). Each held H06 leg now starts right after a baseline restore + re-browse.
This commit is contained in:
@@ -365,9 +365,20 @@ class HistoryGate:
|
||||
report["local_deny"] = {"raw": local, "uns": other, "attempts": attempts}
|
||||
self.restore()
|
||||
consumer = self.runner.primary("consumer")
|
||||
# (c) a consumer session close releases the origin continuation. A projected node's authority lapses with its metadata
|
||||
# lease (15 s) unless something renews it — the same for a value Read (pre-existing v1 behaviour) — so re-browse first.
|
||||
self.rebrowse()
|
||||
# (d) origin rebuild mid-page: a resumed page after the origin's history epoch moved is BadContinuationPointInvalid.
|
||||
def rebuild():
|
||||
self.change(rename_tag={"tag_id": "source-array1", "name": "array1-renamed"})
|
||||
rebuilt = self.held(consumer, ["-n", self.projected[("raw", "counter")], *self.window_args(), "--page-size", "3",
|
||||
"--pause-after-page", "1", "--fresh-after-failure"], "rebuild", rebuild)
|
||||
lines = self.status_lines(rebuilt.stdout)
|
||||
self.runner.check(any(l.startswith("Page 2: BadContinuationPointInvalid") for l in lines), "resume after the origin rebuild is invalid")
|
||||
self.runner.check(any(l.startswith("Fresh: Good") for l in lines), "a fresh read after the rebuild succeeds")
|
||||
report["rebuild"] = lines
|
||||
# (c) a consumer session close releases the origin continuation. Each held read starts right after a deploy + re-browse:
|
||||
# an idle projected node's authority lapses with its 15 s metadata lease and a re-browse served from the cached page
|
||||
# does not renew it (a value Read is refused the same way — pre-existing v1 projection behaviour, reported).
|
||||
self.restore()
|
||||
consumer = self.runner.primary("consumer")
|
||||
self.runner.check(self.origin_state() == 0, "no origin continuation open before")
|
||||
counts = {}
|
||||
|
||||
@@ -384,16 +395,6 @@ class HistoryGate:
|
||||
after = self.origin_state()
|
||||
self.runner.check(after == 0, "the consumer session close released the origin continuation (store count back to 0)")
|
||||
report["session_close"] = {"held": counts.get("held"), "after": after, "lines": self.status_lines(abandoned.stdout)}
|
||||
# (d) origin rebuild mid-page: a resumed page after the origin's history epoch moved is BadContinuationPointInvalid.
|
||||
self.rebrowse()
|
||||
def rebuild():
|
||||
self.change(rename_tag={"tag_id": "source-array1", "name": "array1-renamed"})
|
||||
rebuilt = self.held(consumer, ["-n", self.projected[("raw", "counter")], *self.window_args(), "--page-size", "3",
|
||||
"--pause-after-page", "1", "--fresh-after-failure"], "rebuild", rebuild)
|
||||
lines = self.status_lines(rebuilt.stdout)
|
||||
self.runner.check(any(l.startswith("Page 2: BadContinuationPointInvalid") for l in lines), "resume after the origin rebuild is invalid")
|
||||
self.runner.check(any(l.startswith("Fresh: Good") for l in lines), "a fresh read after the rebuild succeeds")
|
||||
report["rebuild"] = lines
|
||||
return report
|
||||
|
||||
# ------------------------------------------------------------------------------------------------------------- run
|
||||
|
||||
Reference in New Issue
Block a user