-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Internal: TX processing is now event-based (#492)
Problem: the pending TX processor uses a polling loop to determine which transactions must be processed. This leads to some latency when adding a new transaction when there is no currently pending transaction as the task sleeps while waiting for new transactions. Solution: make the TX processor event-based by using a RabbitMQ exchange + message queue. Upon receiving a new transaction from on-chain, we now publish a RabbitMQ message containing the hash of the transaction. The processor can then find the transaction in the DB. The RabbitMQ message is only used as a hint that something must be done. The TX processor still looks for pending TXs in the database.
- Loading branch information
1 parent
aff6b16
commit 8642d31
Showing
13 changed files
with
236 additions
and
82 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
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
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.