-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add queuing system for bitcoin broadcasts (#227)
* added indexes and removed aggregate functions added indexes to btc_blocks_can materialized view, no longer using aggregate functions * added sql * add queuing system for bitcoin broadcasts add a db table btc_transaction_broadcast_request that will store broadcast requests. when someone wants to broadcast a tx, insert into this table (ignoring duplicates). have a few workers that read from this table and attempt to broadcast transactions to electrumx. when a worker "checks out" a broadcast request, it updates the last_broadcast_attempt_at column when a worker confirms a broadcast, it updates the broadcast_at column wait 10 minutes before processing same tx again if not confirmed * fix comment * add index * ignoring requests older than 3 hours, added test * using created_at to determine age, 2 hours * re-added test * squashme * squashme * fix pool pass * constant notify * more optimization: * ordering * delete on certain error * set last error * all errors * stagger * cache l2keystones * cache on new * no stagger * more connections * bss bfg timeout * ref, limit * async refresh and insert * bugfix * fix query * larger backoff * fix tests * don't use input ctx * longer timeouts in ci * pr feedback * smaller backoff * added test wait
- Loading branch information
1 parent
7cd520d
commit 92648fc
Showing
7 changed files
with
722 additions
and
86 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.