|
@ -6,7 +6,6 @@ class ApplicationController < ActionController::Base |
|
|
begin |
|
|
begin |
|
|
action.call |
|
|
action.call |
|
|
ensure |
|
|
ensure |
|
|
ActionView::Base.logger.level = :info |
|
|
|
|
|
duration = Process.clock_gettime(Process::CLOCK_MONOTONIC) - start |
|
|
duration = Process.clock_gettime(Process::CLOCK_MONOTONIC) - start |
|
|
if duration > MAX_DURATION_TO_COMPLETE_IN_SECONDS |
|
|
if duration > MAX_DURATION_TO_COMPLETE_IN_SECONDS |
|
|
logger.warn("processing took too long to complete, please review your code as asynchronous job!", duration: duration * 1_000) |
|
|
logger.warn("processing took too long to complete, please review your code as asynchronous job!", duration: duration * 1_000) |
|
|