-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[APM] Shorten ML Job IDs #111037
Comments
Pinging @elastic/apm-ui (Team:apm) |
Currently a subset of the id is hardcoded on the ml side. The id prefix is specified on the apm side here: kibana/x-pack/plugins/apm/server/lib/anomaly_detection/create_anomaly_detection_jobs.ts Lines 84 to 86 in 1466099
The suffix is specified by ml here: kibana/x-pack/plugins/ml/server/models/data_recognizer/modules/apm_transaction/manifest.json Line 18 in 1466099
@walterra @peteharverson It would be great if we could simply specify the full id when creating a job, instead of the id being a concatenation of different properties specified by apm and ml. |
I am currently working on changes to the You then need to ensure that whatever prefix you supply to the module setup endpoint is no more than |
What about simply allowing the consumer to specify an id that must be less than 64 characters? As I've mentioned before, the way ml modules work makes it quite hard for consumers to understand how the resulting ML job will look. Concatenating fields like in this case is a prime example of this. |
Out of the box, the modules allow the user to specify a prefix and the job suffix is hardcoded, defined in the module - this helps users who create modules in the ML UI to have jobs with a meaningful name. Remember that most modules contain multiple jobs so its simpler to setup groups of jobs that all share the same prefix. This applies to all ML modules, not just APM. At this stage, I propose we keep current module prefix/suffix behaviour. We could allow users to have a configurable APM job_id. The user could then create a job in the ML UI, using any name they wish, and then update the APM settings to use this per environment. We would then need to validate that the fields used in the job were valid (latency, throughput and error rate). This validation would be somewhat tricky as not everything can be perfectly validated. e.g Index patterns In summary:
|
Fine to keep things as is for now. Just a bit of feedback for future api improvements:
It sounds like the id is both a human readable label and a unique identifier. Separating these two would make it easy to both add a good label, and have a unique identifier within the 64 byte limit.
If we had a human readable label I agree that should be configurable. In that case the id doesn't need to be configurable. |
Agree, going forward I think we should move away from the modules. |
Job IDs have a 64 character limit. APM current generates very long job ids by default, like the 44-char
apm-prod-6ed0-high_mean_transaction_duration
. The ML team recommends we shorten them where possible.The text was updated successfully, but these errors were encountered: