Hyperledger fabric Hyperledger结构批注失败:txid存在

Hyperledger fabric Hyperledger结构批注失败:txid存在,hyperledger-fabric,docker-swarm,hyperledger-chaincode,Hyperledger Fabric,Docker Swarm,Hyperledger Chaincode,我目前正在尝试使用Docker Swarm,基于,在Hyperledger结构网络上成功调用链码。我的网络如下: PC1上OrderRog的org1与peer0.org1.com+1 CA org1+CLI org1+orderer.example.com 在PC2上使用peer0.org2.com+1 CA org2的org2 看起来我的网络正在工作,但一旦在对等机上实例化了链码,然后调用,操作就不会传播。例如,我将数据插入分类账,链码容器日志显示它们处理了数据,用于调用链码的对等容器似乎

我目前正在尝试使用Docker Swarm,基于,在Hyperledger结构网络上成功调用链码。我的网络如下:

  • PC1上OrderRog的org1与peer0.org1.com+1 CA org1+CLI org1+orderer.example.com
  • 在PC2上使用peer0.org2.com+1 CA org2的org2
看起来我的网络正在工作,但一旦在对等机上实例化了链码,然后调用,操作就不会传播。例如,我将数据插入分类账,链码容器日志显示它们处理了数据,用于调用链码的对等容器似乎也正确地支持并模拟了查询。所有这些都是通过在CLI中手动使用命令实现的

peer0.org1.com容器日志

2019-07-09 08:52:08.753 UTC [endorser] EndorseWithPlugin -> DEBU 3784 Entering endorsement for {plugin: escc, channel: mychannel, tx: 50732326bbe19c9eb8de42fa327ee67fc2c8102337ef96cdf9ca49fb7a0b7703, chaincode: fabcar}
2019-07-09 08:52:08.753 UTC [msp.identity] Sign -> DEBU 3785 Sign: plaintext: 0A2040CDC0100B7F12FA1505C311EF86...455254494649434154452D2D2D2D2D0A 
2019-07-09 08:52:08.753 UTC [msp.identity] Sign -> DEBU 3786 Sign: digest: 5E7E6A043E851C3316B08F5CB4A05D31840D213793C55BF14EBE64213E852F84 
2019-07-09 08:52:08.756 UTC [endorser] EndorseWithPlugin -> DEBU 3787 Exiting {plugin: escc, channel: mychannel, tx: 50732326bbe19c9eb8de42fa327ee67fc2c8102337ef96cdf9ca49fb7a0b7703, chaincode: fabcar}
2019-07-09 08:52:08.756 UTC [endorser] endorseProposal -> DEBU 3788 [mychannel][50732326] Exit
2019-07-09 08:52:08.756 UTC [lockbasedtxmgr] Done -> DEBU 3789 Done with transaction simulation / query execution [50732326bbe19c9eb8de42fa327ee67fc2c8102337ef96cdf9ca49fb7a0b7703]
2019-07-09 08:52:08.756 UTC [endorser] func1 -> DEBU 378a Exit: request from 10.0.0.4:34978
2019-07-09 08:52:08.756 UTC [comm.grpc.server] 1 -> INFO 378b unary call completed grpc.service=protos.Endorser grpc.method=ProcessProposal grpc.peer_address=10.0.0.4:34978 grpc.code=OK grpc.call_duration=8.895639ms
2019-07-09T09:22:03.277Z - warn: [DiscoveryEndorsementHandler]: _build_endorse_group_member >> G0:1 - endorsement failed - Error: failed to execute transaction a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9: error sending: txid: a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9(mychannel) exists
Failed to submit transaction: Error: Endorsement has failed
然后,对分类账的(成功执行的)查询显示分类账状态没有改变

但是,如果使用(invoke.js)中fabcar示例中提供的节点SDK调用相同的链码操作,则会出现错误:

node invoke.js出现节点sdk错误

