Skip to content

Commit

Permalink
[AUTOCUT] Update opensearch-ruby to reflect the latest OpenSearch API…
Browse files Browse the repository at this point in the history
… spec (2025-02-09) (#271)

Signed-off-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: dblock <542335+dblock@users.noreply.github.com>
  • Loading branch information
opensearch-trigger-bot[bot] and dblock authored Feb 10, 2025
1 parent 29567b4 commit 3f6b256
Show file tree
Hide file tree
Showing 104 changed files with 1,946 additions and 326 deletions.
2 changes: 1 addition & 1 deletion lib/opensearch/api/actions/asynchronous_search/delete.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ module OpenSearch
module API
module AsynchronousSearch
module Actions
# Delete asynchronous search.
# Deletes any responses from an asynchronous search.
#
# @option args [String] :id *Required*
# @option args [List] :ignore set to [404] to ignore server's NOT FOUND error for this request
Expand Down
2 changes: 1 addition & 1 deletion lib/opensearch/api/actions/asynchronous_search/get.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ module OpenSearch
module API
module AsynchronousSearch
module Actions
# Get partial responses from asynchronous search.
# Gets partial responses from an asynchronous search.
#
# @option args [String] :id *Required*
def get(args = {})
Expand Down
8 changes: 4 additions & 4 deletions lib/opensearch/api/actions/asynchronous_search/search.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ module OpenSearch
module API
module AsynchronousSearch
module Actions
# Perform an asynchronous search.
# Performs an asynchronous search.
#
# @option args [String] :index The name of the index to be searched. Can be an individual name, a comma-separated list of indexes, or a wildcard expression of index names.
# @option args [String] :keep_alive The amount of time that the result is saved in the cluster. For example, `2d` means that the results are stored in the cluster for 48 hours. The saved search results are deleted after this period or if the search is canceled. Note that this includes the query execution time. If the query overruns this time, the process cancels this query automatically.
# @option args [Boolean] :keep_on_completion Whether you want to save the results in the cluster after the search is complete.
# @option args [String] :wait_for_completion_timeout The amount of time that you plan to wait for the results. You can poll the remaining results based on an ID. The maximum value is `300s`. Default is `1s`.
# @option args [String] :keep_alive The amount of time that the result is saved in the cluster. For example, `2d` means that the results are stored in the cluster for 48 hours. The saved search results are deleted after this period or if the search is canceled. Note that this includes the query execution time. If the query exceeds this amount of time, the process cancels this query automatically.
# @option args [Boolean] :keep_on_completion Whether to save the results in the cluster after the search is complete. You can examine the stored results at a later time.
# @option args [String] :wait_for_completion_timeout The amount of time to wait for the results. You can poll the remaining results based on an ID. The maximum value is 300 seconds. Default is `1s`.
# @option args [Hash] :body The search definition using the Query DSL.
def search(args = {})
args = Utils.clone_and_normalize_arguments(args)
Expand Down
2 changes: 1 addition & 1 deletion lib/opensearch/api/actions/asynchronous_search/stats.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ module OpenSearch
module API
module AsynchronousSearch
module Actions
# Monitoring of asynchronous searches that are running, completed, and/or persisted.
# Monitors any asynchronous searches that are `running`, `completed`, or `persisted`.
#
def stats(args = {})
args = Utils.clone_and_normalize_arguments(args)
Expand Down
16 changes: 8 additions & 8 deletions lib/opensearch/api/actions/cat/aliases.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ module OpenSearch
module API
module Cat
module Actions
# Shows information about currently configured aliases to indexes including filter and routing info.
# Shows information about aliases currently configured to indexes, including filter and routing information.
#
# @option args [Enumerable<String>, String] :expand_wildcards Whether to expand wildcard expression to concrete indexes that are open, closed or both.
# @option args [String] :format A short version of the Accept header (for example, `json`, `yaml`).
# @option args [Enumerable<String>] :h Comma-separated list of column names to display.
# @option args [Boolean] :help Return help information.
# @option args [Boolean] :local Return local information, do not retrieve the state from cluster-manager node.
# @option args [Enumerable<String>] :s Comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Verbose mode. Display column headers.
# @option args [Enumerable<String>, String] :expand_wildcards Specifies the type of index that wildcard expressions can match. Supports comma-separated values.
# @option args [String] :format A short version of the `Accept` header, such as `json` or `yaml`.
# @option args [Enumerable<String>] :h A comma-separated list of column names to display.
# @option args [Boolean] :help Returns help information.
# @option args [Boolean] :local Whether to return information from the local node only instead of from the cluster manager node.
# @option args [Enumerable<String>] :s A comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Enables verbose mode, which displays column headers.
# @option args [Enumerable<String>, String] :name A comma-separated list of aliases to retrieve. Supports wildcards (`*`). To retrieve all aliases, omit this parameter or use `*` or `_all`.
def aliases(args = {})
args = Utils.clone_and_normalize_arguments(args)
Expand Down
14 changes: 7 additions & 7 deletions lib/opensearch/api/actions/cat/all_pit_segments.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ module OpenSearch
module API
module Cat
module Actions
# Lists all active point-in-time segments.
# Lists all active CAT point-in-time segments.
#
# @option args [String] :bytes The unit in which to display byte values.
# @option args [String] :format A short version of the Accept header (for example, `json`, `yaml`).
# @option args [Enumerable<String>] :h Comma-separated list of column names to display.
# @option args [Boolean] :help Return help information.
# @option args [Enumerable<String>] :s Comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Verbose mode. Display column headers.
# @option args [String] :bytes The units used to display byte values.
# @option args [String] :format A short version of the `Accept` header, such as `json` or `yaml`.
# @option args [Enumerable<String>] :h A comma-separated list of column names to display.
# @option args [Boolean] :help Returns help information.
# @option args [Enumerable<String>] :s A comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Enables verbose mode, which displays column headers.
def all_pit_segments(args = {})
args = Utils.clone_and_normalize_arguments(args)
headers = args.delete('headers') || {}
Expand Down
20 changes: 10 additions & 10 deletions lib/opensearch/api/actions/cat/allocation.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@ module Cat
module Actions
# Provides a snapshot of how many shards are allocated to each data node and how much disk space they are using.
#
# @option args [String] :bytes The unit used to display byte values.
# @option args [String] :cluster_manager_timeout Operation timeout for connection to cluster-manager node.
# @option args [String] :format A short version of the Accept header (for example, `json`, `yaml`).
# @option args [Enumerable<String>] :h Comma-separated list of column names to display.
# @option args [Boolean] :help Return help information.
# @option args [Boolean] :local Return local information, do not retrieve the state from cluster-manager node.
# @option args [String] :master_timeout DEPRECATED Operation timeout for connection to cluster-manager node.
# @option args [Enumerable<String>] :s Comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Verbose mode. Display column headers.
# @option args [Enumerable<String>, String] :node_id Comma-separated list of node identifiers or names used to limit the returned information.
# @option args [String] :bytes The units used to display byte values.
# @option args [String] :cluster_manager_timeout A timeout for connection to the cluster manager node.
# @option args [String] :format A short version of the HTTP `Accept` header, such as `json` or `yaml`.
# @option args [Enumerable<String>] :h A comma-separated list of column names to display.
# @option args [Boolean] :help Returns help information.
# @option args [Boolean] :local Returns local information but does not retrieve the state from cluster-manager node.
# @option args [String] :master_timeout DEPRECATED A timeout for connection to the cluster manager node.
# @option args [Enumerable<String>] :s A comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Enables verbose mode, which displays column headers.
# @option args [Enumerable<String>, String] :node_id A comma-separated list of node IDs or names used to limit the returned information.
def allocation(args = {})
args = Utils.clone_and_normalize_arguments(args)
_node_id = args.delete('node_id')
Expand Down
16 changes: 8 additions & 8 deletions lib/opensearch/api/actions/cat/cluster_manager.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ module Cat
module Actions
# Returns information about the cluster-manager node.
#
# @option args [String] :cluster_manager_timeout Operation timeout for connection to cluster-manager node.
# @option args [String] :format A short version of the Accept header (for example, `json`, `yaml`).
# @option args [Enumerable<String>] :h Comma-separated list of column names to display.
# @option args [Boolean] :help Return help information.
# @option args [Boolean] :local Return local information, do not retrieve the state from cluster-manager node.
# @option args [String] :master_timeout DEPRECATED Operation timeout for connection to cluster-manager node.
# @option args [Enumerable<String>] :s Comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Verbose mode. Display column headers.
# @option args [String] :cluster_manager_timeout A timeout for connection to the cluster manager node.
# @option args [String] :format A short version of the HTTP `Accept` header, such as `json` or `yaml`.
# @option args [Enumerable<String>] :h A comma-separated list of column names to display.
# @option args [Boolean] :help Returns help information.
# @option args [Boolean] :local Returns local information but does not retrieve the state from the cluster manager node.
# @option args [String] :master_timeout DEPRECATED A timeout for connection to the cluster manager node.
# @option args [Enumerable<String>] :s A comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Enables verbose mode, which displays column headers.
def cluster_manager(args = {})
args = Utils.clone_and_normalize_arguments(args)
headers = args.delete('headers') || {}
Expand Down
12 changes: 6 additions & 6 deletions lib/opensearch/api/actions/cat/count.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ module OpenSearch
module API
module Cat
module Actions
# Provides quick access to the document count of the entire cluster, or individual indexes.
# Provides quick access to the document count of the entire cluster or of an individual index.
#
# @option args [String] :format A short version of the Accept header (for example, `json`, `yaml`).
# @option args [Enumerable<String>] :h Comma-separated list of column names to display.
# @option args [Boolean] :help Return help information.
# @option args [Enumerable<String>] :s Comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Verbose mode. Display column headers.
# @option args [String] :format A short version of the `Accept` header, such as `json` or `yaml`.
# @option args [Enumerable<String>] :h A comma-separated list of column names to display.
# @option args [Boolean] :help Returns help information.
# @option args [Enumerable<String>] :s A comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Enables verbose mode, which displays column headers.
# @option args [Enumerable<String>, String] :index 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`.
def count(args = {})
args = Utils.clone_and_normalize_arguments(args)
Expand Down
14 changes: 7 additions & 7 deletions lib/opensearch/api/actions/cat/fielddata.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ module Cat
module Actions
# Shows how much heap memory is currently being used by field data on every data node in the cluster.
#
# @option args [String] :bytes The unit used to display byte values.
# @option args [Enumerable<String>, String] :fields Comma-separated list of fields used to limit returned information.
# @option args [String] :format A short version of the Accept header (for example, `json`, `yaml`).
# @option args [Enumerable<String>] :h Comma-separated list of column names to display.
# @option args [Boolean] :help Return help information.
# @option args [Enumerable<String>] :s Comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Verbose mode. Display column headers.
# @option args [String] :bytes The units used to display byte values.
# @option args [Enumerable<String>, String] :fields A comma-separated list of fields used to limit the amount of returned information.
# @option args [String] :format A short version of the `Accept` header, such as `json` or `yaml`.
# @option args [Enumerable<String>] :h A comma-separated list of column names to display.
# @option args [Boolean] :help Returns help information.
# @option args [Enumerable<String>] :s A comma-separated list of column names or column aliases to sort by.
# @option args [Boolean] :v Enables verbose mode, which displays column headers.
def fielddata(args = {})
args = Utils.clone_and_normalize_arguments(args)
_fields = args.delete('fields')
Expand Down
12 changes: 6 additions & 6 deletions lib/opensearch/api/actions/cat/health.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ module Cat
module Actions
# Returns a concise representation of the cluster health.
#
# @option args [String] :format A short version of the Accept header (for example, `json`, `yaml`).
# @option args [Enumerable<String>] :h Comma-separated list of column names to display.
# @option args [Boolean] :help Return help information.
# @option args [Enumerable<String>] :s Comma-separated list of column names or column aliases to sort by.
# @option args [String] :format A short version of the `Accept` header, such as `json` or `yaml`.
# @option args [Enumerable<String>] :h A comma-separated list of column names to display.
# @option args [Boolean] :help Returns help information.
# @option args [Enumerable<String>] :s A comma-separated list of column names or column aliases to sort by.
# @option args [String] :time The unit used to display time values.
# @option args [Boolean] :ts (default: true) If `true`, returns `HH:MM:SS` and Unix epoch timestamps.
# @option args [Boolean] :v Verbose mode. Display column headers.
# @option args [Boolean] :ts (default: true) When `true`, returns `HH:MM:SS` and Unix epoch timestamps.
# @option args [Boolean] :v Enables verbose mode, which displays column headers.
def health(args = {})
args = Utils.clone_and_normalize_arguments(args)
headers = args.delete('headers') || {}
Expand Down
32 changes: 16 additions & 16 deletions lib/opensearch/api/actions/cat/indices.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,23 +13,23 @@ module OpenSearch
module API
module Cat
module Actions
# Returns information about indexes: number of primaries and replicas, document counts, disk size, ...
# Lists information related to indexes, that is, how much disk space they are using, how many shards they have, their health status, and so on.
#
# @option args [String] :bytes The unit used to display byte values.
# @option args [String] :cluster_manager_timeout Operation timeout for connection to cluster-manager node.
# @option args [Enumerable<String>, String] :expand_wildcards The type of index that wildcard patterns can match.
# @option args [String] :format A short version of the Accept header (for example, `json`, `yaml`).
# @option args [Enumerable<String>] :h Comma-separated list of column names to display.
# @option args [String] :health The health status used to limit returned indexes. By default, the response includes indexes of any health status.
# @option args [Boolean] :help Return help information.
# @option args [Boolean] :include_unloaded_segments If `true`, the response includes information from segments that are not loaded into memory.
# @option args [Boolean] :local Return local information, do not retrieve the state from cluster-manager node.
# @option args [String] :master_timeout DEPRECATED Operation timeout for connection to cluster-manager node.
# @option args [Boolean] :pri If `true`, the response only includes information from primary shards.
# @option args [Enumerable<String>] :s Comma-separated list of column names or column aliases to sort by.
# @option args [String] :time The unit used to display time values.
# @option args [Boolean] :v Verbose mode. Display column headers.
# @option args [Enumerable<String>, String] :index 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`.
# @option args [String] :bytes The units used to display byte values.
# @option args [String] :cluster_manager_timeout The amount of time allowed to establish a connection to the cluster manager node.
# @option args [Enumerable<String>, String] :expand_wildcards Specifies the type of index that wildcard expressions can match. Supports comma-separated values.
# @option args [String] :format A short version of the `Accept` header, such as `json` or `yaml`.
# @option args [Enumerable<String>] :h A comma-separated list of column names to display.
# @option args [String] :health Limits indexes based on their health status. Supported values are `green`, `yellow`, and `red`.
# @option args [Boolean] :help Returns help information.
# @option args [Boolean] :include_unloaded_segments Whether to include information from segments not loaded into memory.
# @option args [Boolean] :local Returns local information but does not retrieve the state from the cluster manager node.
# @option args [String] :master_timeout DEPRECATED The amount of time allowed to establish a connection to the cluster manager node.
# @option args [Boolean] :pri When `true`, returns information only from the primary shards.
# @option args [Enumerable<String>] :s A comma-separated list of column names or column aliases to sort by.
# @option args [String] :time Specifies the time units.
# @option args [Boolean] :v Enables verbose mode, which displays column headers.
# @option args [Enumerable<String>, String] :index 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`.
def indices(args = {})
args = Utils.clone_and_normalize_arguments(args)
_index = args.delete('index')
Expand Down
Loading

0 comments on commit 3f6b256

Please sign in to comment.