Skip to content

Commit

Permalink
fix(es-setup): create data stream on non-aws (#6926)
Browse files Browse the repository at this point in the history
  • Loading branch information
szalai1 authored Jan 3, 2023
1 parent 4209d6f commit a164bda
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion docker/elasticsearch-setup/create-indices.sh
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,13 @@ function create_if_not_exists {

# create indices for ES (non-AWS)
function create_datahub_usage_event_datastream() {
# non-AWS env requires creation of two resources for Datahub usage events:
# non-AWS env requires creation of three resources for Datahub usage events:
# 1. ILM policy
create_if_not_exists "_ilm/policy/${PREFIX}datahub_usage_event_policy" policy.json
# 2. index template
create_if_not_exists "_index_template/${PREFIX}datahub_usage_event_index_template" index_template.json
# 3. although indexing request creates the data stream, it's not queryable before creation, causing GMS to throw exceptions
create_if_not_exists "_data_stream/${PREFIX}datahub_usage_event" "datahub_usage_event"
}

# create indices for ES OSS (AWS)
Expand Down

0 comments on commit a164bda

Please sign in to comment.