chore(proxy): guard metrics retention cleanup

This commit is contained in:
fawney19
2026-05-08 22:57:00 +08:00
parent a703acd1fe
commit e21fb58479
16 changed files with 562 additions and 75 deletions

View File

@@ -1073,11 +1073,16 @@ impl GatewayDataState {
&self,
retain_1m_from_unix_secs: u64,
retain_1h_from_unix_secs: u64,
delete_limit: usize,
) -> Result<super::ProxyNodeMetricsCleanupSummary, DataLayerError> {
match &self.proxy_node_writer {
Some(repository) => {
repository
.cleanup_proxy_node_metrics(retain_1m_from_unix_secs, retain_1h_from_unix_secs)
.cleanup_proxy_node_metrics(
retain_1m_from_unix_secs,
retain_1h_from_unix_secs,
delete_limit,
)
.await
}
None => Ok(super::ProxyNodeMetricsCleanupSummary::default()),