2019-07-09 08:52:08.753 UTC [endorser] EndorseWithPlugin -> DEBU 3784 Entering endorsement for {plugin: escc, channel: mychannel, tx: 50732326bbe19c9eb8de42fa327ee67fc2c8102337ef96cdf9ca49fb7a0b7703, chaincode: fabcar}
2019-07-09 08:52:08.753 UTC [msp.identity] Sign -> DEBU 3785 Sign: plaintext: 0A2040CDC0100B7F12FA1505C311EF86...455254494649434154452D2D2D2D2D0A 
2019-07-09 08:52:08.753 UTC [msp.identity] Sign -> DEBU 3786 Sign: digest: 5E7E6A043E851C3316B08F5CB4A05D31840D213793C55BF14EBE64213E852F84 
2019-07-09 08:52:08.756 UTC [endorser] EndorseWithPlugin -> DEBU 3787 Exiting {plugin: escc, channel: mychannel, tx: 50732326bbe19c9eb8de42fa327ee67fc2c8102337ef96cdf9ca49fb7a0b7703, chaincode: fabcar}
2019-07-09 08:52:08.756 UTC [endorser] endorseProposal -> DEBU 3788 [mychannel][50732326] Exit
2019-07-09 08:52:08.756 UTC [lockbasedtxmgr] Done -> DEBU 3789 Done with transaction simulation / query execution [50732326bbe19c9eb8de42fa327ee67fc2c8102337ef96cdf9ca49fb7a0b7703]
2019-07-09 08:52:08.756 UTC [endorser] func1 -> DEBU 378a Exit: request from 10.0.0.4:34978
2019-07-09 08:52:08.756 UTC [comm.grpc.server] 1 -> INFO 378b unary call completed grpc.service=protos.Endorser grpc.method=ProcessProposal grpc.peer_address=10.0.0.4:34978 grpc.code=OK grpc.call_duration=8.895639ms
2019-07-09T09:22:03.277Z - warn: [DiscoveryEndorsementHandler]: _build_endorse_group_member >> G0:1 - endorsement failed - Error: failed to execute transaction a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9: error sending: txid: a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9(mychannel) exists
Failed to submit transaction: Error: Endorsement has failed
peer0.org1.com节点调用后的容器日志

2019-07-09 09:22:03.273 UTC [endorser] callChaincode -> INFO 15480 [mychannel][a0a2570d] Entry chaincode: name:"fabcar" 
2019-07-09 09:22:03.273 UTC [chaincode] Execute -> DEBU 15481 Entry
2019-07-09 09:22:03.273 UTC [chaincode] Execute -> DEBU 15482 Exit
2019-07-09 09:22:03.273 UTC [endorser] callChaincode -> INFO 15483 [mychannel][a0a2570d] Exit chaincode: name:"fabcar"  (0ms)
2019-07-09 09:22:03.273 UTC [chaincode] handleMessage -> DEBU 15484 [a0a2570d] Fabric side handling ChaincodeMessage of type: PUT_STATE in state ready
2019-07-09 09:22:03.273 UTC [endorser] SimulateProposal -> ERRO 15485 [mychannel][a0a2570d] failed to invoke chaincode name:"fabcar" , error: txid: a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9(mychannel) exists
github.com/hyperledger/fabric/core/chaincode.(*TransactionContexts).Create
    /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/transaction_contexts.go:59
github.com/hyperledger/fabric/core/chaincode.(*Handler).Execute
    /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/handler.go:1207
github.com/hyperledger/fabric/core/chaincode.(*ChaincodeSupport).execute
    /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/chaincode_support.go:313
github.com/hyperledger/fabric/core/chaincode.(*ChaincodeSupport).Invoke
    /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/chaincode_support.go:302
github.com/hyperledger/fabric/core/chaincode.(*ChaincodeSupport).Execute
    /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/chaincode_support.go:239
github.com/hyperledger/fabric/core/endorser.(*SupportImpl).Execute
    /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/support.go:147
github.com/hyperledger/fabric/core/endorser.(*Endorser).callChaincode
    /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/endorser.go:146
github.com/hyperledger/fabric/core/endorser.(*Endorser).SimulateProposal
    /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/endorser.go:247
github.com/hyperledger/fabric/core/endorser.(*Endorser).ProcessProposal
    /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/endorser.go:500
github.com/hyperledger/fabric/core/handlers/auth/filter.(*expirationCheckFilter).ProcessProposal
    /opt/gopath/src/github.com/hyperledger/fabric/core/handlers/auth/filter/expiration.go:61
github.com/hyperledger/fabric/core/handlers/auth/filter.(*filter).ProcessProposal
    /opt/gopath/src/github.com/hyperledger/fabric/core/handlers/auth/filter/filter.go:32
github.com/hyperledger/fabric/protos/peer._Endorser_ProcessProposal_Handler.func1
    /opt/gopath/src/github.com/hyperledger/fabric/protos/peer/peer.pb.go:169
github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware.ChainUnaryServer.func1.1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware/chain.go:31
github.com/hyperledger/fabric/core/comm.(*Throttle).UnaryServerIntercptor
    /opt/gopath/src/github.com/hyperledger/fabric/core/comm/throttle.go:54
github.com/hyperledger/fabric/core/comm.(*Throttle).UnaryServerIntercptor-fm
    /opt/gopath/src/github.com/hyperledger/fabric/peer/node/start.go:224
github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware.ChainUnaryServer.func1.1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware/chain.go:34
github.com/hyperledger/fabric/common/grpclogging.UnaryServerInterceptor.func1
    /opt/gopath/src/github.com/hyperledger/fabric/common/grpclogging/server.go:91
github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware.ChainUnaryServer.func1.1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware/chain.go:34
github.com/hyperledger/fabric/common/grpcmetrics.UnaryServerInterceptor.func1
    /opt/gopath/src/github.com/hyperledger/fabric/common/grpcmetrics/interceptor.go:30
github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware.ChainUnaryServer.func1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware/chain.go:39
github.com/hyperledger/fabric/protos/peer._Endorser_ProcessProposal_Handler
    /opt/gopath/src/github.com/hyperledger/fabric/protos/peer/peer.pb.go:171
github.com/hyperledger/fabric/vendor/google.golang.org/grpc.(*Server).processUnaryRPC
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/google.golang.org/grpc/server.go:982
github.com/hyperledger/fabric/vendor/google.golang.org/grpc.(*Server).handleStream
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/google.golang.org/grpc/server.go:1208
github.com/hyperledger/fabric/vendor/google.golang.org/grpc.(*Server).serveStreams.func1.1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/google.golang.org/grpc/server.go:686
runtime.goexit
    /opt/go/src/runtime/asm_amd64.s:1333
error sending
failed to execute transaction a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9
github.com/hyperledger/fabric/core/chaincode.processChaincodeExecutionResult
    /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/chaincode_support.go:245
github.com/hyperledger/fabric/core/chaincode.(*ChaincodeSupport).Execute
    /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/chaincode_support.go:240
github.com/hyperledger/fabric/core/endorser.(*SupportImpl).Execute
    /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/support.go:147
github.com/hyperledger/fabric/core/endorser.(*Endorser).callChaincode
    /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/endorser.go:146
github.com/hyperledger/fabric/core/endorser.(*Endorser).SimulateProposal
    /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/endorser.go:247
github.com/hyperledger/fabric/core/endorser.(*Endorser).ProcessProposal
    /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/endorser.go:500
github.com/hyperledger/fabric/core/handlers/auth/filter.(*expirationCheckFilter).ProcessProposal
    /opt/gopath/src/github.com/hyperledger/fabric/core/handlers/auth/filter/expiration.go:61
github.com/hyperledger/fabric/core/handlers/auth/filter.(*filter).ProcessProposal
    /opt/gopath/src/github.com/hyperledger/fabric/core/handlers/auth/filter/filter.go:32
github.com/hyperledger/fabric/protos/peer._Endorser_ProcessProposal_Handler.func1
    /opt/gopath/src/github.com/hyperledger/fabric/protos/peer/peer.pb.go:169
