diff options
author | Amar Tumballi <amar@gluster.com> | 2010-07-26 06:13:57 +0000 |
---|---|---|
committer | Anand V. Avati <avati@dev.gluster.com> | 2010-07-27 01:20:04 -0700 |
commit | 667b2496c3f29e24ed359a05b0f44df0d1894969 (patch) | |
tree | a034682bd199951bc492e6db607e3d70c2edb440 /xlators/cluster/dht/src/dht-common.h | |
parent | 4792bb9a6caa4c74b6facebaba9379694893070e (diff) |
dht enhancements
* create(filename@<distribute-volume-name>-<subvol-name>), will
create the file in corresponding subvol of dht.
* same for unlink()
same logic can be extended to other fops if there is a need
Signed-off-by: Amar Tumballi <amar@gluster.com>
Signed-off-by: Anand V. Avati <avati@dev.gluster.com>
BUG: 1200 (enhance distribute with hooks so lot of debugging can be done online)
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1200
Diffstat (limited to 'xlators/cluster/dht/src/dht-common.h')
-rw-r--r-- | xlators/cluster/dht/src/dht-common.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/xlators/cluster/dht/src/dht-common.h b/xlators/cluster/dht/src/dht-common.h index d5a5c7b2c59..dfdaf7e861c 100644 --- a/xlators/cluster/dht/src/dht-common.h +++ b/xlators/cluster/dht/src/dht-common.h @@ -31,6 +31,8 @@ #define GF_DHT_LOOKUP_UNHASHED_ON 1 #define GF_DHT_LOOKUP_UNHASHED_AUTO 2 +#include <fnmatch.h> + typedef int (*dht_selfheal_dir_cbk_t) (call_frame_t *frame, void *cookie, xlator_t *this, int32_t op_ret, int32_t op_errno); @@ -121,6 +123,8 @@ struct dht_local { /* need for file-info */ char *pathinfo; char *key; + + char *newpath; }; typedef struct dht_local dht_local_t; @@ -289,4 +293,8 @@ int dht_frame_su_undo (call_frame_t *frame); int dht_build_child_loc (xlator_t *this, loc_t *child, loc_t *parent, char *name); +int dht_filter_loc_subvol_key (xlator_t *this, loc_t *loc, loc_t *new_loc, + xlator_t **subvol); + + #endif /* _DHT_H */ |