From 85db88236f95be7b71dfc54eb266e85018a5ed3f Mon Sep 17 00:00:00 2001 From: Wonyeong Choi Date: Thu, 24 Sep 2020 15:08:37 +0900 Subject: [PATCH] Add dashboard index map copied from amundsendatabuilder Signed-off-by: Wonyeong Choi --- amundsen_common/models/index_map.py | 77 +++++++++++++++++++++++++++++ 1 file changed, 77 insertions(+) diff --git a/amundsen_common/models/index_map.py b/amundsen_common/models/index_map.py index 680d1bd..e2366b6 100644 --- a/amundsen_common/models/index_map.py +++ b/amundsen_common/models/index_map.py @@ -98,6 +98,83 @@ """ ) +DASHBOARD_ELASTICSEARCH_INDEX_MAPPING = textwrap.dedent( + """ + { + "settings": { + "analysis": { + "normalizer": { + "lowercase_normalizer": { + "type": "custom", + "char_filter": [], + "filter": ["lowercase", "asciifolding"] + } + } + } + }, + "mappings":{ + "dashboard":{ + "properties": { + "group_name": { + "type":"text", + "analyzer": "simple", + "fields": { + "raw": { + "type": "keyword", + "normalizer": "lowercase_normalizer" + } + } + }, + "name": { + "type":"text", + "analyzer": "simple", + "fields": { + "raw": { + "type": "keyword", + "normalizer": "lowercase_normalizer" + } + } + }, + "description": { + "type":"text", + "analyzer": "simple", + "fields": { + "raw": { + "type": "keyword" + } + } + }, + "group_description": { + "type":"text", + "analyzer": "simple", + "fields": { + "raw": { + "type": "keyword" + } + } + }, + "query_names": { + "type":"text", + "analyzer": "simple", + "fields": { + "raw": { + "type": "keyword" + } + } + }, + "tags": { + "type": "keyword" + }, + "badges": { + "type": "keyword" + } + } + } + } + } + """ +) + USER_INDEX_MAP = textwrap.dedent(""" { "mappings":{