synapseweb3 / forcerelay

Apache License 2.0
10 stars 8 forks source link

refactor: refactor the monitor and transaction assembly #377

Closed ashuralyk closed 10 months ago

ashuralyk commented 10 months ago

background

We found the running Forcerelay faces two major problems, which are about the stability of monitor and transaction sending feature.

Monitor of Axon has an unstable problem about the disconnection in logs listener, it frequently missed essential events from Axon which will block the entire relay process.

Transaction assembly in CKB could take RBF and UnknowOutpoint problems, which are caused by the cell compete, and to solve the compete condition should put huge effort on redesigning the structure of IBC cells, so as the best method is to resend unworkable transactions.

change logs

  1. refactor transaction assembly process in CKB to add retry feature
  2. optimize message convertor of CKB to fetch live IBC cells immediately once miss the peak in corresponding cells cache, because if retry the assembly of transaction, it should rerun the assembly process which would kick out dead cells from caches
  3. refactor monitor logic of Axon to use POLL process to take place of the LISTEN process

closed PRs

ashuralyk commented 10 months ago

@Flouse this PR can start review again