module Elasticsearch::API::Logstash::Actions
Public Instance Methods
Source
# File lib/elasticsearch/api/actions/logstash/delete_pipeline.rb, line 34 def delete_pipeline(arguments = {}) request_opts = { endpoint: arguments[:endpoint] || 'logstash.delete_pipeline' } defined_params = [:id].each_with_object({}) do |variable, set_variables| set_variables[variable] = arguments[variable] if arguments.key?(variable) end request_opts[:defined_params] = defined_params unless defined_params.empty? raise ArgumentError, "Required argument 'id' missing" unless arguments[:id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _id = arguments.delete(:id) method = Elasticsearch::API::HTTP_DELETE path = "_logstash/pipeline/#{Utils.listify(_id)}" params = {} Elasticsearch::API::Response.new( perform_request(method, path, params, body, headers, request_opts) ) end
Delete a Logstash
pipeline. Delete a pipeline that is used for Logstash
Central Management. If the request succeeds, you receive an empty response with an appropriate status code.
@option arguments [String] :id An identifier for the pipeline. (Required) @option arguments [Hash] :headers Custom HTTP headers
@see www.elastic.co/docs/api/doc/elasticsearch/v9/operation/operation-logstash-delete-pipeline
Source
# File lib/elasticsearch/api/actions/logstash/get_pipeline.rb, line 33 def get_pipeline(arguments = {}) request_opts = { endpoint: arguments[:endpoint] || 'logstash.get_pipeline' } defined_params = [:id].each_with_object({}) do |variable, set_variables| set_variables[variable] = arguments[variable] if arguments.key?(variable) end request_opts[:defined_params] = defined_params unless defined_params.empty? arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _id = arguments.delete(:id) method = Elasticsearch::API::HTTP_GET path = if _id "_logstash/pipeline/#{Utils.listify(_id)}" else '_logstash/pipeline' end params = {} Elasticsearch::API::Response.new( perform_request(method, path, params, body, headers, request_opts) ) end
Get Logstash
pipelines. Get pipelines that are used for Logstash
Central Management.
@option arguments [String, Array] :id A comma-separated list of pipeline identifiers. @option arguments [Hash] :headers Custom HTTP headers
@see www.elastic.co/docs/api/doc/elasticsearch/v9/operation/operation-logstash-get-pipeline
Source
# File lib/elasticsearch/api/actions/logstash/put_pipeline.rb, line 35 def put_pipeline(arguments = {}) request_opts = { endpoint: arguments[:endpoint] || 'logstash.put_pipeline' } defined_params = [:id].each_with_object({}) do |variable, set_variables| set_variables[variable] = arguments[variable] if arguments.key?(variable) end request_opts[:defined_params] = defined_params unless defined_params.empty? raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'id' missing" unless arguments[:id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _id = arguments.delete(:id) method = Elasticsearch::API::HTTP_PUT path = "_logstash/pipeline/#{Utils.listify(_id)}" params = {} Elasticsearch::API::Response.new( perform_request(method, path, params, body, headers, request_opts) ) end
Create or update a Logstash
pipeline. Create a pipeline that is used for Logstash
Central Management. If the specified pipeline exists, it is replaced.
@option arguments [String] :id An identifier for the pipeline. (Required) @option arguments [Hash] :headers Custom HTTP headers @option arguments [Hash] :body pipeline
@see www.elastic.co/docs/api/doc/elasticsearch/v9/operation/operation-logstash-put-pipeline