News for hackers. Stuff that matters.
Re:Parsing JSON Is a Minefield (2018) by megous on Saturday August 17, 2019 @09:05PM (#20727530)
You can still reserve one value as a control character and have non-text streams that don't need prefixing of data frames by size.

These are also easier to recover the data from in case of corruption, or re-sync the receiver, since you have a control byte you can sync on.

Re:Parsing JSON Is a Minefield (2018) by blackflame7000 on Saturday August 17, 2019 @11:52PM (#20728134)
Yes, in fact, this is most common in video streaming formats. These types of streams are more commonly downloaded as opposed to uploaded where the server has to be careful not to exhaust too many resources parsing variable-length messages.
Re:Parsing JSON Is a Minefield (2018) by megous on Monday August 19, 2019 @09:55AM (#20737749)
It's also fairly common if you have alway-on streams without any signalling, where you can connect to the stream at any time, like with UART.