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
cephfs: add subvolume metadata APIs #691
Conversation
@phlogistonjohn FYI, I had tested these changes with cephfs master/devel code |
Looks really cool so far. The fact that it doesn't work with any released version of ceph yet is a bit annoying though. We need to add the build tags that will restrict what versions the code will work with. Last release I had a similar challenge with nfs mgr module changes - so I created a build tag 'ceph_ci_untested' that allows us to manually toggle a feature that we want in the codebase but can not be tested yet. If you have any questions/thoughts about this process feel fee to ask! |
@nmshelke What version of ceph will have ceph/ceph#45603 ? Do we have plans to backport it to Quincy ? cc: @vshankar @kotreshhr |
@pkalever https://tracker.ceph.com/issues/54472 has the backport details. backport is merged to Quincy. |
Thanks @Madhu-1, as per https://tracker.ceph.com/issues/54472 this feature will be part of |
Thanks @phlogistonjohn, added the build tags on the files and also PREVIEW comment on the APIs, PTAL. |
As per tracker information (https://tracker.ceph.com/issues/54472 ),
We have backport pull requests for quincy and pacific. Please follow following pull request and tracker for more details: |
This is needed for now, ceph/go-ceph#691 This PR at go-ceph add subvolume metadata APIs. Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
This is needed for now, ceph/go-ceph#691 This PR at go-ceph add subvolume metadata APIs. Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
This is needed for now, ceph/go-ceph#691 This PR at go-ceph add subvolume metadata APIs. Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
This is needed for now, ceph/go-ceph#691 This PR at go-ceph add subvolume metadata APIs. Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
This is needed for now, ceph/go-ceph#691 This PR at go-ceph add subvolume metadata APIs. Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
@Mergifyio rebase |
✅ Branch has been successfully rebased |
@phlogistonjohn @ansiwen could you please help review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was going to approve this but then I noticed the new functions are all being added to the stable section of api-status.json. That's not right as they're certainly not stable, as they're not even preview yet. The API itself looks good tho.
Huh, is that a bug of my recent change? |
docs/api-status.json
Outdated
@@ -494,6 +494,26 @@ | |||
{ | |||
"name": "FSAdmin.VolumeStatus", | |||
"comment": "VolumeStatus returns a VolumeStatus object for the given volume name.\n\nSimilar To:\n ceph fs status cephfs <name>\n" | |||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you manually add this, or is this coming from make api-update
? In the latter case we have a bug there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
make api-update
didn't work for me :-(
Had manually edited this with an online json tool.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's unfortunate, but now the CI is failing again because we don't have any API information for the functions.
Please describe how api-update failed for you.
As @ansiwen mentioned there could be a bug in the tool. If we can't fix it quickly we can also edit the JSON manually but the new APIs need to go into a preview section not the stable section.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I rushed my reply. I see you did add the functions but they're missing the descriptive metadata needed for that section. Please take a look a the other sections and how they're adding added_in_version and expected_stable_version. Please feel free to use v0.16.0 for added_in_version.
For expected_stable_version let's try "n/a" for now. If the CI still barfs because it's not a version number (I don't think it cares) just pick a version number far enough in the future that we're not making any promises of quick stabilization (we can always change that, its just a hint) like v0.20.0.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, I can not reproduce the CI failure locally. So I'm a bit unclear on what's actually going on. Please hold off working on this until I report back. Sorry for the noise.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, after one SNAFU where I was trying the changes from your other PR, I think the proper and simplest fix is to simply drop the 2nd patch in your pr ('docs: update subvolume metadata API details'). Because the code is now also guarded by the ceph_ci_untested
tag there's no need to do the API stuff until it is in proper preview
status, eg. when it's only guarded by the ceph_preview
build tag.
I've actually tried this locally and it worked so I have high confidence in this suggestion, and it should be pretty easy to implement on your side. :-)
Just remember when we come from untested status to preview status, then we'll need to do the api status tracking json changes. Hopefully then we can work out any issues you have with the make api-update
command and so it'll mostly be automatic at that time.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I looked into this, and it seems implements
evaluates the tags itself. Since ceph_ci_untested
is not set it ignores these files. So everything works as designed. You should simply not touch this file in this PR and call make api-update
later after you removed the untested tag in a later PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure @phlogistonjohn and @ansiwen, dropped the 2nd patch for now. Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In general LGTM, but there are minor tweaks necessary.
Exports below APIs: SetMetadata(), GetMetadata(), RemoveMetadata(), ForceRemoveMetadata() and ListMetadata() Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
@phlogistonjohn @ansiwen addressed the review comments now, PTAL. Thanks! |
We can't seem to get past the darn test flake today. Because we know that a) this feature is disabled by default b) its not causing any test failures, I'm going to merge w/o having all the CI pass. |
This is needed for now, ceph/go-ceph#691 This PR at go-ceph add subvolume metadata APIs. Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
This is needed for now, ceph/go-ceph#691 This PR at go-ceph add subvolume metadata APIs. Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
Description
Exports below APIs:
SetMetadata,
GetMetadata(),
RemoveMetadata(),
ForceRemoveMetadata() and
ListMetadata()
Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
Checklist