1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
Commit graph

22 commits

Author SHA1 Message Date
Xavier Noria
b678eb57e9 applies new string literal convention in actioncable/lib
The current code base is not uniform. After some discussion,
we have chosen to go with double quotes by default.
2016-08-06 19:13:46 +02:00
Michael Dever
0a8584456e Allow actioncable connections from any port in development 2016-06-16 21:04:43 +01:00
Matthew Draper
a8df1bc345 Properly support reloading for Action Cable channels 2016-06-02 04:08:48 +09:30
Xavier Noria
1dcf280014 renames ActionCable::Railtie to ActionCable::Engine
This is an engine living in action_cable/engine.rb, convention is to
call these things *::Engine.

Looking at thi git history looks like the current *::Railtie was just
an accident.
2016-05-04 06:47:57 -05:00
Javan Makhmali
6689d7c7b9 Share default mount path with client side .js 2016-03-03 21:27:52 -05:00
Matthew Draper
185c93eb0c Use AS::Executor / AS::Reloader to support reloading in ActionCable 2016-03-02 02:14:20 +10:30
Jon Moss
8b69f1eeba Enable Action Cable routes by default
This also marks Action Cable routes as internal to Rails.
2016-02-24 19:05:03 -05:00
Kasper Timm Hansen
861ece99bb Default connection class to ActionCable::Connection::Base.
Instead of depending on ApplicationCable::Connection being defined at initialize
we should inject it in the Railtie.

Thus we can kill more setup in the tests too.
2016-02-14 17:46:48 +01:00
Kasper Timm Hansen
661298176c Inject Rails' channel paths in engine.
We were explicitly referencing Rails.root in ActionCable::Server::Configuration.initialize,
thereby coupling ourselves to Rails.

Instead add `app/channels` to Rails' app paths and assign the existent files
to `channel_paths`.

Users can still append to those load paths with `<<` and `push` in `config/application.rb`.

This means we can remove the custom `Dir` lookup in `channel_paths` and the Rails
and root definitions in the tests.
2016-02-14 17:46:48 +01:00
Jon Moss
75489642c8 config_opts => cable, per @kaspth 2016-01-18 18:59:28 -05:00
Jon Moss
0016e0410b Adapterize ActionCable storage and extract behavior 2016-01-18 18:58:57 -05:00
David Heinemeier Hansson
910572fffe Another stab at only mounting redis if the config is there 2015-12-16 18:17:12 +01:00
David Heinemeier Hansson
7eb12796ca Assume that the cable server is running in-process by default, offer option to change that in config/environments/production.rb 2015-12-16 18:17:12 +01:00
David Heinemeier Hansson
51ad57989d Doh, should have read ff370ee617
Indeed we need this to be an engine for the internal assets to work
2015-12-16 15:52:46 +01:00
David Heinemeier Hansson
346a7528ef We are using railtie, not engine 2015-12-16 15:28:50 +01:00
Rafael Mendonça França
649b9d9321 Move the require to the right place 2015-12-15 16:05:42 -02:00
Rafael Mendonça França
96455349ff Configure the Action Cable's redis in the engine
This will decouple Action Cable from Rails.
2015-12-15 15:59:00 -02:00
Rafael Mendonça França
ff370ee617 Action Cable need to be a engine
Otherwise assets will not work
2015-12-15 15:21:36 -02:00
David Heinemeier Hansson
a8db0328a5 Switch from engine to railtie 2015-12-15 13:10:27 +01:00
Rafael Mendonça França
3d4a423cdc Hook in ActionView::Base, not in ApplicationController
The application can have more than one ApplicationController and we
want Action Cable helpers in all controllers and their views so we
should hook in the same place that others helpers.
2015-12-14 15:54:08 -02:00
Rafael Mendonça França
f8058a6aeb Require the top level file in the engine 2015-12-14 15:53:43 -02:00
David Heinemeier Hansson
bf40bddfce Get ready to merge into Rails 2015-12-14 15:48:54 +01:00
Renamed from lib/action_cable/engine.rb (Browse further)