After Fork
The after_fork hook runs once in each worker process immediately after it is forked. Use it to reinitialize connections (DB, cache) that shouldn’t be shared across forks.
Itsi.rb
after_fork do
DB.reconnect!
end
The after_fork hook runs once in each worker process immediately after it is forked. Use it to reinitialize connections (DB, cache) that shouldn’t be shared across forks.
after_fork do
DB.reconnect!
end