Skip to content

Remove the requests of an in-flight proposal from the pool once it is decided - #702

Merged
pfi79 merged 1 commit into
hyperledger:mainfrom
HagarMeir:fix/inflight-view-requests
Oct 15, 2026
Merged

pfi79 merged 1 commit into
hyperledger:mainfrom
HagarMeir:fix/inflight-view-requests

Conversation

@HagarMeir

Copy link
Copy Markdown
Contributor

Written by Claude (Anthropic's AI assistant) on behalf of Hagar Meir.

Fixes #701.

When a view change commits an in-flight proposal, the temporary view that decides it is not set up like a regular view:

  • it has no requests, so none of them are removed from the request pool, and CountTxsAll is not increased;
  • it has no pre-prepare time, so LatencyBatchProcessing records about 292 years.

Changes

  • commitInFlightProposal sets the in-flight view's inFlightRequests from Verifier.RequestsFromProposal. When the proposal is decided, ViewChanger.Decide then removes them from the pool.
  • commitInFlightProposal sets beginPrePrepare right before the in-flight view starts.
  • TestCommitInFlight now checks that the requests of the decided in-flight proposal are removed, and that a reasonable latency is recorded. Both checks fail without the fix.

No message or decision rule changes. Only the local request pool and metrics are affected.

🤖 Generated with Claude Code

@pfi79

pfi79 commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

@HagarMeir Please fulfill the dco condition

When a view change commits an in-flight proposal, the view that decides
it had no requests and no pre-prepare time. So its requests were never
removed from the request pool (their timers kept running, leading to
forwarding and complaints), CountTxsAll was not increased, and
LatencyBatchProcessing recorded the time since the zero time.

Set the in-flight view's requests from the verifier and its pre-prepare
time right before it starts, and check both in TestCommitInFlight.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Signed-off-by: Hagar Meir <hagar.meir@ibm.com>
@HagarMeir
HagarMeir force-pushed the fix/inflight-view-requests branch from 52f4a26 to 9ea3d07 Compare October 15, 2026 10:08
@pfi79
pfi79 merged commit 8180d0e into hyperledger:main Oct 15, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Committing the in-flight proposal after a view change leaves its requests in the pool and records a bogus batch latency

2 participants