summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPoornima G <pgurusid@redhat.com>2016-05-10 01:50:08 -0400
committerRaghavendra Talur <rtalur@redhat.com>2016-05-20 02:32:34 -0700
commitd6a23889b174cce1f54560a036d82c84b2bf53c5 (patch)
tree420d6a2ed3ed6c87427e75fc17398ecc2eb1d09a
parent9c7c83d7ac285a92607038321a51137ff3879c93 (diff)
leases: Fix the notify being lost
The notify() implemented doesn't really add any value and the EXIT_IF_LEASES_OFF in notify() can cause the notifications to be lost if leases if off. Hence remove the notify definition from leases, also fix a log level. Backport of http://review.gluster.org/#/c/14275/ Change-Id: I8bf30d26f08034a16a450ed811dcf8ac57d70a94 BUG: 1337638 Signed-off-by: Poornima G <pgurusid@redhat.com> Reviewed-on: http://review.gluster.org/14275 Smoke: Gluster Build System <jenkins@build.gluster.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Raghavendra Talur <rtalur@redhat.com> CentOS-regression: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Raghavendra G <rgowdapp@redhat.com> (cherry picked from commit 58c577994b2bf67b6f8d9749d9c7d678edfc9ceb) Reviewed-on: http://review.gluster.org/14429
-rw-r--r--xlators/features/leases/src/leases.c18
1 files changed, 3 insertions, 15 deletions
diff --git a/xlators/features/leases/src/leases.c b/xlators/features/leases/src/leases.c
index 8783a5ce9c2..2c1db34bd9c 100644
--- a/xlators/features/leases/src/leases.c
+++ b/xlators/features/leases/src/leases.c
@@ -991,11 +991,11 @@ init (xlator_t *this)
priv->timer_wheel = glusterfs_global_timer_wheel (this);
if (!priv->timer_wheel) {
- gf_msg (this->name, GF_LOG_ERROR, 0, LEASE_MSG_NO_TIMER_WHEEL,
- "Initing the global timer wheel");
+ gf_msg_debug (this->name, 0, "Initing the global timer wheel");
ret = glusterfs_global_timer_wheel_init (this->ctx);
if (ret) {
- gf_msg (this->name, GF_LOG_INFO, 0, LEASE_MSG_NO_TIMER_WHEEL,
+ gf_msg (this->name, GF_LOG_ERROR, 0,
+ LEASE_MSG_NO_TIMER_WHEEL,
"Initing the global timer wheel failed");
goto out;
}
@@ -1059,18 +1059,6 @@ out:
return ret;
}
-int
-notify (xlator_t *this, int32_t event, void *data, ...)
-{
- int ret = 0;
-
- EXIT_IF_LEASES_OFF (this, out);
-
- ret = default_notify (this, event, data);
-out:
- return ret;
-}
-
struct xlator_fops fops = {
/* Metadata modifying fops */
.fsetattr = leases_fsetattr,