Module: ElasticsearchServerless::API::MachineLearning::Actions
- Defined in:
- lib/elasticsearch-serverless/api/machine_learning/put_job.rb,
lib/elasticsearch-serverless/api/machine_learning/get_jobs.rb,
lib/elasticsearch-serverless/api/machine_learning/open_job.rb,
lib/elasticsearch-serverless/api/machine_learning/close_job.rb,
lib/elasticsearch-serverless/api/machine_learning/flush_job.rb,
lib/elasticsearch-serverless/api/machine_learning/reset_job.rb,
lib/elasticsearch-serverless/api/machine_learning/delete_job.rb,
lib/elasticsearch-serverless/api/machine_learning/put_filter.rb,
lib/elasticsearch-serverless/api/machine_learning/update_job.rb,
lib/elasticsearch-serverless/api/machine_learning/get_filters.rb,
lib/elasticsearch-serverless/api/machine_learning/put_calendar.rb,
lib/elasticsearch-serverless/api/machine_learning/put_datafeed.rb,
lib/elasticsearch-serverless/api/machine_learning/delete_filter.rb,
lib/elasticsearch-serverless/api/machine_learning/get_calendars.rb,
lib/elasticsearch-serverless/api/machine_learning/get_datafeeds.rb,
lib/elasticsearch-serverless/api/machine_learning/get_job_stats.rb,
lib/elasticsearch-serverless/api/machine_learning/stop_datafeed.rb,
lib/elasticsearch-serverless/api/machine_learning/update_filter.rb,
lib/elasticsearch-serverless/api/machine_learning/start_datafeed.rb,
lib/elasticsearch-serverless/api/machine_learning/delete_calendar.rb,
lib/elasticsearch-serverless/api/machine_learning/delete_datafeed.rb,
lib/elasticsearch-serverless/api/machine_learning/update_datafeed.rb,
lib/elasticsearch-serverless/api/machine_learning/preview_datafeed.rb,
lib/elasticsearch-serverless/api/machine_learning/put_calendar_job.rb,
lib/elasticsearch-serverless/api/machine_learning/put_trained_model.rb,
lib/elasticsearch-serverless/api/machine_learning/get_datafeed_stats.rb,
lib/elasticsearch-serverless/api/machine_learning/get_trained_models.rb,
lib/elasticsearch-serverless/api/machine_learning/delete_calendar_job.rb,
lib/elasticsearch-serverless/api/machine_learning/evaluate_data_frame.rb,
lib/elasticsearch-serverless/api/machine_learning/get_calendar_events.rb,
lib/elasticsearch-serverless/api/machine_learning/get_overall_buckets.rb,
lib/elasticsearch-serverless/api/machine_learning/delete_trained_model.rb,
lib/elasticsearch-serverless/api/machine_learning/post_calendar_events.rb,
lib/elasticsearch-serverless/api/machine_learning/delete_calendar_event.rb,
lib/elasticsearch-serverless/api/machine_learning/estimate_model_memory.rb,
lib/elasticsearch-serverless/api/machine_learning/put_trained_model_alias.rb,
lib/elasticsearch-serverless/api/machine_learning/get_data_frame_analytics.rb,
lib/elasticsearch-serverless/api/machine_learning/get_trained_models_stats.rb,
lib/elasticsearch-serverless/api/machine_learning/put_data_frame_analytics.rb,
lib/elasticsearch-serverless/api/machine_learning/stop_data_frame_analytics.rb,
lib/elasticsearch-serverless/api/machine_learning/delete_trained_model_alias.rb,
lib/elasticsearch-serverless/api/machine_learning/start_data_frame_analytics.rb,
lib/elasticsearch-serverless/api/machine_learning/delete_data_frame_analytics.rb,
lib/elasticsearch-serverless/api/machine_learning/update_data_frame_analytics.rb,
lib/elasticsearch-serverless/api/machine_learning/preview_data_frame_analytics.rb,
lib/elasticsearch-serverless/api/machine_learning/put_trained_model_vocabulary.rb,
lib/elasticsearch-serverless/api/machine_learning/stop_trained_model_deployment.rb,
lib/elasticsearch-serverless/api/machine_learning/get_data_frame_analytics_stats.rb,
lib/elasticsearch-serverless/api/machine_learning/start_trained_model_deployment.rb,
lib/elasticsearch-serverless/api/machine_learning/put_trained_model_definition_part.rb
Instance Method Summary collapse
-
#close_job(arguments = {}) ⇒ Object
Closes one or more anomaly detection jobs.
-
#delete_calendar(arguments = {}) ⇒ Object
Deletes a calendar.
-
#delete_calendar_event(arguments = {}) ⇒ Object
Deletes scheduled events from a calendar.
-
#delete_calendar_job(arguments = {}) ⇒ Object
Deletes anomaly detection jobs from a calendar.
-
#delete_data_frame_analytics(arguments = {}) ⇒ Object
Deletes an existing data frame analytics job.
-
#delete_datafeed(arguments = {}) ⇒ Object
Deletes an existing datafeed.
-
#delete_filter(arguments = {}) ⇒ Object
Deletes a filter.
-
#delete_job(arguments = {}) ⇒ Object
Deletes an existing anomaly detection job.
-
#delete_trained_model(arguments = {}) ⇒ Object
Deletes an existing trained inference model that is currently not referenced by an ingest pipeline.
-
#delete_trained_model_alias(arguments = {}) ⇒ Object
Deletes a model alias that refers to the trained model.
-
#estimate_model_memory(arguments = {}) ⇒ Object
Estimates the model memory.
-
#evaluate_data_frame(arguments = {}) ⇒ Object
Evaluates the data frame analytics for an annotated index.
-
#flush_job(arguments = {}) ⇒ Object
Forces any buffered data to be processed by the job.
-
#get_calendar_events(arguments = {}) ⇒ Object
Retrieves information about the scheduled events in calendars.
-
#get_calendars(arguments = {}) ⇒ Object
Retrieves configuration information for calendars.
-
#get_data_frame_analytics(arguments = {}) ⇒ Object
Retrieves configuration information for data frame analytics jobs.
-
#get_data_frame_analytics_stats(arguments = {}) ⇒ Object
Retrieves usage information for data frame analytics jobs.
-
#get_datafeed_stats(arguments = {}) ⇒ Object
Retrieves usage information for datafeeds.
-
#get_datafeeds(arguments = {}) ⇒ Object
Retrieves configuration information for datafeeds.
-
#get_filters(arguments = {}) ⇒ Object
Retrieves filters.
-
#get_job_stats(arguments = {}) ⇒ Object
Retrieves usage information for anomaly detection jobs.
-
#get_jobs(arguments = {}) ⇒ Object
Retrieves configuration information for anomaly detection jobs.
-
#get_overall_buckets(arguments = {}) ⇒ Object
Retrieves overall bucket results that summarize the bucket results of multiple anomaly detection jobs.
-
#get_trained_models(arguments = {}) ⇒ Object
Retrieves configuration information for a trained inference model.
-
#get_trained_models_stats(arguments = {}) ⇒ Object
Retrieves usage information for trained inference models.
-
#open_job(arguments = {}) ⇒ Object
Opens one or more anomaly detection jobs.
-
#post_calendar_events(arguments = {}) ⇒ Object
Posts scheduled events in a calendar.
-
#preview_data_frame_analytics(arguments = {}) ⇒ Object
Previews that will be analyzed given a data frame analytics config.
-
#preview_datafeed(arguments = {}) ⇒ Object
Previews a datafeed.
-
#put_calendar(arguments = {}) ⇒ Object
Instantiates a calendar.
-
#put_calendar_job(arguments = {}) ⇒ Object
Adds an anomaly detection job to a calendar.
-
#put_data_frame_analytics(arguments = {}) ⇒ Object
Instantiates a data frame analytics job.
-
#put_datafeed(arguments = {}) ⇒ Object
Instantiates a datafeed.
-
#put_filter(arguments = {}) ⇒ Object
Instantiates a filter.
-
#put_job(arguments = {}) ⇒ Object
Instantiates an anomaly detection job.
-
#put_trained_model(arguments = {}) ⇒ Object
Creates an inference trained model.
-
#put_trained_model_alias(arguments = {}) ⇒ Object
Creates a new model alias (or reassigns an existing one) to refer to the trained model.
-
#put_trained_model_definition_part(arguments = {}) ⇒ Object
Creates part of a trained model definition.
-
#put_trained_model_vocabulary(arguments = {}) ⇒ Object
Creates a trained model vocabulary.
-
#reset_job(arguments = {}) ⇒ Object
Resets an existing anomaly detection job.
-
#start_data_frame_analytics(arguments = {}) ⇒ Object
Starts a data frame analytics job.
-
#start_datafeed(arguments = {}) ⇒ Object
Starts one or more datafeeds.
-
#start_trained_model_deployment(arguments = {}) ⇒ Object
Start a trained model deployment.
-
#stop_data_frame_analytics(arguments = {}) ⇒ Object
Stops one or more data frame analytics jobs.
-
#stop_datafeed(arguments = {}) ⇒ Object
Stops one or more datafeeds.
-
#stop_trained_model_deployment(arguments = {}) ⇒ Object
Stop a trained model deployment.
-
#update_data_frame_analytics(arguments = {}) ⇒ Object
Updates certain properties of a data frame analytics job.
-
#update_datafeed(arguments = {}) ⇒ Object
Updates certain properties of a datafeed.
-
#update_filter(arguments = {}) ⇒ Object
Updates the description of a filter, adds items, or removes items.
-
#update_job(arguments = {}) ⇒ Object
Updates certain properties of an anomaly detection job.
Instance Method Details
#close_job(arguments = {}) ⇒ Object
Closes one or more anomaly detection jobs. A job can be opened and closed multiple times throughout its lifecycle.
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/close_job.rb', line 36 def close_job(arguments = {}) raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/anomaly_detectors/#{Utils.listify(_job_id)}/_close" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#delete_calendar(arguments = {}) ⇒ Object
Deletes a calendar.
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
# File 'lib/elasticsearch-serverless/api/machine_learning/delete_calendar.rb', line 32 def delete_calendar(arguments = {}) raise ArgumentError, "Required argument 'calendar_id' missing" unless arguments[:calendar_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _calendar_id = arguments.delete(:calendar_id) method = ElasticsearchServerless::API::HTTP_DELETE path = "_ml/calendars/#{Utils.listify(_calendar_id)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#delete_calendar_event(arguments = {}) ⇒ Object
Deletes scheduled events from a calendar.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/delete_calendar_event.rb', line 33 def delete_calendar_event(arguments = {}) raise ArgumentError, "Required argument 'calendar_id' missing" unless arguments[:calendar_id] raise ArgumentError, "Required argument 'event_id' missing" unless arguments[:event_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _calendar_id = arguments.delete(:calendar_id) _event_id = arguments.delete(:event_id) method = ElasticsearchServerless::API::HTTP_DELETE path = "_ml/calendars/#{Utils.listify(_calendar_id)}/events/#{Utils.listify(_event_id)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#delete_calendar_job(arguments = {}) ⇒ Object
Deletes anomaly detection jobs from a calendar.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/delete_calendar_job.rb', line 33 def delete_calendar_job(arguments = {}) raise ArgumentError, "Required argument 'calendar_id' missing" unless arguments[:calendar_id] raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _calendar_id = arguments.delete(:calendar_id) _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_DELETE path = "_ml/calendars/#{Utils.listify(_calendar_id)}/jobs/#{Utils.listify(_job_id)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#delete_data_frame_analytics(arguments = {}) ⇒ Object
Deletes an existing data frame analytics job.
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/delete_data_frame_analytics.rb', line 34 def delete_data_frame_analytics(arguments = {}) raise ArgumentError, "Required argument 'id' missing" unless arguments[:id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _id = arguments.delete(:id) method = ElasticsearchServerless::API::HTTP_DELETE path = "_ml/data_frame/analytics/#{Utils.listify(_id)}" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#delete_datafeed(arguments = {}) ⇒ Object
Deletes an existing datafeed.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/elasticsearch-serverless/api/machine_learning/delete_datafeed.rb', line 33 def delete_datafeed(arguments = {}) raise ArgumentError, "Required argument 'datafeed_id' missing" unless arguments[:datafeed_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _datafeed_id = arguments.delete(:datafeed_id) method = ElasticsearchServerless::API::HTTP_DELETE path = "_ml/datafeeds/#{Utils.listify(_datafeed_id)}" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#delete_filter(arguments = {}) ⇒ Object
Deletes a filter.
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
# File 'lib/elasticsearch-serverless/api/machine_learning/delete_filter.rb', line 32 def delete_filter(arguments = {}) raise ArgumentError, "Required argument 'filter_id' missing" unless arguments[:filter_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _filter_id = arguments.delete(:filter_id) method = ElasticsearchServerless::API::HTTP_DELETE path = "_ml/filters/#{Utils.listify(_filter_id)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#delete_job(arguments = {}) ⇒ Object
Deletes an existing anomaly detection job.
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/elasticsearch-serverless/api/machine_learning/delete_job.rb', line 35 def delete_job(arguments = {}) raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_DELETE path = "_ml/anomaly_detectors/#{Utils.listify(_job_id)}" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#delete_trained_model(arguments = {}) ⇒ Object
Deletes an existing trained inference model that is currently not referenced by an ingest pipeline.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/elasticsearch-serverless/api/machine_learning/delete_trained_model.rb', line 33 def delete_trained_model(arguments = {}) raise ArgumentError, "Required argument 'model_id' missing" unless arguments[:model_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _model_id = arguments.delete(:model_id) method = ElasticsearchServerless::API::HTTP_DELETE path = "_ml/trained_models/#{Utils.listify(_model_id)}" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#delete_trained_model_alias(arguments = {}) ⇒ Object
Deletes a model alias that refers to the trained model
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/delete_trained_model_alias.rb', line 33 def delete_trained_model_alias(arguments = {}) raise ArgumentError, "Required argument 'model_id' missing" unless arguments[:model_id] raise ArgumentError, "Required argument 'model_alias' missing" unless arguments[:model_alias] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _model_alias = arguments.delete(:model_alias) _model_id = arguments.delete(:model_id) method = ElasticsearchServerless::API::HTTP_DELETE path = "_ml/trained_models/#{Utils.listify(_model_id)}/model_aliases/#{Utils.listify(_model_alias)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#estimate_model_memory(arguments = {}) ⇒ Object
Estimates the model memory
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 |
# File 'lib/elasticsearch-serverless/api/machine_learning/estimate_model_memory.rb', line 32 def estimate_model_memory(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/anomaly_detectors/_estimate_model_memory" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#evaluate_data_frame(arguments = {}) ⇒ Object
Evaluates the data frame analytics for an annotated index.
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 |
# File 'lib/elasticsearch-serverless/api/machine_learning/evaluate_data_frame.rb', line 32 def evaluate_data_frame(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/data_frame/_evaluate" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#flush_job(arguments = {}) ⇒ Object
Forces any buffered data to be processed by the job.
38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/elasticsearch-serverless/api/machine_learning/flush_job.rb', line 38 def flush_job(arguments = {}) raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/anomaly_detectors/#{Utils.listify(_job_id)}/_flush" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_calendar_events(arguments = {}) ⇒ Object
Retrieves information about the scheduled events in calendars.
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_calendar_events.rb', line 37 def get_calendar_events(arguments = {}) raise ArgumentError, "Required argument 'calendar_id' missing" unless arguments[:calendar_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _calendar_id = arguments.delete(:calendar_id) method = ElasticsearchServerless::API::HTTP_GET path = "_ml/calendars/#{Utils.listify(_calendar_id)}/events" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_calendars(arguments = {}) ⇒ Object
Retrieves configuration information for calendars.
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_calendars.rb', line 35 def get_calendars(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _calendar_id = arguments.delete(:calendar_id) method = if body ElasticsearchServerless::API::HTTP_POST else ElasticsearchServerless::API::HTTP_GET end path = if _calendar_id "_ml/calendars/#{Utils.listify(_calendar_id)}" else "_ml/calendars" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_data_frame_analytics(arguments = {}) ⇒ Object
Retrieves configuration information for data frame analytics jobs.
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_data_frame_analytics.rb', line 36 def get_data_frame_analytics(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _id = arguments.delete(:id) method = ElasticsearchServerless::API::HTTP_GET path = if _id "_ml/data_frame/analytics/#{Utils.listify(_id)}" else "_ml/data_frame/analytics" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_data_frame_analytics_stats(arguments = {}) ⇒ Object
Retrieves usage information for data frame analytics jobs.
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_data_frame_analytics_stats.rb', line 36 def get_data_frame_analytics_stats(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _id = arguments.delete(:id) method = ElasticsearchServerless::API::HTTP_GET path = if _id "_ml/data_frame/analytics/#{Utils.listify(_id)}/_stats" else "_ml/data_frame/analytics/_stats" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_datafeed_stats(arguments = {}) ⇒ Object
Retrieves usage information for datafeeds.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_datafeed_stats.rb', line 33 def get_datafeed_stats(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _datafeed_id = arguments.delete(:datafeed_id) method = ElasticsearchServerless::API::HTTP_GET path = if _datafeed_id "_ml/datafeeds/#{Utils.listify(_datafeed_id)}/_stats" else "_ml/datafeeds/_stats" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_datafeeds(arguments = {}) ⇒ Object
Retrieves configuration information for datafeeds.
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_datafeeds.rb', line 34 def get_datafeeds(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _datafeed_id = arguments.delete(:datafeed_id) method = ElasticsearchServerless::API::HTTP_GET path = if _datafeed_id "_ml/datafeeds/#{Utils.listify(_datafeed_id)}" else "_ml/datafeeds" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_filters(arguments = {}) ⇒ Object
Retrieves filters.
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_filters.rb', line 34 def get_filters(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _filter_id = arguments.delete(:filter_id) method = ElasticsearchServerless::API::HTTP_GET path = if _filter_id "_ml/filters/#{Utils.listify(_filter_id)}" else "_ml/filters" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_job_stats(arguments = {}) ⇒ Object
Retrieves usage information for anomaly detection jobs.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_job_stats.rb', line 33 def get_job_stats(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_GET path = if _job_id "_ml/anomaly_detectors/#{Utils.listify(_job_id)}/_stats" else "_ml/anomaly_detectors/_stats" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_jobs(arguments = {}) ⇒ Object
Retrieves configuration information for anomaly detection jobs.
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_jobs.rb', line 34 def get_jobs(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_GET path = if _job_id "_ml/anomaly_detectors/#{Utils.listify(_job_id)}" else "_ml/anomaly_detectors" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_overall_buckets(arguments = {}) ⇒ Object
Retrieves overall bucket results that summarize the bucket results of multiple anomaly detection jobs.
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_overall_buckets.rb', line 40 def get_overall_buckets(arguments = {}) raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _job_id = arguments.delete(:job_id) method = if body ElasticsearchServerless::API::HTTP_POST else ElasticsearchServerless::API::HTTP_GET end path = "_ml/anomaly_detectors/#{Utils.listify(_job_id)}/results/overall_buckets" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_trained_models(arguments = {}) ⇒ Object
Retrieves configuration information for a trained inference model.
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_trained_models.rb', line 39 def get_trained_models(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _model_id = arguments.delete(:model_id) method = ElasticsearchServerless::API::HTTP_GET path = if _model_id "_ml/trained_models/#{Utils.listify(_model_id)}" else "_ml/trained_models" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#get_trained_models_stats(arguments = {}) ⇒ Object
Retrieves usage information for trained inference models.
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/elasticsearch-serverless/api/machine_learning/get_trained_models_stats.rb', line 35 def get_trained_models_stats(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _model_id = arguments.delete(:model_id) method = ElasticsearchServerless::API::HTTP_GET path = if _model_id "_ml/trained_models/#{Utils.listify(_model_id)}/_stats" else "_ml/trained_models/_stats" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#open_job(arguments = {}) ⇒ Object
Opens one or more anomaly detection jobs.
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/open_job.rb', line 34 def open_job(arguments = {}) raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/anomaly_detectors/#{Utils.listify(_job_id)}/_open" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#post_calendar_events(arguments = {}) ⇒ Object
Posts scheduled events in a calendar.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/post_calendar_events.rb', line 33 def post_calendar_events(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'calendar_id' missing" unless arguments[:calendar_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _calendar_id = arguments.delete(:calendar_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/calendars/#{Utils.listify(_calendar_id)}/events" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#preview_data_frame_analytics(arguments = {}) ⇒ Object
Previews that will be analyzed given a data frame analytics config.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 |
# File 'lib/elasticsearch-serverless/api/machine_learning/preview_data_frame_analytics.rb', line 33 def preview_data_frame_analytics(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _id = arguments.delete(:id) method = if body ElasticsearchServerless::API::HTTP_POST else ElasticsearchServerless::API::HTTP_GET end path = if _id "_ml/data_frame/analytics/#{Utils.listify(_id)}/_preview" else "_ml/data_frame/analytics/_preview" end params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#preview_datafeed(arguments = {}) ⇒ Object
Previews a datafeed.
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 |
# File 'lib/elasticsearch-serverless/api/machine_learning/preview_datafeed.rb', line 35 def preview_datafeed(arguments = {}) arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _datafeed_id = arguments.delete(:datafeed_id) method = if body ElasticsearchServerless::API::HTTP_POST else ElasticsearchServerless::API::HTTP_GET end path = if _datafeed_id "_ml/datafeeds/#{Utils.listify(_datafeed_id)}/_preview" else "_ml/datafeeds/_preview" end params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_calendar(arguments = {}) ⇒ Object
Instantiates a calendar.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_calendar.rb', line 33 def put_calendar(arguments = {}) raise ArgumentError, "Required argument 'calendar_id' missing" unless arguments[:calendar_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _calendar_id = arguments.delete(:calendar_id) method = ElasticsearchServerless::API::HTTP_PUT path = "_ml/calendars/#{Utils.listify(_calendar_id)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_calendar_job(arguments = {}) ⇒ Object
Adds an anomaly detection job to a calendar.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_calendar_job.rb', line 33 def put_calendar_job(arguments = {}) raise ArgumentError, "Required argument 'calendar_id' missing" unless arguments[:calendar_id] raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _calendar_id = arguments.delete(:calendar_id) _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_PUT path = "_ml/calendars/#{Utils.listify(_calendar_id)}/jobs/#{Utils.listify(_job_id)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_data_frame_analytics(arguments = {}) ⇒ Object
Instantiates a data frame analytics job.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_data_frame_analytics.rb', line 33 def put_data_frame_analytics(arguments = {}) 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 = ElasticsearchServerless::API::HTTP_PUT path = "_ml/data_frame/analytics/#{Utils.listify(_id)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_datafeed(arguments = {}) ⇒ Object
Instantiates a datafeed.
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_datafeed.rb', line 37 def put_datafeed(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'datafeed_id' missing" unless arguments[:datafeed_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _datafeed_id = arguments.delete(:datafeed_id) method = ElasticsearchServerless::API::HTTP_PUT path = "_ml/datafeeds/#{Utils.listify(_datafeed_id)}" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_filter(arguments = {}) ⇒ Object
Instantiates a filter.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_filter.rb', line 33 def put_filter(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'filter_id' missing" unless arguments[:filter_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _filter_id = arguments.delete(:filter_id) method = ElasticsearchServerless::API::HTTP_PUT path = "_ml/filters/#{Utils.listify(_filter_id)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_job(arguments = {}) ⇒ Object
Instantiates an anomaly detection job.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_job.rb', line 33 def put_job(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_PUT path = "_ml/anomaly_detectors/#{Utils.listify(_job_id)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_trained_model(arguments = {}) ⇒ Object
Creates an inference trained model.
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_trained_model.rb', line 34 def put_trained_model(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'model_id' missing" unless arguments[:model_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _model_id = arguments.delete(:model_id) method = ElasticsearchServerless::API::HTTP_PUT path = "_ml/trained_models/#{Utils.listify(_model_id)}" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_trained_model_alias(arguments = {}) ⇒ Object
Creates a new model alias (or reassigns an existing one) to refer to the trained model
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_trained_model_alias.rb', line 34 def put_trained_model_alias(arguments = {}) raise ArgumentError, "Required argument 'model_id' missing" unless arguments[:model_id] raise ArgumentError, "Required argument 'model_alias' missing" unless arguments[:model_alias] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _model_alias = arguments.delete(:model_alias) _model_id = arguments.delete(:model_id) method = ElasticsearchServerless::API::HTTP_PUT path = "_ml/trained_models/#{Utils.listify(_model_id)}/model_aliases/#{Utils.listify(_model_alias)}" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_trained_model_definition_part(arguments = {}) ⇒ Object
Creates part of a trained model definition
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_trained_model_definition_part.rb', line 34 def put_trained_model_definition_part(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'model_id' missing" unless arguments[:model_id] raise ArgumentError, "Required argument 'part' missing" unless arguments[:part] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _model_id = arguments.delete(:model_id) _part = arguments.delete(:part) method = ElasticsearchServerless::API::HTTP_PUT path = "_ml/trained_models/#{Utils.listify(_model_id)}/definition/#{Utils.listify(_part)}" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#put_trained_model_vocabulary(arguments = {}) ⇒ Object
Creates a trained model vocabulary
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/put_trained_model_vocabulary.rb', line 33 def put_trained_model_vocabulary(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'model_id' missing" unless arguments[:model_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _model_id = arguments.delete(:model_id) method = ElasticsearchServerless::API::HTTP_PUT path = "_ml/trained_models/#{Utils.listify(_model_id)}/vocabulary" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#reset_job(arguments = {}) ⇒ Object
Resets an existing anomaly detection job.
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/reset_job.rb', line 34 def reset_job(arguments = {}) raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/anomaly_detectors/#{Utils.listify(_job_id)}/_reset" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#start_data_frame_analytics(arguments = {}) ⇒ Object
Starts a data frame analytics job.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/elasticsearch-serverless/api/machine_learning/start_data_frame_analytics.rb', line 33 def start_data_frame_analytics(arguments = {}) raise ArgumentError, "Required argument 'id' missing" unless arguments[:id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _id = arguments.delete(:id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/data_frame/analytics/#{Utils.listify(_id)}/_start" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#start_datafeed(arguments = {}) ⇒ Object
Starts one or more datafeeds.
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/start_datafeed.rb', line 36 def start_datafeed(arguments = {}) raise ArgumentError, "Required argument 'datafeed_id' missing" unless arguments[:datafeed_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _datafeed_id = arguments.delete(:datafeed_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/datafeeds/#{Utils.listify(_datafeed_id)}/_start" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#start_trained_model_deployment(arguments = {}) ⇒ Object
Start a trained model deployment.
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 |
# File 'lib/elasticsearch-serverless/api/machine_learning/start_trained_model_deployment.rb', line 40 def start_trained_model_deployment(arguments = {}) raise ArgumentError, "Required argument 'model_id' missing" unless arguments[:model_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _model_id = arguments.delete(:model_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/trained_models/#{Utils.listify(_model_id)}/deployment/_start" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#stop_data_frame_analytics(arguments = {}) ⇒ Object
Stops one or more data frame analytics jobs.
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/elasticsearch-serverless/api/machine_learning/stop_data_frame_analytics.rb', line 35 def stop_data_frame_analytics(arguments = {}) raise ArgumentError, "Required argument 'id' missing" unless arguments[:id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _id = arguments.delete(:id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/data_frame/analytics/#{Utils.listify(_id)}/_stop" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#stop_datafeed(arguments = {}) ⇒ Object
Stops one or more datafeeds.
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/elasticsearch-serverless/api/machine_learning/stop_datafeed.rb', line 36 def stop_datafeed(arguments = {}) raise ArgumentError, "Required argument 'datafeed_id' missing" unless arguments[:datafeed_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _datafeed_id = arguments.delete(:datafeed_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/datafeeds/#{Utils.listify(_datafeed_id)}/_stop" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#stop_trained_model_deployment(arguments = {}) ⇒ Object
Stop a trained model deployment.
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/stop_trained_model_deployment.rb', line 34 def stop_trained_model_deployment(arguments = {}) raise ArgumentError, "Required argument 'model_id' missing" unless arguments[:model_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = nil _model_id = arguments.delete(:model_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/trained_models/#{Utils.listify(_model_id)}/deployment/_stop" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#update_data_frame_analytics(arguments = {}) ⇒ Object
Updates certain properties of a data frame analytics job.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/update_data_frame_analytics.rb', line 33 def update_data_frame_analytics(arguments = {}) 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 = ElasticsearchServerless::API::HTTP_POST path = "_ml/data_frame/analytics/#{Utils.listify(_id)}/_update" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#update_datafeed(arguments = {}) ⇒ Object
Updates certain properties of a datafeed.
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/elasticsearch-serverless/api/machine_learning/update_datafeed.rb', line 37 def update_datafeed(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'datafeed_id' missing" unless arguments[:datafeed_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _datafeed_id = arguments.delete(:datafeed_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/datafeeds/#{Utils.listify(_datafeed_id)}/_update" params = Utils.process_params(arguments) ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#update_filter(arguments = {}) ⇒ Object
Updates the description of a filter, adds items, or removes items.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/update_filter.rb', line 33 def update_filter(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'filter_id' missing" unless arguments[:filter_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _filter_id = arguments.delete(:filter_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/filters/#{Utils.listify(_filter_id)}/_update" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |
#update_job(arguments = {}) ⇒ Object
Updates certain properties of an anomaly detection job.
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/elasticsearch-serverless/api/machine_learning/update_job.rb', line 33 def update_job(arguments = {}) raise ArgumentError, "Required argument 'body' missing" unless arguments[:body] raise ArgumentError, "Required argument 'job_id' missing" unless arguments[:job_id] arguments = arguments.clone headers = arguments.delete(:headers) || {} body = arguments.delete(:body) _job_id = arguments.delete(:job_id) method = ElasticsearchServerless::API::HTTP_POST path = "_ml/anomaly_detectors/#{Utils.listify(_job_id)}/_update" params = {} ElasticsearchServerless::API::Response.new( perform_request(method, path, params, body, headers) ) end |