Skip to content

Commit

Permalink
Fix and re-enable abandoned tx tracker (#12533)
Browse files Browse the repository at this point in the history
* Re-enable tracker

* generate

* update tracker

* fix race conditions

* Update tracker.go

* Update tracker.go

* Ensure thread safety

* Update tracker.go

* concurrently track txes

* Optimizations

* update logging

* Update tracker.go

* Update CHANGELOG.md

* Update common/txmgr/tracker.go

Co-authored-by: Jim W <poopoothegorilla@users.noreply.github.com>

* GetAbandonedTransactions

* lint

* enabled address check

* Update tracker_test.go

* Update tracker.go

* Ignore confirmed txes

* Don't resend abandoned txes

* Remove comment

* Update tracker_test.go

* Remove unused block height

* changeset

* Update tracker_test.go

---------

Co-authored-by: Jim W <poopoothegorilla@users.noreply.github.com>
Co-authored-by: Prashant Yadav <34992934+prashantkumar1982@users.noreply.github.com>
  • Loading branch information
3 people committed Apr 17, 2024
1 parent b468bc9 commit ccb8cd8
Show file tree
Hide file tree
Showing 10 changed files with 276 additions and 251 deletions.
5 changes: 5 additions & 0 deletions .changeset/gold-bottles-tell.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"chainlink": minor
---

#added : Re-enable abandoned transaction tracker
3 changes: 0 additions & 3 deletions common/txmgr/resender.go
Original file line number Diff line number Diff line change
Expand Up @@ -140,9 +140,6 @@ func (er *Resender[CHAIN_ID, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) resendUnco
return fmt.Errorf("Resender failed getting enabled keys for chain %s: %w", er.chainID.String(), err)
}

// Tracker currently disabled for BCI-2638; refactor required
// resendAddresses = append(resendAddresses, er.tracker.GetAbandonedAddresses()...)

ageThreshold := er.txConfig.ResendAfterThreshold()
maxInFlightTransactions := er.txConfig.MaxInFlight()
olderThan := time.Now().Add(-ageThreshold)
Expand Down
Loading

0 comments on commit ccb8cd8

Please sign in to comment.