Add a no-op query to prevent database timeouts during a long reindex
This commit is contained in:
parent
2ba90f4239
commit
064468a28a
|
@ -270,6 +270,9 @@ class Solr_Reindex extends BuildTask {
|
||||||
|
|
||||||
// If we're in dev mode, commit more often for fun and profit
|
// If we're in dev mode, commit more often for fun and profit
|
||||||
if (Director::isDev()) Solr::service($index)->commit();
|
if (Director::isDev()) Solr::service($index)->commit();
|
||||||
|
|
||||||
|
// This will slow down things a tiny bit, but it is done so that we don't timeout to the database during a reindex
|
||||||
|
DB::query('SELECT 1');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue