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

Compatibility with ocaml-h2 #9

Open
314eter opened this issue Apr 24, 2019 · 0 comments
Open

Compatibility with ocaml-h2 #9

314eter opened this issue Apr 24, 2019 · 0 comments

Comments

@314eter
Copy link
Owner

314eter commented Apr 24, 2019

There are some differences with ocaml-h2 that still need to be addressed.

Error handling

Angstrom already has error handling, so I think there is no need to return a (header list, error) result if there is only one type of error.

Naming

Decoder.headers should be renamed to Decoder.decode_headers. I don't like the repetition in Decoder.decode_headers decoder very much, but it's probably clearer. Another possibility is to rename Encoder.encode_header to Encoder.header.

I prefer Encoder.change_table_size and Decoder.change_table_size_limit over set_capacity for both.

I think never_index is more descriptive than sensitive. It's perfectly possible to encode headers that are not sensitive with never_index. But it's not a strong preference, I'm okay with sensitive too.

Interface changes

The (optional) arguments of Decoder.create and Encoder.create are changed, but it's easy to adapt h2.

In #8 there is a bigger change to the interface, that makes Header.t a private type.

Header list order

The header list is not reversed anymore.

Table size changes

These are not implemented yet in h2.

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