Why Nostr? What is Njump?
2024-07-20 20:15:52
in reply to

Alex Gleason on Nostr: Refreshing is the right workaround. The second time you load it's cached so it works, ...

Refreshing is the right workaround. The second time you load it's cached so it works, but the cache goes stale after like a minute so it gets slow again.

The root cause is that tag queries are slow.

I figured out it's because the query is trying to load all "p" tags EVER that reference your pubkey instead of just the ones it needs. This means it will retrieve 30,000+ tag rows just to render 20 events. So I am doing surgery on the database in production right now trying to resolve it, but creating the necessary indexes is taking several days.
Author Public Key
npub1q3sle0kvfsehgsuexttt3ugjd8xdklxfwwkh559wxckmzddywnws6cd26p