protocol-http2 0.5.0 → 0.5.1
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '059852cf900073a0e3912ecaecb404c6dc03399171ba1d8d652c94d5c2d05bcb'
|
4
|
+
data.tar.gz: af70c37e08a40cb9ad29405bfa2fedcb35883a5cc198514c0f4b9b2bd9e8d16f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f037c46422f893916eefc69166f38f2f4438648b763cf6326e8fc2ee2d6da8d97eeb7eeb0ff1609d126ae94b2d79312bad11c10f5ae9d42db73b236847af9649
|
7
|
+
data.tar.gz: abc5da3f1ebf160d3427641c5040efad5dd29b5316bf619a5dbae6e66e598e3cd7847517ef4519a9987f889219284e7ee9c7e8b6c96977e6fbe988ebef37b6e5
|
@@ -47,13 +47,6 @@ module Protocol
|
|
47
47
|
end
|
48
48
|
end
|
49
49
|
|
50
|
-
# Accept an incoming push promise from the other side of the connection.
|
51
|
-
# On the client side, we accept push promise streams.
|
52
|
-
# On the server side, streams create push promise streams.
|
53
|
-
def accept_push_promise_stream(stream_id, &block)
|
54
|
-
accept_stream(stream_id, &block)
|
55
|
-
end
|
56
|
-
|
57
50
|
def create_push_promise_stream
|
58
51
|
raise ProtocolError, "Cannot create push promises from client!"
|
59
52
|
end
|
@@ -290,6 +290,9 @@ module Protocol
|
|
290
290
|
create_stream(stream_id, &block)
|
291
291
|
end
|
292
292
|
|
293
|
+
# Accept an incoming push promise from the other side of the connection.
|
294
|
+
# On the client side, we accept push promise streams.
|
295
|
+
# On the server side, existing streams create push promise streams.
|
293
296
|
def accept_push_promise_stream(stream_id, &block)
|
294
297
|
accept_stream(stream_id, &block)
|
295
298
|
end
|
@@ -22,6 +22,9 @@ require_relative 'frame'
|
|
22
22
|
|
23
23
|
module Protocol
|
24
24
|
module HTTP2
|
25
|
+
# Stream Dependency: A 31-bit stream identifier for the stream that
|
26
|
+
# this stream depends on (see Section 5.3). This field is only
|
27
|
+
# present if the PRIORITY flag is set.
|
25
28
|
Priority = Struct.new(:exclusive, :stream_dependency, :weight) do
|
26
29
|
FORMAT = "NC".freeze
|
27
30
|
EXCLUSIVE = 1 << 31
|
@@ -103,8 +103,8 @@ module Protocol
|
|
103
103
|
attr :remote_window
|
104
104
|
|
105
105
|
def priority= priority
|
106
|
-
if priority.
|
107
|
-
raise ProtocolError, "Stream #{@id} cannot depend on itself!"
|
106
|
+
if priority.stream_dependency == @id
|
107
|
+
raise ProtocolError, "Stream priority for stream id #{@id} cannot depend on itself!"
|
108
108
|
end
|
109
109
|
|
110
110
|
@priority = priority
|