Commit Graph

2332 Commits

Author SHA1 Message Date
yosoyubik
0f0af88a31 naive: wip add ordered-map for points 2021-06-09 13:34:04 +02:00
yosoyubik
852881eff1 naive: rename nas to pre (predicted state) 2021-06-09 13:30:36 +02:00
yosoyubik
85c0c11257 naive: add time for next L2 batch to state 2021-06-09 13:05:17 +02:00
yosoyubik
b9c5d9e2e6 naive: listen to %resend timer 2021-06-07 13:09:16 +02:00
yosoyubik
ca2b626c4e naive: init aggregator timer on-init 2021-06-07 13:07:35 +02:00
yosoyubik
e7eaf3d2c6 naive: try updating predicted state on confirmed L2 tx 2021-06-07 11:41:02 +02:00
yosoyubik
e35a8b9e7f naive: cached naive state -> predicted naive state 2021-06-07 11:20:31 +02:00
yosoyubik
a01289145b naive: update aggregator cached naive state eagerly
The aggregator keeps a cached naive state that is recreated using the 
canonical L2 state from the %azimuth agent, every time a new L2 tx comes 
in via +take-tx (used by clients of the aggregator).

This makes the cached state ahead of the canonical L2 state, but 
recreated every time a client sends a tx, using the list of pending (not 
sent out to an ethereum node) and sending (waiting confirmation from 
L1). This step drops any pending and sending transactions that do not 
apply correctly.

Hearing about a new L2 tx confirmed in L1 (+on-naive-diff) removes such 
transaction from the sending list, but does not update the cached state, 
since this was already done when the L2 tx was seen in +take-tx.
2021-06-05 14:24:37 +02:00
yosoyubik
9c70e006a1 naive: fix wrong wire when receiving azimuth txs 2021-06-05 13:58:34 +02:00
yosoyubik
bac79bf55d naive: add get-spawned to rpc-api 2021-06-04 11:41:59 +02:00
yosoyubik
7e665b4fe8 naive: update wires and path in azimuth 2021-06-03 09:27:08 +02:00
yosoyubik
9c18638469 naive: update wires in aggregator 2021-06-03 09:26:13 +02:00
yosoyubik
82ab2b6b2d naive: use canonical state from azimuth in aggregator 2021-06-03 09:24:28 +02:00
yosoyubik
fc8e090a29 naive: add config action 2021-06-03 09:11:33 +02:00
yosoyubik
943eee1db6 naive: add ethereum signing address to aggregator sending map 2021-06-01 16:18:32 +02:00
yosoyubik
4642ece88f naive: use get-network for retrieving chain data 2021-06-01 14:28:17 +02:00
yosoyubik
5453722728 naive: give naive state after aggregator subscription 2021-06-01 14:23:53 +02:00
yosoyubik
9f3202eded naive: use cached naive state in aggregator 2021-06-01 13:56:56 +02:00
yosoyubik
5b0e785cf7 naive: choose contracts from mainnet, ropsten or local 2021-05-29 15:42:27 +02:00
yosoyubik
520225056a naive: send signature and raw tx for every tx in the roll
this assumes that the naive contract has a "fallback" function:

https://docs.soliditylang.org/en/v0.5.3/contracts.html#fallback-function
2021-05-29 14:57:57 +02:00
yosoyubik
98bef023cf naive: send updates to aggregator 2021-05-29 14:53:57 +02:00
yosoyubik
4cbf3d497b naive: update tx state in finding txs 2021-05-29 14:46:19 +02:00
yosoyubik
e834aface1 naive: subscribe to azimuth agent 2021-05-29 14:44:58 +02:00
yosoyubik
9abd6c3e72 naive: use gen-tx-octs from naive-transactions library 2021-05-29 14:44:16 +02:00
yosoyubik
a3ed3182bc naive: use contract/chain from azimuth library 2021-05-29 14:43:13 +02:00
yosoyubik
8b51b526d3 naive: add get-next-nonce thread 2021-05-29 14:40:13 +02:00
yosoyubik
47813a189a naive: hook up subscription to azimuth for %tx diffs 2021-05-23 15:49:55 +02:00
yosoyubik
001d58e539 naive: add parse raw tx in aggregator submit action 2021-05-23 14:59:29 +02:00
yosoyubik
766e2ab610 naive: capture rpc errors when sending l2 batches 2021-05-22 08:10:30 +02:00
yosoyubik
3cee0ff3b8 naive: import /lib/naive-transactions in aggregator 2021-05-21 15:21:09 +02:00
yosoyubik
937cc2ce44 naive: add aggregator sur 2021-05-21 15:07:08 +02:00
yosoyubik
9caa686173 naive: cast to _pending when updating pending-state 2021-05-21 14:29:40 +02:00
yosoyubik
fbb40b688e naive: add %failed for droppped l2 txs 2021-05-21 14:12:05 +02:00
yosoyubik
30bd648d7f json-rpc: move error response core to lib 2021-05-21 13:39:06 +02:00
yosoyubik
8532ef4bb0 naive: remove [] around function calls in scry paths 2021-05-21 13:00:45 +02:00
yosoyubik
6cdc3a1cae Merge branch 'naive/aggregator' into yu/azimuth-rpc 2021-05-21 12:34:33 +02:00
yosoyubik
ce35d07adb naive: remove redundant brackets 2021-05-21 12:34:29 +02:00
yosoyubik
f6adf083ad naive: use /v1/azimuth in rcp-api 2021-05-21 12:28:54 +02:00
yosoyubik
5862aa07ce naive: wip aggregator send thread 2021-05-21 12:16:57 +02:00
yosoyubik
9e7cb91398 Merge branch 'yu/azimuth-rpc' into naive/aggregator 2021-05-17 17:50:45 +02:00
yosoyubik
152cf894ff naive: hook rpc-api with aggregator 2021-05-17 17:49:41 +02:00
yosoyubik
7c57a35ccc naive: wip aggregator compiles
got it to compile and tested poke and scry from /app/azimuth-rpc.hoon
2021-05-17 17:48:49 +02:00
yosoyubik
154baceb8b Merge branch 'yu/azimuth-rpc' into naive/aggregator 2021-05-14 09:46:36 +02:00
yosoyubik
8ebb5e2d6c naive: add pending and tx status RPCs 2021-05-14 07:25:09 +02:00
yosoyubik
7ede24c3cc naive: first pass at tx history RPC 2021-05-14 07:25:04 +02:00
yosoyubik
ae8d98c467 naive: add jsonrpc parsing for sending pending rolls 2021-05-14 07:24:59 +02:00
yosoyubik
0380d18735 naive: add rpc response error codes 2021-05-14 07:24:43 +02:00
yosoyubik
36cdb9493d naive: add jsonrpc parsing for naive txs 2021-05-14 07:24:35 +02:00
yosoyubik
fe8c36dd3f naive: use agentio for scry point 2021-05-14 07:24:27 +02:00
yosoyubik
843fe4ce38 json-rpc: add validation for json-rpc request 2021-05-14 07:24:27 +02:00