-
Notifications
You must be signed in to change notification settings - Fork 206
Bayeux Protocol 2.0 #1053
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@gregw more ideas? |
We need to do some experiments first. Is there really a difference between:
Json is very compressible and json parsing is pretty fast and I expect much of the time is actually spent visiting/contructing the map objects being sent. So I'd like to see some JMH benchmarks of the server-side differences for some binary messages before committing to reworking the clients. |
@gregw agreed. Although the main reason is binary payloads such as images or video/audio. Right now we can Z85 encode/decode with some overhead in size with respect to the binary size (Z85 is similar to Base64 just slightly better). |
Binary payloads are not that common and it would be easy enough to come up with a solution that you just push a URI to fetch the value and if latency is an issue then use http2 to push the binary so it arrives with the message. I think we'd need to see general benefits of binary message format before making the change. |
Now that binary JavaScript is real, it is time to review the Bayeux Protocol and make it binary.
Goals:
meta
messages.Messages such as those on
/meta/connect
channels should amount to just few bytes, therefore using less bandwidth and be faster to parse.message.data
payloads, but still support JSON payloads (Content-Type
)Content-Encoding
)The text was updated successfully, but these errors were encountered: