Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update actionOption attribution for all data soure components #732

Merged

Conversation

jackiehanyang
Copy link
Collaborator

Description

Previously, we define dataSourceId as empty if it doesn't exist url. However, mds team introduced a change that treats empty dataSourceId as the local cluster scenario, and only undefined actionOption will render the default remote data source. Therefore, we have to adopt this change and assign dataSourceId as undefined when it's not presented in the url.

Issues Resolved

#721

Check List

  • New functionality includes testing.
    • All tests pass
  • New functionality has been documented.
  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Copy link
Member

@owaiskazi19 owaiskazi19 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MDS should handle the type correctly here and we shouldn't make it as undefined.

@jackiehanyang jackiehanyang merged commit 225b386 into opensearch-project:feature/mds Apr 23, 2024
2 checks passed
owaiskazi19 pushed a commit to owaiskazi19/anomaly-detection-dashboards-plugin that referenced this pull request Apr 26, 2024
jackiehanyang added a commit to jackiehanyang/anomaly-detection-dashboards-plugin that referenced this pull request Apr 29, 2024
jackiehanyang added a commit that referenced this pull request Apr 29, 2024
* Support MDS on List, Detail, Dashboard, Overview pages (#722)

* update snapshots

Signed-off-by: Jackie Han <[email protected]>

* add snpshot

Signed-off-by: Jackie Han <[email protected]>

* add data source client

Signed-off-by: Jackie Han <[email protected]>

* test

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* add opensearch_dashboards.json file

Signed-off-by: Jackie Han <[email protected]>

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* test

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on DetectorDetails page

Signed-off-by: Jackie Han <[email protected]>

* change 4/7

Signed-off-by: Jackie Han <[email protected]>

* version change

Signed-off-by: Jackie Han <[email protected]>

* list detector list change

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on List, Detail, Dashboard, Overview pages

Signed-off-by: Jackie Han <[email protected]>

* change version back to 3.0

Signed-off-by: Jackie Han <[email protected]>

* revert version change

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId optional in DetectorListItem type

Signed-off-by: Jackie Han <[email protected]>

* update imports

Signed-off-by: Jackie Han <[email protected]>

* remove used function

Signed-off-by: Jackie Han <[email protected]>

* cleanup

Signed-off-by: Jackie Han <[email protected]>

* add getter and setter for dataSource plugin

Signed-off-by: Jackie Han <[email protected]>

* read dataSourceId from the url instead of passing props

Signed-off-by: Jackie Han <[email protected]>

* addressing comments and run prettier

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* make getDataSourceManagementPlugin() optional

Signed-off-by: Jackie Han <[email protected]>

* add comment

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId type safe

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>

* add MDS support for detector creation&Update flow (#728)

* update snapshots

Signed-off-by: Jackie Han <[email protected]>

* add snpshot

Signed-off-by: Jackie Han <[email protected]>

* add data source client

Signed-off-by: Jackie Han <[email protected]>

* test

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* add opensearch_dashboards.json file

Signed-off-by: Jackie Han <[email protected]>

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* test

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on DetectorDetails page

Signed-off-by: Jackie Han <[email protected]>

* change 4/7

Signed-off-by: Jackie Han <[email protected]>

* version change

Signed-off-by: Jackie Han <[email protected]>

* list detector list change

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on List, Detail, Dashboard, Overview pages

Signed-off-by: Jackie Han <[email protected]>

* change version back to 3.0

Signed-off-by: Jackie Han <[email protected]>

* revert version change

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId optional in DetectorListItem type

Signed-off-by: Jackie Han <[email protected]>

* update imports

Signed-off-by: Jackie Han <[email protected]>

* remove used function

Signed-off-by: Jackie Han <[email protected]>

* cleanup

Signed-off-by: Jackie Han <[email protected]>

* add getter and setter for dataSource plugin

Signed-off-by: Jackie Han <[email protected]>

* read dataSourceId from the url instead of passing props

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* addressing comments and run prettier

Signed-off-by: Jackie Han <[email protected]>

* addressing comments in neo1 branch

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* make getDataSourceManagementPlugin() optional

Signed-off-by: Jackie Han <[email protected]>

* add comment

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId type safe

Signed-off-by: Jackie Han <[email protected]>

* add MDS support on creation page

Signed-off-by: Jackie Han <[email protected]>

* updated methods to get data source query param from url

Signed-off-by: Jackie Han <[email protected]>

* using helper to construct url with dataSourceId

Signed-off-by: Jackie Han <[email protected]>

* add update page, and update urls on detector detail page

Signed-off-by: Jackie Han <[email protected]>

* update update call router

Signed-off-by: Jackie Han <[email protected]>

* update reducer and router

Signed-off-by: Jackie Han <[email protected]>

* clean up

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* update enums

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>

* update actionOption attribution for all data soure components (#732)

Signed-off-by: Jackie Han <[email protected]>

* Add MDS UTs and bug fixes (#734)

* working on ut

Signed-off-by: Jackie Han <[email protected]>

* update ut

Signed-off-by: Jackie Han <[email protected]>

* update UTs and add bug fixes

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>

* bug fixes (#737)

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>
opensearch-trigger-bot bot pushed a commit that referenced this pull request Apr 29, 2024
* Support MDS on List, Detail, Dashboard, Overview pages (#722)

* update snapshots

Signed-off-by: Jackie Han <[email protected]>

* add snpshot

Signed-off-by: Jackie Han <[email protected]>

* add data source client

Signed-off-by: Jackie Han <[email protected]>

* test

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* add opensearch_dashboards.json file

Signed-off-by: Jackie Han <[email protected]>

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* test

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on DetectorDetails page

Signed-off-by: Jackie Han <[email protected]>

* change 4/7

Signed-off-by: Jackie Han <[email protected]>

* version change

Signed-off-by: Jackie Han <[email protected]>

* list detector list change

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on List, Detail, Dashboard, Overview pages

Signed-off-by: Jackie Han <[email protected]>

* change version back to 3.0

Signed-off-by: Jackie Han <[email protected]>

* revert version change

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId optional in DetectorListItem type

Signed-off-by: Jackie Han <[email protected]>

* update imports

Signed-off-by: Jackie Han <[email protected]>

* remove used function

Signed-off-by: Jackie Han <[email protected]>

* cleanup

Signed-off-by: Jackie Han <[email protected]>

* add getter and setter for dataSource plugin

Signed-off-by: Jackie Han <[email protected]>

* read dataSourceId from the url instead of passing props

Signed-off-by: Jackie Han <[email protected]>

* addressing comments and run prettier

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* make getDataSourceManagementPlugin() optional

Signed-off-by: Jackie Han <[email protected]>

* add comment

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId type safe

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>

* add MDS support for detector creation&Update flow (#728)

* update snapshots

Signed-off-by: Jackie Han <[email protected]>

* add snpshot

Signed-off-by: Jackie Han <[email protected]>

* add data source client

Signed-off-by: Jackie Han <[email protected]>

* test

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* add opensearch_dashboards.json file

Signed-off-by: Jackie Han <[email protected]>

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* test

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on DetectorDetails page

Signed-off-by: Jackie Han <[email protected]>

* change 4/7

Signed-off-by: Jackie Han <[email protected]>

* version change

Signed-off-by: Jackie Han <[email protected]>

* list detector list change

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on List, Detail, Dashboard, Overview pages

Signed-off-by: Jackie Han <[email protected]>

* change version back to 3.0

Signed-off-by: Jackie Han <[email protected]>

* revert version change

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId optional in DetectorListItem type

Signed-off-by: Jackie Han <[email protected]>

* update imports

Signed-off-by: Jackie Han <[email protected]>

* remove used function

Signed-off-by: Jackie Han <[email protected]>

* cleanup

Signed-off-by: Jackie Han <[email protected]>

* add getter and setter for dataSource plugin

Signed-off-by: Jackie Han <[email protected]>

* read dataSourceId from the url instead of passing props

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* addressing comments and run prettier

Signed-off-by: Jackie Han <[email protected]>

* addressing comments in neo1 branch

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* make getDataSourceManagementPlugin() optional

Signed-off-by: Jackie Han <[email protected]>

* add comment

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId type safe

Signed-off-by: Jackie Han <[email protected]>

* add MDS support on creation page

Signed-off-by: Jackie Han <[email protected]>

* updated methods to get data source query param from url

Signed-off-by: Jackie Han <[email protected]>

* using helper to construct url with dataSourceId

Signed-off-by: Jackie Han <[email protected]>

* add update page, and update urls on detector detail page

Signed-off-by: Jackie Han <[email protected]>

* update update call router

Signed-off-by: Jackie Han <[email protected]>

* update reducer and router

Signed-off-by: Jackie Han <[email protected]>

* clean up

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* update enums

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>

* update actionOption attribution for all data soure components (#732)

Signed-off-by: Jackie Han <[email protected]>

* Add MDS UTs and bug fixes (#734)

* working on ut

Signed-off-by: Jackie Han <[email protected]>

* update ut

Signed-off-by: Jackie Han <[email protected]>

* update UTs and add bug fixes

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>

* bug fixes (#737)

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>
(cherry picked from commit 48acb93)
jackiehanyang added a commit that referenced this pull request Apr 29, 2024
* Support MDS on List, Detail, Dashboard, Overview pages (#722)

* update snapshots

Signed-off-by: Jackie Han <[email protected]>

* add snpshot

Signed-off-by: Jackie Han <[email protected]>

* add data source client

Signed-off-by: Jackie Han <[email protected]>

* test

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* add opensearch_dashboards.json file

Signed-off-by: Jackie Han <[email protected]>

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* test

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on DetectorDetails page

Signed-off-by: Jackie Han <[email protected]>

* change 4/7

Signed-off-by: Jackie Han <[email protected]>

* version change

Signed-off-by: Jackie Han <[email protected]>

* list detector list change

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on List, Detail, Dashboard, Overview pages

Signed-off-by: Jackie Han <[email protected]>

* change version back to 3.0

Signed-off-by: Jackie Han <[email protected]>

* revert version change

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId optional in DetectorListItem type

Signed-off-by: Jackie Han <[email protected]>

* update imports

Signed-off-by: Jackie Han <[email protected]>

* remove used function

Signed-off-by: Jackie Han <[email protected]>

* cleanup

Signed-off-by: Jackie Han <[email protected]>

* add getter and setter for dataSource plugin

Signed-off-by: Jackie Han <[email protected]>

* read dataSourceId from the url instead of passing props

Signed-off-by: Jackie Han <[email protected]>

* addressing comments and run prettier

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* make getDataSourceManagementPlugin() optional

Signed-off-by: Jackie Han <[email protected]>

* add comment

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId type safe

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>

* add MDS support for detector creation&Update flow (#728)

* update snapshots

Signed-off-by: Jackie Han <[email protected]>

* add snpshot

Signed-off-by: Jackie Han <[email protected]>

* add data source client

Signed-off-by: Jackie Han <[email protected]>

* test

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* add opensearch_dashboards.json file

Signed-off-by: Jackie Han <[email protected]>

* neo List Detectors page

Signed-off-by: Jackie Han <[email protected]>

* test

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on DetectorDetails page

Signed-off-by: Jackie Han <[email protected]>

* change 4/7

Signed-off-by: Jackie Han <[email protected]>

* version change

Signed-off-by: Jackie Han <[email protected]>

* list detector list change

Signed-off-by: Jackie Han <[email protected]>

* Support MDS on List, Detail, Dashboard, Overview pages

Signed-off-by: Jackie Han <[email protected]>

* change version back to 3.0

Signed-off-by: Jackie Han <[email protected]>

* revert version change

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId optional in DetectorListItem type

Signed-off-by: Jackie Han <[email protected]>

* update imports

Signed-off-by: Jackie Han <[email protected]>

* remove used function

Signed-off-by: Jackie Han <[email protected]>

* cleanup

Signed-off-by: Jackie Han <[email protected]>

* add getter and setter for dataSource plugin

Signed-off-by: Jackie Han <[email protected]>

* read dataSourceId from the url instead of passing props

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* addressing comments and run prettier

Signed-off-by: Jackie Han <[email protected]>

* addressing comments in neo1 branch

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* make getDataSourceManagementPlugin() optional

Signed-off-by: Jackie Han <[email protected]>

* add comment

Signed-off-by: Jackie Han <[email protected]>

* make dataSourceId type safe

Signed-off-by: Jackie Han <[email protected]>

* add MDS support on creation page

Signed-off-by: Jackie Han <[email protected]>

* updated methods to get data source query param from url

Signed-off-by: Jackie Han <[email protected]>

* using helper to construct url with dataSourceId

Signed-off-by: Jackie Han <[email protected]>

* add update page, and update urls on detector detail page

Signed-off-by: Jackie Han <[email protected]>

* update update call router

Signed-off-by: Jackie Han <[email protected]>

* update reducer and router

Signed-off-by: Jackie Han <[email protected]>

* clean up

Signed-off-by: Jackie Han <[email protected]>

* addressing comments

Signed-off-by: Jackie Han <[email protected]>

* update enums

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>

* update actionOption attribution for all data soure components (#732)

Signed-off-by: Jackie Han <[email protected]>

* Add MDS UTs and bug fixes (#734)

* working on ut

Signed-off-by: Jackie Han <[email protected]>

* update ut

Signed-off-by: Jackie Han <[email protected]>

* update UTs and add bug fixes

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>

* bug fixes (#737)

Signed-off-by: Jackie Han <[email protected]>

---------

Signed-off-by: Jackie Han <[email protected]>
(cherry picked from commit 48acb93)

Co-authored-by: Jackie Han <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants