OpenSearch-Dashboards icon indicating copy to clipboard operation
OpenSearch-Dashboards copied to clipboard

[Workspace]Restrict data source permission when workspace enabled

Open wanglam opened this issue 7 months ago • 1 comments

Description

The data source CUD operations will be restricted in the #7091 , this PR is an enhancement for #7091 in the saved object client get and find methods. It includes below main changes:

  1. Restrict data source permission for non dashboard admin when workspace enabled, global data source only can be accessed by dashboard admin
  2. Remove options.workspaces drop logic in conflict wrapper

Issues Resolved

#7127

Screenshot

No ui changes

Testing the changes

See the integration test file: src/plugins/workspace/server/saved_objects/integration_tests/workspace_saved_objects_client_wrapper.test.ts

Changelog

  • fix: [Workspace]Limit data source permission when workspace enabled

Check List

  • [x] All tests pass
    • [ ] yarn test:jest
    • [ ] yarn test:jest_integration
  • [ ] New functionality includes testing.
  • [ ] New functionality has been documented.
  • [ ] Update CHANGELOG.md
  • [x] Commits are signed per the DCO using --signoff

wanglam avatar Jun 28 '24 09:06 wanglam