Skip to content

Commit 5d13cc8

Browse files
committed
BUGFIX: Fix nodeindex:cleanup command for ES >= 2.0
1 parent 9efa79f commit 5d13cc8

2 files changed

Lines changed: 8 additions & 1 deletion

File tree

Classes/Command/NodeIndexCommandController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ public function cleanupCommand()
270270
}
271271
} catch (\Flowpack\ElasticSearch\Transfer\Exception\ApiException $exception) {
272272
$response = json_decode($exception->getResponse());
273-
$this->logger->log(sprintf('Nothing removed. ElasticSearch responded with status %s, saying "%s"', $response->status, $response->error));
273+
$this->logger->log(sprintf('Nothing removed. ElasticSearch responded with status %s, saying "%s: %s"', $response->status, $response->error->type, $response->error->reason));
274274
}
275275
}
276276
}

Classes/Driver/Version2/SystemDriver.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,11 @@
2121
*/
2222
class SystemDriver extends Version1\SystemDriver
2323
{
24+
/**
25+
* @inheritDoc
26+
*/
27+
public function status()
28+
{
29+
return $this->searchClient->request('GET', '/_stats')->getTreatedContent();
30+
}
2431
}

0 commit comments

Comments
 (0)