我正在将带有Debian映像的beaglebone黑色armv7用作HLF nodejs客户端应用程序。 该应用程序使用fabric-client,fabric-ca-client,fabric-network节点模块,并作为由客户端调用的其余API构建(使用curl进行测试),然后,由于API的存在,该API可以用作通往HLF网络的网关。连接配置文件配置。
问题是,在使用Ubuntu机器时,完全相同的应用程序(具有完全相同的连接配置文件)可以在我的Ubuntu计算机中正常运行(它与部署在AWS实例中的网络通信) BUT 如果使用带Debian的armv7,则客户端 Even ,如果客户端成功注册(调用CA容器中的docker日志确认)在调用或查询链代码"Error: Failed to connect before the deadline".
<时无法与对等方通信, / p>
我不明白为什么会收到此错误,原因可能取决于我的Ubuntu计算机和嵌入式Debian设备之间的差异,也可能取决于我不知道的设置或配置。
很显然,由于我在Debian设备本身上使用了npm install,因此从package.json开始正确编译了Debian的节点模块。
在我收到的错误下面。
curl http://localhost:3000/myBalance/ArmClient
{"error":{"message":"No peers available to query. Errors: [\"Failed to connect before the deadline URL:grpcs://peer1.org1.example.com:8051\",\"Failed to connect before the deadline URL:grpcs://peer0.org1.example.com:7051\"]","stack":"FabricError: No peers available to query. Errors: [\"Failed to connect before the deadline URL:grpcs://peer1.org1.example.com:8051\",\"Failed to connect before the deadline URL:grpcs://peer0.org1.example.com:7051\"]\n at SingleQueryHandler.evaluate (/home/debian/Arm/node_modules/fabric-network/lib/impl/query/singlequeryhandler.js:44:17)\n at <anonymous>\n at process._tickCallback (internal/process/next_tick.js:189:7)","name":"FabricError"}}
2019-11-01T16:03:38.658Z - error: [Remote.js]: Error: Failed to connect before the deadline URL:grpcs://peer1.org1.example.com:8051
2019-11-01T16:03:38.661Z - warn: [Query]: evaluate: Query ID "[object Object]" of peer "peer1.org1.example.com:8051" failed: message=Failed to connect before the deadline URL:grpcs://peer1.org1.example.com:8051, stack=Error: Failed to connect before the deadline URL:grpcs://peer1.org1.example.com:8051
at checkState (/home/debian/Arm/node_modules/grpc/src/client.js:835:16), connectFailed=true
2019-11-01T16:03:41.719Z - error: [Remote.js]: Error: Failed to connect before the deadline URL:grpcs://peer0.org1.example.com:7051
2019-11-01T16:03:41.721Z - warn: [Query]: evaluate: Query ID "[object Object]" of peer "peer0.org1.example.com:7051" failed: message=Failed to connect before the deadline URL:grpcs://peer0.org1.example.com:7051, stack=Error: Failed to connect before the deadline URL:grpcs://peer0.org1.example.com:7051
at checkState (/home/debian/Arm/node_modules/grpc/src/client.js:835:16), connectFailed=true
2019-11-01T16:03:41.724Z - error: [SingleQueryHandler]: evaluate: message=No peers available to query. Errors: ["Failed to connect before the deadline URL:grpcs://peer1.org1.example.com:8051","Failed to connect before the deadline URL:grpcs://peer0.org1.example.com:7051"], stack=FabricError: No peers available to query. Errors: ["Failed to connect before the deadline URL:grpcs://peer1.org1.example.com:8051","Failed to connect before the deadline URL:grpcs://peer0.org1.example.com:7051"]
at SingleQueryHandler.evaluate (/home/debian/Arm/node_modules/fabric-network/lib/impl/query/singlequeryhandler.js:44:17)
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:189:7), name=FabricError
Failed to evaluate transaction: FabricError: No peers available to query. Errors: ["Failed to connect before the deadline URL:grpcs://peer1.org1.example.com:8051","Failed to connect before the deadline URL:grpcs://peer0.org1.example.com:7051"]