Skip to content
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

Find alternative to Bytes for data encoding #1

Open
markhildreth opened this issue Jul 26, 2022 · 0 comments
Open

Find alternative to Bytes for data encoding #1

markhildreth opened this issue Jul 26, 2022 · 0 comments

Comments

@markhildreth
Copy link
Owner

It seems a bit overkill to use Bytes for encoding. Bytes makes more sense in a situation where data is being streamed (e.g., over TCP) with one thread pushing to the buffer while another reads. With the ability to read an entire datagram at once the only niceity is
the API, but with an unnecessary Arc overhead.

Additionally, I'm fine with an API that requires the user to specify the buffer size and error if the buffer would be overwhelmed. That's usually an indication that we should reject the data to begin with.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant