Date   
Documentation Workgroup: Agenda for Friday, 15 Feb Cancelled, Next meeting Feb 22

Anthony O'Dowd
 

Hi All,

Unfortunately, due to travel plans and quite a few other folks' other commitments, we're not going to be able to hold the workgroup call this week.  We'll be holding it next week as usual, so apologies, and see you all then!

Best regards, Anthony.
Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number 741598.
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU

Re: Error hyperledger explorer #fabric

Nick Frunza
 

Please verify each path in config.json, the error clearly says 
{ Error: ENOENT: no such file or directory, scandir '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore'

to make sure, do for each path similar to this $cd /home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore


On Thu, Feb 14, 2019 at 3:36 PM Fernando Gomez <fggrocha@...> wrote:
Hi,
This is de last 50 lines:

[2019-02-09 23:07:32.223] [DEBUG] Platform - ******* Initialization started for hyperledger fabric platform ******
[2019-02-09 23:07:32.224] [DEBUG] Platform - Setting admin organization enrolment files
[2019-02-09 23:07:32.224] [DEBUG] FabricUtils - Organization [Org1] enrolment files path defined as directory
[2019-02-09 23:07:32.224] [ERROR] Platform - { Error: ENOENT: no such file or directory, scandir '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore'
    at Object.fs.readdirSync (fs.js:904:18)
    at setOrgEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:340:26)
    at Object.setAdminEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:319:37)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:70:48)
    at Platform.initialize (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:50:16)
    at Explorer.initialize (/home/fernando/blockchain-explorer/app/Explorer.js:64:22)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
  errno: -2,
  code: 'ENOENT',
  syscall: 'scandir',
  path: '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore' }
[2019-02-09 23:07:32.227] [DEBUG] Platform - Creatinging client [client-1] >>
[2019-02-09 23:18:36.416] [DEBUG] Platform - ******* Initialization started for hyperledger fabric platform ******
[2019-02-09 23:18:36.416] [DEBUG] Platform - Setting admin organization enrolment files
[2019-02-09 23:18:36.417] [DEBUG] FabricUtils - Organization [Org1] enrolment files path defined as directory
[2019-02-09 23:18:36.417] [ERROR] Platform - { Error: ENOENT: no such file or directory, scandir '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore'
    at Object.fs.readdirSync (fs.js:904:18)
    at setOrgEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:340:26)
    at Object.setAdminEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:319:37)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:70:48)
    at Platform.initialize (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:50:16)
    at Explorer.initialize (/home/fernando/blockchain-explorer/app/Explorer.js:64:22)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
  errno: -2,
  code: 'ENOENT',
  syscall: 'scandir',
  path: '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore' }
[2019-02-09 23:18:36.420] [DEBUG] Platform - Creatinging client [client-1] >>
[2019-02-09 23:22:44.435] [DEBUG] Platform - ******* Initialization started for hyperledger fabric platform ******
[2019-02-09 23:22:44.435] [DEBUG] Platform - Setting admin organization enrolment files
[2019-02-09 23:22:44.436] [DEBUG] FabricUtils - Organization [Org1] enrolment files path defined as directory
[2019-02-09 23:22:44.436] [ERROR] Platform - { Error: ENOENT: no such file or directory, scandir '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore'
    at Object.fs.readdirSync (fs.js:904:18)
    at setOrgEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:340:26)
    at Object.setAdminEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:319:37)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:70:48)
    at Platform.initialize (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:50:16)
    at Explorer.initialize (/home/fernando/blockchain-explorer/app/Explorer.js:64:22)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
  errno: -2,
  code: 'ENOENT',
  syscall: 'scandir',
  path: '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore' }
[2019-02-09 23:22:44.438] [DEBUG] Platform - Creatinging client [client-1] >> 

Thank you so much

El mié., 13 feb. 2019 a las 21:34, Nick Frunza (<nfrunza@...>) escribió:
It is hard to figure out your problem either you have invalid config.json, or fabric issues, please email the last 50 lines from 

<explorer path>blockchain-explorer/logs/app/app.log file

thank you

Nik


On Wed, Feb 13, 2019 at 2:16 PM Fernando Gomez <fggrocha@...> wrote:
Hi,

Now i have this error:

postgres://hppoc:password@....0.1:5432/fabricexplorer
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
TypeError: Cannot read property 'substring' of undefined
    at processTLS_URL (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:66:21)
    at cloneConfig (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:58:19)
    at Object.createDetachClient (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:39:25)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:105:38)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
(node:10711) DeprecationWarning: grpc.load: Use the @grpc/proto-loader module with grpc.loadPackageDefinition instead
Received kill signal, shutting down gracefully
Closed out connections

Regads

El dom., 10 feb. 2019 a las 23:05, Nick Frunza (<nfrunza@...>) escribió:
Please use a json validator to see the syntax error, copy and paste your config.json, you can use: https://jsonformatter.curiousconcept.com/


