-
Notifications
You must be signed in to change notification settings - Fork 6k
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
libcephfs: introduce libcephfs *at() APIs #40810
Conversation
62b4019
to
e2d6904
Compare
Do we really need this? We have the |
I haven't closely looked at the |
It depends on the application. ganesha uses the My main worry is that adding so many interfaces to libcephfs will become a maintenance burden. It's also hard to remove interfaces later, once they proliferate out into the field, so we want to make sure that we're only adding things that we think applications need and will use. |
I guess I'm with Jeff. I don't understand the motivation to avoid handles, in general. The "low level" methods were needed to make libcephfs actually useful to protocol translators. It's less clear how important it is for the library to cater to programmers who cannot understand the concept of a handle. |
cephfs mirror daemon. |
I would have thought that the cephfs mirror daemon would be able to use ll apis. As Jeff said, the ganesha "fsal" driver has used them since 2011 or something. Matt |
It obviously can use *_ll APIs. However, I do not expect other users of this library to switch using low-level interfaces for things like these. |
In the go-ceph project we have (partial) coverage of the high level apis but none of the low-level apis, so having *at functions could give some pretty good benefits without having to understand all the details that the lowlevel api might bring. The high level apis are also a very close translation of the typical file systems api calls and thus you can often do use the docs for those calls to help understand the libcephfs apis. I have personally been hesitant to jump into the low level api for go-ceph... as compared to the pretty good doxygen comments for the high level api the low level apis are more sparsely documented (at least I haven't found much on it). While its certainly not insurmountable, there's stuff like |
I'm against proliferating the low-level API any further than we already have. It started out as a hack for ceph-fuse without a lot of thought into its appropriateness for other use-cases. I don't want to increase dependencies on it. The |
The "low level" api calls are somewhat similar to VFS in general, and there are extensions for NFS. While the ll calls do look hacky, the motivations for them were valid. Programs like NFS-Ganesha shouldn't be restricted to a POSIX interface when there's no strong motivation for doing that. |
Fair enough. If you guys feel it's worth it to duplicate this functionality, then so be it. I won't stand in the way of it. |
e2d6904
to
4aa98bb
Compare
4aa98bb
to
e533278
Compare
@batrick fixed and updated |
No need to include this check since _getattr() checks this anyway. Signed-off-by: Venky Shankar <vshankar@redhat.com>
Signed-off-by: Venky Shankar <vshankar@redhat.com>
Signed-off-by: Venky Shankar <vshankar@redhat.com>
Other tests might use the same file names and expect libcephfs calls to succeed. Signed-off-by: Venky Shankar <vshankar@redhat.com>
Fixes: http://tracker.ceph.com/issues/50298 Signed-off-by: Venky Shankar <vshankar@redhat.com>
e533278
to
b88228e
Compare
fixed and updated |
jenkins test make check |
jenkins test make check |
@vshankar @batrick @petrutlucian94 please note this change breaks the windows build.
|
Thanks @tchaikov. We probably need (from include/uapi/linux/fcntl.h):
|
@vshankar right, I suggest defining it here, next to @tchaikov thanks for keeping an eye on the Windows build. |
@vshankar @petrutlucian94 mind creating a fix? |
I'm on it. |
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph#40810
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph#40810 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph#40810 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> (cherry picked from commit 4aab6e3)
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph#40810 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> (cherry picked from commit 4aab6e3)
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph#40810 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> (cherry picked from commit 4aab6e3)
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph/ceph#40810 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> (cherry picked from commit 4aab6e3)
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph/ceph#40810 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> (cherry picked from commit 4aab6e3)
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph/ceph#40810 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> (cherry picked from commit 4aab6e3)
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph/ceph#40810 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> (cherry picked from commit 4aab6e3)
The AT_REMOVEDIR flag is used by a recent change [1] but isn't defined on Windows. This commit will add the missing definition. Note that it won't be passed to OS functions, only being used at the CephFS level. [1] ceph#40810 Resolves: rhbz#1956341 Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com> (cherry picked from commit 4aab6e3) (cherry picked from commit 62c91a3)
Checklist
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 api
jenkins test docs
jenkins render docs
jenkins test ceph-volume all
jenkins test ceph-volume tox