[ML] Allow for injection of job parameters upon module setup #42409
Labels
enhancement
New value added to drive a business result
Feature:Anomaly Detection
ML anomaly detection
:ml
v7.4.0
Summary
This proposes to enhance the module setup route at
/api/ml/modules/setup/:moduleId
such that it is possible to directly specify parameters such as the indices (in the usual Elasticsearch syntax including wildcards) and field names (e.g. the timestamp and other fields used in detectors).Rationale
Two limitations currently make it hard or impossible for solutions to integrate with Machine Learning via this API:
The Elasticsearch indices are either specified via hard-coded index names or via Kibana index patterns which are then resolved to index names. (Side-note: The resolution currently seems to use the Kibana index pattern id as the index name, which doesn't match Kibana's index pattern semantics: the id is an opaque uuid while the
title
attribute holds the index name(s).)Other job parameters such as the timestamp field and detector fields can only be hard-coded in the module specification.
Solutions such as the Infra and Logs UIs neither use Kibana index patterns nor are they limited to static field semantics. As a consequence, jobs created by such solutions as part of an integration with Machine Learning would have to be dynamically parameterized at setup time.
Acceptance criteria
The text was updated successfully, but these errors were encountered: