From 28bf763b335d12c71bcb60945f9c05977a54fbee Mon Sep 17 00:00:00 2001 From: Reinier Criel Date: Wed, 22 Apr 2026 21:14:06 -0700 Subject: [PATCH] Speed up config fetch rate --- proxy-lib/src/endpoint_protection/config.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/proxy-lib/src/endpoint_protection/config.rs b/proxy-lib/src/endpoint_protection/config.rs index 7710c36c..4e2abe33 100644 --- a/proxy-lib/src/endpoint_protection/config.rs +++ b/proxy-lib/src/endpoint_protection/config.rs @@ -1,4 +1,4 @@ -use std::sync::Arc; +use std::{sync::Arc, time::Duration}; use rama::{ Service, @@ -136,6 +136,10 @@ impl RemoteResourceSpec for EndpointConfigRemoteResource { type Payload = EndpointConfig; type State = Option; + fn refresh_interval(&self) -> Duration { + Duration::from_secs(30) + } + fn build_request(&self) -> Result { let mut req = Request::builder() .uri(self.uri.clone())