-
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-2462: Re-enable paging results for queries
Paging result sets is required in order to avoid failures related to large result sets. The Next() call on StateQueryIterator from Chaincode was failing in peer due to a corner case. This fix addresses the corner case (where the number of results is an exact multiple of shim batch size). This is done by keeping the HasMore flag in iterator accurate by pre-fetching the next batch of results when the last cached item from shim is accessed. This fix also adds the Namespace field to commonledger.KV type. The data returned to peer has namespace information. All state iterators return QueryResult with commonledger.KV type elements. Change-Id: Id872130db8a20ec5a59593b1fa004dce43ee36ac Signed-off-by: Balaji Viswanathan <balaji.viswanathan@gmail.com> Signed-off-by: denyeart <enyeart@us.ibm.com>
- Loading branch information
1 parent
7f114bb
commit 868a3e9
Showing
6 changed files
with
189 additions
and
259 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
Oops, something went wrong.