forked from opensearch-project/OpenSearch-Dashboards
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Discover] Data selector enhancement (opensearch-project#6571) (opens…
…earch-project#6691) * datasource and service refactoring * datasource enhancement and refactoring * datasource selectable consolidation and refactoring * add in memory cache with refresh * move refresh to right side * renaming * update default datasource tests * added more tests for default datasource * update selector tests * update changelog * fix data source service tests * add and update tests for datasource service * add more data source service tests * fix sidebar tests * add to change log yml * address comments along with more tests * add test subject * reference from correct type path * correct text * minor change - remove yet used displayOrder * remove from changelog as having fragments already * use expanded name * fix one test --------- (cherry picked from commit 42166d0) Signed-off-by: Eric <[email protected]> Signed-off-by: Eric Wei <[email protected]> Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
- Loading branch information
1 parent
950f9d8
commit 4d14b60
Showing
24 changed files
with
891 additions
and
282 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
refactor: | ||
- discover data selector enhancement and refactoring ([#6571](https://github.com/opensearch-project/OpenSearch-Dashboards/pull/6571)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
/* | ||
* Copyright OpenSearch Contributors | ||
* SPDX-License-Identifier: Apache-2.0 | ||
*/ | ||
|
||
import { i18n } from '@osd/i18n'; | ||
import { DataSourceUIGroupType } from './datasource/types'; | ||
|
||
export const S3_GLUE_DATA_SOURCE_DISPLAY_NAME = 'Amazon S3'; | ||
export const S3_GLUE_DATA_SOURCE_TYPE = 's3glue'; | ||
export const DEFAULT_DATA_SOURCE_TYPE = 'DEFAULT_INDEX_PATTERNS'; | ||
export const DEFAULT_DATA_SOURCE_NAME = i18n.translate('data.datasource.type.openSearchDefault', { | ||
defaultMessage: 'OpenSearch Default', | ||
}); | ||
export const DEFAULT_DATA_SOURCE_DISPLAY_NAME = i18n.translate( | ||
'data.datasource.type.openSearchDefaultDisplayName', | ||
{ | ||
defaultMessage: 'Index patterns', | ||
} | ||
); | ||
|
||
export const defaultDataSourceMetadata = { | ||
ui: { | ||
label: DEFAULT_DATA_SOURCE_DISPLAY_NAME, | ||
typeLabel: DEFAULT_DATA_SOURCE_DISPLAY_NAME, | ||
groupType: DataSourceUIGroupType.defaultOpenSearchDataSource, | ||
selector: { | ||
displayDatasetsAsSource: true, | ||
}, | ||
}, | ||
}; | ||
|
||
export const s3DataSourceMetadata = { | ||
ui: { | ||
label: S3_GLUE_DATA_SOURCE_DISPLAY_NAME, | ||
typeLabel: S3_GLUE_DATA_SOURCE_TYPE, | ||
groupType: DataSourceUIGroupType.s3glue, | ||
selector: { | ||
displayDatasetsAsSource: false, | ||
}, | ||
}, | ||
}; | ||
|
||
export const DATA_SELECTOR_REFRESHER_POPOVER_TEXT = 'Refresh data selector'; | ||
export const DATA_SELECTOR_DEFAULT_PLACEHOLDER = 'Select a data source'; | ||
export const DATA_SELECTOR_S3_DATA_SOURCE_GROUP_HINT_LABEL = ' - Opens in Log Explorer'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.