github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware.ChainUnaryServer.func1.1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware/chain.go:31
github.com/hyperledger/fabric/core/comm.(*Throttle).UnaryServerIntercptor
    /opt/gopath/src/github.com/hyperledger/fabric/core/comm/throttle.go:54
github.com/hyperledger/fabric/core/comm.(*Throttle).UnaryServerIntercptor-fm
    /opt/gopath/src/github.com/hyperledger/fabric/peer/node/start.go:224
github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware.ChainUnaryServer.func1.1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware/chain.go:34
github.com/hyperledger/fabric/common/grpclogging.UnaryServerInterceptor.func1
    /opt/gopath/src/github.com/hyperledger/fabric/common/grpclogging/server.go:91
github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware.ChainUnaryServer.func1.1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware/chain.go:34
github.com/hyperledger/fabric/common/grpcmetrics.UnaryServerInterceptor.func1
    /opt/gopath/src/github.com/hyperledger/fabric/common/grpcmetrics/interceptor.go:30
github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware.ChainUnaryServer.func1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/github.com/grpc-ecosystem/go-grpc-middleware/chain.go:39
github.com/hyperledger/fabric/protos/peer._Endorser_ProcessProposal_Handler
    /opt/gopath/src/github.com/hyperledger/fabric/protos/peer/peer.pb.go:171
github.com/hyperledger/fabric/vendor/google.golang.org/grpc.(*Server).processUnaryRPC
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/google.golang.org/grpc/server.go:982
github.com/hyperledger/fabric/vendor/google.golang.org/grpc.(*Server).handleStream
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/google.golang.org/grpc/server.go:1208
github.com/hyperledger/fabric/vendor/google.golang.org/grpc.(*Server).serveStreams.func1.1
    /opt/gopath/src/github.com/hyperledger/fabric/vendor/google.golang.org/grpc/server.go:686
runtime.goexit
    /opt/go/src/runtime/asm_amd64.s:1333
2019-07-09 09:22:03.273 UTC [endorser] SimulateProposal -> DEBU 15486 [mychannel][a0a2570d] Exit
2019-07-09 09:22:03.273 UTC [lockbasedtxmgr] Done -> DEBU 15487 Done with transaction simulation / query execution [a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9]
2019-07-09 09:22:03.273 UTC [endorser] func1 -> DEBU 15488 Exit: request from 172.18.0.1:51702
2019-07-09 09:22:03.273 UTC [chaincode] HandleTransaction -> DEBU 15489 [a0a2570d] handling PUT_STATE from chaincode
2019-07-09 09:22:03.273 UTC [comm.grpc.server] 1 -> INFO 1548a unary call completed grpc.service=protos.Endorser grpc.method=ProcessProposal grpc.peer_address=172.18.0.1:51702 grpc.code=OK grpc.call_duration=4.573006ms
2019-07-09 09:22:03.274 UTC [chaincode] HandleTransaction -> DEBU 1548b [a0a2570d] Completed PUT_STATE. Sending RESPONSE
2019-07-09 09:22:03.274 UTC [chaincode] handleMessage -> DEBU 1548c [a0a2570d] Fabric side handling ChaincodeMessage of type: PUT_STATE in state ready
2019-07-09 09:22:03.274 UTC [chaincode] HandleTransaction -> DEBU 1548d [a0a2570d] handling PUT_STATE from chaincode
2019-07-09 09:22:03.274 UTC [chaincode] HandleTransaction -> DEBU 1548e [a0a2570d] Completed PUT_STATE. Sending RESPONSE
2019-07-09 09:22:03.275 UTC [chaincode] handleMessage -> DEBU 1548f [a0a2570d] Fabric side handling ChaincodeMessage of type: COMPLETED in state ready
2019-07-09 09:22:03.275 UTC [chaincode] Notify -> DEBU 15490 [a0a2570d] notifying Txid:a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9, channelID:mychannel
2019-07-09 09:22:03.275 UTC [chaincode] Execute -> DEBU 15491 Exit
2019-07-09 09:22:03.275 UTC [endorser] callChaincode -> INFO 15492 [mychannel][a0a2570d] Exit chaincode: name:"fabcar"  (3ms)
2019-07-09 09:22:03.275 UTC [lockbasedtxmgr] GetTxSimulationResults -> DEBU 15493 Simulation completed, getting simulation results
2019-07-09 09:22:03.275 UTC [lockbasedtxmgr] Done -> DEBU 15494 Done with transaction simulation / query execution [a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9]
2019-07-09 09:22:03.275 UTC [endorser] SimulateProposal -> DEBU 15495 [mychannel][a0a2570d] Exit
2019-07-09 09:22:03.275 UTC [endorser] endorseProposal -> DEBU 15496 [mychannel][a0a2570d] Entry chaincode: name:"fabcar" 
2019-07-09 09:22:03.275 UTC [endorser] endorseProposal -> DEBU 15497 [mychannel][a0a2570d] escc for chaincode name:"fabcar"  is escc
2019-07-09 09:22:03.275 UTC [endorser] EndorseWithPlugin -> DEBU 15498 Entering endorsement for {plugin: escc, channel: mychannel, tx: a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9, chaincode: fabcar}
2019-07-09 09:22:03.275 UTC [msp.identity] Sign -> DEBU 15499 Sign: plaintext: 0A20828C242C3048295EE0453AD5EA85...455254494649434154452D2D2D2D2D0A 
2019-07-09 09:22:03.275 UTC [msp.identity] Sign -> DEBU 1549a Sign: digest: F3BEDFED5C78408FD01F0A41C0714245508FD2F5AEF8A34F33E7F3C61DEFF987 
2019-07-09 09:22:03.275 UTC [endorser] EndorseWithPlugin -> DEBU 1549b Exiting {plugin: escc, channel: mychannel, tx: a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9, chaincode: fabcar}
2019-07-09 09:22:03.276 UTC [endorser] endorseProposal -> DEBU 1549c [mychannel][a0a2570d] Exit
2019-07-09 09:22:03.276 UTC [lockbasedtxmgr] Done -> DEBU 1549d Done with transaction simulation / query execution [a0a2570dd9a4ce0c696ab08263320927382c6f3db046843dca70a96b63a97da9]
2019-07-09 09:22:03.276 UTC [endorser] func1 -> DEBU 1549e Exit: request from 172.18.0.1:51702
2019-07-09 09:22:03.276 UTC [comm.grpc.server] 1 -> INFO 1549f unary call completed grpc.service=protos.Endorser grpc.method=ProcessProposal grpc.peer_address=172.18.0.1:51702 grpc.code=OK grpc.call_duration=6.750666ms
我尝试了一些解决方案,例如:

  • 为每个组织设置锚节点:已完成
  • 设置
    CORE\u PEER\u listenadress=org1.example.com:7051
    ->使对等容器失败。如果我将地址设置为0.0.0.0:7051,容器将再次启动,但错误保持不变
  • 重新启动Docker/删除卷/重新下载映像:未更改任何内容
更多要点:

订购方似乎没有收到通知,我们可以在中看到

当我使用node invoke.js时,有时会出现这个错误,当我再次启动命令时,这个错误就会消失。对等日志不会显示错误

节点invoke.js不一致错误

2019-07-09T14:13:21.232Z - error: [AbstractStrategy]: constructor: No event hubs for strategy
Failed to submit transaction: Error: No event hubs for strategy
2019-07-09T13:23:13.602Z - error: [SingleQueryHandler]: evaluate: message=No peers available to query. Errors: [], stack=FabricError: No peers available to query. Errors: []
at SingleQueryHandler.evaluate (/home/path_to_dir/app/javascript/node_modules/fabric-network/lib/impl/query/singlequeryhandler.js:39:17)
at Transaction.evaluate (/home/path_to_dir/app/javascript/node_modules/fabric-network/lib/transaction.js:246:29)
at Contract.evaluateTransaction (/home/path_to_dir/app/javascript/node_modules/fabric-network/lib/contract.js:172:39)
at main (/home/path_to_dir/app/javascript/query.js:47:39)
at <anonymous>, name=FabricError
Failed to evaluate transaction: FabricError: No peers available to query. Errors: []
使用node查询时,有时会出现以下错误:

