async-websocket 0.12.1 → 0.12.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ce69a19f9de2e43719dfb5f5d078a50ac861132e153195f1762fed28114bc6aa
4
- data.tar.gz: ff8d041d95a76e68c2352db339802957472f4cf77aaa948242cdec8f6a7281d5
3
+ metadata.gz: a9ed569bb920db994f1bbc777cb0edb7134a264bcbe1d4b50d20548b27694484
4
+ data.tar.gz: 1ffab71222838d000e0fbfdbeb83736058d8aae007679f55b0f05e2597acba6a
5
5
  SHA512:
6
- metadata.gz: f4ed4461f1a5ece9ad6866220d6eae27cd1f61cd0572765c7e7412b8bb4a2f2aba0043008b3d70f94025de6a29c00d55ec95de2e4ab890000594038dc9cf7126
7
- data.tar.gz: d012e7149f746dbfbae8bade2e76efc0432594ef0eb47b84cd867a89b79dc0bb8ea76380900304428fd7dfc1d38f6a9bb7cd26ff626e5f913faa6a4cbfa6ead0
6
+ metadata.gz: 3f26b555da7f2e0c552e665d34799d51102224f32a3bf5a1b30526bd24751ddb2319cac54ca2292dd8fd11afacd05272ca97c9d28453edfc1e1dc9715b85f840
7
+ data.tar.gz: b18f15df6147da77f3dad4d1c0cbd656be2e17107c79c984fd276bd71bb0abe014c64cb28f46ce91f81755ae8790798d993be226b64cc8e95386092dff5210f4
@@ -14,6 +14,5 @@ matrix:
14
14
  env: JRUBY_OPTS="--debug -X+O"
15
15
  - rvm: ruby-head
16
16
  allow_failures:
17
- - rvm: truffleruby
18
17
  - rvm: ruby-head
19
18
  - rvm: jruby-head
data/README.md CHANGED
@@ -75,13 +75,13 @@ end
75
75
  ```ruby
76
76
  #!/usr/bin/env -S falcon serve --bind http://localhost:7070 --count 1 -c
77
77
 
78
- require 'async/websocket/server/rack'
78
+ require 'async/websocket/adapters/rack'
79
79
  require 'set'
80
80
 
81
81
  $connections = Set.new
82
82
 
83
83
  run lambda {|env|
84
- Async::WebSocket::Server::Rack.open(env, protocols: ['ws']) do |connection|
84
+ Async::WebSocket::Adapters::Rack.open(env, protocols: ['ws']) do |connection|
85
85
  $connections << connection
86
86
 
87
87
  while message = connection.read
@@ -17,7 +17,7 @@ Gem::Specification.new do |spec|
17
17
 
18
18
  spec.add_dependency "async-io", "~> 1.23"
19
19
  spec.add_dependency "async-http", "~> 0.43"
20
- spec.add_dependency "protocol-websocket", "~> 0.6.0"
20
+ spec.add_dependency "protocol-websocket", "~> 0.7.0"
21
21
 
22
22
  spec.add_development_dependency "async-rspec"
23
23
  spec.add_development_dependency "falcon", "~> 0.32"
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env falcon serve --count 1 --bind http://127.0.0.1:7070 -c
2
2
 
3
- require 'async/websocket/server/rack'
3
+ require 'async/websocket/adapters/rack'
4
4
 
5
5
  class Room
6
6
  def initialize(name, description = nil)
@@ -124,7 +124,7 @@ class Server
124
124
  end
125
125
 
126
126
  def call(env)
127
- Async::WebSocket::Server::Rack.open(env, connect: User) do |user|
127
+ Async::WebSocket::Adapters::Rack.open(env, connect: User) do |user|
128
128
  @entrance.enter(user)
129
129
 
130
130
  while message = user.read
@@ -1,13 +1,13 @@
1
1
 
2
2
  prepend Actions
3
3
 
4
- require 'async/websocket/server/rack'
4
+ require 'async/websocket/adapters/rack'
5
5
  require 'set'
6
6
 
7
7
  $connections = Set.new
8
8
 
9
9
  on 'connect' do |request|
10
- response = Async::WebSocket::Server::Rack.open(request.env) do |connection|
10
+ response = Async::WebSocket::Adapters::Rack.open(request.env) do |connection|
11
11
  $connections << connection
12
12
 
13
13
  while message = connection.read
@@ -20,6 +20,6 @@
20
20
 
21
21
  module Async
22
22
  module WebSocket
23
- VERSION = "0.12.1"
23
+ VERSION = "0.12.2"
24
24
  end
25
25
  end
@@ -71,7 +71,6 @@ RSpec.shared_context Async::WebSocket::Server do
71
71
  expect(connection.read).to be_nil
72
72
  expect(connection).to be_closed
73
73
 
74
- Async.logger.debug(connection, "Closing connection...")
75
74
  connection.close
76
75
  end
77
76
  end
@@ -18,7 +18,7 @@
18
18
  # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19
19
  # THE SOFTWARE.
20
20
 
21
- require 'async/websocket/server/rack'
21
+ require 'async/websocket/adapters/rack'
22
22
 
23
23
  class Upgrade
24
24
  def initialize(app)
@@ -26,7 +26,7 @@ class Upgrade
26
26
  end
27
27
 
28
28
  def call(env)
29
- Async::WebSocket::Server::Rack.open(env, supported_protocols: ['ws']) do |connection|
29
+ Async::WebSocket::Adapters::Rack.open(env, supported_protocols: ['ws']) do |connection|
30
30
  read, write = IO.pipe
31
31
 
32
32
  Process.spawn("ls -lah", :out => write)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: async-websocket
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.12.1
4
+ version: 0.12.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-06-06 00:00:00.000000000 Z
11
+ date: 2019-06-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: async-io
@@ -44,14 +44,14 @@ dependencies:
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 0.6.0
47
+ version: 0.7.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: 0.6.0
54
+ version: 0.7.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: async-rspec
57
57
  requirement: !ruby/object:Gem::Requirement