summaryrefslogtreecommitdiffstats
path: root/api
diff options
context:
space:
mode:
authorPoornima G <pgurusid@redhat.com>2016-07-11 15:04:55 +0530
committerRaghavendra G <rgowdapp@redhat.com>2016-08-30 23:07:01 -0700
commit8f053f9d7270f1c6d50c0b3ab5d020503ceeb31a (patch)
tree754b2dbc815e8b0d619016b5d53f7e0acfae8c40 /api
parent55c255b27a99f027cb716800f8330f8faa4eb1f5 (diff)
md-cache: Register the list of xattrs with cache-invalidation
Issue: md-cache caches a specified list of xattrs, and when cache invalidation is enabled, it makes sense to recieve invalidation only when those xattrs are modified by other clients. But the current implementation of upcall is that, it will send invalidation when any of the on-disk xattrs is modified. Solution: md-cache sends a list of xattrs that it is interested in, to upcall by issuing an ipc(). The challenge here is to make sure everytime a brick goes offline and comes back up, the ipc() needs to be issued to the bricks. Hence ipc() is sent from md-cache every time there is a CHILD_UP/CHILD_MODIFIED event. TODO: There will be patches following, in cluster xlators, to implement ipc fop. Change-Id: I6efcf3df474f5ce6eabd3d6694c00c7bd89bc25d BUG: 1211863 Signed-off-by: Poornima G <pgurusid@redhat.com> Reviewed-on: http://review.gluster.org/15002 Smoke: Gluster Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.org> Reviewed-by: Rajesh Joseph <rjoseph@redhat.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Prashanth Pai <ppai@redhat.com> Reviewed-by: Raghavendra G <rgowdapp@redhat.com>
Diffstat (limited to 'api')
-rw-r--r--api/src/glfs-internal.h22
1 files changed, 0 insertions, 22 deletions
diff --git a/api/src/glfs-internal.h b/api/src/glfs-internal.h
index 471fa5fffc1..a10c7289115 100644
--- a/api/src/glfs-internal.h
+++ b/api/src/glfs-internal.h
@@ -103,28 +103,6 @@
#define GFAPI_SYMVER_PRIVATE(fn1, fn2, dotver) /**/
#endif
-/*
- * syncop_xxx() calls are executed in two ways, one is inside a synctask where
- * the executing function will do 'swapcontext' and the other is without
- * synctask where the executing thread is made to wait using pthread_cond_wait.
- * Executing thread may change when syncop_xxx() is executed inside a synctask.
- * This leads to errno_location change i.e. errno may give errno of
- * non-executing thread. So errno is not touched inside a synctask execution.
- * All gfapi calls are executed using the second way of executing syncop_xxx()
- * where the executing thread waits using pthread_cond_wait so it is ok to set
- * errno in these cases. The following macro makes syncop_xxx() behave just
- * like a system call, where -1 is returned and errno is set when a failure
- * occurs.
- */
-#define DECODE_SYNCOP_ERR(ret) do { \
- if (ret < 0) { \
- errno = -ret; \
- ret = -1; \
- } else { \
- errno = 0; \
- } \
- } while (0)
-
#define ESTALE_RETRY(ret,errno,reval,loc,label) do { \
if (ret == -1 && errno == ESTALE) { \
if (reval < DEFAULT_REVAL_COUNT) { \