diff --git a/src/biz/snapshot/cache.rs b/src/biz/snapshot/cache.rs index 34f45c72..47048ed3 100644 --- a/src/biz/snapshot/cache.rs +++ b/src/biz/snapshot/cache.rs @@ -29,7 +29,7 @@ impl SnapshotCache { pub async fn insert(&self, key: &str, value: Vec) -> Result<(), AppError> { let mut redis = self.redis_client.lock().await; redis - .set(key, value) + .set_ex(key, value, 60 * 60 * 24) .await .map_err(|err| AppError::Internal(err.into()))?; Ok(())