Repository: MystenLabs/sui
File: crates/sui-indexer-alt-framework/src/metrics.rs (Rust)

Code before:
            .unwrap(),
            collector_gather_latency: register_histogram_vec_with_registry!(
                name("collector_gather_latency"),
                "Time taken to gather rows into a batch by this collector",
                &["pipeline"],
                PROCESSING_LATENCY_SEC_BUCKETS.to_vec(),
                registry,
            )
            .unwrap(),
            collector_batch_size: register_histogram_vec_with_registry!(
                name("collector_batch_size"),
                "Number of rows in a batch written to the database by this collector",
                &["pipeline"],
                BATCH_SIZE_BUCKETS.to_vec(),
                registry,
            )
            .unwrap(),
            total_collector_skipped_checkpoints: register_int_counter_vec_with_registry!(
                name("total_collector_skipped_checkpoints"),
                "Number of checkpoints skipped by the tasked pipeline's collector due to being below the main reader lo watermark",
                &["pipeline"],
                registry,
            ).unwrap(),
            collector_reader_lo: register_int_gauge_vec_with_registry!(
                name("collector_reader_lo"),
                "Reader lo watermark as observed by the collector",
                &["pipeline"],
                registry,
            )
            .unwrap(),
            committer_commit_latency: register_histogram_vec_with_registry!(
                name("committer_commit_latency"),
                "Time taken to write a batch of rows to the database by this committer",
                &["pipeline"],
                DB_UPDATE_LATENCY_SEC_BUCKETS.to_vec(),
                registry,
            )
            .unwrap(),
            committer_tx_rows: register_histogram_vec_with_registry!(
                name("committer_tx_rows"),
                "Number of rows written to the database in a single database transaction by this committer",
                &["pipeline"],
                BATCH_SIZE_BUCKETS.to_vec(),
                registry,
            )
            .unwrap(),
            watermark_gather_latency: register_histogram_vec_with_registry!(
                name("watermark_gather_latency"),
                "Time taken to calculate the new high watermark after a write by this committer",
                &["pipeline"],
                PROCESSING_LATENCY_SEC_BUCKETS.to_vec(),

Review comment (suggestion):
```suggestion
                "Reader low watermark as observed by the collector",
```

Code after:
            .unwrap(),
            collector_gather_latency: register_histogram_vec_with_registry!(
                name("collector_gather_latency"),
                "Time taken to gather rows into a batch by this collector",
                &["pipeline"],
                PROCESSING_LATENCY_SEC_BUCKETS.to_vec(),
                registry,
            )
            .unwrap(),
            collector_batch_size: register_histogram_vec_with_registry!(
                name("collector_batch_size"),
                "Number of rows in a batch written to the database by this collector",
                &["pipeline"],
                BATCH_SIZE_BUCKETS.to_vec(),
                registry,
            )
            .unwrap(),
            total_collector_skipped_checkpoints: register_int_counter_vec_with_registry!(
                name("total_collector_skipped_checkpoints"),
                "Number of checkpoints skipped by the tasked pipeline's collector due to being below the main reader lo watermark",
                &["pipeline"],
                registry,
            ).unwrap(),
            collector_reader_lo: register_int_gauge_vec_with_registry!(
                name("collector_reader_lo"),
                "Reader low watermark as observed by the collector",
                &["pipeline"],
                registry,
            )
            .unwrap(),
            committer_commit_latency: register_histogram_vec_with_registry!(
                name("committer_commit_latency"),
                "Time taken to write a batch of rows to the database by this committer",
                &["pipeline"],
                DB_UPDATE_LATENCY_SEC_BUCKETS.to_vec(),
                registry,
            )
            .unwrap(),
            committer_tx_rows: register_histogram_vec_with_registry!(
                name("committer_tx_rows"),
                "Number of rows written to the database in a single database transaction by this committer",
                &["pipeline"],
                BATCH_SIZE_BUCKETS.to_vec(),
                registry,
            )
            .unwrap(),
            watermark_gather_latency: register_histogram_vec_with_registry!(
                name("watermark_gather_latency"),
                "Time taken to calculate the new high watermark after a write by this committer",
                &["pipeline"],
                PROCESSING_LATENCY_SEC_BUCKETS.to_vec(),