···
+
writer.describe_metrics();
Ok((reader, writer, js_cursor, sketch_secret))
···
"storage_fjall_l0_run_count",
"number of L0 runs in a partition"
+
"storage_fjall_keyspace_disk_space",
+
"total storage used according to fjall"
+
"storage_fjall_journal_count",
+
"total keyspace journals according to fjall"
+
"storage_fjall_keyspace_sequence",
+
"fjall keyspace sequence"
···
.set(self.rollups.tree.l0_run_count() as f64);
gauge!("storage_fjall_l0_run_count", "partition" => "queues")
.set(self.queues.tree.l0_run_count() as f64);
+
gauge!("storage_fjall_keyspace_disk_space").set(self.keyspace.disk_space() as f64);
+
gauge!("storage_fjall_journal_count").set(self.keyspace.journal_count() as f64);
+
gauge!("storage_fjall_keyspace_sequence").set(self.keyspace.instant() as f64);
async fn get_storage_stats(&self) -> StorageResult<serde_json::Value> {
···
+
fn describe_metrics(&self) {
+
"storage_insert_batch_db_batch_items",
+
"how many items are in the fjall batch for batched inserts"
+
"storage_insert_batch_db_batch_size",
+
"in-memory size of the fjall batch for batched inserts"
+
"storage_rollup_counts_db_batch_items",
+
"how many items are in the fjall batch for a timlies rollup"
+
"storage_rollup_counts_db_batch_size",
+
"in-memory size of the fjall batch for a timelies rollup"
+
"storage_delete_account_partial_commits",
+
"fjall checkpoint commits for cleaning up accounts with too many records"
+
"storage_delete_account_completions",
+
"total count of account deletes handled"
+
"storage_delete_account_records_deleted",
+
"total records deleted when handling account deletes"
+
"storage_trim_dirty_nsids",
+
"number of NSIDs trimmed"
+
"storage_trim_duration",
+
"how long it took to trim the dirty NSIDs"
+
"storage_trim_removed",
+
"how many records were removed during trim"
fn rollup_delete_account(
···
insert_batch_static_neu::<NewRollupCursorKey>(&mut batch, &self.global, last_cursor)?;
+
histogram!("storage_rollup_counts_db_batch_items").record(batch.len() as f64);
+
histogram!("storage_rollup_counts_db_batch_size")
+
.record(std::mem::size_of_val(&batch) as f64);
Ok((cursors_advanced, dirty_nsids))
···
if self.bg_taken.swap(true, Ordering::SeqCst) {
return Err(StorageError::BackgroundAlreadyStarted);
log::info!("reroll: resetting rollup cursor...");
insert_static_neu::<NewRollupCursorKey>(&self.global, Cursor::from_start())?;
···
+
histogram!("storage_insert_batch_db_batch_items").record(batch.len() as f64);
+
histogram!("storage_insert_batch_db_batch_size")
+
.record(std::mem::size_of_val(&batch) as f64);
···
batch.remove(&self.records, key_bytes);
if batch.len() >= MAX_BATCHED_ACCOUNT_DELETE_RECORDS {
+
counter!("storage_delete_account_partial_commits").increment(1);
batch = self.keyspace.batch();
+
counter!("storage_delete_account_completions").increment(1);
+
counter!("storage_delete_account_records_deleted").increment(records_deleted as u64);