NFIBrokerage / spear

A sharp EventStoreDB v20+ client backed by Mint :yum:
https://hex.pm/packages/spear
Apache License 2.0
85 stars 14 forks source link

remove unnecessary access of opaque Mint.HTTP2 field #62

Closed the-mikedavis closed 2 years ago

the-mikedavis commented 2 years ago

In the spirit of https://github.com/elixir-mint/mint/issues/333, we should remove this conn.ref_to_stream_id access since that field is part of the opaque t:Mint.HTTP2.t/0

If I remember correctly, I was trying to avoid the raise that happens when the request_ref does not belong to the conn. I think since this block was written we've refactored the connection to successfully curate its set of open request_refs, so we never end up calling safe_get_request_window_size/2 with an unknown request_ref.