summaryrefslogtreecommitdiffstats
path: root/api/src/glfs-handles.h
Commit message (Collapse)AuthorAgeFilesLines
* libgfapi: Added Handle-based ops to get/set/remove extended attributes in ↵Soumya Koduri2014-05-221-1/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | the libgfapi. Cherry picked from commit Change-Id: I1a8e666018d7b93e0bba2d9882935681da909980 and Change-Id: I62f63da37edf722d6d79c75f72ee7403e93e4936 > BUG: 1089414 > Signed-off-by: Soumya Koduri <skoduri@redhat.com> > Reviewed-on: http://review.gluster.org/7308 > Reviewed-by: Vijay Bellur <vbellur@redhat.com> > Tested-by: Vijay Bellur <vbellur@redhat.com> This patch differs a bit from its earlier master patch - * 'DECODE_SYNCOP_ERR' macro is not defined in this code branch. So lines where this macro is used are skipped. * 'syncop_removexattr(..)' definition differs from the one in the master branch. BUG: 1099878 Change-Id: I1e9cce4efeec038b9736065d39887c35752caead Signed-off-by: Soumya Koduri <skoduri@redhat.com> Reviewed-on: http://review.gluster.org/7825 Reviewed-by: Raghavendra G <rgowdapp@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Niels de Vos <ndevos@redhat.com>
* gfapi: object handle based API extensionsR.Shyamsundar2013-10-111-0/+143
There is an ongoing effort to integrate NFS Ganesha ( https://github.com/nfs-ganesha/nfs-ganesha/wiki ) with GlusterFS as one of the file system back ends. Towards this we need extensions to gfapi that can handle object based operations. Meaning, instead of using full paths or relative paths from cwd, it is required that we can work with APIs, like the *at POSIX variants, to be able to create, lookup, open etc. files and directories. Hence the objects are the files or directories themselves and we give out handles to these objects that can be used for further operations. This code drop is an initial implementation of the proposed APIs. The new APIs are implemented as glfs_h_XXX variants in the file glfs-handleops.c to mirror glfs-fops.c style. The code leverages holding onto inode references and doling these out as opaque/cookie type objects to the callers, to enable them to be used as handles in other operations. An fd based approach was considered, but due to the extra footprint that the fd structure and its counterparts would incur, this was dropped to take the approach of holding inode references themselves. Tested by extending glfsxmp.c to invoke and exercise the added APIs, and further tested with a reference integration of the same as an FSAL with NFS Ganesha. Change-Id: I23629c99e905b54070fa2e6565147812e5f3fa5d BUG: 1016000 Signed-off-by: R.Shyamsundar <srangana@redhat.com> Reviewed-on: http://review.gluster.org/5936 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Anand Avati <avati@redhat.com>