From b82743a5822626e83b233956803421fda9b1c3f9 Mon Sep 17 00:00:00 2001 From: Vijay Bellur Date: Tue, 9 Jul 2019 16:32:36 -0700 Subject: Remove hadoop related code from the codebase As Hadoop is no longer supported, dropping code for handling Hadoop access. Fixes: bz#1728417 Signed-off-by: Vijay Bellur Change-Id: I8fcf4faacb364f1c9a8abb0c48faec337087f845 --- xlators/mount/fuse/src/fuse-bridge.c | 2 +- xlators/mount/fuse/src/fuse-helpers.c | 35 +++++++++++------------------------ 2 files changed, 12 insertions(+), 25 deletions(-) (limited to 'xlators/mount/fuse') diff --git a/xlators/mount/fuse/src/fuse-bridge.c b/xlators/mount/fuse/src/fuse-bridge.c index 5fa3ff532f9..b9531dbc469 100644 --- a/xlators/mount/fuse/src/fuse-bridge.c +++ b/xlators/mount/fuse/src/fuse-bridge.c @@ -6665,7 +6665,7 @@ init(xlator_t *this_xl) GF_OPTION_INIT("no-root-squash", priv->no_root_squash, bool, cleanup_exit); /* change the client_pid to no-root-squash pid only if the - client is none of defrag process, hadoop access and gsyncd process. + client is neither defrag process or gsyncd process. */ if (!priv->client_pid_set) { if (priv->no_root_squash == _gf_true) { diff --git a/xlators/mount/fuse/src/fuse-helpers.c b/xlators/mount/fuse/src/fuse-helpers.c index 5bfc40c9fcb..3b00eee8f6a 100644 --- a/xlators/mount/fuse/src/fuse-helpers.c +++ b/xlators/mount/fuse/src/fuse-helpers.c @@ -581,30 +581,17 @@ fuse_flip_xattr_ns(fuse_private_t *priv, char *okey, char **nkey) int ret = 0; gf_boolean_t need_flip = _gf_false; - switch (priv->client_pid) { - case GF_CLIENT_PID_GSYNCD: - /* valid xattr(s): *xtime, volume-mark* */ - gf_log("glusterfs-fuse", GF_LOG_DEBUG, - "PID: %d, checking xattr(s): " - "volume-mark*, *xtime", - priv->client_pid); - if ((strcmp(okey, UNPRIV_XA_NS ".glusterfs.volume-mark") == 0) || - (fnmatch(UNPRIV_XA_NS ".glusterfs.volume-mark.*", okey, - FNM_PERIOD) == 0) || - (fnmatch(UNPRIV_XA_NS ".glusterfs.*.xtime", okey, FNM_PERIOD) == - 0)) - need_flip = _gf_true; - break; - - case GF_CLIENT_PID_HADOOP: - /* valid xattr(s): pathinfo */ - gf_log("glusterfs-fuse", GF_LOG_DEBUG, - "PID: %d, checking xattr(s): " - "pathinfo", - priv->client_pid); - if (strcmp(okey, UNPRIV_XA_NS ".glusterfs.pathinfo") == 0) - need_flip = _gf_true; - break; + if (GF_CLIENT_PID_GSYNCD == priv->client_pid) { + /* valid xattr(s): *xtime, volume-mark* */ + gf_log("glusterfs-fuse", GF_LOG_DEBUG, + "PID: %d, checking xattr(s): " + "volume-mark*, *xtime", + priv->client_pid); + if ((strcmp(okey, UNPRIV_XA_NS ".glusterfs.volume-mark") == 0) || + (fnmatch(UNPRIV_XA_NS ".glusterfs.volume-mark.*", okey, + FNM_PERIOD) == 0) || + (fnmatch(UNPRIV_XA_NS ".glusterfs.*.xtime", okey, FNM_PERIOD) == 0)) + need_flip = _gf_true; } if (need_flip) { -- cgit