Merge branch 'master' into PHRAS-3184-api-token-header-only

This commit is contained in:
Nicolas Maillat
2020-08-06 16:16:29 +02:00
committed by GitHub

View File

@@ -36,6 +36,7 @@ class PopulateIndexWorker implements WorkerInterface
public function process(array $payload) public function process(array $payload)
{ {
$em = $this->repoWorker->getEntityManager(); $em = $this->repoWorker->getEntityManager();
$this->repoWorker->reconnect();
if (isset($payload['workerJobId'])) { if (isset($payload['workerJobId'])) {
/** @var WorkerRunningJob $workerRunningJob */ /** @var WorkerRunningJob $workerRunningJob */
@@ -139,6 +140,7 @@ class PopulateIndexWorker implements WorkerInterface
// tell that the populate is finished // tell that the populate is finished
if ($workerRunningJob != null) { if ($workerRunningJob != null) {
$this->repoWorker->reconnect();
$workerRunningJob $workerRunningJob
->setStatus(WorkerRunningJob::FINISHED) ->setStatus(WorkerRunningJob::FINISHED)
->setFinished(new \DateTime('now')) ->setFinished(new \DateTime('now'))