OTARIS / MF-REST-API

The MetaHL Fabric REST API is an interface to any Hyperledger® Fabric network.
https://otaris.de/metahl-fabric/
Apache License 2.0
6 stars 2 forks source link

Hold a connection to the node #2

Closed dl-ota closed 3 years ago

dl-ota commented 4 years ago

Since we want to be able to receive notifications by the block chain, we need to hold a session. All required functions should be inside our Utils class.

kk-ota commented 4 years ago

The connection is now established once. Related commit: https://github.com/dl-ota/Nutrisafe-REST-API/commit/fd9ca6235f314c17db44cba2274b943553b3eb24
This is done by testing if the network is null. The Classes Network and Gateway offer no fitting method to for this purpose:
https://hyperledger.github.io/fabric-gateway-java/master/org/hyperledger/fabric/gateway/Network.html
https://hyperledger.github.io/fabric-gateway-java/master/org/hyperledger/fabric/gateway/Gateway.html