mirror of
https://github.com/discourse/discourse.git
synced 2025-05-31 09:17:15 +08:00
FIX: ensure we have no dangling db connections on threads
This correct 10 second timeouts in dev mode, when reloader kicks in
This commit is contained in:
@ -74,6 +74,8 @@ module Scheduler
|
||||
end
|
||||
rescue => ex
|
||||
Discourse.handle_job_exception(ex, message: "Processing deferred code queue")
|
||||
ensure
|
||||
ActiveRecord::Base.connection_handler.clear_active_connections!
|
||||
end
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user