Rafael Mendonça França
1bc9db4a06
Merge pull request #47483 from palkan/fix/channel-test-case-test-server
...
Fix using TestServer in ConnectionStub
2023-03-03 18:23:21 -05:00
Haroon Ahmed
627322eff4
Add a fake configuration with the ability to override the
...
subscription_adapter, so we no longer have to use openstruct.
2023-02-23 23:23:19 +00:00
Vladimir Dementyev
8fff6d609c
fix: do not use TestServer in ConnectionStub
...
It's an internal testing entity, we cannot use it in a test case class
2023-02-23 15:31:58 -05:00
Rafael Mendonça França
177b9494e3
[Action Cable] Stop logging filtered params
...
Co-Autored-By: Kartikey Tanna <tannakartikey@gmail.com>
2023-02-08 17:22:39 +00:00
Zhang Kang
96b74fe433
Introduce ActionCable::Channel#stop_stream_from/for to unsubscribe specific streams ( #37171 )
...
* Like `ActionCable::Channel#stop_all_streams`, but for specific streams
2020-01-17 13:39:06 -08:00
utilum
436ec799a4
Remove redundant accessors
...
introduced in a0ea528b61.
2018-06-11 16:39:50 +02:00
utilum
a0ea528b61
Use Ruby instead of mocha
2018-05-31 17:48:20 +02:00
utilum
84854d9d05
Use minitest/mock instead of mocha
2018-05-31 17:48:20 +02:00
Kir Shatrov
385825fb70
Use frozen string literal in actioncable/
2017-07-23 23:30:29 +03:00
Matthew Draper
87b3e226d6
Revert "Merge pull request #29540 from kirs/rubocop-frozen-string"
...
This reverts commit 3420a14590c0e6915d8b6c242887f74adb4120f9, reversing
changes made to afb66a5a598ce4ac74ad84b125a5abf046dcf5aa.
2017-07-02 02:15:17 +09:30
Kir Shatrov
cfade1ec7e
Enforce frozen string in Rubocop
2017-07-01 02:11:03 +03:00
Rafael Mendonça França
fe1f4b2ad5
Add more rubocop rules about whitespaces
2016-10-29 01:17:49 -02:00
Matthew Draper
3e779d3c67
In-line the configuration points that only existed for Faye support
2016-10-01 15:36:26 +09:30
Matthew Draper
d44177d45e
Remove Faye mode
...
No deprecation, because it was never documented.
2016-10-01 15:35:59 +09:30
Matthew Draper
5d92089bca
Buffer writes to the cable sockets
...
Otherwise, they can sometimes block, leading to reduced system
throughput.
2016-09-28 06:44:23 +09:30
Xavier Noria
46f511685c
revises more Lint/EndAlignment offenses
2016-08-08 18:25:11 +02:00
Xavier Noria
80e66cc4d9
normalizes indentation and whitespace across the project
2016-08-06 20:16:27 +02:00
Xavier Noria
f8477f13bf
applies new string literal convention in actioncable/test
...
The current code base is not uniform. After some discussion,
we have chosen to go with double quotes by default.
2016-08-06 19:15:15 +02:00
Jeremy Daer
b168eb5819
Cable message encoding
...
* Introduce a connection coder responsible for encoding Cable messages
as WebSocket messages, defaulting to `ActiveSupport::JSON` and duck-
typing to any object responding to `#encode` and `#decode`.
* Consolidate encoding responsibility to the connection. No longer
explicitly JSON-encode from channels or other sources. Pass Cable
messages as Hashes to `#transmit` and rely on it to encode.
* Introduce stream encoders responsible for decoding pubsub messages.
Preserve the currently raw encoding, but make it easy to use JSON.
Same duck type as the connection encoder.
* Revert recent data normalization/quoting (#23649 ) which treated
`identifier` and `data` values as nested JSON objects rather than as
opaque JSON-encoded strings. That dealt us an awkward hand where we'd
decode JSON strings… or not, but always encode as JSON. Embedding
JSON object values directly is preferably, no extra JSON encoding,
but that should be a purposeful protocol version change rather than
ambiguously, inadvertently supporting multiple message formats.
2016-03-31 07:08:16 -07:00
Matthew Draper
a373be9da4
Support faye-websocket + EventMachine as an option
2016-03-02 12:17:15 +10:30
Matthew Draper
185c93eb0c
Use AS::Executor / AS::Reloader to support reloading in ActionCable
2016-03-02 02:14:20 +10:30
Matthew Draper
74497eabd5
Revert "Revert "Eliminate the EventMachine dependency""
2016-01-30 03:46:37 +10:30
David Heinemeier Hansson
9ea7aa84d1
Revert "Eliminate the EventMachine dependency"
2016-01-27 14:33:15 +01:00
Matthew Draper
322dca293b
Import the relevant portions of faye-websocket
...
(as adapted to use concurrent-ruby / nio4r instead of eventmachine)
2016-01-24 22:52:40 +10:30
Jon Moss
ae31da20cd
Fix code review comments
...
- adapter -> pubsub (re)rename internally
- Change variable names to match method names
- Add EventMachine `~> 1.0` as a runtime dependency of ActionCable
- Refactor dependency loading for adapters
2016-01-18 19:37:25 -05:00
Jon Moss
4c5d5b75ab
ActionCable::StorageAdapter ==> ActionCable::SubscriptionAdapter
2016-01-18 18:59:30 -05:00
Jon Moss
bc413e814b
Tests passing and small refactoring
2016-01-18 18:59:01 -05:00
David Heinemeier Hansson
bf40bddfce
Get ready to merge into Rails
2015-12-14 15:48:54 +01:00