-
Notifications
You must be signed in to change notification settings - Fork 1k
Marks collector_fees in snapshot as unused
#10851
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -474,7 +474,6 @@ pub struct BankFieldsToDeserialize { | |
| pub(crate) epoch: Epoch, | ||
| pub(crate) block_height: u64, | ||
| pub(crate) leader_id: Pubkey, | ||
| pub(crate) collector_fees: u64, | ||
| pub(crate) fee_rate_governor: FeeRateGovernor, | ||
| pub(crate) rent_collector: RentCollector, | ||
| pub(crate) epoch_schedule: EpochSchedule, | ||
|
|
@@ -519,7 +518,6 @@ pub struct BankFieldsToSerialize { | |
| pub epoch: Epoch, | ||
| pub block_height: u64, | ||
| pub leader_id: Pubkey, | ||
| pub collector_fees: u64, | ||
| pub fee_rate_governor: FeeRateGovernor, | ||
| pub rent_collector: RentCollector, | ||
| pub epoch_schedule: EpochSchedule, | ||
|
|
@@ -568,7 +566,6 @@ impl PartialEq for Bank { | |
| epoch, | ||
| block_height, | ||
| leader_id, | ||
| collector_fees, | ||
| fee_rate_governor, | ||
| rent_collector, | ||
| epoch_schedule, | ||
|
|
@@ -630,7 +627,6 @@ impl PartialEq for Bank { | |
| && epoch == &other.epoch | ||
| && block_height == &other.block_height | ||
| && leader_id == &other.leader_id | ||
| && collector_fees.load(Relaxed) == other.collector_fees.load(Relaxed) | ||
| && fee_rate_governor == &other.fee_rate_governor | ||
| && rent_collector == &other.rent_collector | ||
| && epoch_schedule == &other.epoch_schedule | ||
|
|
@@ -673,7 +669,6 @@ impl BankFieldsToSerialize { | |
| epoch: Epoch::default(), | ||
| block_height: u64::default(), | ||
| leader_id: Pubkey::default(), | ||
| collector_fees: u64::default(), | ||
| fee_rate_governor: FeeRateGovernor::default(), | ||
| rent_collector: RentCollector::default(), | ||
| epoch_schedule: EpochSchedule::default(), | ||
|
|
@@ -840,9 +835,6 @@ pub struct Bank { | |
| /// The validator identity of the leader who produced this block. | ||
| leader_id: Pubkey, | ||
|
|
||
| /// Fees that have been collected | ||
| collector_fees: AtomicU64, | ||
|
Comment on lines
-843
to
-844
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There are zero writers to this field in the repo. And since it is private, it would require a helper fn to write to it. There isn't a helper fn that exposes the field in a way that would allow writing.
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. "This field stopped being used with the activation of this: #583" |
||
|
|
||
| /// Track cluster signature throughput and adjust fee rate | ||
| pub(crate) fee_rate_governor: FeeRateGovernor, | ||
|
|
||
|
|
@@ -1127,7 +1119,6 @@ impl Bank { | |
| epoch: Epoch::default(), | ||
| block_height: u64::default(), | ||
| leader_id: Pubkey::default(), | ||
| collector_fees: AtomicU64::default(), | ||
| fee_rate_governor: FeeRateGovernor::default(), | ||
| rent_collector: RentCollector::default(), | ||
| epoch_schedule: EpochSchedule::default(), | ||
|
|
@@ -1370,7 +1361,6 @@ impl Bank { | |
| parent_hash: parent.hash(), | ||
| parent_slot: parent.slot(), | ||
| leader_id: *leader_id, | ||
| collector_fees: AtomicU64::new(0), | ||
| ancestors: Ancestors::default(), | ||
| hash: RwLock::new(Hash::default()), | ||
| is_delta: AtomicBool::new(false), | ||
|
|
@@ -1917,7 +1907,6 @@ impl Bank { | |
| epoch: fields.epoch, | ||
| block_height: fields.block_height, | ||
| leader_id: fields.leader_id, | ||
| collector_fees: AtomicU64::new(fields.collector_fees), | ||
| fee_rate_governor: fields.fee_rate_governor, | ||
| // clone()-ing is needed to consider a gated behavior in rent_collector | ||
| rent_collector: Self::get_rent_collector_from(&fields.rent_collector, fields.epoch), | ||
|
|
@@ -2038,7 +2027,6 @@ impl Bank { | |
| epoch: self.epoch, | ||
| block_height: self.block_height, | ||
| leader_id: self.leader_id, | ||
| collector_fees: self.collector_fees.load(Relaxed), | ||
| fee_rate_governor: self.fee_rate_governor.clone(), | ||
| rent_collector: self.rent_collector.clone(), | ||
| epoch_schedule: self.epoch_schedule.clone(), | ||
|
|
@@ -4888,10 +4876,6 @@ impl Bank { | |
| hash | ||
| } | ||
|
|
||
| pub fn collector_fees(&self) -> u64 { | ||
| self.collector_fees.load(Relaxed) | ||
| } | ||
|
|
||
| /// Used by ledger tool to run a final hash calculation once all ledger replay has completed. | ||
| /// This should not be called by validator code. | ||
| pub fn run_final_hash_calc(&self) { | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -345,7 +345,7 @@ mod tests { | |
| #[cfg_attr( | ||
| feature = "frozen-abi", | ||
| derive(AbiExample), | ||
| frozen_abi(digest = "FHeeuJgYyE1rqdLRycbJWC8PoTRZqYsRWZZCaP5A7DWb") | ||
| frozen_abi(digest = "EEwojKqUDSpYNeutW56K9bsJmsjCMZn8i4n3qgvJYRxf") | ||
|
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Frozen abi digest changed due to renaming the field. |
||
| )] | ||
| #[derive(serde::Serialize)] | ||
| pub struct BankAbiTestWrapper { | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.