0
votes

This is not a duplicates, at least I have the right version of Composer, I have also read the 3 stackflow composer questions.

I tried to publish definition, the Basic-Sample-Network package came from the git respository, the Basic-sample-network.bna archive file, here's the command :

composer network deploy -p hlfv1.json -a basic-sample-network.bna -i admin -s adminpw

The error (seems to be a generic error message):

Identifier: [email protected]
Description: The Hello World of Hyperledger Composer samples

events.js:160 throw er; // Unhandled 'error' event ^

Error: event message must be properly signed by an identity from the same organization as the peer: [failed deserializing event creator: [Expected MSP ID Org1MSP, received ]]

at ClientDuplexStream._emitStatusIfDone (/usr/local/lib/node_modules/composer-cli/node_modules/grpc/src/node/src/client.js:189:19)
at ClientDuplexStream._receiveStatus (/usr/local/lib/node_modules/composer-cli/node_modules/grpc/src/node/src/client.js:169:8)

at /usr/local/lib/node_modules/composer-cli/node_modules/grpc/src/node/src/client.js:634:14

Here're my environments :

composer -v :

composer-cli v0.10.0

composer-admin v0.10.0

composer-client v0.10.0

composer-common v0.10.0

composer-runtime-hlf v0.10.0

composer-runtime-hlfv1 v0.10.0

npm c 3.10.10

hlfv1.json profile :

{ "type": "hlfv1", "orderers": [ { "url" : "grpc://localhost:7050" } ], "ca": { "url": "http://localhost:7054", "name": "ca.org1.example.com" }, "peers": [ { "requestURL": "grpc://localhost:7051", "eventURL": "grpc://localhost:7053" } ], "keyValStore": "${HOME}/.composer-credentials", "channel": "composerchannel", "mspID": "Org1MSP", "timeout": "300" }

Note I used the fabric-tool script the start the fabric and to generate the profile (hlfv1.json).

docker ps:

570ae25a586e hyperledger/fabric-peer:x86_64-1.0.0 "peer node start -..." 30 minutes ago Up 30 minutes 0.0.0.0:7051->7051/tcp, 0.0.0.0:7053->7053/tcp peer0.org1.example.com

513431e5d217 hyperledger/fabric-ca:x86_64-1.0.0 "sh -c 'fabric-ca-..." 31 minutes ago Up 31 minutes 0.0.0.0:7054->7054/tcp ca.org1.example.com

2e7bf444481d hyperledger/fabric-couchdb:x86_64-1.0.0 "tini -- /docker-e..." 31 minutes ago Up 31 minutes 4369/tcp, 9100/tcp, 0.0.0.0:5984->5984/tcp couchdb

5d5ba67cc602 hyperledger/fabric-orderer:x86_64-1.0.0 "orderer" 31 minutes ago Up 30 minutes 0.0.0.0:7050->7050/tcp orderer.example.com

2

2 Answers

0
votes

If you follow the developer tutorial you will see that the id PeerAdmin must be used to deploy the network.

https://hyperledger.github.io/composer/tutorials/developer-guide.html

0
votes

Problem fixed.

The confusion was providing the connectionProfileName, the -p option, based on reading the document, I thought I have to provide a file with connection information (even thought the provided profile information contain all necessary information), I didn't know it was actually picking up the profile file from ~/.composer-connection-profiles folder based on the name provided in the -p option.