Skip to content

Conversation

@najeal
Copy link
Contributor

@najeal najeal commented Dec 4, 2024

This PR introduce a way to easily switch from a FIFO mempool to a Priority mempool.

Comment on lines +56 to +61
var mempoolFactory mempool.AbstractMempoolFactory[*chain.Transaction] = mempool.NewGeneralMempool[*chain.Transaction]

func WithPriorityMempool(factory mempool.AbstractMempoolFactory[*chain.Transaction]) {
mempoolFactory = factory
}

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The mempool factory switch could be done in a more elegant way.

@najeal najeal marked this pull request as ready for review December 5, 2024 16:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant