protocol-http2 0.27.0 → 0.28.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e218c8562a926b98f24ad707341e1ee24d26ed6ce94b9f6550049000f415cd2b
4
- data.tar.gz: 8ed236e94626982bd750d03a5c568c7b438e233b09256b671e5373db0881617c
3
+ metadata.gz: b123bcf0056d6c21b757beb154bd0e20b099175880fa563f55cb5793c91c0013
4
+ data.tar.gz: 42721396177fccec6c4ec2201e927b6de774d7ef604dabf9652c68c84ea6b8b1
5
5
  SHA512:
6
- metadata.gz: 31dfad736c2d3807ba103ccd70dea68d95375fe53f290582f805691c7b51cc43512494e2aae439c90082b0fbf518568c78e574bf9a3bb19dc4312127eb6378db
7
- data.tar.gz: 2ee408ca054cd3ae3eb205489ea0b7095fe896af11bcb810e377a627d824cd2b6440d013ace9ebba79886ac71c067a541209007c9ee169dcd78803c2be531172
6
+ metadata.gz: 22c8475249a63cc3b4276ac867b6034379f15f10795204d81b1e79de46cb2e1d431a9766537eca67766ca3e88703fc82f8ff38774486d04ee0d4999e8a0e801d
7
+ data.tar.gz: fb451afbc0ef6c216601c18221ed0bfd107fa4262597bf7d3a8188293ae2f475e5f312641a91abbdacb79617837667b769efe1c5cc198f08234506d48cdcf74d
checksums.yaml.gz.sig CHANGED
Binary file
@@ -239,22 +239,21 @@ module Protocol
239
239
  return self
240
240
  end
241
241
 
242
- # The stream has been closed. If closed due to a stream reset, the error will be set.
242
+ # The stream has been closed. If closed due to a stream reset with a non-zero error code, the error will be set.
243
243
  def closed(error = nil)
244
244
  end
245
245
 
246
246
  # Transition the stream into the closed state.
247
- # @parameter error_code [Integer] the error code if the stream was closed due to a stream reset.
247
+ # @parameter error_code [Integer | Nil] The error code if the stream was closed due to a stream reset.
248
248
  def close!(error_code = nil)
249
249
  @state = :closed
250
250
  @connection.delete(@id)
251
251
 
252
- if error_code
253
- if error_code == REFUSED_STREAM
254
- error = ::Protocol::HTTP::RefusedError.new("Stream refused.")
255
- else
256
- error = StreamError.for(error_code)
257
- end
252
+ # `NO_ERROR` represents an orderly stream closure, so it is passed to `closed` as `nil` rather than converted to an exception.
253
+ if error_code == REFUSED_STREAM
254
+ error = ::Protocol::HTTP::RefusedError.new("Stream refused.")
255
+ elsif error_code && error_code != NO_ERROR
256
+ error = StreamError.for(error_code)
258
257
  end
259
258
 
260
259
  self.closed(error)
@@ -7,6 +7,6 @@
7
7
  module Protocol
8
8
  # @namespace
9
9
  module HTTP2
10
- VERSION = "0.27.0"
10
+ VERSION = "0.28.0"
11
11
  end
12
12
  end
data/readme.md CHANGED
@@ -14,6 +14,10 @@ Please see the [project documentation](https://socketry.github.io/protocol-http2
14
14
 
15
15
  Please see the [project releases](https://socketry.github.io/protocol-http2/releases/index) for all releases.
16
16
 
17
+ ### v0.28.0
18
+
19
+ - Treat `RST_STREAM(NO_ERROR)` as an orderly stream closure rather than constructing a `StreamError`.
20
+
17
21
  ### v0.27.0
18
22
 
19
23
  - On a graceful `GOAWAY` (error code `0`), keep the connection open until the streams the remote peer accepted have completed, instead of closing it immediately and failing those requests with `EOFError`.
@@ -53,10 +57,6 @@ Please see the [project releases](https://socketry.github.io/protocol-http2/rele
53
57
 
54
58
  - [Added Priority Update Frame and Stream Priority](https://socketry.github.io/protocol-http2/releases/index#added-priority-update-frame-and-stream-priority)
55
59
 
56
- ### v0.21.0
57
-
58
- - **Breaking**: Removed support for priority frame and stream dependencies. The `Protocol::HTTP2::Stream` class no longer tracks dependencies, and `Stream#send_headers` no longer takes `priority` as the first argument. This change simplifies the internal implementation significantly as HTTP/2 priority frames have been deprecated in the protocol specification.
59
-
60
60
  ## See Also
61
61
 
62
62
  - [Async::HTTP](https://github.com/socketry/async-http) - A high-level HTTP client and server implementation.
data/releases.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Releases
2
2
 
3
+ ## v0.28.0
4
+
5
+ - Treat `RST_STREAM(NO_ERROR)` as an orderly stream closure rather than constructing a `StreamError`.
6
+
3
7
  ## v0.27.0
4
8
 
5
9
  - On a graceful `GOAWAY` (error code `0`), keep the connection open until the streams the remote peer accepted have completed, instead of closing it immediately and failing those requests with `EOFError`.
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: protocol-http2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.27.0
4
+ version: 0.28.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
metadata.gz.sig CHANGED
@@ -1,2 +1,2 @@
1
- t̶��N���r��{��k#x��<���&���1Z�@�lU���asA�^�4�CY-�W;8 7*�Ǭ�㎿�H_��� H=�)#"#��*�d��7������z�����H+Y�t�� 0'��/���݄�q��4Wnx�ozu�\�-h`�m��v��.���\"�1��Ox��T])H$Z����婖O{x�Ȳ�xŢ!)yg�(�.��ڈ�4»V�
2
- �׫�Aw<���C���IU��\�aT� ��R�����2S���?�J%'�����g 1��3\6U(�����kP���}�[��kk`Ns�v�(��|�)1Zc��>��W*��t�n��$��^�ޫ�x��Y7�`�6.�bp �
1
+ �G$٣@��5�'�7����It/�ua*�(I@1����+O�G+t)� 5�6v7�G�Z�k���������Cƽ�<ĸ��N�}q&�T2-Z�Ɲ�ě�)M�f�T�LlŲ�X�M��.Ү�A�M�#Ke��3�ʈ�@x�K�0���0�{FF.�R�T�����Ss�Ue���o� �F���{�=k|���e�/h��e1UI�=� �G���a��J��7�t����-�Xnc ��"�����u8ic %FA~,��I�.�"au�̝�qJ����p
2
+ ��7���-\�kw%�8oNKZ���=)DnӧlcHW [_�� W|a��a