From 626c3349affc5c02e85a905fd7dc03aec3135cc7 Mon Sep 17 00:00:00 2001 From: Yizhe Liu Date: Mon, 24 Aug 2020 20:57:15 -0700 Subject: [PATCH] Add action item and message for init failue case due to invalid search query. Issue:#218 --- public/pages/DetectorDetail/utils/constants.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/public/pages/DetectorDetail/utils/constants.ts b/public/pages/DetectorDetail/utils/constants.ts index 890855fd..58d8af05 100644 --- a/public/pages/DetectorDetail/utils/constants.ts +++ b/public/pages/DetectorDetail/utils/constants.ts @@ -67,6 +67,13 @@ export const DETECTOR_INIT_FAILURES = Object.freeze({ cause: 'the detector is not defined', actionItem: 'Define your detector and try again.', }, + INVALID_FEATURE_QUERY: { + // TODO: https://github.com/opendistro-for-elasticsearch/anomaly-detection/issues/218 + //https://github.com/opendistro-for-elasticsearch/anomaly-detection/blob/master/src/main/java/com/amazon/opendistroforelasticsearch/ad/constant/CommonErrorMessages.java#L28 + keyword: 'Invalid search query', + cause: 'there exists invalid custom feature aggregation query', + actionItem: 'Revise your custom feature aggregation query and try again.', + }, UNKNOWN_EXCEPTION: { //https://github.com/opendistro-for-elasticsearch/anomaly-detection/blob/development/src/main/java/com/amazon/opendistroforelasticsearch/ad/transport/AnomalyResultTransportAction.java#L438 keyword: 'We might have bugs',