summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd.h
diff options
context:
space:
mode:
authorNiels de Vos <ndevos@redhat.com>2013-03-15 10:26:53 +0100
committerVijay Bellur <vbellur@redhat.com>2013-06-20 06:48:54 -0700
commitbc27b7a9e44f2af647b87ab393b0fd1cacd211cf (patch)
tree15ceb173f81efeb5ff31feeca9ff847dbb855949 /xlators/mgmt/glusterd/src/glusterd.h
parentd7e80787fc61a4fe9e72ff80565dc720ac29441a (diff)
store: move glusterd_store functions from mgmt/glusterd to libglusterfs
Making the glusterd_store_* functions re-usable will help with future changes that need to read/write lists of items. BUG: 904065 Change-Id: I99fb8eced76d12d5a254567eccff9790b43d8da3 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/4676 Reviewed-by: Krishnan Parthasarathi <kparthas@redhat.com> Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd.h')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd.h18
1 files changed, 6 insertions, 12 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd.h b/xlators/mgmt/glusterd/src/glusterd.h
index e3b1884eb..6bd9431e8 100644
--- a/xlators/mgmt/glusterd/src/glusterd.h
+++ b/xlators/mgmt/glusterd/src/glusterd.h
@@ -37,6 +37,7 @@
#include "glusterd-pmap.h"
#include "cli1-xdr.h"
#include "syncop.h"
+#include "store.h"
#define GLUSTERD_MAX_VOLUME_NAME 1000
#define DEFAULT_LOG_FILE_DIRECTORY DATADIR "/log/glusterfs"
@@ -98,13 +99,6 @@ typedef enum glusterd_op_ {
} glusterd_op_t;
extern const char * gd_op_list[];
-struct glusterd_store_iter_ {
- int fd;
- FILE *file;
- char filepath[PATH_MAX];
-};
-
-typedef struct glusterd_store_iter_ glusterd_store_iter_t;
struct glusterd_volgen {
dict_t *dict;
@@ -137,7 +131,7 @@ typedef struct {
struct list_head volumes;
pthread_mutex_t xprt_lock;
struct list_head xprt_list;
- glusterd_store_handle_t *handle;
+ gf_store_handle_t *handle;
gf_timer_t *timer;
glusterd_sm_tr_log_t op_sm_log;
struct rpc_clnt_program *gfs_mgmt;
@@ -170,7 +164,7 @@ struct glusterd_brickinfo {
int rdma_port;
char *logfile;
gf_boolean_t signed_in;
- glusterd_store_handle_t *shandle;
+ gf_store_handle_t *shandle;
gf_brick_status_t status;
struct rpc_clnt *rpc;
int decommissioned;
@@ -273,9 +267,9 @@ struct glusterd_volinfo_ {
int dist_leaf_count; /* Number of bricks in one
distribute subvolume */
int port;
- glusterd_store_handle_t *shandle;
- glusterd_store_handle_t *rb_shandle;
- glusterd_store_handle_t *node_state_shandle;
+ gf_store_handle_t *shandle;
+ gf_store_handle_t *rb_shandle;
+ gf_store_handle_t *node_state_shandle;
/* Defrag/rebalance related */
glusterd_rebalance_t rebal;