[Pvfs2-cvs] commit by wligon in pvfs2/src/proto:
PINT-le-bytefield.c pvfs2-req-proto.h
CVS commit program
cvs at parl.clemson.edu
Tue Jun 8 13:31:01 EDT 2010
Update of /projects/cvsroot/pvfs2/src/proto
In directory parlweb1:/tmp/cvs-serv12876/src/proto
Modified Files:
Tag: Orange-Migrate-Tools
PINT-le-bytefield.c pvfs2-req-proto.h
Log Message:
Index: PINT-le-bytefield.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/proto/PINT-le-bytefield.c,v
diff -p -u -r1.58.10.8 -r1.58.10.8.2.1
--- PINT-le-bytefield.c 30 Apr 2010 20:00:54 -0000 1.58.10.8
+++ PINT-le-bytefield.c 8 Jun 2010 17:31:01 -0000 1.58.10.8.2.1
@@ -278,6 +278,9 @@ static void lebf_initialize(void)
resp.u.tree_get_file_size.caller_handle_index = 0;
respsize = extra_size_PVFS_servresp_tree_get_file_size;
break;
+ case PVFS_SERV_MGMT_MIGRATE:
+ /*nothing special */
+ break;
case PVFS_SERV_NUM_OPS: /* sentinel, should not hit */
assert(0);
break;
@@ -447,6 +450,7 @@ static int lebf_encode_req(
CASE(PVFS_SERV_DELEATTR, deleattr);
CASE(PVFS_SERV_LISTEATTR, listeattr);
CASE(PVFS_SERV_LISTATTR, listattr);
+ CASE(PVFS_SERV_MGMT_MIGRATE, mgmt_migrate);
case PVFS_SERV_GETCONFIG:
case PVFS_SERV_MGMT_NOOP:
@@ -561,6 +565,7 @@ static int lebf_encode_resp(
case PVFS_SERV_PROTO_ERROR:
case PVFS_SERV_IMM_COPIES:
case PVFS_SERV_MGMT_SETPARAM:
+ case PVFS_SERV_MGMT_MIGRATE:
/* nothing else */
break;
@@ -659,6 +664,7 @@ static int lebf_decode_req(
CASE(PVFS_SERV_DELEATTR, deleattr);
CASE(PVFS_SERV_LISTEATTR, listeattr);
CASE(PVFS_SERV_LISTATTR, listattr);
+ CASE(PVFS_SERV_MGMT_MIGRATE, mgmt_migrate);
case PVFS_SERV_GETCONFIG:
case PVFS_SERV_MGMT_NOOP:
@@ -763,6 +769,7 @@ static int lebf_decode_resp(
case PVFS_SERV_PROTO_ERROR:
case PVFS_SERV_IMM_COPIES:
case PVFS_SERV_MGMT_SETPARAM:
+ case PVFS_SERV_MGMT_MIGRATE:
/* nothing else */
break;
@@ -913,6 +920,7 @@ static void lebf_decode_rel(struct PINT_
case PVFS_SERV_MGMT_ITERATE_HANDLES:
case PVFS_SERV_MGMT_PERF_MON:
case PVFS_SERV_MGMT_EVENT_MON:
+ case PVFS_SERV_MGMT_MIGRATE: //migrate
case PVFS_SERV_DELEATTR:
case PVFS_SERV_LISTEATTR:
@@ -1075,6 +1083,7 @@ static void lebf_decode_rel(struct PINT_
case PVFS_SERV_BATCH_REMOVE:
case PVFS_SERV_IMM_COPIES:
case PVFS_SERV_TREE_REMOVE:
+ case PVFS_SERV_MGMT_MIGRATE:
/*nothing to free */
break;
case PVFS_SERV_INVALID:
Index: pvfs2-req-proto.h
===================================================================
RCS file: /projects/cvsroot/pvfs2/src/proto/pvfs2-req-proto.h,v
diff -p -u -r1.159.8.8 -r1.159.8.8.2.1
--- pvfs2-req-proto.h 30 Apr 2010 20:00:54 -0000 1.159.8.8
+++ pvfs2-req-proto.h 8 Jun 2010 17:31:01 -0000 1.159.8.8.2.1
@@ -83,6 +83,7 @@ enum PVFS_server_op
PVFS_SERV_IMM_COPIES = 40,
PVFS_SERV_TREE_REMOVE = 41,
PVFS_SERV_TREE_GET_FILE_SIZE = 42,
+ PVFS_SERV_MGMT_MIGRATE = 43,
/* leave this entry last */
PVFS_SERV_NUM_OPS
};
@@ -1902,6 +1903,39 @@ endecode_fields_2a_struct(
#define extra_size_PVFS_servresp_listeattr \
(PVFS_REQ_LIMIT_KEY_LEN * PVFS_REQ_LIMIT_KEYVAL_LIST)
+/* MGMT MIGRATE *****************************************//*COME HERE TO CHANGE STUFF!*/
+/* copy a single object and move to another server*/
+
+struct PVFS_servreq_mgmt_migrate{
+ PVFS_handle handle;
+ PVFS_fs_id fs_id;
+ const char *dist_server;
+};
+
+endecode_fields_3_struct(
+ PVFS_servreq_mgmt_migrate,
+ PVFS_handle, handle,
+ PVFS_fs_id, fs_id,
+ char, dist_server );
+
+#define PINT_SERVREQ_MGMT_MIGRATE_FILL(__req, \
+ __creds, \
+ __fsid, \
+ __handle, \
+ __dist_ser, \
+ __hints) \
+do{ \
+ memset(&(__req), 0, sizeof(__req)); \
+ (__req).op = PVFS_SERV_MGMT_MIGRATE; \
+ (__req).credentials = (__creds); \
+ (__req).hints = (__hints); \
+ (__req).u.mgmt_migrate.handle = (__handle); \
+ (__req).u.mgmt_migrate.fs_id = (__fsid); \
+} while(0);
+
+
+
+
/* server request *********************************************/
/* - generic request with union of all op specific structs */
@@ -1948,6 +1982,7 @@ struct PVFS_server_req
struct PVFS_servreq_listattr listattr;
struct PVFS_servreq_tree_remove tree_remove;
struct PVFS_servreq_tree_get_file_size tree_get_file_size;
+ struct PVFS_servreq_mgmt_migrate mgmt_migrate;
} u;
};
#ifdef __PINT_REQPROTO_ENCODE_FUNCS_C
More information about the Pvfs2-cvs
mailing list