method
async_query_executor
v8.0.0 -
Show latest stable
- Class:
ActiveRecord
async_query_executorpublic
Sets the async_query_executor for an application. By default the thread pool executor set to nil which will not run queries in the background. Applications must configure a thread pool executor to use this feature. Options are:
* nil - Does not initialize a thread pool executor. Any async calls will be run in the foreground. * :global_thread_pool - Initializes a single +Concurrent::ThreadPoolExecutor+ that uses the +async_query_concurrency+ for the +max_threads+ value. * :multi_thread_pool - Initializes a +Concurrent::ThreadPoolExecutor+ for each database connection. The initializer values are defined in the configuration hash.