I'm not a coder, but... (Surely horrors follow here)

Every event has to have some kind of ID, right? The ID gets signed by your nsec, and things like links and jpegs follow... something like that?

And your client asks relays for any events it has seen, right? If I'm at least in the right ballpark, then you should be able to have a client check all new events against events it has already displayed. So then it could put missed events at the top, maybe with a little angel next to the timestamp to tell you its been resurrected.

Idk. Not a coder. Hopefully that wasn't too bad.

Reply to this note

Please Login to reply.

Discussion

What you're describing works for events/messages that a relay has received but I think she's describing the situation where you're favourite nostr account is posting to two relays for example, relay A and relay B. You grab your events from relay B but maybe the newest event from your fav nostr account somehow didn't make it to relay B. And you would have no idea.

And to be clear you have no idea about the existence of relay A in my example*

Okay, how about this idea - relays chirp at each other at intervals, saying, "hey I got these events, you got them?" But it would really work by taking all events from a certain npub for the past 3 hrs, hashing them, comparing that string with the same hashed output from your own relay, then going forward with a bigger exchange if there's a mismatch. So your own relay would do that for each npub you follow every three hours or so.

This might be where relays start having to specialize - I see devs pushing for us setting up relays for certain functions, but it doesn't seem necessary right now.

There is a protocol for syncing distributed databases called negentropy that does something similar to what you're describing. And although your solution works on paper, there are trade offs. 1. Relays become bloated as every relay needs a copy of every event making it harder for anyone to run a relay. 2. This would certainly make queries for events slower as a result (since now there are so many events to go through to find the right ones). 3. Relays can no longer serve small isolated communities that know nothing about the rest of the nostr network and instead serve one giant public square removing some flexibility in the network.