On Sat, Feb 9, 2019 at 8:41 AM Jean-Gaël Dominé <jgdomine@...> wrote:
Hi,

In the content you gave, a last bracket is missing. Thus your json file ends prematurely... :)

Hope it will fix your problem

JG



--
Nik Frunza



--
Nik Frunza



--
Nik Frunza

Re: Error hyperledger explorer #fabric

Fernando <fggrocha@...>
 

Hi,
This is de last 50 lines:

[2019-02-09 23:07:32.223] [DEBUG] Platform - ******* Initialization started for hyperledger fabric platform ******
[2019-02-09 23:07:32.224] [DEBUG] Platform - Setting admin organization enrolment files
[2019-02-09 23:07:32.224] [DEBUG] FabricUtils - Organization [Org1] enrolment files path defined as directory
[2019-02-09 23:07:32.224] [ERROR] Platform - { Error: ENOENT: no such file or directory, scandir '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore'
    at Object.fs.readdirSync (fs.js:904:18)
    at setOrgEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:340:26)
    at Object.setAdminEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:319:37)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:70:48)
    at Platform.initialize (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:50:16)
    at Explorer.initialize (/home/fernando/blockchain-explorer/app/Explorer.js:64:22)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
  errno: -2,
  code: 'ENOENT',
  syscall: 'scandir',
  path: '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore' }
[2019-02-09 23:07:32.227] [DEBUG] Platform - Creatinging client [client-1] >>
[2019-02-09 23:18:36.416] [DEBUG] Platform - ******* Initialization started for hyperledger fabric platform ******
[2019-02-09 23:18:36.416] [DEBUG] Platform - Setting admin organization enrolment files
[2019-02-09 23:18:36.417] [DEBUG] FabricUtils - Organization [Org1] enrolment files path defined as directory
[2019-02-09 23:18:36.417] [ERROR] Platform - { Error: ENOENT: no such file or directory, scandir '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore'
    at Object.fs.readdirSync (fs.js:904:18)
    at setOrgEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:340:26)
    at Object.setAdminEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:319:37)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:70:48)
    at Platform.initialize (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:50:16)
    at Explorer.initialize (/home/fernando/blockchain-explorer/app/Explorer.js:64:22)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
  errno: -2,
  code: 'ENOENT',
  syscall: 'scandir',
  path: '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore' }
[2019-02-09 23:18:36.420] [DEBUG] Platform - Creatinging client [client-1] >>
[2019-02-09 23:22:44.435] [DEBUG] Platform - ******* Initialization started for hyperledger fabric platform ******
[2019-02-09 23:22:44.435] [DEBUG] Platform - Setting admin organization enrolment files
[2019-02-09 23:22:44.436] [DEBUG] FabricUtils - Organization [Org1] enrolment files path defined as directory
[2019-02-09 23:22:44.436] [ERROR] Platform - { Error: ENOENT: no such file or directory, scandir '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore'
    at Object.fs.readdirSync (fs.js:904:18)
    at setOrgEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:340:26)
    at Object.setAdminEnrolmentPath (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:319:37)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:70:48)
    at Platform.initialize (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:50:16)
    at Explorer.initialize (/home/fernando/blockchain-explorer/app/Explorer.js:64:22)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
  errno: -2,
  code: 'ENOENT',
  syscall: 'scandir',
  path: '/home/fernando/fabric-dev-servers/fabric-samples/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore' }
[2019-02-09 23:22:44.438] [DEBUG] Platform - Creatinging client [client-1] >> 

Thank you so much

El mié., 13 feb. 2019 a las 21:34, Nick Frunza (<nfrunza@...>) escribió:
It is hard to figure out your problem either you have invalid config.json, or fabric issues, please email the last 50 lines from 

<explorer path>blockchain-explorer/logs/app/app.log file

thank you

Nik


On Wed, Feb 13, 2019 at 2:16 PM Fernando Gomez <fggrocha@...> wrote:
Hi,

Now i have this error:

postgres://hppoc:password@....0.1:5432/fabricexplorer
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
TypeError: Cannot read property 'substring' of undefined
    at processTLS_URL (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:66:21)
    at cloneConfig (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:58:19)
    at Object.createDetachClient (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:39:25)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:105:38)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
(node:10711) DeprecationWarning: grpc.load: Use the @grpc/proto-loader module with grpc.loadPackageDefinition instead
Received kill signal, shutting down gracefully
Closed out connections

Regads

El dom., 10 feb. 2019 a las 23:05, Nick Frunza (<nfrunza@...>) escribió:
Please use a json validator to see the syntax error, copy and paste your config.json, you can use: https://jsonformatter.curiousconcept.com/


On Sat, Feb 9, 2019 at 8:41 AM Jean-Gaël Dominé <jgdomine@...> wrote:
Hi,