节点query.js不一致错误

2019-07-09T14:13:21.232Z - error: [AbstractStrategy]: constructor: No event hubs for strategy
Failed to submit transaction: Error: No event hubs for strategy
2019-07-09T13:23:13.602Z - error: [SingleQueryHandler]: evaluate: message=No peers available to query. Errors: [], stack=FabricError: No peers available to query. Errors: []
at SingleQueryHandler.evaluate (/home/path_to_dir/app/javascript/node_modules/fabric-network/lib/impl/query/singlequeryhandler.js:39:17)
at Transaction.evaluate (/home/path_to_dir/app/javascript/node_modules/fabric-network/lib/transaction.js:246:29)
at Contract.evaluateTransaction (/home/path_to_dir/app/javascript/node_modules/fabric-network/lib/contract.js:172:39)
at main (/home/path_to_dir/app/javascript/query.js:47:39)
at <anonymous>, name=FabricError
Failed to evaluate transaction: FabricError: No peers available to query. Errors: []
2019-07-09T13:23:13.602Z-错误:[SingleQueryHandler]:评估:消息=没有可查询的对等点。错误:[],stack=Fabricerr:没有可查询的对等点。错误:[]
在SingleQueryHandler.evaluate(/home/path_to_dir/app/javascript/node_modules/fabric network/lib/impl/query/SingleQueryHandler.js:39:17)
在Transaction.evaluate(/home/path_to_dir/app/javascript/node_modules/fabric network/lib/Transaction.js:246:29)
在Contract.evaluateransaction(/home/path_to_dir/app/javascript/node_modules/fabric network/lib/Contract.js:172:39)
在main(/home/path_to_dir/app/javascript/query.js:47:39)
在

编辑:在尝试节点insert.js后添加和记录(请参见注释)

配置信息 HLF 1.4.1;Docker 18.09.7;docker compose 1.23.2;节点v8.16.0;npm 6.4.1;Ubuntu 18.04.2 LTS


我为众多的错误表示歉意,这些错误使问题变得广泛,但我认为它们都与背书问题有关。如果没有,请毫不犹豫地编辑/ping我以缩小范围。

关于nodejs SDK,您可以分享您的代码吗?您可能错误地插入了一个错误(我今天早上刚刚插入了一个错误,值得检查,不需要花费太多时间),建议您获取fabric node sdk的日志,如本链接中所述,以帮助您调查错误problem@david_k完成了,我想没有多大用处:实际上它证实了我的想法。出于某种原因,节点sdk向同一对等方发送了两次建议。因此,对等方将接受1,并拒绝另一个表示txid已经存在。至于它为什么这样做,我不知道。建议您提出Jira,因为它可能是NodeSDK中的一个bug,但可能是一个配置问题。请首先确保您使用的是最新版本的node sdk,以防有任何修复。@Rouliboy我想是的,但我不确定,我会在可能的时候检查它。自从8月以来我就没碰过代码,所以我不能保证我会找到任何东西:/你试着去hyperledger聊天了吗?当我与FabricsSDK合作时,他们非常有帮助。关于nodejs SDK,你能分享你的代码吗?您可能错误地插入了一个错误(我今天早上刚刚插入了一个错误,值得检查,不需要花费太多时间),建议您获取fabric node sdk的日志,如本链接中所述,以帮助您调查错误problem@david_k完成了,我想没有多大用处:实际上它证实了我的想法。出于某种原因,节点sdk向同一对等方发送了两次建议。因此,对等方将接受1,并拒绝另一个表示txid已经存在。至于它为什么这样做,我不知道。建议您提出Jira,因为它可能是NodeSDK中的一个bug,但可能是一个配置问题。请首先确保您使用的是最新版本的node sdk,以防有任何修复。@Rouliboy我想是的,但我不确定,我会在可能的时候检查它。自从8月以来我就没碰过代码,所以我不能保证我会找到任何东西:/你试着去hyperledger聊天了吗?当我使用织物时,它们非常有用