cargo fmt (unrelated to prev commit)

This commit is contained in:
Christian Schwarz
2025-07-25 13:33:02 +02:00
parent a948054db3
commit 1e61ac6af2
3 changed files with 10 additions and 8 deletions

View File

@@ -20,6 +20,7 @@ pub mod lsn_lease;
pub mod metrics;
mod migration;
pub mod monitor;
pub mod pageserver_client;
pub mod params;
pub mod pg_helpers;
pub mod pgbouncer;
@@ -30,4 +31,3 @@ mod spec_apply;
pub mod swap;
pub mod sync_sk;
pub mod tls;
pub mod pageserver_client;

View File

@@ -144,7 +144,10 @@ impl Client {
Ok(resp.try_into()?)
}
pub async fn lease_standby_horizon(&mut self, req: LeaseStandbyHorizonRequest) -> tonic::Result<LeaseStandbyHorizonResponse> {
pub async fn lease_standby_horizon(
&mut self,
req: LeaseStandbyHorizonRequest,
) -> tonic::Result<LeaseStandbyHorizonResponse> {
let req = proto::LeaseStandbyHorizonRequest::from(req);
let resp = self.inner.lease_standby_horizon(req).await?.into_inner();
Ok(resp.try_into()?)

View File

@@ -735,7 +735,8 @@ static STANDBY_HORIZON_LEASES: Lazy<UIntGaugeVec> = Lazy::new(|| {
"pageserver_standby_horizon_leases",
"Gauge indicating current number of standby horizon leases, per timeline",
&["tenant_id", "shard_id", "timeline_id"]
).expect("failed to define a metric")
)
.expect("failed to define a metric")
});
static RESIDENT_PHYSICAL_SIZE: Lazy<UIntGaugeVec> = Lazy::new(|| {
@@ -3344,11 +3345,9 @@ impl TimelineMetrics {
legacy_value: STANDBY_HORIZON
.get_metric_with_label_values(&[&tenant_id, &shard_id, &timeline_id])
.unwrap(),
leases_count_gauge: STANDBY_HORIZON_LEASES.get_metric_with_label_values(&[
&tenant_id,
&shard_id,
&timeline_id,
]).unwrap(),
leases_count_gauge: STANDBY_HORIZON_LEASES
.get_metric_with_label_values(&[&tenant_id, &shard_id, &timeline_id])
.unwrap(),
};
let resident_physical_size_gauge = RESIDENT_PHYSICAL_SIZE
.get_metric_with_label_values(&[&tenant_id, &shard_id, &timeline_id])