In the content you gave, a last bracket is missing. Thus your json file ends prematurely... :)

Hope it will fix your problem

JG



--
Nik Frunza



--
Nik Frunza

Re: Timeout expired while executing transaction a heavy chaincode function #fabric #fabric-sdk-java

Joao Antunes
 

Just a quick update:

The peer1-org1 logs:

 

2019-02-14 17:42:03.360 UTC [endorser] simulateProposal -> ERRO 1e5b6 [project1][d90dbe85] failed to invoke chaincode name:"project1" version:"1.0" , error: timeout expired while executing transaction

github.com/hyperledger/fabric/core/chaincode.(*ChaincodeSupport).Execute

        /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/chaincode_support.go:813

github.com/hyperledger/fabric/core/chaincode.Execute

        /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/exectransaction.go:58

github.com/hyperledger/fabric/core/chaincode.ExecuteChaincode

        /opt/gopath/src/github.com/hyperledger/fabric/core/chaincode/chaincodeexec.go:85

github.com/hyperledger/fabric/core/endorser.(*SupportImpl).Execute

        /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/support.go:93

github.com/hyperledger/fabric/core/endorser.(*Endorser).callChaincode

        /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/endorser.go:132

github.com/hyperledger/fabric/core/endorser.(*Endorser).simulateProposal

        /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/endorser.go:265

github.com/hyperledger/fabric/core/endorser.(*Endorser).ProcessProposal

        /opt/gopath/src/github.com/hyperledger/fabric/core/endorser/endorser.go:491

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:31

github.com/hyperledger/fabric/protos/peer._Endorser_ProcessProposal_Handler

        /opt/gopath/src/github.com/hyperledger/fabric/protos/peer/peer.pb.go:112

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:781

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:981

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:551

runtime.goexit

        /opt/go/src/runtime/asm_amd64.s:2337

failed to execute transaction

error executing chaincode

 
 
 

Timeout expired while executing transaction a heavy chaincode function #fabric #fabric-sdk-java

Joao Antunes
 

Hi to all,

Currently I have a chaincode that takes a bit of time to execute (it's expected).

The problem is that when I run the call I receive the following error:

Caused by: io.grpc.StatusRuntimeException: UNKNOWN: error executing chaincode: failed to execute transaction: timeout expired while executing transaction


I'm using java sdk and yes, I have my proposal.waitTime=60000.

Can the transaction timeout be changed? Where, sdk or network config?

Thank you and regards,
João Antunes

Re: A sequence of GetState(key1) ==> PutState(key1,val2) ==> GetState(key1) returns old value for key1.

Alessandro Sorniotti
 

Hi

The scenario you describe works as expected: a chaincode invocation doesn't actually write to the ledger; instead, the proposed ledger changes are captured in the "read-write set" artefact. The read-write set is later placed in a transaction message. After ordering, if the transaction complies with the endorsement policy, its read-write set is applied to the ledger, at which point its changes will become visible to future chaincode invocations. This means that a chaincode execution is unable to see its own writes to the ledger: this will only be possible after the transaction is ordered.

More details here: https://arxiv.org/abs/1801.10228

Cheers,
Ale

On Thu, 14 Feb 2019, at 9:22 AM, Vishal wrote:
Hi,

One of the Invoke operation in chaincode has below sequence of APIs
calls:
* GetState(key1) ==>returns val1
* PutState(key1,val2) ==> returns shim.OK
* *GetState(key1) ==> returns val1, instead it should return val2*
*But, the opertaion returns the correct value i.e. val2 when it called
one more time.*

Here is the actual code snippet from the chaincode:
```
    // Get current value of available fund under the project
    prjBytes, err := stub.GetState(p.ProjectID)
    if err != nil {
        cErr := &chainError{ "readProject" , p.ProjectID,
CODEGENEXCEPTION, err}
        return shim.Error(cErr.Error())
    }
    prj := &project{}
    err = json.Unmarshal(prjBytes, prj)
    if err != nil {
        cErr := &chainError{ "readProject" , p.ProjectID,
CODEGENEXCEPTION, err}
        return shim.Error(cErr.Error())
    }
    // calculate the new value
    prj.Data.AvlFund =
prj.Data.AvlFund.Add(donationAggregate.Sub(spendAggregate))

    prjBytes, err = json.Marshal(prj)
    if err != nil {
        cErr := &chainError{ "readProject" , p.ProjectID, CODEGENEXCEPTION, err}
        return shim.Error(cErr.Error())
    }

    // Save the update value of available funds under a project
    err = stub.PutState(p.ProjectID, prjBytes)
    if err != nil {
        cErr := &chainError{ "readProject" , p.ProjectID, CODEGENEXCEPTION, err}
        return shim.Error(cErr.Error())
    }

    // Read and return the updated project state
    prjBytes, err = stub.GetState(p.ProjectID)
    if err != nil {
        cErr := &chainError{ "readProject" , p.ProjectID, CODEGENEXCEPTION, err}
        return shim.Error(cErr.Error())
    }
    r := response{CODEALLAOK, p.ProjectID, prjBytes}
    return shim.Success((r.formatResponse()))
}

```


Re: Error hyperledger explorer #fabric

Nick Frunza
 

It is hard to figure out your problem either you have invalid config.json, or fabric issues, please email the last 50 lines from 

<explorer path>blockchain-explorer/logs/app/app.log file

thank you

Nik


On Wed, Feb 13, 2019 at 2:16 PM Fernando Gomez <fggrocha@...> wrote:
Hi,

Now i have this error:

postgres://hppoc:password@....0.1:5432/fabricexplorer
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
TypeError: Cannot read property 'substring' of undefined
    at processTLS_URL (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:66:21)
    at cloneConfig (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:58:19)
    at Object.createDetachClient (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:39:25)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:105:38)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
