Date   

Re: Customize chaincode docker image

Brett T Logan <brett.t.logan@...>
 

Part of the chaincode instantiation process is to compile the JAR, this isn't something you can hijack in 1.4.x without modifying the source code. Fabric v2.0 (which released last week) provides a framework for configuring and running chaincode however you want: https://hyperledger-fabric.readthedocs.io/en/master/cc_launcher.html
 
And, if you want to debug your chaincode containers you can forward their standard output to the peer container where you can grep the log for the chaincodes output. You can enable this by setting CORE_VM_DOCKER_ATTACHSTDOUT=true in your peer launch environment, but note, this is not meant for production purposes as it can leak sensitive information into the peer logs from broken or malicious code.
 
Brett Logan
Software Engineer, IBM Blockchain
Phone: 1-984-242-6890
 
 
 

----- Original message -----
From: sanjaykumar3989@...
Sent by: fabric@...
To: fabric@...
Cc:
Subject: [EXTERNAL] Re: [Hyperledger Fabric] Customize chaincode docker image
Date: Mon, Feb 3, 2020 6:47 PM
 
Hi,

Every time when i initiate the chaincode , it take time to build the jar. To skip this process for multiple times and to learn the flow of hyperledger CC flow, i am customizing the image.

Usually capturing the docker logs of the chaincode really helps in cases like this. - CC container get killed automatically. Is there is some way how i can capture the logs?
 


Re: Customize chaincode docker image

sanjaykumar3989@...
 

Hi,

Every time when i initiate the chaincode , it take time to build the jar. To skip this process for multiple times and to learn the flow of hyperledger CC flow, i am customizing the image.

Usually capturing the docker logs of the chaincode really helps in cases like this. - CC container get killed automatically. Is there is some way how i can capture the logs?


Re: Potential project in need of BFT orderers #consensus #fabric-orderer

Brian Behlendorf <bbehlendorf@...>
 

You really should use a different status for deferred feature requests than "Closed", because "decided not to implement this ever" is a closer inference from "Closed" than "maybe someday".  Jira is depended upon as a future-feature-request tool by lots of other projects and asking people to know it's differently treated at Fabric is another cognitive burden to new contributors.  At the very least I suggest updating FAB-33 with a link to new work.

Brian

On 2/3/20 7:44 AM, Jason Yellick wrote:
I've seen some similar confusion to this on Rocketchat as well.

FAB-33 was closed along with hundreds of other items in an overall cleanup of JIRA.  Its closure does not indicate any mothballing or abandonment of BFT efforts, in fact, there's been considerably more activity in the space in the recent months; particularly there are some ongoing efforts to develop a golang BFT consensus library that is compatible with Fabric.

JIRA can be a good tool for tracking the progress of a designed, approved, and mid-implementation item, but it's the wrong place to look for future work.  Future work is to be submitted and approved as an RFC https://github.com/hyperledger/fabric-rfcs/ so I would watch that space for updates.

Thanks,
~Jason
 
----- Original message -----
From: atom@...
Sent by: fabric@...
To: fabric@...
Cc:
Subject: [EXTERNAL] [Hyperledger Fabric] Potential project in need of BFT orderers #consensus #fabric-orderer
Date: Sun, Feb 2, 2020 6:16 PM
 

We are leading a standardization effort within SunSpec.org to utilize blockchain for securing the distributed power grid in the US.

https://sunspec.org/sunspec-alliance-advances-security-for-distributed-energy-resource-systems/

Fabric could be a good candidate for this effort but we need BFT in the orderer nodes.  It looks like this effort has been mothballed to an extent:

https://jira.hyperledger.org/browse/FAB-33

What are the options for revitalizing this effort?

Thanks,
Alfred
Wivity Inc.

 


-- 
Brian Behlendorf
Executive Director, Hyperledger
bbehlendorf@...
Twitter: @brianbehlendorf


Re: Potential project in need of BFT orderers #consensus #fabric-orderer

Jason Yellick <jyellick@...>
 

I've seen some similar confusion to this on Rocketchat as well.

