anycable 0.1.0 → 0.2.0

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
  SHA1:
3
- metadata.gz: 1728535555e8fb2b4117c3acc46a37c99f854b20
4
- data.tar.gz: 50344774fb497a690c610a6e4d2758ab8237aa89
3
+ metadata.gz: eafc0ee0da24cde74dd95034c6e2021f30baefd6
4
+ data.tar.gz: a72505c9ce7e11651bade19e3bd078c10faec624
5
5
  SHA512:
6
- metadata.gz: d1679838e7116f199f29e1ef51d156422da51daa52c6f6b61e42adf0d1d17e36c47f45614fa05f400757a3811d80e03ca26196cca1055c314a3f7b97b9dec523
7
- data.tar.gz: 3cf4eb06da615053c914b86da466d77f3f4f9bc84265d3fcb4079ebd8e30ce451d9bbd2cf5fa62637f543bfc3fbe0f5ba21594e0870bef9e6c1fe6b53ad70c66
6
+ metadata.gz: e9ecf0ee0cd599092cf3ea4b1ff46688c3e4ed6551f03f3ec6e3eb37e79e6652f4df027c5e1a41aefb94c498584b2a4553fb5c4d3995b596b0c9c550f8718c39
7
+ data.tar.gz: d729762ead17bfff76c8d9b287d8b2b06d63d7efe8383b22c0ec439b4b079379ad9713b53b161b6344adcb05341a3c0ed5f8bb79df2565c286596514f79dc311
data/README.md CHANGED
@@ -8,6 +8,11 @@ With AnyCable you can use channels, client-side JS, broadcasting - (almost) all
8
8
 
9
9
  You can even use ActionCable in development and not be afraid of compatibility issues.
10
10
 
11
+ [Example Application](https://github.com/anycable/anycable_demo)
12
+
13
+ <a href="https://evilmartians.com/">
14
+ <img src="https://evilmartians.com/badges/sponsored-by-evil-martians.svg" alt="Sponsored by Evil Martians" width="236" height="54"></a>
15
+
11
16
  ## Requirements
12
17
 
13
18
  - Ruby ~> 2.3;
@@ -16,11 +21,12 @@ You can even use ActionCable in development and not be afraid of compatibility i
16
21
 
17
22
  ## How It Works?
18
23
 
19
- TBD
24
+ <img src="https://trello-attachments.s3.amazonaws.com/5781e0ed48e4679e302833d3/820x987/5b6a305417b04e20e75f49c5816e027c/Anycable_vs_ActionCable_copy.jpg" width="400" />
20
25
 
21
26
  ## Compatible WebSocket servers
22
27
 
23
- TBD
28
+ - [Anycable Go](https://github.com/anycable/anycable-go)
29
+ - coming soon ...
24
30
 
25
31
 
26
32
  ## Installation
@@ -47,7 +53,7 @@ Add `config/anycable.yml`if you want to override defaults (see below):
47
53
 
48
54
  ```yml
49
55
  production:
50
- # gRPC server host and port
56
+ # gRPC server host
51
57
  rpc_host: "localhost:50051"
52
58
  # Redis URL (for broadcasting)
53
59
  redis_url: "redis://localhost:6379/2"
@@ -63,7 +69,7 @@ Anycable uses [anyway_config](https://github.com/palkan/anyway_config), thus it
63
69
  Run Anycable server:
64
70
 
65
71
  ```ruby
66
- bundle exec anycable
72
+ ./bin/anycable
67
73
  ```
68
74
 
69
75
  ## ActionCable Compatibility
@@ -23,9 +23,8 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
23
23
  optional :status, :enum, 1, "anycable.Status"
24
24
  optional :disconnect, :bool, 2
25
25
  optional :stop_streams, :bool, 3
26
- optional :stream_from, :bool, 4
27
- optional :stream_id, :string, 5
28
- repeated :transmissions, :string, 6
26
+ repeated :streams, :string, 4
27
+ repeated :transmissions, :string, 5
29
28
  end
30
29
  add_message "anycable.DisconnectRequest" do
31
30
  optional :identifiers, :string, 1
@@ -6,7 +6,10 @@ require_relative 'rpc'
6
6
 
7
7
  module Anycable
8
8
  module RPC
9
+
10
+ # TODO: add proto service documentation here
9
11
  class Service
12
+
10
13
  include GRPC::GenericService
11
14
 
12
15
  self.marshal_class_method = :encode
@@ -61,8 +61,7 @@ module Anycable
61
61
  status: Anycable::Status::SUCCESS,
62
62
  disconnect: connection.closed?,
63
63
  stop_streams: channel.stop_streams?,
64
- stream_from: channel.streams.present?,
65
- stream_id: channel.streams.first || '',
64
+ streams: channel.streams,
66
65
  transmissions: connection.transmissions
67
66
  )
68
67
  end
@@ -78,8 +77,7 @@ module Anycable
78
77
  Anycable::CommandResponse.new(
79
78
  status: Anycable::Status::SUCCESS,
80
79
  disconnect: false,
81
- stop_streams: true,
82
- stream_from: false
80
+ stop_streams: true
83
81
  )
84
82
  end
85
83
 
@@ -97,8 +95,7 @@ module Anycable
97
95
  status: Anycable::Status::SUCCESS,
98
96
  disconnect: connection.closed?,
99
97
  stop_streams: channel.stop_streams?,
100
- stream_from: channel.streams.present?,
101
- stream_id: channel.streams.first || '',
98
+ streams: channel.streams,
102
99
  transmissions: connection.transmissions
103
100
  )
104
101
  else
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module Anycable
3
- VERSION = "0.1.0"
3
+ VERSION = "0.2.0"
4
4
  end
@@ -37,9 +37,8 @@ message CommandResponse {
37
37
  Status status = 1;
38
38
  bool disconnect = 2;
39
39
  bool stop_streams = 3;
40
- bool stream_from = 4;
41
- string stream_id = 5;
42
- repeated string transmissions = 6;
40
+ repeated string streams = 4;
41
+ repeated string transmissions = 5;
43
42
  }
44
43
 
45
44
  message DisconnectRequest {
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: anycable
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - palkan
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-09-03 00:00:00.000000000 Z
11
+ date: 2016-10-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -198,4 +198,3 @@ signing_key:
198
198
  specification_version: 4
199
199
  summary: Polyglot replacement for ActionCable server
200
200
  test_files: []
201
- has_rdoc: