jb55 @jb55 - 2y
one of the slowest parts of receiving lots of events on mobile is actually json decoding. I wonder if it’s time to create an optimized binary transport for nostr notes. Could be a simple TLV format.
b3e43 - 2y
グッドモーニング☀️
0e460 - 2y
That’s what I call an idea 👍
ohaiou
f4db5 - 2y
GM Will 🌞💜🧡🤙
5abcd - 2y
I have no idea what you are saying but I know it will be awesome.
496d3 - 2y
That is correct, will. Now tell the people what the audiophiles prize. 📎
nostrnaut @nostrnaut - 2y
me reading this note:
b2dd4 - 2y
Using the inbuilt Apple JSON support? Maybe we can try swap out to a faster external library? The other major issue I see is websockets have no congestion management - it’s event by event, and a large event blocks all the smaller ones behind it.
Jack Chakany @Jack - 2y
Definitely
This? “IkigaJSON is a really fast JSON parser. It performed ~4x faster than macOS/iOS Foundation in our tests when decoding a type from JSON.” https://github.com/orlandos-nl/IkigaJSON
0xtr @0xtr - 2y
I don’t see why not 🤷♂️
i tried a branch where I built my own custom json decoder, but you still need to walk every byte in the string and unescape things. json decoding is not trivial, where a TLV format would be as simple as copying bytes directly.
8eee8 - 2y
Yes. And there is more of what should be done: https://damus.io/note12044688xrg67tnc2lkv5whwrvycy0y2rsrg6lgd8s8ses2pr57nsfv85x5
gek @gek - 2y
I don’t think I understand what this man means but it talks about replacing json decoding with something else… if it’s j something it needs replacing, right? Thant’s how it works?
I need to automatically convert these links to note refs…. nostr:note12044688xrg67tnc2lkv5whwrvycy0y2rsrg6lgd8s8ses2pr57nsfv85x5
ohayo!
Duck Nebuchadnezzar @duck - 2y
Would this mean that relays would need to support both formats? (falling back to json if the client doesn't support it)
Nope, relays could advertise that they support it or not. Would be completely optional.
1e9d8 - 2y
But then you specifically request data in this firmat from the relay, so that you need no detection on client side, right?
It would be advertised in the relay metadata if it’s supported or not.
I have a draft for “denostr” with Noise_XK encryption, GPG/SSH keys, binary data & DoS protection - which is interoperable with current nostr (each denostr mag is valid nostr msg). Plan to submit a NIP.
I can’t see anyone using that, too much is changed