(node:10711) DeprecationWarning: grpc.load: Use the @grpc/proto-loader module with grpc.loadPackageDefinition instead
Received kill signal, shutting down gracefully
Closed out connections

Regads

El dom., 10 feb. 2019 a las 23:05, Nick Frunza (<nfrunza@...>) escribió:
Please use a json validator to see the syntax error, copy and paste your config.json, you can use: https://jsonformatter.curiousconcept.com/


On Sat, Feb 9, 2019 at 8:41 AM Jean-Gaël Dominé <jgdomine@...> wrote:
Hi,

In the content you gave, a last bracket is missing. Thus your json file ends prematurely... :)

Hope it will fix your problem

JG



--
Nik Frunza



--
Nik Frunza

Re: Error hyperledger explorer #fabric

Fernando <fggrocha@...>
 

Hi,

Now i have this error:

postgres://hppoc:password@....0.1:5432/fabricexplorer
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
TypeError: Cannot read property 'substring' of undefined
    at processTLS_URL (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:66:21)
    at cloneConfig (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:58:19)
    at Object.createDetachClient (/home/fernando/blockchain-explorer/app/platform/fabric/utils/FabricUtils.js:39:25)
    at Platform.buildClients (/home/fernando/blockchain-explorer/app/platform/fabric/Platform.js:105:38)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:189:7)
(node:10711) DeprecationWarning: grpc.load: Use the @grpc/proto-loader module with grpc.loadPackageDefinition instead
Received kill signal, shutting down gracefully
Closed out connections

Regads

El dom., 10 feb. 2019 a las 23:05, Nick Frunza (<nfrunza@...>) escribió:
Please use a json validator to see the syntax error, copy and paste your config.json, you can use: https://jsonformatter.curiousconcept.com/


On Sat, Feb 9, 2019 at 8:41 AM Jean-Gaël Dominé <jgdomine@...> wrote:
Hi,

In the content you gave, a last bracket is missing. Thus your json file ends prematurely... :)

Hope it will fix your problem

JG



--
Nik Frunza

Re: [Request] regarding Hyperledger Development Work.

Nick Frunza
 


On Tue, Feb 12, 2019 at 1:13 PM Denny Hong <dennymrh@...> wrote:
Hi Nick,

Thank you for your response. What is the address of HLExplorer? I could not find it on Google. 

Sincerely,
Denny Hong

On Sun, Feb 10, 2019 at 4:08 PM Nick Frunza <nfrunza@...> wrote:
Please join HLExplorer, you're welcome

thank you
Nik

On Fri, Feb 8, 2019 at 12:29 PM Denny Hong <dennymrh@...> wrote:
Hi Team,

This is Denny. I already tried Fabric tutorials, and I am very interested in learning/developing a blockchain application. Do you know a person or team I can join and help? Please let me know if you have any questions.

Sincerely,
Denny Hong



--
Nik Frunza



--
Nik Frunza

Re: [Request] regarding Hyperledger Development Work.

Denny Hong <dennymrh@...>
 

Hi Nick,

Thank you for your response. What is the address of HLExplorer? I could not find it on Google. 

Sincerely,
Denny Hong


On Sun, Feb 10, 2019 at 4:08 PM Nick Frunza <nfrunza@...> wrote:
Please join HLExplorer, you're welcome

thank you
Nik

On Fri, Feb 8, 2019 at 12:29 PM Denny Hong <dennymrh@...> wrote:
Hi Team,

This is Denny. I already tried Fabric tutorials, and I am very interested in learning/developing a blockchain application. Do you know a person or team I can join and help? Please let me know if you have any questions.

Sincerely,
Denny Hong



--
Nik Frunza

Re: 答复: [Hyperledger Fabric] example of system plugin not work

Huijian
 

Hi

 

You should build with “pluginsenabled” from source code, since the official image isn’t built with this switch on.

