mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Move behavior to Server::Base, and flush pubsub
This commit is contained in:
parent
a5dfba4135
commit
35a497dc29
2 changed files with 6 additions and 3 deletions
|
@ -70,7 +70,6 @@ module ActionCable
|
|||
|
||||
app.reloader.before_class_unload do
|
||||
ActionCable.server.restart
|
||||
ActionCable.server.pubsub.shutdown
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -37,9 +37,13 @@ module ActionCable
|
|||
connections.each(&:close)
|
||||
|
||||
@mutex.synchronize do
|
||||
worker_pool.halt if @worker_pool
|
||||
|
||||
# Shutdown the worker pool
|
||||
@worker_pool.halt if @worker_pool
|
||||
@worker_pool = nil
|
||||
|
||||
# Shutdown the pub/sub adapter
|
||||
@pubsub.shutdown if @pubsub
|
||||
@pubsub = nil
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue