Asset With Multi Issuance Listing Pattern Error/Bug

+2 votes

This is related to the multiple issuance of an asset in Multichain.  I have faced the issue multiple times where in the nodes wallets failed to respond after a particular state of the system. It took me some time to pin point the issue. Once the issue is reached, the multichain nodes fails to respond and goes to hang state which doesn't get solved using reindex=1 as well. 

If an asset is issued with open as true. If the asset is issued 6 -7 times further and the command listassets assetname is executed, wallet hangs. The pattern remain same if the address balances is fetched. I have multiple chains with the issue. If required I can share the data.

The issue is not related to the number of assets in the chain but the number of times any asset is reissued. I have tested creation of 600-700 assets and listing them successfully. The issue can be reproduced by the following process:

  1. Create a new chain
  2. Issue an asset to the origin address
  3. Wait for the asset to get confirmed by checking for the asset reference name in listassets assetname
  4. Execute listasset assetname true
  5. Reissue the asset 
  6. Execute listassets assetname true/false or listassets or listassets '' true
  7. Repeat 5 and 6 till the commands fails to respond.
One the system hangs. We can kill the process and restart multichain. The getinfo commands work, the moment commands like gettotalbalances or listassets is executed, it will go to hang state. I think the issue is related to fixed memory size allocation in the code programme.
 
Let me know if you require more info.

 

asked Aug 9, 2016 by 7sigma
What version are you on?
"version" : "1.0 alpha 23",
    "protocolversion" : 10005,
    "walletversion" : 60000,
    "walletdbversion" : 2
How ever I have seen the issues in the previous versions as well. The json data which I am putting while re issuance of assets is (for reference):
//        JSONObject js = new JSONObject();
//        js.put("a", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
//        js.put("b", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
//        js.put("c", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
//        js.put("d", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
//        js.put("e", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
//        js.put("f", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
//        js.put("g", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
//        js.put("h", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
//        js.put("i", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa|aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
Please find the link to steps:
https://krypc-my.sharepoint.com/personal/mohit_krypc_com/_layouts/15/guestaccess.aspx?guestaccesstoken=WlHZnKeq%2bl%2fKPKE6xPOKZBPVH5Tm3IOM%2bTdEwi4a1WE%3d&docid=17696dab52fcc42cda786de53ff523f47&rev=1

This time I am not having hanging issue but 'error: no response from server'.
I think I executed commands faster, I will perform another simulation wherein I would be able to show the hang issue. Will share another link in some time. Sorry for the delay.

2 Answers

0 votes
 
Best answer
We've found the bug - thank you. It happens if there are more than 2 follow-on asset issuances with details longer that 70 bytes in the same block. We'e already fixed it internally - let us know if you need access to a fixed version now, or if it's OK to wait until alpha 24 (scheduled for September).
answered Aug 14, 2016 by MultiChain
selected Aug 16, 2016 by 7sigma
I would like to have access to the early release. Please let me know how can I get it.
We've made it available at http://www.multichain.com/download/multichain-1.0-alpha-23.1.tar.gz - please note this is an unofficial release.
0 votes
Unfortunately I cannot reproduce it. This is my command sequence:

2. Issue new asset

~/bin/multichain-1.0-alpha-23/multichain-cli net8 issue 1Gx2FLfzfmqjWQ1cwg4v7akTF7PxAJQQafsrsV '{"name":"asset03","open":true}' 1000000

3. Wait for asset to be confirmed

~/bin/multichain-1.0-alpha-23/multichain-cli net8 listassets asset03 true

5. Issue more units of the asset:

~/bin/multichain-1.0-alpha-23/multichain-cli net8 issuemore 1Gx2FLfzfmqjWQ1cwg4v7akTF7PxAJQQafsrsV asset03 1000

6. Check listassets:

~/bin/multichain-1.0-alpha-23/multichain-cli net8 listassets asset03 true

7. Repeat 5 and 6 100 times

This is the output of listassets after 7 (works fine):

[
    {
        "name" : "asset03",
        "issuetxid" : "ba45cb746ef2605d5d554ad3dfc7cd374d9305a9ebcb67332a708cfcaf9598c9",
        "assetref" : "13-264-17850",
        "multiple" : 1,
        "units" : 1.00000000,
        "open" : true,
        "details" : {
        },
        "issueqty" : 1100000.00000000,
        "issueraw" : 1100000
    }
]

 

 

Can you please post your sequence of commands? Then we can try to understand what is different.
answered Aug 11, 2016 by Michael
Please find the link to steps:
https://krypc-my.sharepoint.com/personal/mohit_krypc_com/_layouts/15/guestaccess.aspx?guestaccesstoken=WlHZnKeq%2bl%2fKPKE6xPOKZBPVH5Tm3IOM%2bTdEwi4a1WE%3d&docid=17696dab52fcc42cda786de53ff523f47&rev=1

This time I am not having hanging issue but 'error: no response from server'.
I think I executed commands faster, I will perform another simulation wherein I would be able to show the hang issue. Will share another link in some time. Sorry for the delay.
Thanks. Once you can reproduce the issue please zip up the blockchain directory on an affected node and send it to multichain.debug@gmail.com, so we can take a look.
Thanks so much for the support and guidance. I have reproduce the issue. Have emailed the zipped version of the blockchain and as well sent command sequence screen shots in a word document in odt format. Let me know if you need more info.
Thanks - we got it and will get back to you ASAP.
...