Please refer to https://jira.hyperledger.org/browse/FAB-7710

 

Best Regards

 

发件人: fabric@... [mailto:fabric@...] 代表 XIaoguang Wang
发送时间: 201921 18:29
收件人: hyperledger-fabric
主题: [Hyperledger Fabric] example of system plugin not work

 

Hi  experts

 

Has anyone deployed the official system plugin example under fabric 1.4 source codes folder(github.com/hyperledger/fabric/examples/plugins/scc) successfully?

 

I built the system chaincode plugin (by go build -buildmode=plugin) successfully and config peer node configuration core.yaml according to official  guide as below.

 

But the system chaincode plugin is not loaded during peer startup.

 

BR

Xiaoguang

 

 

Configuring Plugins

Plugins are configured in the chaincode.systemPlugin section in core.yaml:

chaincode:
  systemPlugins:
    - enabled: true
      name: mysyscc
      path: /opt/lib/syscc.so
      invokableExternal: true
      invokableCC2CC: true

A system chaincode must also be whitelisted in the chaincode.system section in core.yaml:

chaincode:
  system:
    mysyscc: enable

 

Re: Problem with Node-SDk with fabric-network package when invoke transaction

Nikhil Gupta
 

You may also be hitting this problem because you do not have the correct TLS Certs, or the SDK is not able to read them. I noticed there are no TLS certificates in your connection profile. I hit the same error when my connection profile was built incorrectly.





From:        "Jean-Gaël Dominé" <jgdomine@...>
To:        fabric@...
Date:        02/09/2019 12:02 PM
Subject:        Re: [Hyperledger Fabric] Problem with Node-SDk with fabric-network package when invoke transaction
Sent by:        fabric@...




Hi,

The first idea that comes to my mind when reading your error is that you've got a problem with the artifacts you must have generated with cryptogen et configtxgen.
I might be wrong but I would look for an issue inside one of those files (maybe more the configtx.yaml but both are worth a look).

Could you attach those files ?

JG



Re: [Request] regarding Hyperledger Development Work.

Nick Frunza
 

Please join HLExplorer, you're welcome

thank you
Nik

On Fri, Feb 8, 2019 at 12:29 PM Denny Hong <dennymrh@...> wrote:
Hi Team,

This is Denny. I already tried Fabric tutorials, and I am very interested in learning/developing a blockchain application. Do you know a person or team I can join and help? Please let me know if you have any questions.

Sincerely,
Denny Hong



--
Nik Frunza

Re: Error hyperledger explorer #fabric

Nick Frunza
 

Please use a json validator to see the syntax error, copy and paste your config.json, you can use: https://jsonformatter.curiousconcept.com/


On Sat, Feb 9, 2019 at 8:41 AM Jean-Gaël Dominé <jgdomine@...> wrote:
Hi,

In the content you gave, a last bracket is missing. Thus your json file ends prematurely... :)

Hope it will fix your problem

JG



--
Nik Frunza

Re: 答复: [Hyperledger Fabric] Fabric v1.4.1 & Move to Node 10 for Chaincode

david liu
 

PS: FYR, it is https://jira.hyperledger.org/browse/FABN-1031

 

Best Regards,

David Liu

+852 5982 3942

 


发件人: fabric@... <fabric@...> 代表 david liu <david-khala@...>
发送时间: Sunday, February 10, 2019 6:34:40 PM
收件人: Gari Singh; Matthew White
抄送: hyperledger-fabric@...
主题: 答复: [Hyperledger Fabric] Fabric v1.4.1 & Move to Node 10 for Chaincode
 

I have created a issue for sdk-node and welcome suggest below. It has been witnessed for a while and looks it is time to go forward.

 

Best Regards,

David Liu

+852 5982 3942

 


发件人: fabric@... <fabric@...> 代表 Gari Singh <garis@...>
发送时间: Wednesday, February 6, 2019 6:41:03 PM
收件人: Matthew White
抄送: hyperledger-fabric@...
主题: Re: [Hyperledger Fabric] Fabric v1.4.1 & Move to Node 10 for Chaincode
 
Yep ... this is the right move.
We should also look at doing the same thing for the SDK
 

 -----------------------------------------
 Gari Singh
 Distinguished Engineer, CTO - IBM Blockchain
 IBM Middleware
 550 King St
 Littleton, MA 01460
 Cell: 978-846-7499
 garis@...
 -----------------------------------------

-----fabric@... wrote: -----
To: hyperledger-fabric@...
From: "Matthew White"
Sent by: fabric@...
Date: 02/06/2019 04:51AM
Subject: [Hyperledger Fabric] Fabric v1.4.1 & Move to Node 10 for Chaincode

Hello;

I wanted to get community views on the topic of moving the v1.4.1 Node.js chaincode support from Node 8 to Node 10

