-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add broadcast transaction to tbcd (#285)
* Add skeleton to broadcast transactions * Working broadcast * Fix disconnects caused by ReadDeadline. Go's ReadDealine has surprising side effects that caused a functional connection to be terminated prior to actually expiring. By setting the ReadDeadline to 0 the peer read never times out. This is ok because there are a bunch of other commands being written that will cause the read to fail if they do not complete. Simply rely on the chatter to cause a connection close instead of trying to be clever and detect which error type the close path received. * Read broadcast tx's once included in block * Broadcast all pending txs to new connected peers * Remove bogus code * Use R mutex to create all broadcast list * Update service/tbc/rpc.go Co-authored-by: Joshua Sing <joshua@bloq.com> * Update service/tbc/rpc.go Co-authored-by: Joshua Sing <joshua@bloq.com> --------- Co-authored-by: Joshua Sing <joshua@bloq.com>
- Loading branch information
1 parent
27d195b
commit 0891a3b
Showing
4 changed files
with
252 additions
and
3 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