From 759737a3c665725f792cede05285230f4429dce2 Mon Sep 17 00:00:00 2001 From: Pierre Gayvallet Date: Fri, 29 Nov 2024 14:33:17 +0100 Subject: [PATCH] [product documentation] Fix index names (#202265) ## Summary Follow-up of https://github.com/elastic/kibana/pull/194379. Turns out, the prefix for kibana system indices is `.kibana_*`, so our indices were not considered as kibana system indices and causing warnings when created, such as ``` Elasticsearch deprecation: 299 Elasticsearch-6db572c986d7e114b8b46f1d6f4169bed06717c5 "index name [.kibana-ai-product-doc-kibana] starts with a dot '.', in the next major version, index names starting with a dot are reserved for hidden indices and system indices" Origin:kibana ``` This PR addresses it, by changing the product doc index names to follow our system index pattern. (cherry picked from commit d5cf0a6be4a4f4436a2aff7636d84558260541b0) --- x-pack/packages/ai-infra/product-doc-common/src/indices.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/x-pack/packages/ai-infra/product-doc-common/src/indices.ts b/x-pack/packages/ai-infra/product-doc-common/src/indices.ts index b48cacf79fd23..90e416ff48c46 100644 --- a/x-pack/packages/ai-infra/product-doc-common/src/indices.ts +++ b/x-pack/packages/ai-infra/product-doc-common/src/indices.ts @@ -7,9 +7,9 @@ import type { ProductName } from './product'; -export const productDocIndexPrefix = '.kibana-ai-product-doc'; -export const productDocIndexPattern = `${productDocIndexPrefix}-*`; +export const productDocIndexPrefix = '.kibana_ai_product_doc'; +export const productDocIndexPattern = `${productDocIndexPrefix}_*`; export const getProductDocIndexName = (productName: ProductName): string => { - return `${productDocIndexPrefix}-${productName.toLowerCase()}`; + return `${productDocIndexPrefix}_${productName.toLowerCase()}`; };