Skip to content

Commit

Permalink
Merge pull request #324 from bitcoin-sv/refactor/metamorph-processor
Browse files Browse the repository at this point in the history
Refactor/metamorph processor
  • Loading branch information
boecklim authored Mar 11, 2024
2 parents 14ea662 + 8b7fb62 commit c3f10b3
Show file tree
Hide file tree
Showing 9 changed files with 331 additions and 317 deletions.
7 changes: 7 additions & 0 deletions cmd/metamorph.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,13 @@ func StartMetamorph(logger *slog.Logger) (func(), error) {
metamorph.WithProcessStatusUpdatesInterval(processStatusUpdateInterval),
)

metamorphProcessor.StartLockTransactions()
time.Sleep(200 * time.Millisecond) // wait a short time so that process expired transactions will start shortly after lock transactions go routine

metamorphProcessor.StartProcessExpiredTransactions()
metamorphProcessor.StartProcessStatusUpdatesInStorage()
metamorphProcessor.StartProcessMinedCallbacks()

http.HandleFunc("/pstats", metamorphProcessor.HandleStats)

go func() {
Expand Down
50 changes: 50 additions & 0 deletions metamorph/mocks/store_mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit c3f10b3

Please sign in to comment.