summaryrefslogtreecommitdiffstats
path: root/xlators/features/upcall/src/upcall.h
diff options
context:
space:
mode:
authorSoumya Koduri <skoduri@redhat.com>2015-04-30 13:28:44 +0530
committerKaleb KEITHLEY <kkeithle@redhat.com>2015-05-05 06:57:43 -0700
commit170cc4ea08aa48e69c2df6be5841076c9a119d5a (patch)
treea1afb1e9efc19225a4f37a1cb08deb6b4aaffebf /xlators/features/upcall/src/upcall.h
parent08107796c89f5f201b24d689ab6757237c743c0d (diff)
Upcall: Send stat as part of cache_invalidation notifications
Have added support to send attributes of both entries and its parent (include oldparent in case of RENAME fop) in the same notification request to avoid multiple rpc requests. Also, made changes in gfapi to send parent object and its attributes changed in a single upcall event. Change-Id: I92833da3bcec38d65216921c2ce4d10367c32ef1 BUG: 1200262 Signed-off-by: Soumya Koduri <skoduri@redhat.com> Reviewed-on: http://review.gluster.org/10460 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Diffstat (limited to 'xlators/features/upcall/src/upcall.h')
-rw-r--r--xlators/features/upcall/src/upcall.h32
1 files changed, 9 insertions, 23 deletions
diff --git a/xlators/features/upcall/src/upcall.h b/xlators/features/upcall/src/upcall.h
index 41895786382..295ddc26167 100644
--- a/xlators/features/upcall/src/upcall.h
+++ b/xlators/features/upcall/src/upcall.h
@@ -16,15 +16,11 @@
#endif
#include "compat-errno.h"
-#include "stack.h"
-#include "call-stub.h"
#include "upcall-mem-types.h"
#include "client_t.h"
-#include "rpcsvc.h"
-#include "lkowner.h"
-#include "locking.h"
#include "upcall-messages.h"
#include "upcall-cache-invalidation.h"
+#include "upcall-utils.h"
#define EXIT_IF_UPCALL_OFF(this, label) do { \
if (!is_upcall_enabled(this)) \
@@ -84,18 +80,6 @@ struct _upcall_inode_ctx_t {
};
typedef struct _upcall_inode_ctx_t upcall_inode_ctx_t;
-struct _notify_event_data {
- uuid_t gfid;
- upcall_client_t *client_entry;
- gf_upcall_event_t event_type;
- uint32_t invalidate_flags;
- /* any extra data needed, like inode flags
- * to be invalidated incase of cache invalidation,
- * may be fd for lease recalls */
- void *extra;
-};
-typedef struct _notify_event_data notify_event_data_t;
-
struct upcall_local {
/* XXX: need to check if we can store
* pointers in 'local' which may get freed
@@ -137,13 +121,15 @@ int upcall_reaper_thread_init (xlator_t *this);
gf_boolean_t is_upcall_enabled(xlator_t *this);
/* Cache invalidation specific */
-void upcall_cache_invalidate (call_frame_t *frame, xlator_t *this, client_t *client,
- inode_t *inode, uint32_t flags);
+void upcall_cache_invalidate (call_frame_t *frame, xlator_t *this,
+ client_t *client, inode_t *inode,
+ uint32_t flags, struct iatt *stbuf,
+ struct iatt *p_stbuf,
+ struct iatt *oldp_stbuf);
void upcall_client_cache_invalidate (xlator_t *xl, uuid_t gfid,
upcall_client_t *up_client_entry,
- uint32_t flags);
-void upcall_cache_invalidate_dir (call_frame_t *frame, xlator_t *this,
- client_t *client, inode_t *inode,
- uint32_t flags);
+ uint32_t flags, struct iatt *stbuf,
+ struct iatt *p_stbuf,
+ struct iatt *oldp_stbuf);
#endif /* __UPCALL_H__ */