This repository has been archived by the owner on Nov 6, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Removing old transactions from the queue #4046
Merged
Merged
Conversation
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
gavofyork
suggested changes
Jan 5, 2017
@@ -488,6 +495,11 @@ pub enum PrioritizationStrategy { | |||
GasFactorAndGasPrice, | |||
} | |||
|
|||
/// Point in time when transaction was inserted. | |||
/// (implying block numbers) | |||
pub type InsertionTime = u64; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this is blocks, might want to change type to BlockNumber
, and name to QueuingPeriod
.
for sender in senders { | ||
self.remove_all(sender, fetch_nonce(&sender)); | ||
for (sender, details) in senders.iter() { | ||
self.remove_all(*sender, details.nonce); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove_all
is a rather misleading name. there is very specific logic here that the name should imply. suggest remove_dead
or even just cull
.
minor grumbles. |
Grumbles addressed, renamed |
gavofyork
approved these changes
Jan 5, 2017
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I'm not sure about the block time choice, or balance re-validation.
Would like to hear some second thoughts on this.
Closes #3928
Explains: #4007, #3996, #3358