Thread

Zero-JS Hypermedia Browser

Relays: 5
Replies: 10
Generated: 07:46:43
I’m almost done with the new relay for nostrcheck-server, currently experimenting with search extensions. So far, it’s stable and fast with 3,000,000 events loaded into memory. I had to fine-tune every operation to avoid bottlenecks across the system. Querying such a large dataset is inherently slow, but on top of that, the relay has to handle hundreds of simultaneous requests over open WebSockets. To tackle this, the relay currently runs with a pool of n workers and a processing queue for heavy tasks. It’s fully compatible with all relevant NIPs. Not designed for 100 million events yet, but more than capable of efficiently handling community-scale needs. I’m sure I’m running into the same problems others have already solved, but I’m doing it anyway—because this is Nostr. We have to keep 500 incomplete and incompatible clients connecting to 500 incomplete and incompatible relays, otherwise, what are we even doing here? 🤣🤓 Good morning #nerdstr 🥳🥳
2025-02-27 07:18:37 from 1 relay(s) 3 replies ↓
Login to reply

Replies (10)

i have a question for you—it might also relate to what you’re doing now. i want to set up a fast, lightweight relay dedicated to events like a paywall podcast event, but it has to be light & fast. i need to use it on my client to fetch those events & also be able to make requests from my server function to get & process relay data. i’m not expecting an exact answer, just your thoughts & experience while building this stuff—you might be able to point me to something.
2025-02-27 07:31:21 from 1 relay(s) ↑ Parent 1 replies ↓ Reply
Iefan, long time no talk 💜 A fast and lightweight relay, in my opinion, fundamentally depends on the number of events it stores. Any relay is fast with 10,000 events. So, I’d say any relay would work, especially if you’re filtering by just a few specific kinds. If you’d like, we can share opinions and code via DM or Telegram.
2025-02-27 07:51:48 from 1 relay(s) ↑ Parent 1 replies ↓ Reply
thanks for the response. i just want to deploy my relay using the best possible approach, completely forget about it & focus on other stuff, so i want to get it right from the start. any thoughts on strfry relay? that’s what i’m currently using. or is there any relay implementation more targeted towards apps? for example, if an app wants to use a relay as the majority of its backend, is there anything built for that, or do people just use strfry most of the time?
2025-02-27 08:07:33 from 1 relay(s) ↑ Parent 1 replies ↓ Reply