diff --git a/src/Solr/Reindex/Handlers/SolrReindexImmediateHandler.php b/src/Solr/Reindex/Handlers/SolrReindexImmediateHandler.php index db5db3b..66409f6 100644 --- a/src/Solr/Reindex/Handlers/SolrReindexImmediateHandler.php +++ b/src/Solr/Reindex/Handlers/SolrReindexImmediateHandler.php @@ -97,6 +97,13 @@ class SolrReindexImmediateHandler extends SolrReindexBase // Execute script via shell $process = new Process($cmd); + + // Set timeout from config. Process default is 60 seconds. + $timeout = Config::inst()->get(static::class, 'process_timeout'); + if ($timeout) { + $process->setTimeout($timeout); + } + $process->inheritEnvironmentVariables(); $process->run();