Skip to content

Conversation

@akash-R-A-J
Copy link

  • Support omitting sequence parameter (pass 0) to query latest approved chaincode definition
  • Support omitting chaincode name (pass empty string) to query all approved chaincode definitions on the channel
  • Add documentation for new Fabric v3 query modes

Addresses issue #208

- Support omitting sequence parameter (pass 0) to query latest approved chaincode definition
- Support omitting chaincode name (pass empty string) to query all approved chaincode definitions on the channel
- Add documentation for new Fabric v3 query modes

Addresses issue hyperledger#208

Signed-off-by: Akash Raj <[email protected]>
@akash-R-A-J
Copy link
Author

akash-R-A-J commented Dec 30, 2025

Testing Notes

As discussed in issue #208, this behavior was exercised during Fabric v3 end-to-end testing.

Supported Query Modes

This implementation enables the following Fabric v3 lifecycle query behaviors:

  • Query the latest approved chaincode definition
    Pass sequence = 0 to retrieve the most recent approved definition.

  • Query all approved chaincode definitions on a channel
    Pass chaincodeName = "" (empty string) to retrieve all approved definitions.

Implementation Details

The implementation conditionally sets the Name and Sequence fields in the lifecycle query protobuf only when values are provided. This allows the Fabric v3 lifecycle to correctly apply its optional query semantics without altering existing behavior.

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.

1 participant