I'd sure like to see #Nostr move to #protobuf + streaming persistent connections in the coming years.

So much wasted time/redources going into polling relays and marshalling JSON, not to mention all the extra legwork defending against malshaped request/response bodies.

It's a damn shame.

Reply to this note

Please Login to reply.

Discussion

i used to think this, but inefficiency is par for the course with websites in general. simple JSON makes it much easier to build for

Strongly-typed clients eliminate all the room for error. The client becomes the documentation and all that defensive coding goes away. Not to mention increased performance and reduced load.

The hard part with proto is generating clients and distributing them.

There are teams out there making sense of that part: https://buf.build/solutions/adopt-protobuf-on-web-and-mobile