Skip to content

Commit

Permalink
Merge branch 'main' into friendlier-publicBaseUrl-warning
Browse files Browse the repository at this point in the history
  • Loading branch information
TinaHeiligers authored Feb 23, 2022
2 parents 5b89676 + bc35610 commit 1404742
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 12 deletions.
7 changes: 7 additions & 0 deletions .buildkite/scripts/steps/cloud/build_and_deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,13 @@ if [ -z "${CLOUD_DEPLOYMENT_ID}" ]; then
CLOUD_DEPLOYMENT_ID=$(jq -r --slurp '.[0].id' "$JSON_FILE")
CLOUD_DEPLOYMENT_STATUS_MESSAGES=$(jq --slurp '[.[]|select(.resources == null)]' "$JSON_FILE")

# Enable stack monitoring
jq '
.settings.observability.metrics.destination.deployment_id = "'$CLOUD_DEPLOYMENT_ID'" |
.settings.observability.logging.destination.deployment_id = "'$CLOUD_DEPLOYMENT_ID'"
' .buildkite/scripts/steps/cloud/stack_monitoring.json > /tmp/stack_monitoring.json
ecctl deployment update "$CLOUD_DEPLOYMENT_ID" --track --output json --file /tmp/stack_monitoring.json &> "$JSON_FILE"

# Refresh vault token
VAULT_ROLE_ID="$(retry 5 15 gcloud secrets versions access latest --secret=kibana-buildkite-vault-role-id)"
VAULT_SECRET_ID="$(retry 5 15 gcloud secrets versions access latest --secret=kibana-buildkite-vault-secret-id)"
Expand Down
19 changes: 19 additions & 0 deletions .buildkite/scripts/steps/cloud/stack_monitoring.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"prune_orphans": false,
"settings": {
"observability": {
"metrics": {
"destination": {
"deployment_id": null,
"ref_id": "main-elasticsearch"
}
},
"logging": {
"destination": {
"deployment_id": null,
"ref_id": "main-elasticsearch"
}
}
}
}
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -106,18 +106,18 @@ export class UpdateSourceEditor extends Component<Props, State> {
};

_getMetricsFilter() {
if (this.props.currentLayerType === LAYER_TYPE.HEATMAP) {
return (metric: EuiComboBoxOptionOption<AGG_TYPE>) => {
// these are countable metrics, where blending heatmap color blobs make sense
return metric.value ? isMetricCountable(metric.value) : false;
};
}

if (this.props.resolution === GRID_RESOLUTION.SUPER_FINE) {
return (metric: EuiComboBoxOptionOption<AGG_TYPE>) => {
return metric.value !== AGG_TYPE.TERMS;
};
}
return this.props.currentLayerType === LAYER_TYPE.HEATMAP
? (metric: EuiComboBoxOptionOption<AGG_TYPE>) => {
// these are countable metrics, where blending heatmap color blobs make sense
return metric.value ? isMetricCountable(metric.value) : false;
}
: (metric: EuiComboBoxOptionOption<AGG_TYPE>) => {
// terms aggregation is not supported with Elasticsearch _mvt endpoint
// The goal is to remove GeoJSON ESGeoGridSource implemenation and only have MVT ESGeoGridSource implemenation
// First step is to deprecate terms aggregation for ESGeoGridSource
// and prevent new uses of terms aggregation for ESGeoGridSource
return metric.value !== AGG_TYPE.TERMS;
};
}

_renderMetricsPanel() {
Expand Down

0 comments on commit 1404742

Please sign in to comment.