From 0de836fb12dbd8fe35cb535f904b73d77fa0aa0c Mon Sep 17 00:00:00 2001 From: Kevin Delemme Date: Mon, 23 Sep 2024 12:02:44 -0400 Subject: [PATCH] feat(slo): Add optional pipeline processor in the SLI ingest pipeline for advanced customer (#193628) (cherry picked from commit cd32affc9265a8ed4d135d19f046c343c6317502) --- .../assets/ingest_templates/slo_pipeline_template.ts | 7 +++++++ .../server/services/__snapshots__/create_slo.test.ts.snap | 7 +++++++ .../server/services/__snapshots__/reset_slo.test.ts.snap | 7 +++++++ 3 files changed, 21 insertions(+) diff --git a/x-pack/plugins/observability_solution/slo/server/assets/ingest_templates/slo_pipeline_template.ts b/x-pack/plugins/observability_solution/slo/server/assets/ingest_templates/slo_pipeline_template.ts index e5aaa260e2f1d..c378cd745397c 100644 --- a/x-pack/plugins/observability_solution/slo/server/assets/ingest_templates/slo_pipeline_template.ts +++ b/x-pack/plugins/observability_solution/slo/server/assets/ingest_templates/slo_pipeline_template.ts @@ -64,6 +64,13 @@ export const getSLOPipelineTemplate = (slo: SLODefinition) => ({ .join(','), }, }, + { + pipeline: { + ignore_missing_pipeline: true, + ignore_failure: true, + name: `slo-${slo.id}@custom`, + }, + }, ], _meta: { description: 'Ingest pipeline for SLO rollup data', diff --git a/x-pack/plugins/observability_solution/slo/server/services/__snapshots__/create_slo.test.ts.snap b/x-pack/plugins/observability_solution/slo/server/services/__snapshots__/create_slo.test.ts.snap index ef8c79410fb39..d747d5083cd28 100644 --- a/x-pack/plugins/observability_solution/slo/server/services/__snapshots__/create_slo.test.ts.snap +++ b/x-pack/plugins/observability_solution/slo/server/services/__snapshots__/create_slo.test.ts.snap @@ -57,6 +57,13 @@ Array [ "value": "*", }, }, + Object { + "pipeline": Object { + "ignore_failure": true, + "ignore_missing_pipeline": true, + "name": "slo-unique-id@custom", + }, + }, ], }, ] diff --git a/x-pack/plugins/observability_solution/slo/server/services/__snapshots__/reset_slo.test.ts.snap b/x-pack/plugins/observability_solution/slo/server/services/__snapshots__/reset_slo.test.ts.snap index 95f767988708c..00dc9bb4654ae 100644 --- a/x-pack/plugins/observability_solution/slo/server/services/__snapshots__/reset_slo.test.ts.snap +++ b/x-pack/plugins/observability_solution/slo/server/services/__snapshots__/reset_slo.test.ts.snap @@ -253,6 +253,13 @@ exports[`ResetSLO resets all associated resources 8`] = ` "value": "*", }, }, + Object { + "pipeline": Object { + "ignore_failure": true, + "ignore_missing_pipeline": true, + "name": "slo-irrelevant@custom", + }, + }, ], }, ],