Data reporting
THIS PAGE IS WORK IN PROGRESS
Usage scenario
User A wants to transfer REV from their vault to B's vault.
This scenario is covered by the script Vault Demo
Concepts
The main focus of the above scenario is the ability to observe the 2 balances A's vault balance and B's vault balance after the transfer.
To be able to reason about the above scenario basic concepts need to be covered.
DeployId is the unique identifier which is produced as the result of "deploy" RNode API.
A block is a list of deploys.
A deploy can be added to multiple blocks (similar to mempool).
A block can be either finalized or not. Finalization has a certain fault tolerance which dictates how stable the DAG above the finalization point is.
With a reasonable fault tolerance, a finalized block containing a particular deploy can be considered certain.
A finalized deploy will be removed from the "mempool".
Implementation
Setup step requires the users interested in observing a particular transfer need to connect to a WebSocket endpoint {{/ws/events}}.
During deploy of the transfer contract the owner of the vault A will receive a DeployId D1.
D1 will be included in blocks created and added by validators in the network.
This can be observed in the events produced by {{/ws/events}}.
At some point, a block B1 containing D1 will be finalized.
The hash of B1 can be used to compute the execution trace of D1 by using {{/reporting/trace?blockHash=B1hash}}.
This trace needs to be parsed to find the balances of A's vault and B's vault.
Generalization
In general, it is possible to trace all the changes that are happening on the chain by tracking the DAG {{/ws/events}} and the traces in finalized blocks {{/reporting/trace}} in an automatic fashion. This requires:
A) storage - which is obvious
B) parsing - the ability to gain insight about the interesting parts (e.g. vault balance) of the data stored on the chain. This requires additional resources but can be done offline and post-fact.
One aspect that has been omitted in the above scenario is the ability to catch up to the state of the network. A newcomer wants to be able to trace vault balances of all the users but is able to observe only the addition of new blocks via {{/ws/events}}. This concern is covered by "catch-up".
ws/events
WebSocket endpoint which returns a live view of RNode.
Events:
https://github.com/rchain/rchain/blob/dev/shared/src/main/scala/coop/rchain/shared/RChainEvent.scala
reporting/trace
The endpoint accepts the hash of a given block and returns a list of deploy traces.
https://github.com/rchain/rchain/pull/2725/files#diff-f4ada6511b299a079f29f72754e5c0c9R91-R141
PoC
network
The network consists of two validators (standalone bootstrap and connected).
04a66e6bb045d05ed87ab0662cd758c911d0ada8a573435eb644bf4e2220a954d8f10e98c40b4a408242a17c276afe473c5d65ad967384a3b597ea8045e01d2c2f 3 0462791f59a78c69c398c1901d47f079f65580fe2cbe71d9c42847bde7f609d701652afb7efe3d74d314a60a980ac61dc67c4927bff497a128ed731c6816f04383 1
wallets
7761944e1e8c53000fbb8a37fcac42850ec7acfe,10000,0 589991fc2c659528487c31d0f40e9cc8ad4f8dd1,10000,0 fed0bd59c86f48cea56e6cbbf76de7687be1bf18,10000,0 1563915e194d8cfba1943570603f7606a3115508,10000,0 405180553baf3a5e79e59f9b8b1ecc6a51b793a1,10000,0 cc39925ef672e7fb5f884d4ab99ac9aba9509c1d,10000,0 4dd6d184d28ec6ccd443e8047567e9aa9a04d31f,10000,0
read-only node
Additional ro node with --reporting
flag.
block explorer
https://github.com/dzajkowski/transfer-watchers
A simplistic application that tracks the chain.
setup
export A_ETH='589991fc2c659528487c31d0f40e9cc8ad4f8dd1' export A_PRV='0222222222222222222222222222222222222222222222222222222222222222' export A_PUB='04014c54e489355f6f303a22072cc0d47463e96c78b1761e39e0c41781294cace222f02adcda70bc0494365386bbd93c5b13d34333e42a762fc91bae766122b99f' export A_REV='11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk' export B_ETH='fed0bd59c86f48cea56e6cbbf76de7687be1bf18' export B_PRV='1222222222222222222222222222222222222222222222222222222222222222' export B_PUB='04ffac4572de30b3d4b97bcaacf5ee123e8e8a478c6a58ce110eb4281def531310cebae00cc0ed4181b5869830e20d927353c5c86b667f5cebb30c07e89f454b00' export B_REV='11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ' export C_ETH='1563915e194d8cfba1943570603f7606a3115508' export C_PRV='2222222222222222222222222222222222222222222222222222222222222222' export C_PUB='04466d7fcae563e5cb09a0d1870bb580344804617879a14949cf22285f1bae3f276728176c3c6431f8eeda4538dc37c865e2784f3a9e77d044f33e407797e1278a' export C_REV='1111yoPaoSxvmNRGDpP9GUGToHaCdUFEu3KdbNgTuyydUgg6cty7g' export D_ETH='405180553baf3a5e79e59f9b8b1ecc6a51b793a1' export D_PRV='3222222222222222222222222222222222222222222222222222222222222222' export D_PUB='04c983273b7508f5465a683ac86d420434cea6fad7fee7518579a2317a35959f3984fb7e057cb4acc30ec07288a8b7e4773d552ddc2d1fcab9b151c0b5f4c0357a' export D_REV='11112RX9D72VNteMD2fKDUHiypt7GXvMj3de2TsCZ5oaRCutCmxpq3' export E_ETH='cc39925ef672e7fb5f884d4ab99ac9aba9509c1d' export E_PRV='4222222222222222222222222222222222222222222222222222222222222222' export E_PUB='042ef883e017eabfa5ba41d4da6e9b78d2c3370eaf1d24c55e578b94449121fe0a96ec283f684e6b38b377164fdc12bc669d4d6314790a91716d703a7cf212bf42' export E_REV='11115XdeFp1nyeebwdKdRSQReJZykARGJMJp3DWk4RVsUHdBG8N8t' export F_ETH='4dd6d184d28ec6ccd443e8047567e9aa9a04d31f' export F_PRV='5222222222222222222222222222222222222222222222222222222222222222' export F_PUB='04dbe4a39abd05cbee578cdffec55a9bc12f4fb8e8a63fb26d67d561e3d60aba413cbbb4990f3e70d5752fce8076c7edd02913e9729ffb4c6c6a85e49ce749c3c1' export F_REV='1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS'
#!/usr/bin/env bash set -ex RNODE="../../node/target/universal/stage/bin/rnode" sed -e '' $3 $2 > $2.run $RNODE deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key $1 $2.run rm $2.run
14:28:18 in rchain/rholang/examples on rspace/reporting-rspace [$!?] λ ./propose2.sh $A_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$A_REV/" + RNODE='../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402' + sed -e '' -e s/%REV_ADDR/11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 0222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 30440220745d636318b04a6936b53ce5a89b6f19befe0e68a6245646bbbdf3783534ba0602201f984a468bcd51baf55729e35c6af0c95bb419eaa0c1db23427c7760848c589c + rm vault_demo/2.check_balance.rho.run 14:28:50 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ./propose2.sh $B_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$B_REV/" + RNODE='../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402' + sed -e '' -e s/%REV_ADDR/11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 1222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 3045022100d4b97a165bb502eeeeb09843ffcef71de625441d6acc1b7e9a529558c464c96f0220428661d9f026299c6616097e0c7d7c89fcdd3d827c5dff9ac048fad3f74d20e0 + rm vault_demo/2.check_balance.rho.run 14:29:08 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ./propose2.sh $C_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$C_REV/" + RNODE='../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402' + sed -e '' -e s/%REV_ADDR/1111yoPaoSxvmNRGDpP9GUGToHaCdUFEu3KdbNgTuyydUgg6cty7g/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 2222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 3045022100873e96fb0cf9c807e33c564f9a02c642052d0a6284d6888da50476b9fa102ea7022036967d5ef4cf9ef7e6b03debf6b6e5809c829ea13cbff7fc92915279814e0de2 + rm vault_demo/2.check_balance.rho.run 14:29:21 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ./propose2.sh $D_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$D_REV/" + RNODE='../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402' + sed -e '' -e s/%REV_ADDR/11112RX9D72VNteMD2fKDUHiypt7GXvMj3de2TsCZ5oaRCutCmxpq3/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 3222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 3045022100bc50767e5257f514386ce494286664d70a5b1e43d31497a32c31adc0204ad2ef02200ae9d2be738e1260c80c20411a9d9d4ada4fd685b1316f5b0c25868b113dc1cd + rm vault_demo/2.check_balance.rho.run 14:29:35 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ./propose2.sh $E_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$E_REV/" + RNODE='../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402' + sed -e '' -e s/%REV_ADDR/11115XdeFp1nyeebwdKdRSQReJZykARGJMJp3DWk4RVsUHdBG8N8t/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 4222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 3044022017152447a6132901c46553cda67ca4b3733e2a61949b43026d9ddb23bd3128ac02205ef6fc625fc2f35e9e9f8beed47567b03cfcc4cf3c7f74949a9bf4a49f8844eb + rm vault_demo/2.check_balance.rho.run 14:29:58 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ./propose2.sh $F_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$F_REV/" + RNODE='../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402' + sed -e '' -e s/%REV_ADDR/1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 5222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 304402207fcf607ccc999f1cf4aa29f0124b18e65152cfc28daa7f2f3d4e187a7c39047f0220207df65a478fa78d2726b2143311d1de0c7b26d24843974a9b1a9ad15123cde0 + rm vault_demo/2.check_balance.rho.run
../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 propose Response: Success! Block 258ca42e92e7c07b765391055aa68755b543f41e9a03b310b6e62975eca33e11 created and added.
"2.check_balance.rho" ("Accessing vault at RevAddress", "11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk") "Obtained vault, checking balance" ("Balance is", 10000) "2.check_balance.rho" ("Accessing vault at RevAddress", "1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS") "Obtained vault, checking balance" ("Balance is", 10000) "2.check_balance.rho" ("Accessing vault at RevAddress", "11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ") "Obtained vault, checking balance" ("Balance is", 10000) "2.check_balance.rho" ("Accessing vault at RevAddress", "11112RX9D72VNteMD2fKDUHiypt7GXvMj3de2TsCZ5oaRCutCmxpq3") "Obtained vault, checking balance" ("Balance is", 10000) "2.check_balance.rho" ("Accessing vault at RevAddress", "11115XdeFp1nyeebwdKdRSQReJZykARGJMJp3DWk4RVsUHdBG8N8t") "Obtained vault, checking balance" ("Balance is", 10000) "2.check_balance.rho" ("Accessing vault at RevAddress", "1111yoPaoSxvmNRGDpP9GUGToHaCdUFEu3KdbNgTuyydUgg6cty7g") "Obtained vault, checking balance" ("Balance is", 10000)
Post setup
scenarios
transfer 100 rev from A to B using validator 2
#!/usr/bin/env bash set -ex RNODE="../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402" sed -e '' $3 $2 > $2.run $RNODE deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key $1 $2.run rm $2.run
./propose2.sh $A_PRV vault_demo/3.transfer_funds.rho "-e s/%FROM/$A_REV/ -e s/%TO/$B_REV/" + RNODE='../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402' + sed -e '' -e s/%FROM/11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk/ -e s/%TO/11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ/ vault_demo/3.transfer_funds.rho + ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 0222222222222222222222222222222222222222222222222222222222222222 vault_demo/3.transfer_funds.rho.run Response: Success! DeployId is: 3045022100c71de638a91462f68844dd5764bc100a695664cf08d0a3e984d8319ce87153f602207925f24b321815620a1abc9c29069fef091384ef045cff0c92f018d5588c75e1 + rm vault_demo/3.transfer_funds.rho.run
../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 propose Response: Success! Block 29e050019cf80c45f30da4bc3176cdfc0867e864e2e65978a7594b9e5b196dd9 created and added.
"3.transfer_funds.rho" ("Beginning transfer of ", 100, "REV from", "11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk", "to", "11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ") ("Finished transfer of ", 100, "REV to", "11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ", "result was:", (true, Nil)) 14:33:50.814 [node-runner-139] INFO c.r.casper.MultiParentCasperImpl - Attempting to add Block 29e050019c... to DAG. 14:33:50.820 [node-runner-139] INFO c.r.c.util.rholang.InterpreterUtil$ - Computed parents post state for Block #2 (29e050019c...) -- Sender ID 0462791f59... -- M Parent Hash 258ca42e92... -- Contents 66d9b6b449...-- Shard ID rchain. "3.transfer_funds.rho" ("Beginning transfer of ", 100, "REV from", "11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk", "to", "11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ") ("Finished transfer of ", 100, "REV to", "11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ", "result was:", (true, Nil))
transfer 100 rev from B to C using validator 1, transfer 100 rev from C to D using validator 1, transfer 100 rev from D to E using validator 1, transfer 100 rev from E to F using validator 1, transfer 100 rev from F to A using validator 1, transfer 100 rev from A to B using validator 1
#!/usr/bin/env bash set -ex RNODE="../../node/target/universal/stage/bin/rnode" sed -e '' $3 $2 > $2.run $RNODE deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key $1 $2.run rm $2.run
./propose.sh $B_PRV vault_demo/3.transfer_funds.rho "-e s/%FROM/$B_REV/ -e s/%TO/$C_REV/"; ./propose.sh $C_PRV vault_demo/3.transfer_funds.rho "-e s/%FROM/$C_REV/ -e s/%TO/$D_REV/"; ./propose.sh $D_PRV vault_demo/3.transfer_funds.rho "-e s/%FROM/$D_REV/ -e s/%TO/$E_REV/"; ./propose.sh $E_PRV vault_demo/3.transfer_funds.rho "-e s/%FROM/$E_REV/ -e s/%TO/$F_REV/"; ./propose.sh $F_PRV vault_demo/3.transfer_funds.rho "-e s/%FROM/$F_REV/ -e s/%TO/$A_REV/"; + RNODE=../../node/target/universal/stage/bin/rnode + sed -e '' -e s/%FROM/11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ/ -e s/%TO/1111yoPaoSxvmNRGDpP9GUGToHaCdUFEu3KdbNgTuyydUgg6cty7g/ vault_demo/3.transfer_funds.rho + ../../node/target/universal/stage/bin/rnode deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 1222222222222222222222222222222222222222222222222222222222222222 vault_demo/3.transfer_funds.rho.run Response: Success! DeployId is: 30440220064ad29f6bf19471d4a5ebd779bf1f86357bbfd2486181f10a13062827ca592d022028220c93960a61d3cddc95e4bed370f716446180a52960fad5a126946c4f2e44 + rm vault_demo/3.transfer_funds.rho.run + RNODE=../../node/target/universal/stage/bin/rnode + sed -e '' -e s/%FROM/1111yoPaoSxvmNRGDpP9GUGToHaCdUFEu3KdbNgTuyydUgg6cty7g/ -e s/%TO/11112RX9D72VNteMD2fKDUHiypt7GXvMj3de2TsCZ5oaRCutCmxpq3/ vault_demo/3.transfer_funds.rho + ../../node/target/universal/stage/bin/rnode deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 2222222222222222222222222222222222222222222222222222222222222222 vault_demo/3.transfer_funds.rho.run Response: Success! DeployId is: 3045022100f85a0ff8c49b7c9c5ee42c470ea55034181be096f0547036e84801c9b198cd63022022219893aad97dfcec114c3df9f4b120a2b02f36dd73ce8f1817e0751844e829 + rm vault_demo/3.transfer_funds.rho.run + RNODE=../../node/target/universal/stage/bin/rnode + sed -e '' -e s/%FROM/11112RX9D72VNteMD2fKDUHiypt7GXvMj3de2TsCZ5oaRCutCmxpq3/ -e s/%TO/11115XdeFp1nyeebwdKdRSQReJZykARGJMJp3DWk4RVsUHdBG8N8t/ vault_demo/3.transfer_funds.rho + ../../node/target/universal/stage/bin/rnode deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 3222222222222222222222222222222222222222222222222222222222222222 vault_demo/3.transfer_funds.rho.run Response: Success! DeployId is: 304502210094bc5a48f2e68ee08ea963c299e1241469178c108bfcf5fcd9850ba65df65bb2022057ed1a4df01028aaf7f5afc22a186b9f3da723ba786f699b7e927deb8bf68e72 + rm vault_demo/3.transfer_funds.rho.run + RNODE=../../node/target/universal/stage/bin/rnode + sed -e '' -e s/%FROM/11115XdeFp1nyeebwdKdRSQReJZykARGJMJp3DWk4RVsUHdBG8N8t/ -e s/%TO/1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS/ vault_demo/3.transfer_funds.rho + ../../node/target/universal/stage/bin/rnode deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 4222222222222222222222222222222222222222222222222222222222222222 vault_demo/3.transfer_funds.rho.run Response: Success! DeployId is: 3045022100bfc13aefc396f9a5e7264e496a26a03879f3d2782a9d4d3e1f47f16f5e63272e02202657b28bf4aa689f0c292385c5f97f67a2cbe788e8385624f6bf349d2214aab8 + rm vault_demo/3.transfer_funds.rho.run + RNODE=../../node/target/universal/stage/bin/rnode + sed -e '' -e s/%FROM/1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS/ -e s/%TO/11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk/ vault_demo/3.transfer_funds.rho + ../../node/target/universal/stage/bin/rnode deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 5222222222222222222222222222222222222222222222222222222222222222 vault_demo/3.transfer_funds.rho.run Response: Success! DeployId is: 304402204302f2dd013aec169e3e9d7e009acee05640938e744fdd75683936b7839655be02202806d02d27fef0c96f65cbc99cec9e19e84e532c07364e1876a750fb64f05836 + rm vault_demo/3.transfer_funds.rho.run
"3.transfer_funds.rho" ("Beginning transfer of ", 100, "REV from", "11112w7Hh13CoK8aaPpit3v6vgof4v4NX2i3ieh4orUmwHqeQpsLtJ", "to", "1111yoPaoSxvmNRGDpP9GUGToHaCdUFEu3KdbNgTuyydUgg6cty7g") ("Finished transfer of ", 100, "REV to", "1111yoPaoSxvmNRGDpP9GUGToHaCdUFEu3KdbNgTuyydUgg6cty7g", "result was:", (true, Nil)) "3.transfer_funds.rho" ("Beginning transfer of ", 100, "REV from", "1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS", "to", "11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk") ("Finished transfer of ", 100, "REV to", "11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk", "result was:", (true, Nil)) "3.transfer_funds.rho" ("Beginning transfer of ", 100, "REV from", "1111yoPaoSxvmNRGDpP9GUGToHaCdUFEu3KdbNgTuyydUgg6cty7g", "to", "11112RX9D72VNteMD2fKDUHiypt7GXvMj3de2TsCZ5oaRCutCmxpq3") ("Finished transfer of ", 100, "REV to", "11112RX9D72VNteMD2fKDUHiypt7GXvMj3de2TsCZ5oaRCutCmxpq3", "result was:", (true, Nil)) "3.transfer_funds.rho" ("Beginning transfer of ", 100, "REV from", "11112RX9D72VNteMD2fKDUHiypt7GXvMj3de2TsCZ5oaRCutCmxpq3", "to", "11115XdeFp1nyeebwdKdRSQReJZykARGJMJp3DWk4RVsUHdBG8N8t") ("Finished transfer of ", 100, "REV to", "11115XdeFp1nyeebwdKdRSQReJZykARGJMJp3DWk4RVsUHdBG8N8t", "result was:", (true, Nil)) "3.transfer_funds.rho" ("Beginning transfer of ", 100, "REV from", "11115XdeFp1nyeebwdKdRSQReJZykARGJMJp3DWk4RVsUHdBG8N8t", "to", "1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS") ("Finished transfer of ", 100, "REV to", "1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS", "result was:", (true, Nil))
2 blocks from validator 2, 1 block from validator 1.
a manual trigger of trace scraping.
http://localhost:9000/trace/fee327adcbe1dffbbf737dd72736a62fbea8589a44eee03d89e0a4779c78885b
Finalization
Validator 2 proposes a block, validator 1 proposes a block, validator 2 proposes a block, validator 1 proposes a block, last-finalized-block
invoked on ro node.
14:48:32 in rchain/rholang/examples on rspace/reporting-rspace [$!?] λ ./propose2.sh $F_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$F_REV/" + RNODE='../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402' + sed -e '' -e s/%REV_ADDR/1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 5222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 304502210084ea5b343322e2074828b4399e6749c61a226fa7d1c02ad5e039b6b8c3888d67022024e2bc04bfcb906339d9d3a1ba0e6551bc4aaa32edbe85011a5e9ce4ca65402b + rm vault_demo/2.check_balance.rho.run 14:48:47 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 4s λ ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 propose Response: Success! Block c3aaf1f842847a970d2bca06ffd3a24c19a7879a4c0b26d711959b9aa15c1c59 created and added. 14:48:58 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ./propose.sh $A_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$A_REV/" + RNODE=../../node/target/universal/stage/bin/rnode + sed -e '' -e s/%REV_ADDR/11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 0222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 30450221008dd3d00589e2eeb09e5c3b1a4bf5d8597f28271b0696fdb3211cc3452df09de70220242fa3e32d8635ef5e3a19a2ce43568dbb27f8f3090032ae3e709e712e4c8cde + rm vault_demo/2.check_balance.rho.run 14:49:16 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ../../node/target/universal/stage/bin/rnode propose Response: Success! Block 8b365cdc8165c982a9395acdf2bed840ef23d0212aae49d545f101fd3086784b created and added. 14:49:23 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ./propose2.sh $F_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$F_REV/" + RNODE='../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402' + sed -e '' -e s/%REV_ADDR/1111LTpECeubxTweD9ZoWnM3BJ2HzmAr7bjo9Q1x1r3DJSgHqyfGS/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 5222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 30440220067cb86ede425e33374417ea9c520e82c95c76d3e7c19b8d6d65b27c9fc2f9f5022011abfddfb8e30a978b58f5c93b57fb62d6056d65a31b058bce31ef9670ae773b + rm vault_demo/2.check_balance.rho.run 14:49:30 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ../../node/target/universal/stage/bin/rnode --grpc-port 36401 --grpc-port-internal 36402 propose Response: Success! Block cc13606ca63be204fe5220877354a858f675f291322ec91c9df2afb313bba2cf created and added. 14:49:35 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ./propose.sh $A_PRV vault_demo/2.check_balance.rho "-e s/%REV_ADDR/$A_REV/" + RNODE=../../node/target/universal/stage/bin/rnode + sed -e '' -e s/%REV_ADDR/11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk/ vault_demo/2.check_balance.rho + ../../node/target/universal/stage/bin/rnode deploy --phlo-limit 10000000000000 --phlo-price 1 --private-key 0222222222222222222222222222222222222222222222222222222222222222 vault_demo/2.check_balance.rho.run Response: Success! DeployId is: 3044022005e2531684a7772545c5df6cc6a67ba0e1df7e7ba79e4a9f57bdb3b2f3e4d0170220607383e43988b85e13294579a8829690eaf69e1014eb64ddae3ae642351374fa + rm vault_demo/2.check_balance.rho.run 14:49:42 in rchain/rholang/examples on rspace/reporting-rspace [$!?] took 3s λ ../../node/target/universal/stage/bin/rnode propose Response: Success! Block 9f9b0545a87e317ececb8a36a09639ed9b24e53a6fbe53bde1f6c9dbf2b39661 created and added.
./node/target/universal/stage/bin/rnode --grpc-port 38401 last-finalized-block blockHash: "9f9b0545a87e317ececb8a36a09639ed9b24e53a6fbe53bde1f6c9dbf2b39661" blockSize: "7756" blockNumber: 7 version: 1 deployCount: 1 tupleSpaceHash: "c8955fe63d94994d4ea66140c3d17309251762890c466e7acaceea14bf8adcbd" timestamp: 1570020590649 faultTolerance: 0.5 mainParentHash: "cc13606ca63be204fe5220877354a858f675f291322ec91c9df2afb313bba2cf" parentsHashList: "cc13606ca63be204fe5220877354a858f675f291322ec91c9df2afb313bba2cf" sender: "04a66e6bb045d05ed87ab0662cd758c911d0ada8a573435eb644bf4e2220a954d8f10e98c40b4a408242a17c276afe473c5d65ad967384a3b597ea8045e01d2c2f" shardId: "rchain" bondsValidatorList: "0462791f59a78c69c398c1901d47f079f65580fe2cbe71d9c42847bde7f609d701652afb7efe3d74d314a60a980ac61dc67c4927bff497a128ed731c6816f04383: 1" bondsValidatorList: "04a66e6bb045d05ed87ab0662cd758c911d0ada8a573435eb644bf4e2220a954d8f10e98c40b4a408242a17c276afe473c5d65ad967384a3b597ea8045e01d2c2f: 3" deployCost: "User: 04014c54e489355f6f303a22072cc0d47463e96c78b1761e39e0c41781294cace222f02adcda70bc0494365386bbd93c5b13d34333e42a762fc91bae766122b99f, Cost: PCost(15428) DeployData #1570020581518 -- new\n rl(`rho:registry:lookup`), RevVaultCh,\n vaultCh, balanceCh,\n stdout(`rho:io:stdout`)\nin {\n\n rl!(`rho:rchain:revVault`, *RevVaultCh) |\n for (@(_, RevVault) <- RevVaultCh) {\n\n stdout!((\"2.check_balance.rho\")) |\n\n // REPLACE THE REV ADDRESS HERE vvv\n match \"11112fBUMqiToCGQG2GAiGZhddbTZ44wgw2ySYf8VKkZ628cyFQoWk\" {\n revAddress => {\n\n stdout!((\"Accessing vault at RevAddress\", revAddress)) |\n\n // most RevVault methods return an `Either[String, A] = (false, String) \\/ (true, A)`\n @RevVault!(\"findOrCreate\", revAddress, *vaultCh) |\n for (@(true, vault) <- vaultCh) {\n\n stdout!(\"Obtained vault, checking balance\") |\n\n @vault!(\"balance\", *balanceCh) |\n for (@balance <- balanceCh) {\n\n stdout!((\"Balance is\", balance))\n }\n }\n }\n }\n\n }\n\n}\n}"
14:51:21.276 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Fault tolerance for block 258ca42e92... is 1.0. 14:51:21.282 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Removed 0 deploys from deploy history as we finalized block 258ca42e92.... 14:51:21.284 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Fault tolerance for block 29e050019c... is 1.0. 14:51:21.285 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Removed 0 deploys from deploy history as we finalized block 29e050019c.... 14:51:21.287 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Fault tolerance for block fee327adcb... is 1.0. 14:51:21.289 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Removed 0 deploys from deploy history as we finalized block fee327adcb.... 14:51:21.290 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Fault tolerance for block c3aaf1f842... is 1.0. 14:51:21.291 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Removed 0 deploys from deploy history as we finalized block c3aaf1f842.... 14:51:21.292 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Fault tolerance for block 8b365cdc81... is 1.0. 14:51:21.293 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Removed 0 deploys from deploy history as we finalized block 8b365cdc81.... 14:51:21.294 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Fault tolerance for block cc13606ca6... is 0.5. 14:51:21.295 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Removed 0 deploys from deploy history as we finalized block cc13606ca6.... 14:51:21.296 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Fault tolerance for block 9f9b0545a8... is 0.5. 14:51:21.296 [node-runner-17] INFO c.r.c.LastFinalizedBlockCalculator - Removed 0 deploys from deploy history as we finalized block 9f9b0545a8....
Catch-up
APIs that cover catching up are under development.