mirror of
https://github.com/neondatabase/neon.git
synced 2026-05-17 21:20:37 +00:00
cargo fmt (unrelated to prev commit)
This commit is contained in:
@@ -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;
|
||||
|
||||
@@ -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()?)
|
||||
|
||||
@@ -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])
|
||||
|
||||
Reference in New Issue
Block a user