We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6487615 commit e18554bCopy full SHA for e18554b
crates/batcher/src/lib.rs
@@ -1500,6 +1500,20 @@ impl Batcher {
1500
finalized_batch.len()
1501
);
1502
1503
+ // Update queue metrics after successful batch extraction
1504
+ let queue_len = batch_state_lock.batch_queue.len();
1505
+ match calculate_batch_size(&batch_state_lock.batch_queue) {
1506
+ Ok(queue_size_bytes) => {
1507
+ self.metrics
1508
+ .update_queue_metrics(queue_len as i64, queue_size_bytes as i64);
1509
+ }
1510
+ Err(e) => {
1511
+ error!("Failed to calculate batch size for queue metrics update: {:?}", e);
1512
+ // Still update queue length metric, set size to 0 due to calculation error
1513
+ self.metrics.update_queue_metrics(queue_len as i64, 0);
1514
1515
1516
+
1517
Some(finalized_batch)
1518
}
1519
0 commit comments