Skip to content

Saved Object Aggregation View#1146

Merged
peternied merged 14 commits intomainfrom
main_aggregation_view
Oct 27, 2022
Merged

Saved Object Aggregation View#1146
peternied merged 14 commits intomainfrom
main_aggregation_view

Conversation

@cliu123
Copy link
Member

@cliu123 cliu123 commented Oct 18, 2022

Description

Enable saved object table to show saved objects across all permitted tenants on a single panel. This is the 1st milestone of the new saved object sharing experience.

Category

New feature

Why these changes are required?

The 1st milestone of the new saved object sharing experience.

What is the old behavior before changes and new behavior after changes?

(See the issue)
Current Behavior:
The Saved Object table shows only the saved objects in the selected tenants.
New Behavior:
The Saved Object table shows all the saved objects across all tenants that the logged in user has permissions to.

Issues Resolved

opensearch-project/OpenSearch-Dashboards#2249

Testing

Check List

  • New functionality includes testing
  • 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.

cliu123 and others added 5 commits October 17, 2022 16:42
Co-authored-by: Craig Perkins <cwperx@amazon.com>
Co-authored-by: Ryan Liang <jiallian@amazon.com>
Co-authored-by: Yan Zeng <zengyan@amazon.com>

Signed-off-by: Chang Liu <lc12251109@gmail.com>
* Add cypress CI for aggregation view

Signed-off-by: Ryan Liang <jiallian@amazon.com>
Signed-off-by: Chang Liu <lc12251109@gmail.com>
Signed-off-by: Chang Liu <lc12251109@gmail.com>
Signed-off-by: Ryan Liang <jiallian@amazon.com>
@cliu123 cliu123 requested a review from a team October 18, 2022 00:00
@codecov-commenter
Copy link

codecov-commenter commented Oct 18, 2022

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 73.90%. Comparing base (7b80f9b) to head (4e67d39).
⚠️ Report is 267 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1146      +/-   ##
==========================================
- Coverage   75.08%   73.90%   -1.19%     
==========================================
  Files          86       86              
  Lines        1975     1901      -74     
  Branches      278      251      -27     
==========================================
- Hits         1483     1405      -78     
- Misses        432      439       +7     
+ Partials       60       57       -3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Signed-off-by: Chang Liu <lc12251109@gmail.com>
Copy link
Member

@peternied peternied left a comment

Choose a reason for hiding this comment

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

The 1st milestone

I didn't seen milestones called out in opensearch-project/security#1869, is this Saved Objects Aggregated View the only consideration in scope?

Copy link
Member

@DarshitChanpura DarshitChanpura left a comment

Choose a reason for hiding this comment

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

Looks good overall! Requested a few changes

Signed-off-by: Ryan Liang <jiallian@amazon.com>
@cliu123
Copy link
Member Author

cliu123 commented Oct 21, 2022

The 1st milestone

I didn't seen milestones called out in opensearch-project/security#1869, is this Saved Objects Aggregated View the only consideration in scope?

The PM, UX and Eng are working on figuring out milestones in detail. We have a direction that we are going towards, but the expected UX needs to be fleshed out to provide the following milestones. The issue that this PR is trying to resolve has been linked to the RFC.

Signed-off-by: Chang Liu <lc12251109@gmail.com>
cliu123 and others added 3 commits October 24, 2022 11:38
Co-authored-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Chang Liu <lc12251109@gmail.com>
Signed-off-by: Chang Liu <lc12251109@gmail.com>
Signed-off-by: Chang Liu <lc12251109@gmail.com>
@cliu123 cliu123 added backport 2.x backport to 2.x branch v2.4.0 'Issues and PRs related to version v2.4.0' and removed backport 2.x backport to 2.x branch v2.4.0 'Issues and PRs related to version v2.4.0' labels Oct 27, 2022
@cliu123
Copy link
Member Author

cliu123 commented Oct 27, 2022

