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

[Workspace]Redirect to use case landing page after workspace create #7933

Conversation

wanglam
Copy link
Contributor

@wanglam wanglam commented Aug 30, 2024

Description

This PR is for redirecting to use case landing page after workspace create successfully. The first nav links of each use case will be treated as the landing page. The PR will read the first nav link id and redirect to this page after workspace created.

Issues Resolved

#7952

Screenshot

No UI changes

Testing the changes

  • Clone branch code and run yarn osd bootstrap --single-version ignore
  • Add below configs in config/opensearch_dashboards.yml
savedObjects.permission.enabled: true
workspace.enabled: true
uiSettings:
  overrides:
    'home:useNewHomePage': true
  • Run yarn start --no-base-path
  • Login and visit workspace create page
  • Click "Create workspace" button
  • The page will redirect to the use case landing page instead of workspace detail page

Changelog

  • feat: [Workspace]Redirect to use case landing page after workspace create

Check List

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

Signed-off-by: Lin Wang <wonglam@amazon.com>
Copy link

codecov bot commented Aug 30, 2024

Codecov Report

Attention: Patch coverage is 66.66667% with 1 line in your changes missing coverage. Please review.

Project coverage is 61.01%. Comparing base (976c567) to head (3e65c96).
Report is 109 commits behind head on main.

Files with missing lines Patch % Lines
...components/workspace_creator/workspace_creator.tsx 66.66% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #7933   +/-   ##
=======================================
  Coverage   61.01%   61.01%           
=======================================
  Files        3685     3685           
  Lines       87143    87146    +3     
  Branches    13405    13406    +1     
=======================================
+ Hits        53169    53172    +3     
+ Misses      30755    30754    -1     
- Partials     3219     3220    +1     
Flag Coverage Δ
Linux_1 29.37% <66.66%> (+<0.01%) ⬆️
Linux_2 56.22% <ø> (ø)
Linux_3 37.82% <ø> (?)
Linux_4 29.58% <ø> (ø)
Windows_1 29.38% <66.66%> (+<0.01%) ⬆️
Windows_2 56.17% <ø> (ø)
Windows_3 37.82% <ø> (ø)
Windows_4 29.58% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

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

…ce-create

Signed-off-by: Lin Wang <wonglam@amazon.com>
@SuZhou-Joe SuZhou-Joe merged commit 6bd64f2 into opensearch-project:main Sep 2, 2024
66 of 67 checks passed
@opensearch-trigger-bot
Copy link
Contributor

The backport to 2.x failed:

The process '/usr/bin/git' failed with exit code 128

To backport manually, run these commands in your terminal:

# Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/OpenSearch-Dashboards/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/OpenSearch-Dashboards/backport-2.x
# Create a new branch
git switch --create backport/backport-7933-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 6bd64f2f5b209b64f2d810700d1ed1c6e7433c6c
# Push it to GitHub
git push --set-upstream origin backport/backport-7933-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/OpenSearch-Dashboards/backport-2.x

Then, create a pull request where the base branch is 2.x and the compare/head branch is backport/backport-7933-to-2.x.

wanglam added a commit to wanglam/OpenSearch-Dashboards that referenced this pull request Sep 3, 2024
…pensearch-project#7933)

* Redirect to use case landing page after workspace create

Signed-off-by: Lin Wang <wonglam@amazon.com>

* Changeset file for PR opensearch-project#7933 created/updated

---------

Signed-off-by: Lin Wang <wonglam@amazon.com>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
Co-authored-by: SuZhou-Joe <suzhou@amazon.com>
wanglam added a commit to wanglam/OpenSearch-Dashboards that referenced this pull request Sep 3, 2024
…pensearch-project#7933)

* Redirect to use case landing page after workspace create

Signed-off-by: Lin Wang <wonglam@amazon.com>

* Changeset file for PR opensearch-project#7933 created/updated

---------

Signed-off-by: Lin Wang <wonglam@amazon.com>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
Co-authored-by: SuZhou-Joe <suzhou@amazon.com>
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 4, 2024
…7933)

* Redirect to use case landing page after workspace create

Signed-off-by: Lin Wang <wonglam@amazon.com>

* Changeset file for PR #7933 created/updated

---------

Signed-off-by: Lin Wang <wonglam@amazon.com>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
Co-authored-by: SuZhou-Joe <suzhou@amazon.com>
(cherry picked from commit 6bd64f2)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
SuZhou-Joe added a commit that referenced this pull request Sep 4, 2024
…7933) (#7993)

* Redirect to use case landing page after workspace create



* Changeset file for PR #7933 created/updated

---------




(cherry picked from commit 6bd64f2)

Signed-off-by: Lin Wang <wonglam@amazon.com>
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>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
Co-authored-by: SuZhou-Joe <suzhou@amazon.com>
@opensearch-trigger-bot
Copy link
Contributor

The backport to 2.17 failed:

The process '/usr/bin/git' failed with exit code 128

To backport manually, run these commands in your terminal:

# Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/OpenSearch-Dashboards/backport-2.17 2.17
# Navigate to the new working tree
pushd ../.worktrees/OpenSearch-Dashboards/backport-2.17
# Create a new branch
git switch --create backport/backport-7933-to-2.17
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 6bd64f2f5b209b64f2d810700d1ed1c6e7433c6c
# Push it to GitHub
git push --set-upstream origin backport/backport-7933-to-2.17
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/OpenSearch-Dashboards/backport-2.17

Then, create a pull request where the base branch is 2.17 and the compare/head branch is backport/backport-7933-to-2.17.

opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 6, 2024
…7933) (#7993)

* Redirect to use case landing page after workspace create

* Changeset file for PR #7933 created/updated

---------

(cherry picked from commit 6bd64f2)

Signed-off-by: Lin Wang <wonglam@amazon.com>
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>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
Co-authored-by: SuZhou-Joe <suzhou@amazon.com>
(cherry picked from commit 624c692)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
SuZhou-Joe added a commit that referenced this pull request Sep 6, 2024
…7933) (#7993) (#8047)

* Redirect to use case landing page after workspace create

* Changeset file for PR #7933 created/updated

---------

(cherry picked from commit 6bd64f2)






(cherry picked from commit 624c692)

Signed-off-by: Lin Wang <wonglam@amazon.com>
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>
Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
Co-authored-by: SuZhou-Joe <suzhou@amazon.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants