raiden-network / light-client

The Raiden Light Client
https://raiden.network/
MIT License
33 stars 30 forks source link

Mainnet smoke test #2561

Closed palango closed 3 years ago

palango commented 3 years ago

Description

We want to do some first, simple mainnet testing.

Tasks

Outcomes

Timings for initial/subsequent syncs

Subsequent syncs aren't substantially faster than the initial sync: https://github.com/raiden-network/light-client/issues/2566

agatsoh commented 3 years ago

Ok finally leaving my testing results for 2 nodes with a channel here

LC browser node

0x9307b1EE0f1299547F8F46A268efbd6089Ce81B2 subkey account: 0x07d036DbC602F0191a4bC8e217fe48d34cD4a230 Initial synch for fresh account: 6136 ms

DAI Address 0x6B175474E89094C44Da98b954EedeAC495271d0F

Summary of all spending on the LC Browser node can be found here

Made 4 direct transfers which became faster over time with each transfer.

273ms 225ms 211ms 183ms

LC browser logs

raiden_0x07d036DbC602F0191a4bC8e217fe48d34cD4a230_2021-02-25T10_45_14.018Z.log raiden_0x07d036DbC602F0191a4bC8e217fe48d34cD4a230_2021-02-24T13_18_23.400Z.log raiden_0x07d036DbC602F0191a4bC8e217fe48d34cD4a230_2021-02-24T08_57_57.881Z.log

LC CLI node

0x5d3c715dfec88ee0C1a14C2B6ed3b0878612581c Does not have any funds in ETH or any other coin till date

I started the LC node in two ways and then stuck to the 2nd

node build/index.js --pathfinding-service-address=https://pfs.transport.raiden.overdoze.se --matrix-server=https://transport.raiden.overdoze.se --eth-rpc-endpoint http://10.104.6.7:8545 --api-address "http://localhost:5010" --keystore-path /home/devaki/.ethereum/keystore/ --address 0x5d3c715dfec88ee0C1a14C2B6ed3b0878612581c --log-file node-5d3c71-mainnet-24thFeb2021.log --password-file password_file.txt --accept-disclaimer --enable-monitoring
node build/index.js --eth-rpc-endpoint http://10.104.6.7:8545 --api-address "http://localhost:5010" --keystore-path /home/devaki/.ethereum/keystore/ --address 0x5d3c715dfec88ee0C1a14C2B6ed3b0878612581c --log-file node-5d3c71-mainnet-8thMarch2021.log --password-file password_file.txt --accept-disclaimer --enable-monitoring

Querying API of CLI Node:

Did several transfers but could not decipher the payment times due to encoding in the log files but I am attaching logs so that would make it clear. Its mostly something like this 33m222274 33m0 33m1 33m5473

LC CLI logs

agatsoh commented 3 years ago

LC browser node

0x9307b1EE0f1299547F8F46A268efbd6089Ce81B2

Transfer times for mediated transfers:

4239ms 590ms 458ms 494ms

LC CLI node

0x5d3c715dfec88ee0C1a14C2B6ed3b0878612581c

Important Unless the CLI node is started with --enableMediation it will not mediate transfers and PFS will keep giving No route available errors

Open a channel

curl -i -X PUT \
http://localhost:5010/api/v1/channels \
-H 'Content-Type: application/json' \
--data-raw '{"partner_address": "0xF087038D9032dc5e419C62dF32e865C2d160db2e", "token_address": "0x6B175474E89094C44Da98b954EedeAC495271d0F", "total_deposit": "10000000000000000000", "settle_timeout": "500"}'

curl -i -X PUT \

http://localhost:5010/api/v1/channels \ -H 'Content-Type: application/json' \ --data-raw '{"partner_address": "0xF087038D9032dc5e419C62dF32e865C2d160db2e", "token_address": "0x6B175474E89094C44Da98b954EedeAC495271d0F", "total_deposit": "10000000000000000000", "settle_timeout": "500"}' HTTP/1.1 201 Created X-Powered-By: Express Access-Control-Allow-Origin: http://localhost:/ Vary: Origin Content-Type: application/json; charset=utf-8 Content-Length: 375 ETag: W/"177-JZbA4c6HnfH9JBCFmSG6zFtQIOQ" Date: Tue, 09 Mar 2021 12:57:23 GMT Connection: keep-alive Keep-Alive: timeout=5

{
"channel_identifier": "67",
"token_network_address": "0xEA92bD481e54BBB9Bb6C927970a54E82eE26c6B4",
"partner_address": "0xF087038D9032dc5e419C62dF32e865C2d160db2e",
"token_address": "0x6B175474E89094C44Da98b954EedeAC495271d0F",
"balance": "10000000000000000000",
"total_deposit": "10000000000000000000",
"total_withdraw": "0",
"state": "opened",
"settle_timeout": "500",
"reveal_timeout": "50"
}

Query channels

curl -i \
http://localhost:5010/api/v1/channels/0x6B175474E89094C44Da98b954EedeAC495271d0F

curl -i \

http://localhost:5010/api/v1/channels/0x6B175474E89094C44Da98b954EedeAC495271d0F HTTP/1.1 200 OK X-Powered-By: Express Access-Control-Allow-Origin: http://localhost:/ Vary: Origin Content-Type: application/json; charset=utf-8 Content-Length: 733 ETag: W/"2dd-5F9EJ3TLZb0KMbk/HDdApSEsLQQ" Date: Tue, 09 Mar 2021 13:12:43 GMT Connection: keep-alive Keep-Alive: timeout=5

[
{
"channel_identifier": "66",
"token_network_address": "0xEA92bD481e54BBB9Bb6C927970a54E82eE26c6B4",
"partner_address": "0x07d036DbC602F0191a4bC8e217fe48d34cD4a230",
"token_address": "0x6B175474E89094C44Da98b954EedeAC495271d0F",
"balance": "6999999999999999997",
"total_deposit": "0",
"total_withdraw": "0",
"state": "opened",
"settle_timeout": "500",
"reveal_timeout": "50"
},
{
"channel_identifier": "67",
"token_network_address": "0xEA92bD481e54BBB9Bb6C927970a54E82eE26c6B4",
"partner_address": "0xF087038D9032dc5e419C62dF32e865C2d160db2e",
"token_address": "0x6B175474E89094C44Da98b954EedeAC495271d0F",
"balance": "5000000000000000000",
"total_deposit": "10000000000000000000",
"total_withdraw": "0",
"state": "opened",
"settle_timeout": "500",
"reveal_timeout": "50"
}
]

Send a direct transfer

curl -i -X POST \
http://localhost:5010/api/v1/payments/0x6B175474E89094C44Da98b954EedeAC495271d0F/0xF087038D9032dc5e419C62dF32e865C2d160db2e \
-H 'Content-Type: application/json' \
--data-raw '{"amount": "1000000000000000000"}'

LC Browser Node 2

0x5e37689540503CCa3968bD9d41Ee3813E5DF00CB subkey account: 0xF087038D9032dc5e419C62dF32e865C2d160db2e

palango commented 3 years ago

Did a successful run of BF1 on mainnet again. There was a disconnect of the SP from the geth node, but I could restart it and then it finished successfully.

See also https://github.com/raiden-network/team/issues/896