[Pvfs2-cvs] commit by slang in pvfs2/test/io/trove: trove-mkfs.c

CVS commit program cvs at parl.clemson.edu
Thu Oct 19 18:29:21 EDT 2006


Update of /projects/cvsroot/pvfs2/test/io/trove
In directory parlweb1:/tmp/cvs-serv7191/test/io/trove

Modified Files:
      Tag: WALT3
	trove-mkfs.c 
Log Message:
fix trove method stuff


Index: trove-mkfs.c
===================================================================
RCS file: /projects/cvsroot/pvfs2/test/io/trove/trove-mkfs.c,v
diff -p -u -r1.16.2.1 -r1.16.2.2
--- trove-mkfs.c	19 Oct 2006 22:17:25 -0000	1.16.2.1
+++ trove-mkfs.c	19 Oct 2006 22:29:21 -0000	1.16.2.2
@@ -25,7 +25,6 @@ int main(int argc, char **argv)
     TROVE_handle root_handle;
     TROVE_ds_state state;
     TROVE_keyval_s key, val;
-    char *method_name;
     TROVE_extent cur_extent;
     TROVE_handle_extent_array extent_array;
     TROVE_context_id trove_context = -1;
@@ -37,20 +36,22 @@ int main(int argc, char **argv)
     }
 
     /* try to initialize; fails if storage space isn't there? */
-    ret = trove_initialize(storage_space, 0, &method_name, 0);
+    ret = trove_initialize(
+            TROVE_METHOD_DBPF, NULL, storage_space, 0);
     if (ret < 0) {
 	fprintf(stderr, "warning: initialize failed.  trying to create storage space.\n");
 
 	/* create the storage space */
 	/* Q: what good is the op_id here if we have to match on coll_id in test fn? */
-	ret = trove_storage_create(storage_space, NULL, &op_id);
+	ret = trove_storage_create(TROVE_METHOD_DBPF, storage_space, NULL, &op_id);
 	if (ret < 0) {
 	    fprintf(stderr, "storage create failed.\n");
 	    return -1;
 	}
 
 	/* second try at initialize, in case it failed first try. */
-	ret = trove_initialize(storage_space, 0, &method_name, 0);
+	ret = trove_initialize(
+                TROVE_METHOD_DBPF, NULL, storage_space, 0);
 	if (ret < 0) {
 	    fprintf(stderr, "initialized failed second time.\n");
 	    return -1;
@@ -58,7 +59,8 @@ int main(int argc, char **argv)
     }
 
     /* try to look up collection used to store file system */
-    ret = trove_collection_lookup(file_system, &coll_id, NULL, &op_id);
+    ret = trove_collection_lookup(
+        TROVE_METHOD_DBPF, file_system, &coll_id, NULL, &op_id);
     if (ret != -1) {
 	fprintf(stderr, "collection lookup succeeded before it should.\n");
 	return -1;
@@ -83,7 +85,8 @@ int main(int argc, char **argv)
      * but it's a good test i guess...
      */
     /* NOTE: can't test on this because we still don't know a coll_id */
-    ret = trove_collection_lookup(file_system, &coll_id, NULL, &op_id);
+    ret = trove_collection_lookup(
+        TROVE_METHOD_DBPF, file_system, &coll_id, NULL, &op_id);
     if (ret < 0) {
 	fprintf(stderr, "collection lookup failed.\n");
 	return -1;
@@ -142,7 +145,7 @@ int main(int argc, char **argv)
 	   ROOT_HANDLE_KEYSTR);
 
     trove_close_context(coll_id, trove_context);
-    trove_finalize();
+    trove_finalize(TROVE_METHOD_DBPF);
 
     return 0;
 }



More information about the Pvfs2-cvs mailing list