FAB-33 was closed along with hundreds of other items in an overall cleanup of JIRA.  Its closure does not indicate any mothballing or abandonment of BFT efforts, in fact, there's been considerably more activity in the space in the recent months; particularly there are some ongoing efforts to develop a golang BFT consensus library that is compatible with Fabric.

JIRA can be a good tool for tracking the progress of a designed, approved, and mid-implementation item, but it's the wrong place to look for future work.  Future work is to be submitted and approved as an RFC https://github.com/hyperledger/fabric-rfcs/ so I would watch that space for updates.

Thanks,
~Jason
 

----- Original message -----
From: atom@...
Sent by: fabric@...
To: fabric@...
Cc:
Subject: [EXTERNAL] [Hyperledger Fabric] Potential project in need of BFT orderers #consensus #fabric-orderer
Date: Sun, Feb 2, 2020 6:16 PM
 

We are leading a standardization effort within SunSpec.org to utilize blockchain for securing the distributed power grid in the US.

https://sunspec.org/sunspec-alliance-advances-security-for-distributed-energy-resource-systems/

Fabric could be a good candidate for this effort but we need BFT in the orderer nodes.  It looks like this effort has been mothballed to an extent:

https://jira.hyperledger.org/browse/FAB-33

What are the options for revitalizing this effort?

Thanks,
Alfred
Wivity Inc.

 


Re: Private data : issues and problems #fabric #fabric-questions #fabric-dstorage

Yacov
 

> because the actual data is unknown to verifiers/endorsers

Well but you can have the endorsement policy be satisfied by a set of members that they are all in the collection policy.
Furthermore you can also have a custom endorsement policy for each collection.



From:        "Ivan Ch" <acizlan@...>
To:        fabric@...
Date:        02/03/2020 01:32 PM
Subject:        [EXTERNAL] Re: [Hyperledger Fabric] Private data : issues and problems #fabric #fabric-questions #fabric-dstorage
Sent by:        fabric@...




I apologize for restarting this old topic, someone sent me a private message so I think the least I can do is to make the problem clear


On Wed, Dec 11, 2019 at 06:51 PM, Gari Singh wrote:
1) hashes on chain cannot be validated by any third party, so they can be used by adversaries to trick honest participants

How does this trick honest participants? When you deploy chaincode, you specify an endorsement policy. Transactions which dod not meet the endorsement policy will be marked as invalid. You need to take a look at the overall transaction flow in Fabric: https://hyperledger-fabric.readthedocs.io/en/release-1.4/txflow.html.
The validation rules for Fabric include:
- check to make sure the block is valid and that it was obtained from the correct orderer as specified in the channel definition
- check to make sure the submitter was allowed to actually submit the transaction (e.g. is allowed to write to the chaincode)
- check that the transaction meets the endorsement policy for the chaincode that was invoked
- perform MVCC check

In the case of private data, the steps are the same. If you are not a member of the collection, even though you do not have the actual data you still follow all of the rules above to validate the transaction (including the MVCC check). Not sure how someone can "trick" anyone if you have a strong endorsement policy (e.g. majority, etc).

This is no different than how private transactions work in Quorum, Besu or even Corda if you choose not to have the notary execute transactions.

The problem is that all the checks you mentioned above are checking something non-verifiable and therefore cannot be used to validate any business logic at all!!! because the actual data is unknown to verifiers/endorsers (who cares about endorsement policy if the endorser doesn't know whatever the heck he is endorsing. block, MVCC, and even transaction sender identity checks got nothing to do with the actual business logic).

of course if the data is in clear text than it would work, because then the endorsers would run the logic inside the chaincode to verify the business logic associated with the transactions being endorsed. Quorum has a host of problems but at least they are exploring crypto/ZKP options like the PoC they did with JPMorgan (to be fair, that was only a PoC, but at least it was a good attempt that fabric's been lacking).

the bottom line is Private data feature does not solve the data privacy problem (or any problem to be honest) but it is given a name and making people believe it does. this is unfortunate because fabric's endorsement architecture is actually a much better platform than anything ethereum to run ZKP cryptos.






Re: Private data : issues and problems #fabric #fabric-questions #fabric-dstorage

Ivan Ch <acizlan@...>
 

I apologize for restarting this old topic, someone sent me a private message so I think the least I can do is to make the problem clear


On Wed, Dec 11, 2019 at 06:51 PM, Gari Singh wrote:
1) hashes on chain cannot be validated by any third party, so they can be used by adversaries to trick honest participants

How does this trick honest participants? When you deploy chaincode, you specify an endorsement policy. Transactions which dod not meet the endorsement policy will be marked as invalid. You need to take a look at the overall transaction flow in Fabric: https://hyperledger-fabric.readthedocs.io/en/release-1.4/txflow.html.
The validation rules for Fabric include:
- check to make sure the block is valid and that it was obtained from the correct orderer as specified in the channel definition
- check to make sure the submitter was allowed to actually submit the transaction (e.g. is allowed to write to the chaincode)
- check that the transaction meets the endorsement policy for the chaincode that was invoked
- perform MVCC check

In the case of private data, the steps are the same. If you are not a member of the collection, even though you do not have the actual data you still follow all of the rules above to validate the transaction (including the MVCC check). Not sure how someone can "trick" anyone if you have a strong endorsement policy (e.g. majority, etc).

This is no different than how private transactions work in Quorum, Besu or even Corda if you choose not to have the notary execute transactions.

The problem is that all the checks you mentioned above are checking something non-verifiable and therefore cannot be used to validate any business logic at all!!! because the actual data is unknown to verifiers/endorsers (who cares about endorsement policy if the endorser doesn't know whatever the heck he is endorsing. block, MVCC, and even transaction sender identity checks got nothing to do with the actual business logic).

of course if the data is in clear text than it would work, because then the endorsers would run the logic inside the chaincode to verify the business logic associated with the transactions being endorsed. Quorum has a host of problems but at least they are exploring crypto/ZKP options like the PoC they did with JPMorgan (to be fair, that was only a PoC, but at least it was a good attempt that fabric's been lacking). 

the bottom line is Private data feature does not solve the data privacy problem (or any problem to be honest) but it is given a name and making people believe it does. this is unfortunate because fabric's endorsement architecture is actually a much better platform than anything ethereum to run ZKP cryptos.



Next Hyperledger Fabric Application Developer Community call - this Thursday, Feb 6th @ 4pm UTC (4pm UK) - 11am ET, 8am PT

Paul O'Mahoney <mahoney@...>
 

dear Fabric Application Developer,


the next  Fabric Application Developer community call is scheduled for this  Thursday Feb 6th @ 4pm UTC (4pm UK) - 11am ET (-5 hrs), 8am PT(-8 hrs) - see time zones.   It lasts approx 30-60 mins FYI.

The agenda will be posted here -> https://wiki.hyperledger.org/display/fabric/Meeting+Agendas%3A+Fabric+Application+Developer+Community+Call

This community call is held bi-weekly via Zoom webconference and is aimed at :

- helping the worldwide Hyperledger Fabric Application Developer community grow (eg. developing applications, smart contracts,  developing application clients, using the SDKs, tutorials/demos etc -  NodeJS/TypeScript, Java, Go etc etc) 
- helping App developers understand / hear more about exciting new things in Fabric, eg. features upcoming or work in progress - ie things that appeal to the developer
- foster more interest, best practices etc in developing applications (eg developing solutions, use cases) with Hyperledger Fabric. 
- opportunity to ask questions of the Fabric team eg. you may have feedback/questions on your experiences developing solutions with Fabric
- to share stuff you've done with the community, eg sample code / sample use cases that others may be interested in

If you wish to share content on a call, just let me know via email direct or DM me on Rocketchat (ID: mahoney1) and I'll put an item on the agenda. Provide the following:
- the topic (state whether its presentation, or demo etc)
- the full name of the presenter, and 
- approx length of your pitch in minutes


The Zoom webconference ID is https://zoom.us/my/hyperledger.community   

More information can be found on the community page -> https://wiki.hyperledger.org/display/fabric/Fabric+Application+Developer+Community+Calls

You can get calendar invites (eg iCal) here

many thanks for your time - feel free to forward this email if you think it is of interest to a colleague.

Paul O'Mahony
Community Lead - Hyperledger Fabric Developer Community
RocketChat:  mahoney1

mahoney@...

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


User registration in Fabric go sdk #fabric-sdk-go

Amal C Saji
 

Hi,
How to register and enroll a user in fabric sdk go? The Register function is found at /pkg/client/msp/client.go file. I am confused with how this function is invoked? Is there any reference documentation for user registration  and enrollment?


Potential project in need of BFT orderers #consensus #fabric-orderer

atom@...
 

We are leading a standardization effort within SunSpec.org to utilize blockchain for securing the distributed power grid in the US.

https://sunspec.org/sunspec-alliance-advances-security-for-distributed-energy-resource-systems/

Fabric could be a good candidate for this effort but we need BFT in the orderer nodes.  It looks like this effort has been mothballed to an extent:

https://jira.hyperledger.org/browse/FAB-33

What are the options for revitalizing this effort?

Thanks,
Alfred
Wivity Inc.


Error when joining the channel

Marina Wanis <marinamaged1996@...>
 

Hi,

 

I used to be able to create the channel using the channel transaction and join the channel with the command :

peer channel join -o localhost:7050 -b ./acmechannel.block

 

I got the following error:

 

2020-02-01 09:24:48.338 UTC [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized

Error: proposal failed (err: rpc error: code = Unknown desc = access denied: channel [] creator org [Org1MSP])

 

I made sure that the identity of the peer is admin. I’m really not sure why I keep getting this error.

Thank you,

Marina

 

Sent from Mail for Windows 10

 


Hyperledger Fabric Documentation Workgroup call - Western hemisphere - Fri, 01/31/2020 #cal-notice

fabric@lists.hyperledger.org Calendar <noreply@...>
 

Hyperledger Fabric Documentation Workgroup call - Western hemisphere

When:
Friday, 31 January 2020
4:00pm to 5:00pm
(GMT+00:00) Europe/London

Where:
https://zoom.us/j/6223336701

Organizer:
a_o-dowd@... +441962816761

Description:
Documentation workgroup call.
Agenda, minutes and recordings :https://wiki.hyperledger.org/display/fabric/Documentation+Working+Group


Hyperledger Fabric Documentation Workgroup call - Eastern hemisphere - Fri, 01/31/2020 #cal-notice

fabric@lists.hyperledger.org Calendar <noreply@...>
 

Hyperledger Fabric Documentation Workgroup call - Eastern hemisphere

When:
Friday, 31 January 2020
6:00am to 7:00am
(GMT+00:00) Europe/London

Where:
https://zoom.us/j/6223336701

Organizer:
a_o-dowd@... +441962816761

Description:
Documentation workgroup call.
Agenda, minutes and recordings: https://wiki.hyperledger.org/display/fabric/Documentation+Working+Group


Documentation Workgroup: Agenda for Friday, 31 Jan

Anthony O'Dowd <a_o-dowd@...>
 

Hello!

We will hold the documentation workgroup call this Friday, both Western and Eastern hemispheres.  Thanks to everyone who attended last week's call.
The summary minutes for last week's meeting: https://wiki.hyperledger.org/display/fabric/Meetings

You can read all about the call at https://wiki.hyperledger.org/display/fabric/2020+01+24+DWG+Agenda It included a V2 status update from Pam and Joe, an overview of the new Test network from Nik, and deployment guide from Pam. You can catch up via the recording: https://wiki.hyperledger.org/display/fabric/Recordings

You'll see that there are lots of interesting items for this week: https://wiki.hyperledger.org/display/fabric/2020+01+31+DWG+Agenda
Please feel free to contribute using the wiki.

You can also help build next week's agenda: https://wiki.hyperledger.org/display/fabric/2020+02+07+DWG+Agenda

Thanks!

Pam, Anthony,  Joe, Nik

Meeting Details
-------------
Please use the following link to attend the meeting:  https://zoom.us/j/6223336701

The meeting times are as follows: https://wiki.hyperledger.org/display/fabric/Documentation+Working+Group

Meeting 113A: Friday 31 Jan
                   1130 India Standard Time
                   1400 China Standard Time
                   1500 Japan Standard Time
                   1700 Australia Eastern Time
                   1400 Singapore Time
                   1000 Gulf Standard Time
                   0900 Moscow Standard Time
                   0600 Greenwich Mean Time
                   0700 Central European Time    

Meeting 113B: Friday 31 Jan
              1000 Central Daylight Time
                   1100 Eastern Daylight Time
                   0800 Pacific Daylight Time
                   1300 Brasil Time (BRT)
                   1600 Greenwich Mean Time
                   1700 Central European Time
                   1800 Moscow Standard Time
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: anyone able to iterate over records using getStateByRange?

Siddharth Jain
 

its the same code that we tried and it does not work even with the MAX_UNICODE_RUNE_VALUE key. we have filed a bug here



From: Matthew White <WHITEMAT@...>
Sent: Thursday, January 30, 2020 12:26 AM
To: siddjain@... <siddjain@...>
Cc: fabric@... <fabric@...>
Subject: Re: [Hyperledger Fabric] anyone able to iterate over records using getStateByRange?
 
Hello;
 
 
Will need to double check, but as a workaround for an unbounded range try this as the end key
 
const MAX_UNICODE_RUNE_VALUE = '\u{10ffff}';
 
Though such an unbounded range could potentially give you a lot data; worth looking at the pagination variants especially if there's any doubt about the size of data that might come back 
 
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"
 
 
 
----- Original message -----
From: "Siddharth Jain" <siddjain@...>
Sent by: fabric@...
To: "fabric@..." <fabric@...>
Cc:
Subject: [EXTERNAL] [Hyperledger Fabric] anyone able to iterate over records using getStateByRange?
Date: Wed, Jan 29, 2020 9:24 PM
 
this method:
 
Note that startKey and endKey can be empty string, which implies unbounded range query on start or end.
 
is supposed to enable enumerating records in the database but when we tried it, it did not work. e.g.:
 
public async getAssets(ctx: Context): Promise<Asset[]> {
        const assets: Asset[] = [];
        const results = await ctx.stub.getStateByRange('', '');
        while (true) {
            let item = await results.next();
            if (item.done) {
                break;
            } else {
                let buffer = item.value.getValue();
                let asset = JSON.parse(buffer.buffer.toString()) as Asset;     // buffer.buffer returns many records not just once and the JSON.parse will fail           
                assets.push(asset);                
            }
        }
        await results.close();
        return assets;
    }
 
buffer.toString()
"ByteBufferNB(offset=22,markedOffset=-1,limit=386,capacity=1981)"
 
buffer.buffer.toString()
"
�
�
mycc00000�{"createdBy":"","id":"00000","lastModifiedBy":"","metadata":"","owner":"org2MSP"}
�
�
mycc00001�{"createdBy":"","id":"00001","lastModifiedBy":"","metadata":"","owner":"org1MSP"}
�
�
mycc00002�{"createdBy":"","id":"00002","lastModifiedBy":"","metadata":"","owner":"org1MSP"}
�
�
mycc00003�{"createdBy":"","id":"00003","lastModifiedBy":"","metadata":"","owner":"org1MSP"}
�
�
mycc00004�{"createdBy":"","id":"00004","lastModifiedBy":"","metadata":"","owner":"org1MSP"}$efc8d188-16ae-41e8-a024-7880a8d0bf31"
 
 
JSON.parse(buffer.buffer.toString())
SyntaxError: Unexpected token � in JSON at position 1
 
buffer.buffer.buffer.toString()
"[object ArrayBuffer]"
has anyone been able to use this method successfully?
 
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


Hyperledger DCI Survey

Gari Singh <garis@...>
 

At Hyperledger, "All are welcome here!" Having a community that has a culture of encouraging people to voice their diverse opinions is crucial for the long term success of the project.

Today we are launching a survey ( https://www.surveymonkey.com/r/DCIWGsurvey ) to help us understand our community better.

We need to hear from you. Whether you are a frequent or occasional contributor, past or present we want to know more about you and your experiences here at Hyperledger.

Diversity, Civility, and Inclusion can cover many different community health issues. The DCI Working Group will be using this data to help guide our efforts over the coming year. We plan to release results from the survey at the Hyperledger Global Forum March 3-6.

Thanks for taking this survey. This one simple action is an important contribution you make to continue building a healthy open source community.

https://www.surveymonkey.com/r/DCIWGsurvey

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


ANNOUNCEMENT: Hyperledger Fabric v2.0 is now available!

David Enyeart
 

The Hyperledger Fabric maintainers are pleased to announce the availability of Fabric v2.0!

Given this important milestone, Baohua Yang and I have written a blog to reflect on the evolution of Fabric and the significance of the new release:
https://www.hyperledger.org/blog/2020/01/30/welcome-hyperledger-fabric-2-0:-enterprise-dlt-for-production

As always, you can find additional details of release content in the What’s New documentation:
https://hyperledger-fabric.readthedocs.io/en/release-2.0/whatsnew.html

Information about Fabric changes and upgrade considerations can be found in the release notes:
https://github.com/hyperledger/fabric/releases/tag/v2.0.0

Download Hyperledger Fabric v2.0 today and give the new test network in the fabric-samples repository a try:
https://hyperledger-fabric.readthedocs.io/en/release-2.0/install.html

Concerning Fabric CA server, while the Fabric CA server remains a preferred and tested certificate authority for Hyperledger Fabric, a new major release of Fabric CA will not be released at this time, since none of the new Fabric features required Fabric CA changes. Fabric CA will remain at v1.4.x for the time being.

Thank you to everybody in the community that helped to make the Fabric v2.0 release possible!

The Hyperledger Fabric maintainers


Re: Peer communication during chaincode execution

Yacov
 

Look at my last commits from https://github.com/yacovm/fabric2/commits/p2p

There is a sample that uses this API to performa secure summation



From:        "Kimheng SOK" <sok.kimheng@...>
To:        Yacov Manevich <YACOVM@...>
Cc:        fabric@..., hyperledger-fabric@...
Date:        01/30/2020 09:22 AM
Subject:        [EXTERNAL] Re: [Hyperledger Fabric] Peer communication during chaincode execution
Sent by:        fabric@...




Hi,

Could you show me more about those two new APIs, and where can I find all the related files related to Gossip protocol and Chaincode Shim API, 
I would love to learn and may be have time to customize those methods too.
It is good to deep dive into the protocol level as a hyperleder developer, as now I am only a fresh hyperledger user.

Bests,


On Thu, Jan 30, 2020 at 8:17 AM Yacov Manevich <YACOVM@...> wrote:
Unfortunately Fabric doesn't have this feature yet... you can comment in the JIRA that it's needed for you, but I am skeptic that we'll have this feature anytime soon

If you are willing to use your own Fabric build with custom modifications, I can point you to a PoC that adds 2 methods to the chaincode shim API:


        P2PSend(payload []byte, to ... string)
        P2PRecv() (payload []byte, from string)


However, this PoC is experimental.




From:        
"Kimheng SOK" <sok.kimheng@...>
To:        
Yacov Manevich <YACOVM@...>
Cc:        
hyperledger-fabric@...
Date:        
01/30/2020 02:55 AM
Subject:        
[EXTERNAL] Re: [Hyperledger Fabric] Peer communication during chaincode execution
Sent by:        
fabric@...




Hi,

My usecase is chaincode need to call external program, in the case of multiple peers, each peer could produce non-deterministic result and the invoke function will return Error: Could not assemble transaction. So all peers need to communicate with each other about the result and compute deterministic result so that the error will not happen. 

This feature could open the possibility to avoid all peers just passively receiving the deterministic result from a client or central entity.
For sure the computation time will increase, because the more peers we have, the more communication need to be done just like gossip protocol. So it is a trade-off .
The good news is hyperledger is a permission blockchain, so the number of peers is limited depend on the use case, so some applications could be useful to have this feature.

Bests,


On Thu, Jan 30, 2020 at 6:14 AM Yacov Manevich <YACOVM@...> wrote:
See
https://jira.hyperledger.org/browse/FAB-11980

May I ask why do you need it? what's your use case?




From:        
"Kimheng SOK" <sok.kimheng@...>
To:        
hyperledger-fabric@...
Date:        
01/29/2020 11:57 PM
Subject:        
[EXTERNAL] [Hyperledger Fabric] Peer communication during chaincode execution
Sent by:        
fabric@...




Dear all,

I wonder is it possible for peers to pass message to each other on the channel during the chaincode execution in the context of chaincode developer level not the protocol level? Or we need to modify the gossip protocol it self.

Appreciate for answering the question.








Re: Customize chaincode docker image

Matthew White
 

Hello - my best guess would be that the chaincode is failing to call back to the peer to 'register'. 
 
Usually capturing the docker logs of the chaincode really helps in cases like this. 
 
Can I ask what your requirement is to customize the docker image? Just curious!
 
 
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"
 
 
 
----- Original message -----
From: sanjaykumar3989@...
Sent by: fabric@...
To: fabric@...
Cc:
Subject: [EXTERNAL] Re: [Hyperledger Fabric] Customize chaincode docker image
Date: Thu, Jan 30, 2020 5:46 AM
 
Hi,

I have created the customized image from hyperledger/fabric-javaenv:amd64-1.4.4. and used as CORE_CHAINCODE_JAVA_RUNTIME=sanjaykumar3989/myenv:amd64-1.4.4.

In this new image i am replacing build.sh and start file in location  /root/chaincode-java/. 
The build.sh is running successfully as my jar is building but after that it exit with below msg:
Error: could not assemble transaction, err proposal response was not successful, error code 500, msg chaincode registration failed: container exited with 1
 
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: anyone able to iterate over records using getStateByRange?

Matthew White
 

Hello;
 
 
Will need to double check, but as a workaround for an unbounded range try this as the end key
 
const MAX_UNICODE_RUNE_VALUE = '\u{10ffff}';
 
Though such an unbounded range could potentially give you a lot data; worth looking at the pagination variants especially if there's any doubt about the size of data that might come back 
 
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"
 
 
 
----- Original message -----
From: "Siddharth Jain" <siddjain@...>
Sent by: fabric@...
To: "fabric@..." <fabric@...>
Cc:
Subject: [EXTERNAL] [Hyperledger Fabric] anyone able to iterate over records using getStateByRange?
Date: Wed, Jan 29, 2020 9:24 PM
 
this method:
 
Note that startKey and endKey can be empty string, which implies unbounded range query on start or end.
 
is supposed to enable enumerating records in the database but when we tried it, it did not work. e.g.:
 
public async getAssets(ctx: Context): Promise<Asset[]> {
        const assets: Asset[] = [];
        const results = await ctx.stub.getStateByRange('', '');
        while (true) {
            let item = await results.next();
            if (item.done) {
                break;
            } else {
                let buffer = item.value.getValue();
                let asset = JSON.parse(buffer.buffer.toString()) as Asset;     // buffer.buffer returns many records not just once and the JSON.parse will fail           
                assets.push(asset);                
            }
        }
        await results.close();
        return assets;
    }
 
buffer.toString()
"ByteBufferNB(offset=22,markedOffset=-1,limit=386,capacity=1981)"
 
buffer.buffer.toString()
"
�
�
mycc00000�{"createdBy":"","id":"00000","lastModifiedBy":"","metadata":"","owner":"org2MSP"}
�
�
mycc00001�{"createdBy":"","id":"00001","lastModifiedBy":"","metadata":"","owner":"org1MSP"}
�
�
mycc00002�{"createdBy":"","id":"00002","lastModifiedBy":"","metadata":"","owner":"org1MSP"}
�
�
mycc00003�{"createdBy":"","id":"00003","lastModifiedBy":"","metadata":"","owner":"org1MSP"}
�
�
mycc00004�{"createdBy":"","id":"00004","lastModifiedBy":"","metadata":"","owner":"org1MSP"}$efc8d188-16ae-41e8-a024-7880a8d0bf31"
 
 
JSON.parse(buffer.buffer.toString())
SyntaxError: Unexpected token � in JSON at position 1
 
buffer.buffer.buffer.toString()
"[object ArrayBuffer]"
has anyone been able to use this method successfully?
 
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


Error when I start the peer node

Marina Wanis <marinamaged1996@...>
 

Hi,

 

Does any one know why am I getting the following error in the orderer logs, once I start the

Peer node?

 

 

Thank you,

Marina

 

 

 

Sent from Mail for Windows 10

 

3881 - 3900 of 11521