Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a new fabric connector to utilise the new peer gateway api #1205

Closed
davidkel opened this issue Jan 19, 2022 · 5 comments · Fixed by #1253, #1270, #1298, #1227 or #1310
Closed

Add a new fabric connector to utilise the new peer gateway api #1205

davidkel opened this issue Jan 19, 2022 · 5 comments · Fixed by #1253, #1270, #1298, #1227 or #1310
Assignees
Labels
component/fabric Related to the HL Fabric adapter enhancement New feature or request
Milestone

Comments

@davidkel
Copy link
Contributor

davidkel commented Jan 19, 2022

Please share the technical limitation of Caliper that you encountered.

Hyperledger fabric has introduced a new client api for applications. This new client api uses a new service in peers tp perform the work of handling transaction lifecycle and querying reducing the overhead of the client and centralising the logic that is common across all the client sdks.
This api is the new standard api released in 2.4 and will be part of an LTS release soon. The other SDKs will remain but any further enhancements to the application api space are likely to be within the new standard rather than the legacy apis and so caliper should embrace the new programming model going forward

Please detail your feature idea that could alleviate the limitation.

We should implement a new fabric connector to take advantage of this new api., it will be similar to the current connectors in both implementation and the network configuration

Please share some details about your use case if possible, and how the new feature would make Caliper a better performance benchmarking framework.

Caliper needs to keep up with the changes within fabric to stay relevant

Please share any suggestions about the new feature's code/configuration API (using formatted YAML segments or pseudo-code).

  • the new connector will be selected when a user binds to fabric:2.4
  • the new connector will support the following network configuration
caliper:
  blockchain: fabric

organizations:
  - mspid: Org1MSP
    identities:
      certificates:
      - name: 'User1'
        clientPrivateKey:
          path: '../fabric-samples/test-network/organizations/peerOrganizations/org1.example.com/users/[email protected]/msp/keystore/priv_sk'
        clientSignedCert:
          path: '../fabric-samples/test-network/organizations/peerOrganizations/org1.example.com/users/[email protected]/msp/signcerts/[email protected]'
    connectionprofile:
      path: './Org2ConnectionProfile.json'

note that there is no discover option on the connection profile. If it is specified, as with the current 2.0.0 specification of the fabric network config it will be ignored.

Although a connection profile can contain multiple peers, only the first one found in the connection profile should be used.

@davidkel davidkel added the enhancement New feature or request label Jan 19, 2022
@davidkel
Copy link
Contributor Author

There are some enhancements to this connector that can be done but will be part of another further feature requests

  • support endorse and commit sub timings
  • mutual tls support
  • gateway peer load balancing

@davidkel davidkel added the component/fabric Related to the HL Fabric adapter label Jan 19, 2022
@aklenik
Copy link
Contributor

aklenik commented Jan 20, 2022

@davidkel Updating the network config version number is a good idea. We should also make this explicit in the docs, and the Fabric connectors should inspect this version, and output appropriate error messages in case of a mismatch.

@davidkel
Copy link
Contributor Author

For this issue we won't be adding in this support

peers:
      -   endpoint: host:port
        tlsCACerts:
          pem: |
            pem-data
          path: ....
        grpcOptions:
          ssl-target-name-override: peer0.org.example.com
          hostnameOverride: peer0.org.example.com

This will be moved to a new issue

@fraVlaca
Copy link
Contributor

fraVlaca commented Feb 14, 2022

Add new connector version to caliper repo:

Create new folder peer-gateway on the connector-versions folder with

Documentation will be covered in 3 separate issues
#1284, #1256 and #1299

@davidkel
Copy link
Contributor Author

the minimal connector implementation is now complete

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment