ocaml-cohttp
ocaml-cohttp copied to clipboard
cohttp-eio `expert` mode doesn't allow closing of the stream
the Expert handler type documentation says that you can close the input channel to close the connection. When using Cohttp_eio, the input channel is of type Eio.Buf_read, which does not have any mechanism to close its underlying flow. currently we work around this by declaring exception Die and raiseing it in the callback, but it would be nice to have some kind of underlying access to the flows, or some mechanism for deliberately closing the connection.