Skip to content

feat(fabric-shim): implement native gRPC batching for GetMultipleStates and GetMultiplePrivateData#504

Open
JhaSourav07 wants to merge 1 commit intohyperledger:mainfrom
JhaSourav07:feature/grpc-batching-implementation
Open

feat(fabric-shim): implement native gRPC batching for GetMultipleStates and GetMultiplePrivateData#504
JhaSourav07 wants to merge 1 commit intohyperledger:mainfrom
JhaSourav07:feature/grpc-batching-implementation

Conversation

@JhaSourav07
Copy link
Contributor

This PR implements the native Fabric v3.1 gRPC batching for GetMultipleStates and GetMultiplePrivateData, replacing the temporary fallback loops introduced in Phase 1 (PR #497).

Changes:

  • Updated handler.js to utilize the GetStateMultiple request and GetStateMultipleResult response protobufs from @hyperledger/fabric-protos@0.3.7.
  • Updated integration tests in stub.js to drive the public API and mock the handler logic as requested.
  • Updated unit tests in handler.js to assert the correct GET_STATE_MULTIPLE network messages are dispatched.

Closes #453 >
(cc: @bestbeforetoday - Thank you for the guidance on the test architecture and for bumping the protos!)

image

…eStates

This commit replaces the temporary fallback loops from Phase 1 with the highly optimized native Fabric v3.1 gRPC batching requests (GetStateMultiple and GetStateMultipleResult).

- Updated handler.js to use native protobuf batching.

- Refactored stub.js integration tests to drive the public API and mock the handler.

- Updated handler.js unit tests to assert correct GET_STATE_MULTIPLE network message dispatch.

- Fixed TypeScript linting errors in chaincode.ts.

Closes hyperledger#453

Signed-off-by: Sourav <souravkjha2007@gmail.com>
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.

Read/write batching

1 participant