@peternied Thanks for reviewing! Sorry, I didn’t mean to re-request your review. I clicked the request review button on all reviewers by mistake.

FTR_PATH: 'ftr'
START_CMD: 'node ../scripts/opensearch_dashboards --dev --no-base-path --no-watch --opensearch_security.multitenancy.enable_aggregation_view=true'
OPENSEARCH_SNAPSHOT_CMD: 'node ../scripts/opensearch snapshot'
SPEC: 'cypress/integration/plugins/security-dashboards-plugin/aggregation_view.js,'
Copy link
Member

@DarshitChanpura DarshitChanpura Oct 27, 2022

Choose a reason for hiding this comment

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

should this changed to a folder path? Could be done in future if we are planning to add and test more cypress tests.

tenant = await fetchCurrentTenant(coreStart.http);
} catch (e) {
tenant = undefined;
console.log(e);
Copy link
Member

Choose a reason for hiding this comment

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

Do we need this console.log?

@peternied peternied merged commit 7c8ede6 into main Oct 27, 2022
cliu123 added a commit to cliu123/security-dashboards-plugin that referenced this pull request Nov 3, 2022
(cherry picked from commit 7c8ede6)

Signed-off-by: Chang Liu <lc12251109@gmail.com>
Signed-off-by: Ryan Liang <jiallian@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Yan Zeng <zengyan@amazon.com>

Co-authored-by: Ryan Liang <jiallian@amazon.com>
Co-authored-by: Ryan Liang <109499885+RyanL1997@users.noreply.github.com>
Co-authored-by: Craig Perkins <cwperx@amazon.com>
Co-authored-by: Yan Zeng <zengyan@amazon.com>

Change version to 2.4 for backport

Signed-off-by: Chang Liu <lc12251109@gmail.com>
cliu123 added a commit to cliu123/security-dashboards-plugin that referenced this pull request Nov 3, 2022
(cherry picked from commit 7c8ede6)

Signed-off-by: Chang Liu <lc12251109@gmail.com>
Signed-off-by: Ryan Liang <jiallian@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Yan Zeng <zengyan@amazon.com>

Co-authored-by: Ryan Liang <jiallian@amazon.com>
Co-authored-by: Ryan Liang <109499885+RyanL1997@users.noreply.github.com>
Co-authored-by: Craig Perkins <cwperx@amazon.com>
Co-authored-by: Yan Zeng <zengyan@amazon.com>
peternied pushed a commit that referenced this pull request Nov 3, 2022
* Saved Object Aggregation View (#1146)
* Move tenant-related utils to common folder (#1184)
* [Saved Object Aggregation View] Use namespace registry to add tenant filter (#1169)

Signed-off-by: Chang Liu <lc12251109@gmail.com>
Signed-off-by: Ryan Liang <jiallian@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Yan Zeng <zengyan@amazon.com>

Co-authored-by: Ryan Liang <jiallian@amazon.com>
Co-authored-by: Ryan Liang <109499885+RyanL1997@users.noreply.github.com>
Co-authored-by: Craig Perkins <cwperx@amazon.com>
Co-authored-by: Yan Zeng <zengyan@amazon.com>
peternied pushed a commit that referenced this pull request Nov 3, 2022
* Saved Object Aggregation View (#1146)
* Move tenant-related utils to common folder (#1184)
* [Saved Object Aggregation View] Use namespace registry to add tenant filter (#1169)

Signed-off-by: Chang Liu <lc12251109@gmail.com>
Signed-off-by: Ryan Liang <jiallian@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Yan Zeng <zengyan@amazon.com>

Co-authored-by: Ryan Liang <jiallian@amazon.com>
Co-authored-by: Ryan Liang <109499885+RyanL1997@users.noreply.github.com>
Co-authored-by: Craig Perkins <cwperx@amazon.com>
Co-authored-by: Yan Zeng <zengyan@amazon.com>
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.

10 participants