-
Notifications
You must be signed in to change notification settings - Fork 8.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FAB-5330] Prevent payload buffer overpopulation
The state transfer module receives blocks from either the orderer or other peers, and puts them into a payload buffer for reordering so they would enter the ledger in-order. In some cases: - If the peer joined late and it receives blocks from peers starting from index i where the ledger is missing indices [j, i] for some j<i and the rate of block reception from peers is very fast - If the ledger is "stuck" (i.e file system full, etc.) and cannot advance This buffer would overpopulate. This commit addresses this, and adds a maximum distance constant that if the difference between the ledger height and the sequence of the block that is received is greater than this constant, the block is dropped. Change-Id: Ia1ba8966ea6d211c5d1b7ddd84a4fad34af797d4 Signed-off-by: yacovm <yacovm@il.ibm.com>
- Loading branch information
Showing
3 changed files
with
129 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters