Conditions | 1 |
Paths | 1 |
Total Lines | 16 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 1 |
Changes | 0 |
1 | <?php |
||
31 | 19 | private function buildElasticsearchClient() : Client |
|
32 | { |
||
33 | 19 | $clientBuilder = ClientBuilder::create(); |
|
34 | 19 | $clientBuilder->setHosts([ |
|
35 | [ |
||
36 | 19 | 'host' => $this->getHost(), |
|
37 | 19 | 'port' => $this->getPort(), |
|
38 | 19 | 'scheme' => $this->getScheme(), |
|
39 | 19 | 'user' => $this->getUser(), |
|
40 | 19 | 'pass' => $this->getPassword() |
|
41 | ] |
||
42 | ]); |
||
43 | |||
44 | 19 | $clientBuilder->setRetries($this->getRetries()); |
|
45 | |||
46 | 19 | return $clientBuilder->build(); |
|
47 | } |
||
49 |