Skip to content

Commit

Permalink
Fix the remaining txns calculation in proof queue (aptos-labs#13889)
Browse files Browse the repository at this point in the history
* Fix the remaining txns calcualtion in proof queue

* Fixing the bug

* Change unit test

* Add unit test

* Increase memory limits in forge

* Update counters

* Minor changes

* Fix logs in proof queue

* Add more unit tests and fixes

* Reset forge settings

* Garbage collection of batches without proofs

* Increase forge overload limits

* Decrease graceful overload tps

* Optimize

* Switch back forge settings

* rust lint

* fix unit test

* Use sample
  • Loading branch information
vusirikala authored Jul 9, 2024
1 parent 59e7482 commit 62340d1
Show file tree
Hide file tree
Showing 3 changed files with 439 additions and 161 deletions.
45 changes: 29 additions & 16 deletions consensus/src/quorum_store/counters.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

use aptos_metrics_core::{
exponential_buckets, op_counters::DurationHistogram, register_avg_counter, register_histogram,
register_histogram_vec, register_int_counter, register_int_counter_vec, register_int_gauge,
Histogram, HistogramVec, IntCounter, IntCounterVec, IntGauge,
register_histogram_vec, register_int_counter, register_int_counter_vec, Histogram,
HistogramVec, IntCounter, IntCounterVec,
};
use once_cell::sync::Lazy;
use std::time::Duration;
Expand Down Expand Up @@ -374,34 +374,47 @@ pub fn pos_to_commit(bucket: u64, secs: f64) {
// Proof Queue
//////////////////////

pub static PROOFS_WITHOUT_BATCH_DATA: Lazy<IntGauge> = Lazy::new(|| {
register_int_gauge!(
pub static PROOFS_WITHOUT_BATCH_SUMMARY: Lazy<Histogram> = Lazy::new(|| {
register_histogram!(
"quorum_store_proofs_without_batch_data",
"Number of proofs received without batch data"
"Number of proofs received without batch data",
PROOF_COUNT_BUCKETS.clone(),
)
.unwrap()
});

pub static PROOFS_WITH_BATCH_SUMMARY: Lazy<Histogram> = Lazy::new(|| {
register_histogram!(
"quorum_store_proofs_with_batch_data",
"Number of proofs received without batch data",
PROOF_COUNT_BUCKETS.clone(),
)
.unwrap()
});

pub static TXNS_WITH_DUPLICATE_BATCHES: Lazy<IntGauge> = Lazy::new(|| {
register_int_gauge!(
pub static TXNS_WITH_DUPLICATE_BATCHES: Lazy<Histogram> = Lazy::new(|| {
register_histogram!(
"quorum_store_txns_with_duplicate_batches",
"Number of transactions received with duplicate batches"
"Number of transactions received with duplicate batches",
TRANSACTION_COUNT_BUCKETS.clone(),
)
.unwrap()
});

pub static TXNS_IN_PROOF_QUEUE: Lazy<IntGauge> = Lazy::new(|| {
register_int_gauge!(
"quorum_store_txns_in_proof_queue",
"Number of transactions in the proof queue"
pub static TXNS_IN_PROOFS_WITH_SUMMARIES: Lazy<Histogram> = Lazy::new(|| {
register_histogram!(
"quorum_store_txns_in_proof_queue_with_summaries",
"Number of transactions in the proof queue",
TRANSACTION_COUNT_BUCKETS.clone(),
)
.unwrap()
});

pub static PROOFS_IN_PROOF_QUEUE: Lazy<IntGauge> = Lazy::new(|| {
register_int_gauge!(
"quorum_store_proofs_in_proof_queue",
"Number of proofs in the proof queue"
pub static TXNS_IN_PROOFS_WITHOUT_SUMMARIES: Lazy<Histogram> = Lazy::new(|| {
register_histogram!(
"quorum_store_txns_in_proof_queue_without_summaries",
"Number of transactions in the proof queue",
TRANSACTION_COUNT_BUCKETS.clone(),
)
.unwrap()
});
Expand Down
Loading

0 comments on commit 62340d1

Please sign in to comment.