Replying to Avatar hzrd149

Added support for nostr:npub1v0lxxxxutpvrelsksy8cdhgfux9l6a42hsj2qzquu2zk7vc9qnkszrqj49's @snort/worker-relay package in #noStrudel, it runs a SQLite using WASM in a web worker 😀

Its not quite as fast as using the Indexeddb api but it doesn't make the browse freeze up as much. I have not tested it on mobile so I have no idea how well it will work.

You can find the package here https://git.v0l.io/Kieran/snort/src/branch/main/packages/worker-relay

And if your reading this nostr:npub1v0lxxxxutpvrelsksy8cdhgfux9l6a42hsj2qzquu2zk7vc9qnkszrqj49 there are a few improvements id like to see

- a way to delete specific events (base on a REQ filter) from the database

- a method for deleting the database out right

- the ability to stop the web worker and close the database

Right now there is no way to "manage" the database so it just keeps growing in size 😞

Changes are only on next.nostrudel.ninja for testing

pls enable disabling all caches altogether

Reply to this note

Please Login to reply.

Discussion

that would be a cool idea. although I think it would be better to build an in-memory cache. that way you could view stats (total events stored, kinds) but it would reset every time you open the app

pls, just enable disabling of all caching so set relays must be queried

this would be huge for relay devs in general and massive for me, set a price i'll pay it

disabling the cache is a little difficult because the whole app is built around the expectation that the cache exists. although it could be easier than I'm thinking to remove that requirement

if you make this possible i will zap you 14400 sats

remind me

i will double this at some point, don't mess with me

I would be afraid that many normies would find that option and try it out to never un-try it later, just increasing traffic for them and relays while creating support issues for OP.

on behalf of all the relay devs and back end devs in the universe, i wish to bid you a merry GFY