diff options
author | Pranith K <pranithk@gluster.com> | 2011-03-10 21:49:04 +0000 |
---|---|---|
committer | Vijay Bellur <vijay@dev.gluster.com> | 2011-03-14 03:08:50 -0700 |
commit | 05dbcd0cb2415bb218221eccc1e7005645aa318b (patch) | |
tree | 1cb7324001287a01a70e52cb3617d34c53da69e2 /xlators/mgmt/glusterd/src/glusterd-store.h | |
parent | 5a8edf3fc4deb4713d390690b144342e24659f8c (diff) |
mgmt/glusterd: remodel glusterd store
Signed-off-by: Pranith Kumar K <pranithk@gluster.com>
Signed-off-by: Vijay Bellur <vijay@dev.gluster.com>
BUG: 1754 ()
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1754
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-store.h')
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-store.h | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-store.h b/xlators/mgmt/glusterd/src/glusterd-store.h index 472a6ef4f..0403c10f9 100644 --- a/xlators/mgmt/glusterd/src/glusterd-store.h +++ b/xlators/mgmt/glusterd/src/glusterd-store.h @@ -37,6 +37,11 @@ #include "glusterd.h" #include "rpcsvc.h" +typedef enum glusterd_store_ver_ac_{ + GLUSTERD_VOLINFO_VER_AC_NONE = 0, + GLUSTERD_VOLINFO_VER_AC_INCREMENT = 1, +} glusterd_volinfo_ver_ac_t; + #define GLUSTERD_STORE_UUID_KEY "UUID" @@ -80,7 +85,7 @@ typedef enum { } glusterd_store_op_errno_t; int32_t -glusterd_store_create_volume (glusterd_volinfo_t *volinfo); +glusterd_store_volinfo (glusterd_volinfo_t *volinfo, glusterd_volinfo_ver_ac_t ac); int32_t glusterd_store_delete_volume (glusterd_volinfo_t *volinfo); @@ -92,21 +97,17 @@ int32_t glusterd_store_handle_new (char *path, glusterd_store_handle_t **handle); int32_t -glusterd_store_save_value (glusterd_store_handle_t *handle, - char *key, char *value); +glusterd_store_save_value (int fd, char *key, char *value); int32_t glusterd_store_retrieve_value (glusterd_store_handle_t *handle, char *key, char **value); int32_t -glusterd_store_update_volume (glusterd_volinfo_t *volinfo); - -int32_t glusterd_retrieve_uuid (); int32_t -glusterd_store_update_peerinfo (glusterd_peerinfo_t *peerinfo); +glusterd_store_peerinfo (glusterd_peerinfo_t *peerinfo); int32_t glusterd_store_delete_peerinfo (glusterd_peerinfo_t *peerinfo); @@ -121,4 +122,7 @@ glusterd_store_handle_destroy (glusterd_store_handle_t *handle); int32_t glusterd_restore (); +void +glusterd_perform_volinfo_version_action (glusterd_volinfo_t *volinfo, + glusterd_volinfo_ver_ac_t ac); #endif |