[the jira issue is https://jira.hyperledger.org/browse/FAB-13075]

Fabric v1.4 is the LTS release

NodeJS v8 is no longer in 'active' status, NodeJS v10 is the active LTS release.
There was one issue with Node 10 - but that has been resolved now. The CI pipelines have Node 10 support

Please feedback positive or negative on this change. Based on the current positive feedback the intent *is to move* to using Node 10 for v1.4.1

Thanks

Regards, Matthew.
Matthew B White  IBM Blockchain Solutions Architect

Email me at WHITEMAT@...
Find me on StackOverflow, and generally at  calanais.me.uk

Note: restricted availability for meetings 14:30 to 17:00 UK Tuesday
IBM United Kingdom Limited, Hursley Park, Winchester, Hampshire, SO21 2JN
"The wrong answers are the ones you go looking for when the right answers stare you in the face"
 Unless stated otherwise above:
 IBM United Kingdom Limited - Registered in England and Wales with number 741598.
 Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU
 
  
  




Re: 答复: [Hyperledger Fabric] Fabric v1.4.1 & Move to Node 10 for Chaincode

david liu
 

I have created a issue for sdk-node and welcome suggest below. It has been witnessed for a while and looks it is time to go forward.

 

Best Regards,

David Liu

+852 5982 3942

 


发件人: fabric@... <fabric@...> 代表 Gari Singh <garis@...>
发送时间: Wednesday, February 6, 2019 6:41:03 PM
收件人: Matthew White
抄送: hyperledger-fabric@...
主题: Re: [Hyperledger Fabric] Fabric v1.4.1 & Move to Node 10 for Chaincode
 
Yep ... this is the right move.
We should also look at doing the same thing for the SDK
 

 -----------------------------------------
 Gari Singh
 Distinguished Engineer, CTO - IBM Blockchain
 IBM Middleware
 550 King St
 Littleton, MA 01460
 Cell: 978-846-7499
 garis@...
 -----------------------------------------

-----fabric@... wrote: -----
To: hyperledger-fabric@...
From: "Matthew White"
Sent by: fabric@...
Date: 02/06/2019 04:51AM
Subject: [Hyperledger Fabric] Fabric v1.4.1 & Move to Node 10 for Chaincode

Hello;

I wanted to get community views on the topic of moving the v1.4.1 Node.js chaincode support from Node 8 to Node 10

[the jira issue is https://jira.hyperledger.org/browse/FAB-13075]

Fabric v1.4 is the LTS release

NodeJS v8 is no longer in 'active' status, NodeJS v10 is the active LTS release.
There was one issue with Node 10 - but that has been resolved now. The CI pipelines have Node 10 support

Please feedback positive or negative on this change. Based on the current positive feedback the intent *is to move* to using Node 10 for v1.4.1

Thanks

Regards, Matthew.
Matthew B White  IBM Blockchain Solutions Architect

Email me at WHITEMAT@...
Find me on StackOverflow, and generally at  calanais.me.uk

Note: restricted availability for meetings 14:30 to 17:00 UK Tuesday
IBM United Kingdom Limited, Hursley Park, Winchester, Hampshire, SO21 2JN
"The wrong answers are the ones you go looking for when the right answers stare you in the face"
 Unless stated otherwise above:
 IBM United Kingdom Limited - Registered in England and Wales with number 741598.
 Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU
 
  
  




Re: Problem with Node-SDk with fabric-network package when invoke transaction

Jean-Gaël Dominé
 

Hi,

The first idea that comes to my mind when reading your error is that you've got a problem with the artifacts you must have generated with cryptogen et configtxgen.
I might be wrong but I would look for an issue inside one of those files (maybe more the configtx.yaml but both are worth a look).

Could you attach those files ?

JG

Re: Error hyperledger explorer #fabric

Jean-Gaël Dominé
 

Hi,

In the content you gave, a last bracket is missing. Thus your json file ends prematurely... :)

Hope it will fix your problem

JG

Error hyperledger explorer #fabric

Fernando <fggrocha@...>
 

Dear Sir/Madam
We have a problem when launching Hyperledger Explorer. The issue is in config.json file. when launch start.sh, the explorer don't start and the error in the console logs are the following:

postgres://hppoc:password@....0.1:5432/fabricexplorer
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
SyntaxError: /home/fernando/blockchain-explorer/app/platform/fabric/config.json: Unexpected end of JSON input
    at JSON.parse (<anonymous>)
    at Object.Module._extensions..json (module.js:672:27)
    at Module.load (module.js:566:32)
    at tryModuleLoad (module.js:506:12)
    at Function.Module._load (module.js:498:3)
    at Module.require (module.js:597:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (/home/fernando/blockchain-explorer/app/platform/fabric/service/channelService.js:9:14)
    at Module._compile (module.js:653:30)
    at Object.Module._extensions..js (module.js:664:10)
(node:16572) DeprecationWarning: grpc.load: Use the @grpc/proto-loader module with grpc.loadPackageDefinition instead
Received kill signal, shutting down gracefully
Closed out connections

And config.json is:

{
  "network-configs": {
    "network-1": {
      "version": "1.0",
      "clients": {
        "client-1": {
          "tlsEnable": true,
          "organization": "Org1",
          "channel": "mychannel",
          "credentialStore": {
            "path": "./tmp/credentialStore_Org1/credential",
            "cryptoStore": {
              "path": "./tmp/credentialStore_Org1/crypto"
            }
          }
        }
      },
      "channels": {
        "mychannel": {
          "peers": {
            "peer0.org1.example.com": {}
          },
          "connection": {
            "timeout": {
              "peer": {
                "endorser": "6000",
                "eventHub": "6000",
                "eventReg": "6000"
              }
            }
          }
        }
      },
      "organizations": {
        "Org1": {
          "mspid": "Org1MSP",
          "fullpath": false,
          "adminPrivateKey": {
            "path": "/home/fernando/fabric-dev-servers/fabric-scripts/hlfv12/composer/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore"
          },
          "signedCert": {
            "path": "/home/fernando/fabric-dev-servers/fabric-scripts/hlfv12/composer/crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/signcerts"
          }
        },
        "Orderer": {
          "mspid": "OrdererMSP",
          "adminPrivateKey": {
            "path": "/home/fernando/fabric-dev-servers/fabric-scripts/hlfv12/composer/crypto-config/ordererOrganizations/example.com/users/Admin@.../msp/keystore"
          }
        }
      },
      "peers": {
        "peer0.org1.example.com": {
          "tlsCACerts": {
            "path": "/home/fernando/fabric-dev-servers/fabric-scripts/hlfv12/composer/crypto-config/peerOrganizations/org1.example.com/peers/peer0.org1.example.com/tls/ca.crt"
          },
          "url": "grpcs://localhost:7051",
          "eventUrl": "grpcs://localhost:7053",
          "grpcOptions": {
            "ssl-target-name-override": "peer0.org1.example.com"
          }
        },
      "orderers": {
        "orderer.example.com": {
          "url": "grpcs://localhost:7050"
        }
      }
    },
    "network-2": {}
  },
  "configtxgenToolPath": "/home/fernando/fabric-samples/bin",
  "license": "Apache-2.0"
}

Thanks and Regards.

Fernando

Problem with Node-SDk with fabric-network package when invoke transaction

Tharindu Sandaruwan <TharinduSA@...>
 

Dear Sir/Madam

 

I have set up a network and create a nodejs application to connect with it using nodejs SDK. When I try to invoke a transaction it leaves me this output on the terminal.

Failed to submit transaction: Error: PEM encoded certificate is required.

Then I look for the logs of dev-peers it leaves me an error like this.

17 ssl_transport_security.cc:238] Could not get common name of subject from certificate.

This is how my connection.json file looks like.

{
"name": "basic-network",
"version": "1.0.0",
"client": {
"organization": "Org1",
"connection": {
"timeout": {
"peer": {
"endorser": "300"
},
"orderer": "300"
}
}
},
"channels": {
"mychannel": {
"orderers": ["orderer.example.com"],
"peers": {
"peer0.org1.example.com": {
"endorsingPeer": true,
"chaincodeQuery": true,
"ledgerQuery": true,
"eventSource": true
},
"peer0.org2.example.com": {
"endorsingPeer": true,
"chaincodeQuery": true,
"ledgerQuery": true,
"eventSource": true
}
}
}
},
"organizations": {
"Org1": {
"mspid": "Org1MSP",
"peers": [
"peer0.org1.example.com",
"peer1.org1.example.com"
],
"certificateAuthorities": ["ca.org1.example.com"],
"adminPrivateKey": {
"path": "../crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/keystore/8f3055ee24c8e4575f2fea297a7bbde998i63b7451ea8f7880b5cb91ec24a7d_sk"
},
"signedCert": {
"path": "../crypto-config/peerOrganizations/org1.example.com/users/Admin@.../msp/signcerts/Admin@..."
}
},
"Org2": {
"mspid": "Org2MSP",
"peers": [
"peer0.org2.example.com",
"peer1.org2.example.com"
],
"certificateAuthorities": ["ca.org2.example.com"],
"adminPrivateKey": {
"path": "../crypto-config/peerOrganizations/org2.example.com/users/Admin@.../msp/keystore/e2537a15b0609866b4ec1f70e7a4f77qf915653980f9788af8d2f2b67bdf910_sk"
},
"signedCert": {
"path": "../crypto-config/peerOrganizations/org2.example.com/users/Admin@.../msp/signcerts/Admin@..."
}
}
},
"orderers": {
"orderer.example.com": {
"url": "grpcs://localhost:7050",
"grpcOptions": {
"ssl-target-name-override": "orderer.example.com",
"grpc-max-send-message-length": 15
},
" tlsCACerts": {
"path": "../crypto-config/ordererOrganizations/trafficfine.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem"
}
}
},
"peers": {
"peer0.org1.example.com": {
"url": "grpcs://localhost:7051",
"eventUrl": "grpcs://localhost:7053",
"grpcOptions": {
"ssl-target-name-override": "peer0.org1.example.com",
"grpc.keepalive_time_ms": 600000
},
"tlsCACerts": {
"path": "../crypto-config/peerOrganizations/org1.example.com/peers/peer0.org1.example.com/msp/tlscacerts/tlsca.org1.example.com-cert.pem"
}
},
"peer1.org1.example.com": {
"url": "grpcs://localhost:8051",
"eventUrl": "grpcs://localhost:8053",
"grpcOptions": {
"ssl-target-name-override": "peer1.org1.example.com",
"grpc.keepalive_time_ms": 600000
},
"tlsCACerts": {
"path": "../crypto-config/peerOrganizations/org1.example.com/peers/peer1.org1example.com/msp/tlscacerts/tlsca.org1.example.com-cert.pem"
}
},
"peer0.org2.example.com": {
"url": "grpcs://localhost:9051",
"eventUrl": "grpcs://localhost:9053",
"grpcOptions": {
"ssl-target-name-override": "peer0.org2.example.com",
"grpc.keepalive_time_ms": 600000
},
"tlsCACerts": {
"path": "../crypto-config/peerOrganizations/org2.example.com/peers/peer0.org2.example.com/msp/tlscacerts/tlsca.org2.example.com-cert.pem"
}
},
"peer1.org2.example.com": {
"url": "grpcs://localhost:7051",
"eventUrl": "grpcs://localhost:7053",
"grpcOptions": {
"ssl-target-name-override": "peer1.org2.example.com",
"grpc.keepalive_time_ms": 600000
},
"tlsCACerts": {
"path": "../crypto-config/peerOrganizations/org2.example.com/peers/peer1.org2.example.com/msp/tlscacerts/tlsca.org2.example.com-cert.pem"
}
}
},
"certificateAuthorities": {
"ca.org1.example.com": {
"url": "https://localhost:7054",
"httpOptions": {
"verify": false
},
"caName": "ca.org1.example.com",
"tlsCACerts": {
"path": "../crypto-config/peerOrganizations/org1.example.com/ca/ca.org1.example.com-cert.pem"
}
},
"ca.org2.example.com": {
"url": "https://localhost:7054",
"httpOptions": {
"verify": false
},
"caName": "ca.org2.example.com",
"tlsCACerts": {
"path": "../crypto-config/peerOrganizations/org2.example.com/ca/ca.org2.example.com-cert.pem"
}
}
}
}

This is how my invoke.js file looks like.

/*
* SPDX-License-Identifier: Apache-2.0
*/

"use strict";

const { FileSystemWallet, Gateway } = require("fabric-network");
const fs = require("fs");
const path = require("path");

const ccpPath = path.resolve(__dirname, ".", "connection.json");
const ccpJSON = fs.readFileSync(ccpPath, "utf8");
const ccp = JSON.parse(ccpJSON);

async function main() {
try {
// Create a new file system based wallet for managing identities.
const walletPath = path.join(process.cwd(), "wallet");
const wallet = new FileSystemWallet(walletPath);
console.log(`Wallet path: ${walletPath}`);

// Check to see if we've already enrolled the user.
const userExists = await wallet.exists("TharinduSA");
if (!userExists) {
console.log(
'An identity for the user "user1" does not exist in the wallet'
);
console.log("Run the registerUser.js application before retrying");
return;
}

// Create a new gateway for connecting to our peer node.
const gateway = new Gateway();
await gateway.connect(ccp, {
wallet,
identity: "TharinduSA",
discovery: { enabled: false }
});

// Get the network (channel) our contract is deployed to.
const network = await gateway.getNetwork("mychannel");
// console.log(network);

// Get the contract from the network.
const contract = network.getContract("fabcar");
// console.log(contract);

// Submit the specified transaction.
// createCar transaction - requires 5 argument, ex: ('createCar', 'CAR12', 'Honda', 'Accord', 'Black', 'Tom')
// changeCarOwner transaction - requires 2 args , ex: ('changeCarOwner', 'CAR10', 'Dave')
await contract.submitTransaction(
"createCar",
"CAR12",
"Honda",
"Accord",
"Black",
"Tom"
);
console.log("Transaction has been submitted");

// Disconnect from the gateway.
await gateway.disconnect();
} catch (error) {
console.error(`Failed to submit transaction: ${error}`);
process.exit(1);
}
}

main();

 

I tried to figure it out. But I was unable to find any solution for this Issue if you can give me any solution to this problem It would be grateful for me. Thank you!