add ttl to user_cache

This commit is contained in:
Bryan Stitt 2022-09-19 23:09:31 +00:00
parent 8785cb6d2d
commit 90fed885bc

View File

@ -351,6 +351,7 @@ impl Web3ProxyApp {
// TODO: max_capacity from config
let user_cache = Cache::builder()
.max_capacity(10_000)
.time_to_live(Duration::from_secs(60))
.build_with_hasher(ahash::RandomState::new());
let app = Self {