Skip to content

Commit

Permalink
RCX666
Browse files Browse the repository at this point in the history
  • Loading branch information
martin-headspace committed Nov 22, 2017
1 parent 54c231f commit acb0385
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 10 deletions.
2 changes: 1 addition & 1 deletion Uber-Lyra/app/invoke-transaction.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ var invokeChaincode = function(peerNames, channelName, chaincodeName, fcn, args,
let handle = setTimeout(() => {
eh.disconnect();
reject();
}, 120000);
}, 30000);

eh.registerTxEvent(transactionID, (tx, code) => {
clearTimeout(handle);
Expand Down
7 changes: 6 additions & 1 deletion Uber-Lyra/artifacts/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ services:
container_name: orderer.example.com
image: hyperledger/fabric-orderer
environment:
- ORDERER_GENERAL_LEDGERTYPE=ram
- ORDERER_GENERAL_LOGLEVEL=debug
- ORDERER_GENERAL_LISTENADDRESS=0.0.0.0
- ORDERER_GENERAL_GENESISMETHOD=file
Expand Down Expand Up @@ -68,6 +67,8 @@ services:
- CORE_PEER_ID=peer0.org1.example.com
- CORE_PEER_LOCALMSPID=Org1MSP
- CORE_PEER_ADDRESS=peer0.org1.example.com:7051
- CORE_PEER_VALIDATOR_CONSENSUS_PLUGIN=pbft
- CORE_PBFT_GENERAL_MODE=batch
ports:
- 7051:7051
- 7053:7053
Expand All @@ -85,6 +86,8 @@ services:
- CORE_PEER_ID=peer1.org1.example.com
- CORE_PEER_LOCALMSPID=Org1MSP
- CORE_PEER_ADDRESS=peer1.org1.example.com:7051
- CORE_PEER_VALIDATOR_CONSENSUS_PLUGIN=pbft
- CORE_PBFT_GENERAL_MODE=batch
ports:
- 7056:7051
- 7058:7053
Expand Down Expand Up @@ -119,6 +122,8 @@ services:
- CORE_PEER_ID=peer1.org2.example.com
- CORE_PEER_LOCALMSPID=Org2MSP
- CORE_PEER_ADDRESS=peer1.org2.example.com:7051
- CORE_PEER_VALIDATOR_CONSENSUS_PLUGIN=pbft
- CORE_PBFT_GENERAL_MODE=batch
ports:
- 8056:7051
- 8058:7053
Expand Down
17 changes: 9 additions & 8 deletions Uber-Lyra/blockchainManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,17 +109,18 @@ class BlockchainManager {
cannonBalls.push(this.invokeTransactions(peer, chaincodeName, chaincodeName, 'transferFunds', args, username, orgName));
}
start = now();
// Promise.resolve([])
// .then(all => cannonBalls[0].then(Array.prototype.concat.bind(all)))
return Promise.all(cannonBalls)

var chain;
return Promise.resolve([])
.then(all => cannonBalls[0].then(Array.prototype.concat.bind(all)))
})
.then(() => {
end = now();
this.profilingTime(start, end, amount, 'tx');
return this.getWalletByRange(peer, chaincodeName, channelName, start, end, username, orgName);
// return this.getWalletByRange(peer, chaincodeName, channelName, start, end, username, orgName);
})
.then((ledger) => {
return this.syncChecker(ledger);
//return this.syncChecker(ledger);
})
.catch(function (err) {
console.log('An error occured: ', chalk.bold.red(err));
Expand Down Expand Up @@ -235,9 +236,9 @@ class BlockchainManager {
}
//Launch the accounts
start = now();
Promise.resolve([])
// .then(all => all_promise[0].then(Array.prototype.concat.bind(all)))
return Promise.all(all_promise)

return Promise.resolve([])
.then(all => all_promise[0].then(Array.prototype.concat.bind(all)))
.then(() => {
end = now();
this.profilingTime(start, end, amount, 'acc');
Expand Down
1 change: 1 addition & 0 deletions basic-network/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ services:
container_name: orderer.example.com
image: hyperledger/fabric-orderer
environment:
- ORDERER_GENERAL_LEDGERTYPE=ram
- ORDERER_GENERAL_LOGLEVEL=debug
- ORDERER_GENERAL_LISTENADDRESS=0.0.0.0
- ORDERER_GENERAL_GENESISMETHOD=file
Expand Down

0 comments on commit acb0385

Please sign in to comment.