From 099fec6e3109f0b504b4da8b755a3fb6fef73264 Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Fri, 20 Sep 2024 13:13:26 -0500 Subject: [PATCH] Increase nip05 cache to 3000, link previews to 1000 --- src/utils/nip05.ts | 2 +- src/utils/unfurl.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/nip05.ts b/src/utils/nip05.ts index 696b5078..8f453c93 100644 --- a/src/utils/nip05.ts +++ b/src/utils/nip05.ts @@ -44,7 +44,7 @@ const nip05Cache = new SimpleLRU( throw e; } }, - { max: 500, ttl: Time.hours(1), gauge: cachedNip05sSizeGauge }, + { max: 3000, ttl: Time.hours(1), gauge: cachedNip05sSizeGauge }, ); async function localNip05Lookup(store: NStore, localpart: string): Promise { diff --git a/src/utils/unfurl.ts b/src/utils/unfurl.ts index e749dbcb..5763c151 100644 --- a/src/utils/unfurl.ts +++ b/src/utils/unfurl.ts @@ -57,7 +57,7 @@ async function unfurlCard(url: string, signal: AbortSignal): Promise>({ ttl: Time.hours(12), - max: 500, + max: 1000, }); /** Unfurl card from cache if available, otherwise fetch it. */