@@ -156,7 +156,7 @@ |
||
| 156 | 156 | $this->log->debug("Curl Options:", $opts); |
| 157 | 157 | |
| 158 | 158 | $this->lastRequest = array('request' => |
| 159 | - array( |
|
| 159 | + array( |
|
| 160 | 160 | 'uri' => $uri, |
| 161 | 161 | 'body' => $body, |
| 162 | 162 | 'options' => $options, |
@@ -203,7 +203,7 @@ |
||
| 203 | 203 | $this->process4xxError($request, $exception, $body); |
| 204 | 204 | |
| 205 | 205 | } catch (CurlException $exception) { |
| 206 | - $this->processCurlError($exception); |
|
| 206 | + $this->processCurlError($exception); |
|
| 207 | 207 | |
| 208 | 208 | } catch (\Exception $exception) { |
| 209 | 209 | $error = 'Unexpected error: ' . $exception->getMessage(); |
@@ -38,9 +38,9 @@ discard block |
||
| 38 | 38 | /** @var \Elasticsearch\Endpoints\Snapshot\Create $endpoint */ |
| 39 | 39 | $endpoint = $endpointBuilder('Snapshot\Create'); |
| 40 | 40 | $endpoint->setRepository($repository) |
| 41 | - ->setSnapshot($snapshot) |
|
| 42 | - ->setParams($params) |
|
| 43 | - ->setBody($body); |
|
| 41 | + ->setSnapshot($snapshot) |
|
| 42 | + ->setParams($params) |
|
| 43 | + ->setBody($body); |
|
| 44 | 44 | $response = $endpoint->performRequest(); |
| 45 | 45 | return $response['data']; |
| 46 | 46 | } |
@@ -65,8 +65,8 @@ discard block |
||
| 65 | 65 | /** @var \Elasticsearch\Endpoints\Snapshot\Repository\Create $endpoint */ |
| 66 | 66 | $endpoint = $endpointBuilder('Snapshot\Repository\Create'); |
| 67 | 67 | $endpoint->setRepository($repository) |
| 68 | - ->setBody($body) |
|
| 69 | - ->setParams($params); |
|
| 68 | + ->setBody($body) |
|
| 69 | + ->setParams($params); |
|
| 70 | 70 | $response = $endpoint->performRequest(); |
| 71 | 71 | return $response['data']; |
| 72 | 72 | } |
@@ -90,8 +90,8 @@ discard block |
||
| 90 | 90 | /** @var \Elasticsearch\Endpoints\Snapshot\Delete $endpoint */ |
| 91 | 91 | $endpoint = $endpointBuilder('Snapshot\Delete'); |
| 92 | 92 | $endpoint->setRepository($repository) |
| 93 | - ->setSnapshot($snapshot) |
|
| 94 | - ->setParams($params); |
|
| 93 | + ->setSnapshot($snapshot) |
|
| 94 | + ->setParams($params); |
|
| 95 | 95 | $response = $endpoint->performRequest(); |
| 96 | 96 | return $response['data']; |
| 97 | 97 | } |
@@ -115,7 +115,7 @@ discard block |
||
| 115 | 115 | /** @var \Elasticsearch\Endpoints\Snapshot\Repository\Delete $endpoint */ |
| 116 | 116 | $endpoint = $endpointBuilder('Snapshot\Repository\Delete'); |
| 117 | 117 | $endpoint->setRepository($repository) |
| 118 | - ->setParams($params); |
|
| 118 | + ->setParams($params); |
|
| 119 | 119 | $response = $endpoint->performRequest(); |
| 120 | 120 | return $response['data']; |
| 121 | 121 | } |
@@ -141,8 +141,8 @@ discard block |
||
| 141 | 141 | /** @var \Elasticsearch\Endpoints\Snapshot\Get $endpoint */ |
| 142 | 142 | $endpoint = $endpointBuilder('Snapshot\Get'); |
| 143 | 143 | $endpoint->setRepository($repository) |
| 144 | - ->setSnapshot($snapshot) |
|
| 145 | - ->setParams($params); |
|
| 144 | + ->setSnapshot($snapshot) |
|
| 145 | + ->setParams($params); |
|
| 146 | 146 | $response = $endpoint->performRequest(); |
| 147 | 147 | return $response['data']; |
| 148 | 148 | } |
@@ -166,7 +166,7 @@ discard block |
||
| 166 | 166 | /** @var \Elasticsearch\Endpoints\Snapshot\Repository\Get $endpoint */ |
| 167 | 167 | $endpoint = $endpointBuilder('Snapshot\Repository\Get'); |
| 168 | 168 | $endpoint->setRepository($repository) |
| 169 | - ->setParams($params); |
|
| 169 | + ->setParams($params); |
|
| 170 | 170 | $response = $endpoint->performRequest(); |
| 171 | 171 | return $response['data']; |
| 172 | 172 | } |
@@ -192,9 +192,9 @@ discard block |
||
| 192 | 192 | /** @var \Elasticsearch\Endpoints\Snapshot\Restore $endpoint */ |
| 193 | 193 | $endpoint = $endpointBuilder('Snapshot\Restore'); |
| 194 | 194 | $endpoint->setRepository($repository) |
| 195 | - ->setSnapshot($snapshot) |
|
| 196 | - ->setParams($params) |
|
| 197 | - ->setBody($body); |
|
| 195 | + ->setSnapshot($snapshot) |
|
| 196 | + ->setParams($params) |
|
| 197 | + ->setBody($body); |
|
| 198 | 198 | $response = $endpoint->performRequest(); |
| 199 | 199 | return $response['data']; |
| 200 | 200 | } |
@@ -217,8 +217,8 @@ discard block |
||
| 217 | 217 | /** @var \Elasticsearch\Endpoints\Snapshot\Status $endpoint */ |
| 218 | 218 | $endpoint = $endpointBuilder('Snapshot\Status'); |
| 219 | 219 | $endpoint->setRepository($repository) |
| 220 | - ->setSnapshot($snapshot) |
|
| 221 | - ->setParams($params); |
|
| 220 | + ->setSnapshot($snapshot) |
|
| 221 | + ->setParams($params); |
|
| 222 | 222 | $response = $endpoint->performRequest(); |
| 223 | 223 | return $response['data']; |
| 224 | 224 | } |
@@ -241,7 +241,7 @@ discard block |
||
| 241 | 241 | /** @var \Elasticsearch\Endpoints\Snapshot\Repository\Verify $endpoint */ |
| 242 | 242 | $endpoint = $endpointBuilder('Snapshot\Repository\Verify'); |
| 243 | 243 | $endpoint->setRepository($repository) |
| 244 | - ->setParams($params); |
|
| 244 | + ->setParams($params); |
|
| 245 | 245 | $response = $endpoint->performRequest(); |
| 246 | 246 | return $response['data']; |
| 247 | 247 | } |
@@ -79,8 +79,8 @@ discard block |
||
| 79 | 79 | /** @var \Elasticsearch\Endpoints\Indices\Get $endpoint */ |
| 80 | 80 | $endpoint = $endpointBuilder('Indices\Get'); |
| 81 | 81 | $endpoint->setIndex($index) |
| 82 | - ->setFeature($feature) |
|
| 83 | - ->setParams($params); |
|
| 82 | + ->setFeature($feature) |
|
| 83 | + ->setParams($params); |
|
| 84 | 84 | |
| 85 | 85 | $response = $endpoint->performRequest(); |
| 86 | 86 | return $response['data']; |
@@ -169,8 +169,8 @@ discard block |
||
| 169 | 169 | /** @var \Elasticsearch\Endpoints\Indices\Warmer\Delete $endpoint */ |
| 170 | 170 | $endpoint = $endpointBuilder('Indices\Warmer\Delete'); |
| 171 | 171 | $endpoint->setIndex($index) |
| 172 | - ->setName($name) |
|
| 173 | - ->setType($type); |
|
| 172 | + ->setName($name) |
|
| 173 | + ->setType($type); |
|
| 174 | 174 | $endpoint->setParams($params); |
| 175 | 175 | $response = $endpoint->performRequest(); |
| 176 | 176 | return $response['data']; |
@@ -242,7 +242,7 @@ discard block |
||
| 242 | 242 | /** @var \Elasticsearch\Endpoints\Indices\Stats $endpoint */ |
| 243 | 243 | $endpoint = $endpointBuilder('Indices\Stats'); |
| 244 | 244 | $endpoint->setIndex($index) |
| 245 | - ->setMetric($metric); |
|
| 245 | + ->setMetric($metric); |
|
| 246 | 246 | $endpoint->setParams($params); |
| 247 | 247 | $response = $endpoint->performRequest(); |
| 248 | 248 | return $response['data']; |
@@ -272,7 +272,7 @@ discard block |
||
| 272 | 272 | /** @var \Elasticsearch\Endpoints\Indices\Settings\Put $endpoint */ |
| 273 | 273 | $endpoint = $endpointBuilder('Indices\Settings\Put'); |
| 274 | 274 | $endpoint->setIndex($index) |
| 275 | - ->setBody($body); |
|
| 275 | + ->setBody($body); |
|
| 276 | 276 | $endpoint->setParams($params); |
| 277 | 277 | $response = $endpoint->performRequest(); |
| 278 | 278 | return $response['data']; |
@@ -330,7 +330,7 @@ discard block |
||
| 330 | 330 | /** @var \Elasticsearch\Endpoints\Indices\Mapping\Get $endpoint */ |
| 331 | 331 | $endpoint = $endpointBuilder('Indices\Mapping\Get'); |
| 332 | 332 | $endpoint->setIndex($index) |
| 333 | - ->setType($type); |
|
| 333 | + ->setType($type); |
|
| 334 | 334 | $endpoint->setParams($params); |
| 335 | 335 | $response = $endpoint->performRequest(); |
| 336 | 336 | return $response['data']; |
@@ -361,8 +361,8 @@ discard block |
||
| 361 | 361 | /** @var \Elasticsearch\Endpoints\Indices\Mapping\GetField $endpoint */ |
| 362 | 362 | $endpoint = $endpointBuilder('Indices\Mapping\GetField'); |
| 363 | 363 | $endpoint->setIndex($index) |
| 364 | - ->setType($type) |
|
| 365 | - ->setField($field); |
|
| 364 | + ->setType($type) |
|
| 365 | + ->setField($field); |
|
| 366 | 366 | |
| 367 | 367 | $endpoint->setParams($params); |
| 368 | 368 | $response = $endpoint->performRequest(); |
@@ -481,7 +481,7 @@ discard block |
||
| 481 | 481 | /** @var \Elasticsearch\Endpoints\Indices\Type\Exists $endpoint */ |
| 482 | 482 | $endpoint = $endpointBuilder('Indices\Type\Exists'); |
| 483 | 483 | $endpoint->setIndex($index) |
| 484 | - ->setType($type); |
|
| 484 | + ->setType($type); |
|
| 485 | 485 | $endpoint->setParams($params); |
| 486 | 486 | |
| 487 | 487 | try { |
@@ -527,8 +527,8 @@ discard block |
||
| 527 | 527 | /** @var \Elasticsearch\Endpoints\Indices\Alias\Put $endpoint */ |
| 528 | 528 | $endpoint = $endpointBuilder('Indices\Alias\Put'); |
| 529 | 529 | $endpoint->setIndex($index) |
| 530 | - ->setName($name) |
|
| 531 | - ->setBody($body); |
|
| 530 | + ->setName($name) |
|
| 531 | + ->setBody($body); |
|
| 532 | 532 | $endpoint->setParams($params); |
| 533 | 533 | $response = $endpoint->performRequest(); |
| 534 | 534 | return $response['data']; |
@@ -562,8 +562,8 @@ discard block |
||
| 562 | 562 | /** @var \Elasticsearch\Endpoints\Indices\Warmer\Get $endpoint */ |
| 563 | 563 | $endpoint = $endpointBuilder('Indices\Warmer\Get'); |
| 564 | 564 | $endpoint->setIndex($index) |
| 565 | - ->setName($name) |
|
| 566 | - ->setType($type); |
|
| 565 | + ->setName($name) |
|
| 566 | + ->setType($type); |
|
| 567 | 567 | $endpoint->setParams($params); |
| 568 | 568 | $response = $endpoint->performRequest(); |
| 569 | 569 | return $response['data']; |
@@ -601,9 +601,9 @@ discard block |
||
| 601 | 601 | /** @var \Elasticsearch\Endpoints\Indices\Warmer\Put $endpoint */ |
| 602 | 602 | $endpoint = $endpointBuilder('Indices\Warmer\Put'); |
| 603 | 603 | $endpoint->setIndex($index) |
| 604 | - ->setName($name) |
|
| 605 | - ->setType($type) |
|
| 606 | - ->setBody($body); |
|
| 604 | + ->setName($name) |
|
| 605 | + ->setType($type) |
|
| 606 | + ->setBody($body); |
|
| 607 | 607 | $endpoint->setParams($params); |
| 608 | 608 | $response = $endpoint->performRequest(); |
| 609 | 609 | return $response['data']; |
@@ -636,7 +636,7 @@ discard block |
||
| 636 | 636 | /** @var \Elasticsearch\Endpoints\Indices\Template\Put $endpoint */ |
| 637 | 637 | $endpoint = $endpointBuilder('Indices\Template\Put'); |
| 638 | 638 | $endpoint->setName($name) |
| 639 | - ->setBody($body); |
|
| 639 | + ->setBody($body); |
|
| 640 | 640 | $endpoint->setParams($params); |
| 641 | 641 | $response = $endpoint->performRequest(); |
| 642 | 642 | return $response['data']; |
@@ -674,8 +674,8 @@ discard block |
||
| 674 | 674 | /** @var \Elasticsearch\Endpoints\Indices\Validate\Query $endpoint */ |
| 675 | 675 | $endpoint = $endpointBuilder('Indices\Validate\Query'); |
| 676 | 676 | $endpoint->setIndex($index) |
| 677 | - ->setType($type) |
|
| 678 | - ->setBody($body); |
|
| 677 | + ->setType($type) |
|
| 678 | + ->setBody($body); |
|
| 679 | 679 | $endpoint->setParams($params); |
| 680 | 680 | $response = $endpoint->performRequest(); |
| 681 | 681 | return $response['data']; |
@@ -707,7 +707,7 @@ discard block |
||
| 707 | 707 | /** @var \Elasticsearch\Endpoints\Indices\Alias\Get $endpoint */ |
| 708 | 708 | $endpoint = $endpointBuilder('Indices\Alias\Get'); |
| 709 | 709 | $endpoint->setIndex($index) |
| 710 | - ->setName($name); |
|
| 710 | + ->setName($name); |
|
| 711 | 711 | $endpoint->setParams($params); |
| 712 | 712 | $response = $endpoint->performRequest(); |
| 713 | 713 | return $response['data']; |
@@ -742,8 +742,8 @@ discard block |
||
| 742 | 742 | /** @var \Elasticsearch\Endpoints\Indices\Mapping\Put $endpoint */ |
| 743 | 743 | $endpoint = $endpointBuilder('Indices\Mapping\Put'); |
| 744 | 744 | $endpoint->setIndex($index) |
| 745 | - ->setType($type) |
|
| 746 | - ->setBody($body); |
|
| 745 | + ->setType($type) |
|
| 746 | + ->setBody($body); |
|
| 747 | 747 | $endpoint->setParams($params); |
| 748 | 748 | $response = $endpoint->performRequest(); |
| 749 | 749 | return $response['data']; |
@@ -773,7 +773,7 @@ discard block |
||
| 773 | 773 | /** @var \Elasticsearch\Endpoints\Indices\Mapping\Delete $endpoint */ |
| 774 | 774 | $endpoint = $endpointBuilder('Indices\Mapping\Delete'); |
| 775 | 775 | $endpoint->setIndex($index) |
| 776 | - ->setType($type); |
|
| 776 | + ->setType($type); |
|
| 777 | 777 | $endpoint->setParams($params); |
| 778 | 778 | $response = $endpoint->performRequest(); |
| 779 | 779 | return $response['data']; |
@@ -865,7 +865,7 @@ discard block |
||
| 865 | 865 | /** @var \Elasticsearch\Endpoints\Indices\Create $endpoint */ |
| 866 | 866 | $endpoint = $endpointBuilder('Indices\Create'); |
| 867 | 867 | $endpoint->setIndex($index) |
| 868 | - ->setBody($body); |
|
| 868 | + ->setBody($body); |
|
| 869 | 869 | $endpoint->setParams($params); |
| 870 | 870 | $response = $endpoint->performRequest(); |
| 871 | 871 | return $response['data']; |
@@ -930,7 +930,7 @@ discard block |
||
| 930 | 930 | /** @var \Elasticsearch\Endpoints\Indices\Alias\Delete $endpoint */ |
| 931 | 931 | $endpoint = $endpointBuilder('Indices\Alias\Delete'); |
| 932 | 932 | $endpoint->setIndex($index) |
| 933 | - ->setName($name); |
|
| 933 | + ->setName($name); |
|
| 934 | 934 | $endpoint->setParams($params); |
| 935 | 935 | $response = $endpoint->performRequest(); |
| 936 | 936 | return $response['data']; |
@@ -993,7 +993,7 @@ discard block |
||
| 993 | 993 | /** @var \Elasticsearch\Endpoints\Indices\Analyze $endpoint */ |
| 994 | 994 | $endpoint = $endpointBuilder('Indices\Analyze'); |
| 995 | 995 | $endpoint->setIndex($index) |
| 996 | - ->setBody($body); |
|
| 996 | + ->setBody($body); |
|
| 997 | 997 | $endpoint->setParams($params); |
| 998 | 998 | $response = $endpoint->performRequest(); |
| 999 | 999 | return $response['data']; |
@@ -1061,7 +1061,7 @@ discard block |
||
| 1061 | 1061 | /** @var \Elasticsearch\Endpoints\Indices\Aliases\Update $endpoint */ |
| 1062 | 1062 | $endpoint = $endpointBuilder('Indices\Aliases\Update'); |
| 1063 | 1063 | $endpoint->setIndex($index) |
| 1064 | - ->setBody($body); |
|
| 1064 | + ->setBody($body); |
|
| 1065 | 1065 | $endpoint->setParams($params); |
| 1066 | 1066 | $response = $endpoint->performRequest(); |
| 1067 | 1067 | return $response['data']; |
@@ -1090,7 +1090,7 @@ discard block |
||
| 1090 | 1090 | /** @var \Elasticsearch\Endpoints\Indices\Aliases\Get $endpoint */ |
| 1091 | 1091 | $endpoint = $endpointBuilder('Indices\Aliases\Get'); |
| 1092 | 1092 | $endpoint->setIndex($index) |
| 1093 | - ->setName($name); |
|
| 1093 | + ->setName($name); |
|
| 1094 | 1094 | $endpoint->setParams($params); |
| 1095 | 1095 | $response = $endpoint->performRequest(); |
| 1096 | 1096 | return $response['data']; |
@@ -1123,7 +1123,7 @@ discard block |
||
| 1123 | 1123 | /** @var \Elasticsearch\Endpoints\Indices\Alias\Exists $endpoint */ |
| 1124 | 1124 | $endpoint = $endpointBuilder('Indices\Alias\Exists'); |
| 1125 | 1125 | $endpoint->setIndex($index) |
| 1126 | - ->setName($name); |
|
| 1126 | + ->setName($name); |
|
| 1127 | 1127 | $endpoint->setParams($params); |
| 1128 | 1128 | |
| 1129 | 1129 | try { |
@@ -1192,7 +1192,7 @@ discard block |
||
| 1192 | 1192 | /** @var \Elasticsearch\Endpoints\Indices\Settings\Get $endpoint */ |
| 1193 | 1193 | $endpoint = $endpointBuilder('Indices\Settings\Get'); |
| 1194 | 1194 | $endpoint->setIndex($index) |
| 1195 | - ->setName($name); |
|
| 1195 | + ->setName($name); |
|
| 1196 | 1196 | $endpoint->setParams($params); |
| 1197 | 1197 | $response = $endpoint->performRequest(); |
| 1198 | 1198 | return $response['data']; |
@@ -54,9 +54,9 @@ discard block |
||
| 54 | 54 | /** @var \Elasticsearch\Endpoints\Cluster\Nodes\Stats $endpoint */ |
| 55 | 55 | $endpoint = $endpointBuilder('Cluster\Nodes\Stats'); |
| 56 | 56 | $endpoint->setNodeID($nodeID) |
| 57 | - ->setMetric($metric) |
|
| 58 | - ->setIndexMetric($index_metric) |
|
| 59 | - ->setParams($params); |
|
| 57 | + ->setMetric($metric) |
|
| 58 | + ->setIndexMetric($index_metric) |
|
| 59 | + ->setParams($params); |
|
| 60 | 60 | $response = $endpoint->performRequest(); |
| 61 | 61 | return $response['data']; |
| 62 | 62 | } |
@@ -66,7 +66,6 @@ discard block |
||
| 66 | 66 | * ['metric'] = (list) A comma-separated list of metrics you wish returned. Leave empty to return all. |
| 67 | 67 | * ['flat_settings'] = (boolean) Return settings in flat format (default: false) |
| 68 | 68 | * ['human'] = (boolean) Whether to return time and byte values in human-readable format. |
| 69 | - |
|
| 70 | 69 | * |
| 71 | 70 | * @param $params array Associative array of parameters |
| 72 | 71 | * |
@@ -104,8 +104,8 @@ discard block |
||
| 104 | 104 | /** @var \Elasticsearch\Endpoints\Cluster\State $endpoint */ |
| 105 | 105 | $endpoint = $endpointBuilder('Cluster\State'); |
| 106 | 106 | $endpoint->setParams($params) |
| 107 | - ->setIndex($index) |
|
| 108 | - ->setMetric($metric); |
|
| 107 | + ->setIndex($index) |
|
| 108 | + ->setMetric($metric); |
|
| 109 | 109 | $response = $endpoint->performRequest(); |
| 110 | 110 | return $response['data']; |
| 111 | 111 | } |
@@ -128,7 +128,7 @@ discard block |
||
| 128 | 128 | /** @var \Elasticsearch\Endpoints\Cluster\Stats $endpoint */ |
| 129 | 129 | $endpoint = $endpointBuilder('Cluster\Stats'); |
| 130 | 130 | $endpoint->setNodeID($nodeID) |
| 131 | - ->setParams($params); |
|
| 131 | + ->setParams($params); |
|
| 132 | 132 | $response = $endpoint->performRequest(); |
| 133 | 133 | return $response['data']; |
| 134 | 134 | } |
@@ -171,8 +171,8 @@ discard block |
||
| 171 | 171 | /** @var \Elasticsearch\Endpoints\Get $endpoint */ |
| 172 | 172 | $endpoint = $endpointBuilder('Get'); |
| 173 | 173 | $endpoint->setID($id) |
| 174 | - ->setIndex($index) |
|
| 175 | - ->setType($type); |
|
| 174 | + ->setIndex($index) |
|
| 175 | + ->setType($type); |
|
| 176 | 176 | $endpoint->setParams($params); |
| 177 | 177 | $response = $endpoint->performRequest(); |
| 178 | 178 | return $response['data']; |
@@ -212,9 +212,9 @@ discard block |
||
| 212 | 212 | /** @var \Elasticsearch\Endpoints\Get $endpoint */ |
| 213 | 213 | $endpoint = $endpointBuilder('Get'); |
| 214 | 214 | $endpoint->setID($id) |
| 215 | - ->setIndex($index) |
|
| 216 | - ->setType($type) |
|
| 217 | - ->returnOnlySource(); |
|
| 215 | + ->setIndex($index) |
|
| 216 | + ->setType($type) |
|
| 217 | + ->returnOnlySource(); |
|
| 218 | 218 | $endpoint->setParams($params); |
| 219 | 219 | $response = $endpoint->performRequest(); |
| 220 | 220 | return $response['data']; |
@@ -255,8 +255,8 @@ discard block |
||
| 255 | 255 | /** @var \Elasticsearch\Endpoints\Delete $endpoint */ |
| 256 | 256 | $endpoint = $endpointBuilder('Delete'); |
| 257 | 257 | $endpoint->setID($id) |
| 258 | - ->setIndex($index) |
|
| 259 | - ->setType($type); |
|
| 258 | + ->setIndex($index) |
|
| 259 | + ->setType($type); |
|
| 260 | 260 | $endpoint->setParams($params); |
| 261 | 261 | $response = $endpoint->performRequest(); |
| 262 | 262 | return $response['data']; |
@@ -334,8 +334,8 @@ discard block |
||
| 334 | 334 | /** @var \Elasticsearch\Endpoints\Count $endpoint */ |
| 335 | 335 | $endpoint = $endpointBuilder('Count'); |
| 336 | 336 | $endpoint->setIndex($index) |
| 337 | - ->setType($type) |
|
| 338 | - ->setBody($body); |
|
| 337 | + ->setType($type) |
|
| 338 | + ->setBody($body); |
|
| 339 | 339 | $endpoint->setParams($params); |
| 340 | 340 | $response = $endpoint->performRequest(); |
| 341 | 341 | return $response['data']; |
@@ -373,9 +373,9 @@ discard block |
||
| 373 | 373 | /** @var \Elasticsearch\Endpoints\CountPercolate $endpoint */ |
| 374 | 374 | $endpoint = $endpointBuilder('CountPercolate'); |
| 375 | 375 | $endpoint->setIndex($index) |
| 376 | - ->setType($type) |
|
| 377 | - ->setID($id) |
|
| 378 | - ->setBody($body); |
|
| 376 | + ->setType($type) |
|
| 377 | + ->setID($id) |
|
| 378 | + ->setBody($body); |
|
| 379 | 379 | $endpoint->setParams($params); |
| 380 | 380 | $response = $endpoint->performRequest(); |
| 381 | 381 | return $response['data']; |
@@ -407,9 +407,9 @@ discard block |
||
| 407 | 407 | /** @var \Elasticsearch\Endpoints\Percolate $endpoint */ |
| 408 | 408 | $endpoint = $endpointBuilder('Percolate'); |
| 409 | 409 | $endpoint->setIndex($index) |
| 410 | - ->setType($type) |
|
| 411 | - ->setID($id) |
|
| 412 | - ->setBody($body); |
|
| 410 | + ->setType($type) |
|
| 411 | + ->setID($id) |
|
| 412 | + ->setBody($body); |
|
| 413 | 413 | $endpoint->setParams($params); |
| 414 | 414 | $response = $endpoint->performRequest(); |
| 415 | 415 | return $response['data']; |
@@ -440,8 +440,8 @@ discard block |
||
| 440 | 440 | /** @var \Elasticsearch\Endpoints\MPercolate $endpoint */ |
| 441 | 441 | $endpoint = $endpointBuilder('MPercolate'); |
| 442 | 442 | $endpoint->setIndex($index) |
| 443 | - ->setType($type) |
|
| 444 | - ->setBody($body); |
|
| 443 | + ->setType($type) |
|
| 444 | + ->setBody($body); |
|
| 445 | 445 | $endpoint->setParams($params); |
| 446 | 446 | $response = $endpoint->performRequest(); |
| 447 | 447 | return $response['data']; |
@@ -479,9 +479,9 @@ discard block |
||
| 479 | 479 | /** @var \Elasticsearch\Endpoints\TermVectors $endpoint */ |
| 480 | 480 | $endpoint = $endpointBuilder('TermVectors'); |
| 481 | 481 | $endpoint->setIndex($index) |
| 482 | - ->setType($type) |
|
| 483 | - ->setID($id) |
|
| 484 | - ->setBody($body); |
|
| 482 | + ->setType($type) |
|
| 483 | + ->setID($id) |
|
| 484 | + ->setBody($body); |
|
| 485 | 485 | $endpoint->setParams($params); |
| 486 | 486 | $response = $endpoint->performRequest(); |
| 487 | 487 | return $response['data']; |
@@ -519,8 +519,8 @@ discard block |
||
| 519 | 519 | /** @var \Elasticsearch\Endpoints\MTermVectors $endpoint */ |
| 520 | 520 | $endpoint = $endpointBuilder('MTermVectors'); |
| 521 | 521 | $endpoint->setIndex($index) |
| 522 | - ->setType($type) |
|
| 523 | - ->setBody($body); |
|
| 522 | + ->setType($type) |
|
| 523 | + ->setBody($body); |
|
| 524 | 524 | $endpoint->setParams($params); |
| 525 | 525 | $response = $endpoint->performRequest(); |
| 526 | 526 | return $response['data']; |
@@ -559,8 +559,8 @@ discard block |
||
| 559 | 559 | /** @var \Elasticsearch\Endpoints\Exists $endpoint */ |
| 560 | 560 | $endpoint = $endpointBuilder('Exists'); |
| 561 | 561 | $endpoint->setID($id) |
| 562 | - ->setIndex($index) |
|
| 563 | - ->setType($type); |
|
| 562 | + ->setIndex($index) |
|
| 563 | + ->setType($type); |
|
| 564 | 564 | $endpoint->setParams($params); |
| 565 | 565 | |
| 566 | 566 | try { |
@@ -630,9 +630,9 @@ discard block |
||
| 630 | 630 | /** @var \Elasticsearch\Endpoints\Mlt $endpoint */ |
| 631 | 631 | $endpoint = $endpointBuilder('Mlt'); |
| 632 | 632 | $endpoint->setID($id) |
| 633 | - ->setIndex($index) |
|
| 634 | - ->setType($type) |
|
| 635 | - ->setBody($body); |
|
| 633 | + ->setIndex($index) |
|
| 634 | + ->setType($type) |
|
| 635 | + ->setBody($body); |
|
| 636 | 636 | $endpoint->setParams($params); |
| 637 | 637 | $response = $endpoint->performRequest(); |
| 638 | 638 | return $response['data']; |
@@ -675,8 +675,8 @@ discard block |
||
| 675 | 675 | /** @var \Elasticsearch\Endpoints\Mget $endpoint */ |
| 676 | 676 | $endpoint = $endpointBuilder('Mget'); |
| 677 | 677 | $endpoint->setIndex($index) |
| 678 | - ->setType($type) |
|
| 679 | - ->setBody($body); |
|
| 678 | + ->setType($type) |
|
| 679 | + ->setBody($body); |
|
| 680 | 680 | $endpoint->setParams($params); |
| 681 | 681 | $response = $endpoint->performRequest(); |
| 682 | 682 | return $response['data']; |
@@ -711,8 +711,8 @@ discard block |
||
| 711 | 711 | /** @var \Elasticsearch\Endpoints\Msearch $endpoint */ |
| 712 | 712 | $endpoint = $endpointBuilder('Msearch'); |
| 713 | 713 | $endpoint->setIndex($index) |
| 714 | - ->setType($type) |
|
| 715 | - ->setBody($body); |
|
| 714 | + ->setType($type) |
|
| 715 | + ->setBody($body); |
|
| 716 | 716 | $endpoint->setParams($params); |
| 717 | 717 | $response = $endpoint->performRequest(); |
| 718 | 718 | return $response['data']; |
@@ -761,10 +761,10 @@ discard block |
||
| 761 | 761 | /** @var \Elasticsearch\Endpoints\Index $endpoint */ |
| 762 | 762 | $endpoint = $endpointBuilder('Index'); |
| 763 | 763 | $endpoint->setID($id) |
| 764 | - ->setIndex($index) |
|
| 765 | - ->setType($type) |
|
| 766 | - ->setBody($body) |
|
| 767 | - ->createIfAbsent(); |
|
| 764 | + ->setIndex($index) |
|
| 765 | + ->setType($type) |
|
| 766 | + ->setBody($body) |
|
| 767 | + ->createIfAbsent(); |
|
| 768 | 768 | $endpoint->setParams($params); |
| 769 | 769 | $response = $endpoint->performRequest(); |
| 770 | 770 | return $response['data']; |
@@ -801,8 +801,8 @@ discard block |
||
| 801 | 801 | /** @var \Elasticsearch\Endpoints\Bulk $endpoint */ |
| 802 | 802 | $endpoint = $endpointBuilder('Bulk'); |
| 803 | 803 | $endpoint->setIndex($index) |
| 804 | - ->setType($type) |
|
| 805 | - ->setBody($body); |
|
| 804 | + ->setType($type) |
|
| 805 | + ->setBody($body); |
|
| 806 | 806 | $endpoint->setParams($params); |
| 807 | 807 | $response = $endpoint->performRequest(); |
| 808 | 808 | return $response['data']; |
@@ -852,9 +852,9 @@ discard block |
||
| 852 | 852 | /** @var \Elasticsearch\Endpoints\Index $endpoint */ |
| 853 | 853 | $endpoint = $endpointBuilder('Index'); |
| 854 | 854 | $endpoint->setID($id) |
| 855 | - ->setIndex($index) |
|
| 856 | - ->setType($type) |
|
| 857 | - ->setBody($body); |
|
| 855 | + ->setIndex($index) |
|
| 856 | + ->setType($type) |
|
| 857 | + ->setBody($body); |
|
| 858 | 858 | $endpoint->setParams($params); |
| 859 | 859 | $response = $endpoint->performRequest(); |
| 860 | 860 | return $response['data']; |
@@ -888,7 +888,7 @@ discard block |
||
| 888 | 888 | /** @var \Elasticsearch\Endpoints\Suggest $endpoint */ |
| 889 | 889 | $endpoint = $endpointBuilder('Suggest'); |
| 890 | 890 | $endpoint->setIndex($index) |
| 891 | - ->setBody($body); |
|
| 891 | + ->setBody($body); |
|
| 892 | 892 | $endpoint->setParams($params); |
| 893 | 893 | $response = $endpoint->performRequest(); |
| 894 | 894 | return $response['data']; |
@@ -941,9 +941,9 @@ discard block |
||
| 941 | 941 | /** @var \Elasticsearch\Endpoints\Explain $endpoint */ |
| 942 | 942 | $endpoint = $endpointBuilder('Explain'); |
| 943 | 943 | $endpoint->setID($id) |
| 944 | - ->setIndex($index) |
|
| 945 | - ->setType($type) |
|
| 946 | - ->setBody($body); |
|
| 944 | + ->setIndex($index) |
|
| 945 | + ->setType($type) |
|
| 946 | + ->setBody($body); |
|
| 947 | 947 | $endpoint->setParams($params); |
| 948 | 948 | $response = $endpoint->performRequest(); |
| 949 | 949 | return $response['data']; |
@@ -1006,8 +1006,8 @@ discard block |
||
| 1006 | 1006 | /** @var \Elasticsearch\Endpoints\Search $endpoint */ |
| 1007 | 1007 | $endpoint = $endpointBuilder('Search'); |
| 1008 | 1008 | $endpoint->setIndex($index) |
| 1009 | - ->setType($type) |
|
| 1010 | - ->setBody($body); |
|
| 1009 | + ->setType($type) |
|
| 1010 | + ->setBody($body); |
|
| 1011 | 1011 | $endpoint->setParams($params); |
| 1012 | 1012 | $response = $endpoint->performRequest(); |
| 1013 | 1013 | return $response['data']; |
@@ -1039,7 +1039,7 @@ discard block |
||
| 1039 | 1039 | /** @var \Elasticsearch\Endpoints\SearchShards $endpoint */ |
| 1040 | 1040 | $endpoint = $endpointBuilder('SearchShards'); |
| 1041 | 1041 | $endpoint->setIndex($index) |
| 1042 | - ->setType($type); |
|
| 1042 | + ->setType($type); |
|
| 1043 | 1043 | $endpoint->setParams($params); |
| 1044 | 1044 | $response = $endpoint->performRequest(); |
| 1045 | 1045 | return $response['data']; |
@@ -1066,8 +1066,8 @@ discard block |
||
| 1066 | 1066 | /** @var \Elasticsearch\Endpoints\Search $endpoint */ |
| 1067 | 1067 | $endpoint = $endpointBuilder('SearchTemplate'); |
| 1068 | 1068 | $endpoint->setIndex($index) |
| 1069 | - ->setType($type) |
|
| 1070 | - ->setBody($body); |
|
| 1069 | + ->setType($type) |
|
| 1070 | + ->setBody($body); |
|
| 1071 | 1071 | $endpoint->setParams($params); |
| 1072 | 1072 | $response = $endpoint->performRequest(); |
| 1073 | 1073 | return $response['data']; |
@@ -1095,7 +1095,7 @@ discard block |
||
| 1095 | 1095 | /** @var \Elasticsearch\Endpoints\Scroll $endpoint */ |
| 1096 | 1096 | $endpoint = $endpointBuilder('Scroll'); |
| 1097 | 1097 | $endpoint->setScrollID($scrollID) |
| 1098 | - ->setBody($body); |
|
| 1098 | + ->setBody($body); |
|
| 1099 | 1099 | $endpoint->setParams($params); |
| 1100 | 1100 | $response = $endpoint->performRequest(); |
| 1101 | 1101 | return $response['data']; |
@@ -1123,8 +1123,8 @@ discard block |
||
| 1123 | 1123 | /** @var \Elasticsearch\Endpoints\Scroll $endpoint */ |
| 1124 | 1124 | $endpoint = $endpointBuilder('Scroll'); |
| 1125 | 1125 | $endpoint->setScrollID($scrollID) |
| 1126 | - ->setBody($body) |
|
| 1127 | - ->setClearScroll(true); |
|
| 1126 | + ->setBody($body) |
|
| 1127 | + ->setClearScroll(true); |
|
| 1128 | 1128 | $endpoint->setParams($params); |
| 1129 | 1129 | $response = $endpoint->performRequest(); |
| 1130 | 1130 | return $response['data']; |
@@ -1176,9 +1176,9 @@ discard block |
||
| 1176 | 1176 | /** @var \Elasticsearch\Endpoints\Update $endpoint */ |
| 1177 | 1177 | $endpoint = $endpointBuilder('Update'); |
| 1178 | 1178 | $endpoint->setID($id) |
| 1179 | - ->setIndex($index) |
|
| 1180 | - ->setType($type) |
|
| 1181 | - ->setBody($body); |
|
| 1179 | + ->setIndex($index) |
|
| 1180 | + ->setType($type) |
|
| 1181 | + ->setBody($body); |
|
| 1182 | 1182 | $endpoint->setParams($params); |
| 1183 | 1183 | $response = $endpoint->performRequest(); |
| 1184 | 1184 | return $response['data']; |
@@ -1204,7 +1204,7 @@ discard block |
||
| 1204 | 1204 | /** @var \Elasticsearch\Endpoints\Script\Get $endpoint */ |
| 1205 | 1205 | $endpoint = $endpointBuilder('Script\Get'); |
| 1206 | 1206 | $endpoint->setID($id) |
| 1207 | - ->setLang($lang); |
|
| 1207 | + ->setLang($lang); |
|
| 1208 | 1208 | $endpoint->setParams($params); |
| 1209 | 1209 | $response = $endpoint->performRequest(); |
| 1210 | 1210 | return $response['data']; |
@@ -1229,7 +1229,7 @@ discard block |
||
| 1229 | 1229 | /** @var \Elasticsearch\Endpoints\Script\Delete $endpoint */ |
| 1230 | 1230 | $endpoint = $endpointBuilder('Script\Delete'); |
| 1231 | 1231 | $endpoint->setID($id) |
| 1232 | - ->setLang($lang); |
|
| 1232 | + ->setLang($lang); |
|
| 1233 | 1233 | $endpoint->setParams($params); |
| 1234 | 1234 | $response = $endpoint->performRequest(); |
| 1235 | 1235 | return $response['data']; |
@@ -1255,8 +1255,8 @@ discard block |
||
| 1255 | 1255 | /** @var \Elasticsearch\Endpoints\Script\Put $endpoint */ |
| 1256 | 1256 | $endpoint = $endpointBuilder('Script\Put'); |
| 1257 | 1257 | $endpoint->setID($id) |
| 1258 | - ->setLang($lang) |
|
| 1259 | - ->setBody($body); |
|
| 1258 | + ->setLang($lang) |
|
| 1259 | + ->setBody($body); |
|
| 1260 | 1260 | $endpoint->setParams($params); |
| 1261 | 1261 | $response = $endpoint->performRequest(); |
| 1262 | 1262 | return $response['data']; |
@@ -1324,7 +1324,7 @@ discard block |
||
| 1324 | 1324 | /** @var \Elasticsearch\Endpoints\Template\Put $endpoint */ |
| 1325 | 1325 | $endpoint = $endpointBuilder('Template\Put'); |
| 1326 | 1326 | $endpoint->setID($id) |
| 1327 | - ->setBody($body); |
|
| 1327 | + ->setBody($body); |
|
| 1328 | 1328 | $endpoint->setParams($params); |
| 1329 | 1329 | $response = $endpoint->performRequest(); |
| 1330 | 1330 | return $response['data']; |
@@ -1436,7 +1436,7 @@ discard block |
||
| 1436 | 1436 | } |
| 1437 | 1437 | |
| 1438 | 1438 | if ($this->params['logObject'] === null) { |
| 1439 | - $this->setDefaultLogger(); |
|
| 1439 | + $this->setDefaultLogger(); |
|
| 1440 | 1440 | } |
| 1441 | 1441 | |
| 1442 | 1442 | if ($this->params['traceObject'] === null) { |
@@ -200,7 +200,7 @@ |
||
| 200 | 200 | $uri[] = $endpoint; |
| 201 | 201 | $uri = array_filter($uri); |
| 202 | 202 | |
| 203 | - return '/' . implode('/', $uri); |
|
| 203 | + return '/' . implode('/', $uri); |
|
| 204 | 204 | } |
| 205 | 205 | |
| 206 | 206 | |
@@ -58,7 +58,7 @@ |
||
| 58 | 58 | */ |
| 59 | 59 | protected function getURI() |
| 60 | 60 | { |
| 61 | - return $this->getOptionalURI('_bulk'); |
|
| 61 | + return $this->getOptionalURI('_bulk'); |
|
| 62 | 62 | |
| 63 | 63 | } |
| 64 | 64 | |