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

mgr/dashboard: cephfs volume rm and rename #52645

Merged
merged 1 commit into from Aug 11, 2023

Conversation

avanthakkar
Copy link
Contributor

@avanthakkar avanthakkar commented Jul 26, 2023

Fixes: https://tracker.ceph.com/issues/62408
Signed-off-by: avanthakkar avanjohn@gmail.com

Edit CephFS Volume:
Screencast from 2023-07-26 23-51-40.webm

Delete CephFS Volume:
Screencast from 2023-07-26 23-52-46.webm

If mon_allow_pool_delete is disabled:
Screenshot from 2023-07-26 23-58-16

Contribution Guidelines

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard cephadm
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox
  • jenkins test windows

@avanthakkar avanthakkar changed the title mgr/dashboard: cephfs volume rm and rename REST APIs mgr/dashboard: cephfs volume rm and rename Jul 26, 2023
@cloudbehl
Copy link
Contributor

Can we divide them in two different PR separating out remove and edit?

@avanthakkar
Copy link
Contributor Author

Can we divide them in two different PR separating out remove and edit?

The changes aren't much for both, it's just right now I've cherry-picked Pere's PR for creation as some changes are required from that PR. Once that PR is merged I can remove that commit so there won't be much changes left then.

@avanthakkar avanthakkar marked this pull request as ready for review August 1, 2023 08:06
@avanthakkar avanthakkar requested a review from a team as a code owner August 1, 2023 08:06
@avanthakkar avanthakkar requested review from aaSharma14 and nizamial09 and removed request for a team August 1, 2023 08:06
Copy link
Member

@nizamial09 nizamial09 left a comment

Choose a reason for hiding this comment

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

Removing the volume gives me this message in notification. this should be handled.

Screenshot from 2023-08-01 15-11-34

@github-actions
Copy link

github-actions bot commented Aug 1, 2023

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

@cloudbehl
Copy link
Contributor

Removing the volume gives me this message in notification. this should be handled.

Screenshot from 2023-08-01 15-11-34

I can still see this issue.

Also once the notification is gone, I can't see that in task and notification section.

@github-actions
Copy link

github-actions bot commented Aug 3, 2023

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

Comment on lines +160 to +170
this.modalService.show(FormModalComponent, {
titleText: $localize`Edit Volume: ${selectedVolume}`,
fields: [
{
type: 'text',
name: 'volumeName',
value: selectedVolume,
label: $localize`Name`,
required: true
}
],
Copy link
Member

Choose a reason for hiding this comment

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

I just noticed this. We already have a form component for the volume creation. Why not reuse that and disable whatever that is not needed for the edit? Otherwise whenever we add new things to the creation form, we'll need to explicitly maintain the edit form as well. So we can follow the similar pattern that is done all over the dashboard for this edit form as well.

@avanthakkar avanthakkar marked this pull request as draft August 7, 2023 06:41
@avanthakkar avanthakkar force-pushed the cephfs-vol-rm branch 2 times, most recently from e7ae4df to 1b70344 Compare August 7, 2023 09:28
@avanthakkar
Copy link
Contributor Author

jenkins test api

Copy link
Contributor

@Pegonzal Pegonzal left a comment

Choose a reason for hiding this comment

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

LGTM! Working nicely, thanks Avan.

@avanthakkar
Copy link
Contributor Author

jenkins retest this please

@nizamial09
Copy link
Member

lint:tsc     ] src/app/ceph/cephfs/cephfs-list/cephfs-list.component.spec.ts(11,28): error TS6133: 'modalServiceShow' is declared but its value is never read.
[lint:tsc     ] src/app/ceph/cephfs/cephfs-list/cephfs-list.component.spec.ts(15,1): error TS6133: 'NotificationType' is declared but its value is never read.
[lint:tsc     ] src/app/ceph/cephfs/cephfs-list/cephfs-list.component.spec.ts(16,1): error TS6133: 'NotificationService' is declared but its value is never read.
[lint:tsc     ] src/app/ceph/cephfs/cephfs-list/cephfs-list.component.spec.ts(18,1): error TS6133: 'FormModalComponent' is declared but its value is never read.

Try running 'npm run fix' to fix some linting errors. Some errors might need a manual fix.

Lint failing on relates errors @avanthakkar . Looks like some unused variables. Try to run npm run fix before committing

@nizamial09
Copy link
Member

2023-08-09 15:17:08,368.368 INFO:__main__:
2023-08-09 15:17:08,368.368 INFO:__main__:----------------------------------------------------------------------
2023-08-09 15:17:08,368.368 INFO:__main__:Traceback (most recent call last):
2023-08-09 15:17:08,368.368 INFO:__main__:  File "/home/jenkins-build/build/workspace/ceph-api/qa/tasks/mgr/dashboard/test_cephfs.py", line 181, in test_cephfs_remove
2023-08-09 15:17:08,368.368 INFO:__main__:    self.assertStatus(200)
2023-08-09 15:17:08,368.368 INFO:__main__:  File "/home/jenkins-build/build/workspace/ceph-api/qa/tasks/mgr/dashboard/helper.py", line 497, in assertStatus
2023-08-09 15:17:08,368.368 INFO:__main__:    self.assertEqual(self._resp.status_code, status)
2023-08-09 15:17:08,368.368 INFO:__main__:AssertionError: 400 != 200
2023-08-09 15:17:08,368.368 INFO:__main__:
Cannot find device "ceph-brx"
2023-08-09 15:17:08,387.387 INFO:__main__:
2023-08-09 15:17:08,387.387 INFO:__main__:----------------------------------------------------------------------
2023-08-09 15:17:08,387.387 INFO:__main__:

Api test failure is also related!

@avanthakkar avanthakkar force-pushed the cephfs-vol-rm branch 2 times, most recently from fbe0f63 to 860cae5 Compare August 10, 2023 10:41
@avanthakkar
Copy link
Contributor Author

jenkins retest this please

@github-actions
Copy link

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

@nizamial09
Copy link
Member

2023-08-11 04:17:49,409.409 INFO:__main__:----------------------------------------------------------------------
2023-08-11 04:17:49,409.409 INFO:__main__:
2023-08-11 04:17:49,409.409 INFO:__main__:Traceback (most recent call last):
2023-08-11 04:17:49,409.409 INFO:__main__:  File "/home/jenkins-build/build/workspace/ceph-api/qa/tasks/mgr/dashboard/test_cephfs.py", line 177, in test_cephfs_create
2023-08-11 04:17:49,409.409 INFO:__main__:    self.assertStatus(200)
2023-08-11 04:17:49,410.410 INFO:__main__:  File "/home/jenkins-build/build/workspace/ceph-api/qa/tasks/mgr/dashboard/helper.py", line 497, in assertStatus
2023-08-11 04:17:49,410.410 INFO:__main__:    self.assertEqual(self._resp.status_code, status)
2023-08-11 04:17:49,410.410 INFO:__main__:AssertionError: 201 != 200
2023-08-11 04:17:49,410.410 INFO:__main__:
Cannot find device "ceph-brx"
2023-08-11 04:17:49,429.429 INFO:__main__:
2023-08-11 04:17:49,429.429 INFO:__main__:----------------------------------------------------------------------
2023-08-11 04:17:49,430.430 INFO:__main__:

@nizamial09
Copy link
Member

@avanthakkar maybe its best to test the API tests of this PR locally before pushing and waiting for the jenkins to pass.

@nizamial09
Copy link
Member

also I just noticed there is no tracker attached!

@avanthakkar avanthakkar force-pushed the cephfs-vol-rm branch 3 times, most recently from d6504f3 to a540cac Compare August 11, 2023 09:30
@avanthakkar
Copy link
Contributor Author

jenkins test api

@avanthakkar
Copy link
Contributor Author

jenkins test make check

1 similar comment
@cloudbehl
Copy link
Contributor

jenkins test make check

Fixes: https://tracker.ceph.com/issues/62408
Signed-off-by: avanthakkar <avanjohn@gmail.com>
@nizamial09 nizamial09 merged commit 91f75ab into ceph:main Aug 11, 2023
11 of 13 checks passed
@nizamial09 nizamial09 deleted the cephfs-vol-rm branch August 11, 2023 18:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants