Skip to content

Commit

Permalink
Updated opensearch-php to reflect the latest OpenSearch API spec (202…
Browse files Browse the repository at this point in the history
…4-11-15)

Signed-off-by: GitHub <[email protected]>
  • Loading branch information
dblock authored Nov 15, 2024
1 parent 6b08b16 commit 33dd622
Show file tree
Hide file tree
Showing 12 changed files with 147 additions and 146 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
### Fixed
- Fixed PHP 8.4 deprecations
### Updated APIs
- Updated opensearch-php APIs to reflect [opensearch-api-specification@398481e](https://github.com/opensearch-project/opensearch-api-specification/commit/398481e5bd1cc590d947c35379c47096f2114f00)
- Updated opensearch-php APIs to reflect [opensearch-api-specification@6bb1fed](https://github.com/opensearch-project/opensearch-api-specification/commit/6bb1fed0a2c7cf094a5ecfdb01f0306a4b9f8eba)
- Updated opensearch-php APIs to reflect [opensearch-api-specification@07e329e](https://github.com/opensearch-project/opensearch-api-specification/commit/07e329e8d01fd0576de6a0a3c35412fd5a9163db)
- Updated opensearch-php APIs to reflect [opensearch-api-specification@1db1840](https://github.com/opensearch-project/opensearch-api-specification/commit/1db184063a463c5180a2cc824b1efc1aeebfd5eb)
Expand Down
68 changes: 34 additions & 34 deletions src/OpenSearch/Client.php

Large diffs are not rendered by default.

28 changes: 14 additions & 14 deletions src/OpenSearch/Namespaces/CatNamespace.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@
class CatNamespace extends AbstractNamespace
{
/**
* Shows information about currently configured aliases to indices including filter and routing infos.
* Shows information about currently configured aliases to indexes including filter and routing info.
*
* $params['name'] = (array) A comma-separated list of aliases to retrieve. Supports wildcards (`*`). To retrieve all aliases, omit this parameter or use `*` or `_all`.
* $params['expand_wildcards'] = (any) Whether to expand wildcard expression to concrete indices that are open, closed or both.
* $params['expand_wildcards'] = (any) Whether to expand wildcard expression to concrete indexes that are open, closed or both.
* $params['format'] = (string) A short version of the Accept header, e.g. json, yaml.
* $params['h'] = (array) Comma-separated list of column names to display.
* $params['help'] = (boolean) Return help information. (Default = false)
Expand Down Expand Up @@ -149,9 +149,9 @@ public function clusterManager(array $params = [])
return $this->performRequest($endpoint);
}
/**
* Provides quick access to the document count of the entire cluster, or individual indices.
* Provides quick access to the document count of the entire cluster, or individual indexes.
*
* $params['index'] = (array) Comma-separated list of data streams, indices, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indices, omit this parameter or use `*` or `_all`.
* $params['index'] = (array) Comma-separated list of data streams, indexes, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`.
* $params['format'] = (string) A short version of the Accept header, e.g. json, yaml.
* $params['h'] = (array) Comma-separated list of column names to display.
* $params['help'] = (boolean) Return help information. (Default = false)
Expand Down Expand Up @@ -255,15 +255,15 @@ public function help(array $params = [])
return $this->performRequest($endpoint);
}
/**
* Returns information about indices: number of primaries and replicas, document counts, disk size, ...
* Returns information about indexes: number of primaries and replicas, document counts, disk size, ...
*
* $params['index'] = (array) Comma-separated list of data streams, indices, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indices, omit this parameter or use `*` or `_all`.
* $params['index'] = (array) Comma-separated list of data streams, indexes, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`.
* $params['bytes'] = (enum) The unit used to display byte values. (Options = b,g,gb,k,kb,m,mb,p,pb,t,tb)
* $params['cluster_manager_timeout'] = (string) Operation timeout for connection to cluster-manager node.
* $params['expand_wildcards'] = (any) The type of index that wildcard patterns can match.
* $params['format'] = (string) A short version of the Accept header, e.g. json, yaml.
* $params['h'] = (array) Comma-separated list of column names to display.
* $params['health'] = (enum) The health status used to limit returned indices. By default, the response includes indices of any health status. (Options = green,red,yellow)
* $params['health'] = (enum) The health status used to limit returned indexes. By default, the response includes indexes of any health status. (Options = green,red,yellow)
* $params['help'] = (boolean) Return help information. (Default = false)
* $params['include_unloaded_segments'] = (boolean) If true, the response includes information from segments that are not loaded into memory. (Default = false)
* $params['local'] = (boolean) Return local information, do not retrieve the state from cluster-manager node. (Default = false)
Expand Down Expand Up @@ -468,7 +468,7 @@ public function plugins(array $params = [])
/**
* Returns information about index shard recoveries, both on-going completed.
*
* $params['index'] = (array) A comma-separated list of data streams, indices, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indices, omit this parameter or use `*` or `_all`.
* $params['index'] = (array) A comma-separated list of data streams, indexes, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`.
* $params['active_only'] = (boolean) If `true`, the response only includes ongoing shard recoveries. (Default = false)
* $params['bytes'] = (enum) The unit used to display byte values. (Options = b,g,gb,k,kb,m,mb,p,pb,t,tb)
* $params['detailed'] = (boolean) If `true`, the response includes detailed information about shard recoveries. (Default = false)
Expand Down Expand Up @@ -531,16 +531,16 @@ public function repositories(array $params = [])
*
* $params['index'] = (array) Comma-separated list or wildcard expression of index names to limit the returned information.
* $params['active_only'] = (boolean) If `true`, the response only includes ongoing segment replication events. (Default = false)
* $params['allow_no_indices'] = (boolean) Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified).
* $params['allow_no_indices'] = (boolean) Whether to ignore if a wildcard indexes expression resolves into no concrete indexes. (This includes `_all` string or when no indexes have been specified).
* $params['bytes'] = (enum) The unit in which to display byte values. (Options = b,g,gb,k,kb,m,mb,p,pb,t,tb)
* $params['completed_only'] = (boolean) If `true`, the response only includes latest completed segment replication events. (Default = false)
* $params['detailed'] = (boolean) If `true`, the response includes detailed information about segment replications. (Default = false)
* $params['expand_wildcards'] = (any) Whether to expand wildcard expression to concrete indices that are open, closed or both.
* $params['expand_wildcards'] = (any) Whether to expand wildcard expression to concrete indexes that are open, closed or both.
* $params['format'] = (string) A short version of the Accept header, e.g. json, yaml.
* $params['h'] = (array) Comma-separated list of column names to display.
* $params['help'] = (boolean) Return help information. (Default = false)
* $params['ignore_throttled'] = (boolean) Whether specified concrete, expanded or aliased indices should be ignored when throttled.
* $params['ignore_unavailable'] = (boolean) Whether specified concrete indices should be ignored when unavailable (missing or closed).
* $params['ignore_throttled'] = (boolean) Whether specified concrete, expanded or aliased indexes should be ignored when throttled.
* $params['ignore_unavailable'] = (boolean) Whether specified concrete indexes should be ignored when unavailable (missing or closed).
* $params['s'] = (array) Comma-separated list of column names or column aliases to sort by.
* $params['shards'] = (array) Comma-separated list of shards to display.
* $params['time'] = (enum) The unit in which to display time values. (Options = d,h,m,micros,ms,nanos,s)
Expand Down Expand Up @@ -569,7 +569,7 @@ public function segmentReplication(array $params = [])
/**
* Provides low-level information about the segments in the shards of an index.
*
* $params['index'] = (array) A comma-separated list of data streams, indices, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indices, omit this parameter or use `*` or `_all`.
* $params['index'] = (array) A comma-separated list of data streams, indexes, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`.
* $params['bytes'] = (enum) The unit used to display byte values. (Options = b,g,gb,k,kb,m,mb,p,pb,t,tb)
* $params['cluster_manager_timeout'] = (string) Operation timeout for connection to cluster-manager node.
* $params['format'] = (string) A short version of the Accept header, e.g. json, yaml.
Expand Down Expand Up @@ -601,7 +601,7 @@ public function segments(array $params = [])
/**
* Provides a detailed view of shard allocation on nodes.
*
* $params['index'] = (array) A comma-separated list of data streams, indices, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indices, omit this parameter or use `*` or `_all`.
* $params['index'] = (array) A comma-separated list of data streams, indexes, and aliases used to limit the request. Supports wildcards (`*`). To target all data streams and indexes, omit this parameter or use `*` or `_all`.
* $params['bytes'] = (enum) The unit used to display byte values. (Options = b,g,gb,k,kb,m,mb,p,pb,t,tb)
* $params['cluster_manager_timeout'] = (string) Operation timeout for connection to cluster-manager node.
* $params['format'] = (string) A short version of the Accept header, e.g. json, yaml.
Expand Down
16 changes: 8 additions & 8 deletions src/OpenSearch/Namespaces/ClusterNamespace.php
Original file line number Diff line number Diff line change
Expand Up @@ -280,11 +280,11 @@ public function getWeightedRouting(array $params = [])
/**
* Returns basic information about the health of the cluster.
*
* $params['index'] = (array) Comma-separated list of data streams, indices, and index aliases used to limit the request. Wildcard expressions (*) are supported. To target all data streams and indices in a cluster, omit this parameter or use `_all` or `*`.
* $params['index'] = (array) Comma-separated list of data streams, indexes, and index aliases used to limit the request. Wildcard expressions (*) are supported. To target all data streams and indexes in a cluster, omit this parameter or use `_all` or `*`.
* $params['awareness_attribute'] = (string) The awareness attribute for which the health is required.
* $params['cluster_manager_timeout'] = (string) Operation timeout for connection to cluster-manager node.
* $params['expand_wildcards'] = (any) Whether to expand wildcard expression to concrete indices that are open, closed or both.
* $params['level'] = (enum) Can be one of cluster, indices or shards. Controls the details level of the health information returned. (Options = awareness_attributes,cluster,indices,shards)
* $params['expand_wildcards'] = (any) Whether to expand wildcard expression to concrete indexes that are open, closed or both.
* $params['level'] = (enum) Can be one of cluster, indexes or shards. Controls the details level of the health information returned. (Options = awareness_attributes,cluster,indices,shards)
* $params['local'] = (boolean) If true, the request retrieves information from the local node only. Defaults to false, which means information is retrieved from the master node. (Default = false)
* $params['master_timeout'] = (string) Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error.
* $params['timeout'] = (string) Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error.
Expand Down Expand Up @@ -363,7 +363,7 @@ public function postVotingConfigExclusions(array $params = [])
/**
* Creates or updates a component template.
*
* $params['name'] = (string) Name of the component template to create. OpenSearch includes the following built-in component templates: `logs-mappings`; 'logs-settings`; `metrics-mappings`; `metrics-settings`;`synthetics-mapping`; `synthetics-settings`. OpenSearch Agent uses these templates to configure backing indices for its data streams. If you use OpenSearch Agent and want to overwrite one of these templates, set the `version` for your replacement template higher than the current version. If you don't use OpenSearch Agent and want to disable all built-in component and index templates, set `stack.templates.enabled` to `false` using the cluster update settings API.
* $params['name'] = (string) Name of the component template to create. OpenSearch includes the following built-in component templates: `logs-mappings`; 'logs-settings`; `metrics-mappings`; `metrics-settings`;`synthetics-mapping`; `synthetics-settings`. OpenSearch Agent uses these templates to configure backing indexes for its data streams. If you use OpenSearch Agent and want to overwrite one of these templates, set the `version` for your replacement template higher than the current version. If you don't use OpenSearch Agent and want to disable all built-in component and index templates, set `stack.templates.enabled` to `false` using the cluster update settings API.
* $params['cluster_manager_timeout'] = (string) Operation timeout for connection to cluster-manager node.
* $params['create'] = (boolean) If `true`, this request cannot replace or update existing component templates. (Default = false)
* $params['master_timeout'] = (string) Period to wait for a connection to the master node.If no response is received before the timeout expires, the request fails and returns an error.
Expand Down Expand Up @@ -527,12 +527,12 @@ public function reroute(array $params = [])
* Returns a comprehensive information about the state of the cluster.
*
* $params['metric'] = (array) Limit the information returned to the specified metrics
* $params['index'] = (array) A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices
* $params['allow_no_indices'] = (boolean) Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)
* $params['index'] = (array) A comma-separated list of index names; use `_all` or empty string to perform the operation on all indexes
* $params['allow_no_indices'] = (boolean) Whether to ignore if a wildcard indexes expression resolves into no concrete indexes. (This includes `_all` string or when no indexes have been specified)
* $params['cluster_manager_timeout'] = (string) Operation timeout for connection to cluster-manager node.
* $params['expand_wildcards'] = (any) Whether to expand wildcard expression to concrete indices that are open, closed or both.
* $params['expand_wildcards'] = (any) Whether to expand wildcard expression to concrete indexes that are open, closed or both.
* $params['flat_settings'] = (boolean) Return settings in flat format. (Default = false)
* $params['ignore_unavailable'] = (boolean) Whether specified concrete indices should be ignored when unavailable (missing or closed)
* $params['ignore_unavailable'] = (boolean) Whether specified concrete indexes should be ignored when unavailable (missing or closed)
* $params['local'] = (boolean) Return local information, do not retrieve the state from cluster-manager node. (Default = false)
* $params['master_timeout'] = (string) Specify timeout for connection to master
* $params['wait_for_metadata_version'] = (integer) Wait for the metadata version to be equal or greater than the specified metadata version
Expand Down
2 changes: 1 addition & 1 deletion src/OpenSearch/Namespaces/DanglingIndicesNamespace.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public function importDanglingIndex(array $params = [])
return $this->performRequest($endpoint);
}
/**
* Returns all dangling indices.
* Returns all dangling indexes.
*
* $params['pretty'] = (boolean) Whether to pretty format the returned JSON response. (Default = false)
* $params['human'] = (boolean) Whether to return human readable values for statistics. (Default = true)
Expand Down
Loading

0 comments on commit 33dd622

Please sign in to comment.