summaryrefslogtreecommitdiffstats
path: root/src/H5Oprivate.h
diff options
context:
space:
mode:
authorJohn Mainzer <mainzer@hdfgroup.org>2008-02-18 05:28:04 (GMT)
committerJohn Mainzer <mainzer@hdfgroup.org>2008-02-18 05:28:04 (GMT)
commitcd571e4a45e5af71ae608388141e6b28a16f8171 (patch)
tree27a6b76035cd03c2b13946730225b34f0f03d98d /src/H5Oprivate.h
parentd3e926b897b42d27e1c5f8533a8a413c448738e2 (diff)
downloadhdf5-cd571e4a45e5af71ae608388141e6b28a16f8171.zip
hdf5-cd571e4a45e5af71ae608388141e6b28a16f8171.tar.gz
hdf5-cd571e4a45e5af71ae608388141e6b28a16f8171.tar.bz2
[svn-r14594] Ported flash cache size increase code into the journaling branch --
note that both the H5C and H5C2 code have been updated. Also checked in code to track journaling status in the super block. Note that this code has not been tested -- but as best I can tell, it does not break the existing regression tests. Tested serial (debug and production) on Phoenix. Also tested parallel on kagiso. Note that regression test fails on kagiso (but not on phoenix) if the cache2 serial tests are configured to use the core file driver. Thus this code is check in with the core file driver optimization of the cache2 tests disabled. To turn it on, set the USE_CORE_DRIVER #define to TRUE.
Diffstat (limited to 'src/H5Oprivate.h')
-rw-r--r--src/H5Oprivate.h59
1 files changed, 58 insertions, 1 deletions
diff --git a/src/H5Oprivate.h b/src/H5Oprivate.h
index 31738a9..3188468 100644
--- a/src/H5Oprivate.h
+++ b/src/H5Oprivate.h
@@ -62,6 +62,8 @@ typedef struct H5O_t H5O_t;
#define H5O_FHEAP_MAX_MAN_SIZE (4 * 1024)
#define H5O_FHEAP_ID_LEN 8
+/* #define H5O_ENABLE_BOGUS 1 */
+
/* Object header macros */
#define H5O_MESG_MAX_SIZE 65536 /*max obj header message size */
#define H5O_ALL (-1) /* Operate on all messages of type */
@@ -160,7 +162,8 @@ typedef struct H5O_copy_t {
#define H5O_DRVINFO_ID 0x0014 /* Driver info message. */
#define H5O_AINFO_ID 0x0015 /* Attribute info message. */
#define H5O_REFCOUNT_ID 0x0016 /* Reference count message. */
-#define H5O_UNKNOWN_ID 0x0017 /* Placeholder message ID for unknown message. */
+#define H5O_MDJ_CONF_ID 0x0017 /* Metadata journaling config message */
+#define H5O_UNKNOWN_ID 0x0018 /* Placeholder message ID for unknown message. */
/* (this should never exist in a file) */
@@ -491,6 +494,60 @@ typedef struct H5O_ainfo_t {
*/
typedef uint32_t H5O_refcount_t; /* Contains # of links to object, if >1 */
+
+/*
+ * Metadata journaling configuration message
+ *
+ * Information on whether and how metadata changes are being journaled,
+ * so as to reconstruct consistent metadata in the file in the event of
+ * a crash, stored in a superblock extension
+ * (Data structure in memory)
+ *
+ * The fields of the H5O_mdj_conf_t structure are discussed individually
+ * below:
+ *
+ * journaling_enabled: Boolean flag indicating whether metadata journaling
+ * is currently enabled.
+ *
+ * journal_is_external: Boolean flag indicating whether the journal is
+ * stored in an external file, or within the HDF5 file.
+ *
+ * If the field is TRUE, external_journal_file_path points to a
+ * buffer containing the path to the external journal file, and
+ * internal_journal_loc is undefined.
+ *
+ * If the field is FALSE, internal_journal_loc contains the base
+ * address of the journal within the hdf5 file, and
+ * external_journal_file_path_ptr must be NULL.
+ *
+ * At least for the initial implementation, journal_is_external
+ * will always be TRUE.
+ *
+ * internal_journal_loc: haddr_t containing the base address of the
+ * interal journal -- if there is one, or undefined if there
+ * isn't (see discussion of journal_is_external above).
+ *
+ * path_len: size_t containing the size of the buffer needed to
+ * contain the path to the external journal file. This field
+ * must contain 0 if the journal is internal.
+ *
+ * external_journal_file_path_ptr: Pointer to uint8_t. If the
+ * journal is stored in an external file, this field points to
+ * a buffer containing the path to this file.
+ *
+ * If the journal is internal, this field must be NULL.
+ */
+typedef struct H5O_mdj_conf_t {
+
+ hbool_t journaling_enabled;
+ hbool_t journal_is_external;
+ haddr_t internal_journal_loc;
+ size_t path_len;
+ uint8_t * external_journal_file_path_ptr;
+
+} H5O_mdj_conf_t;
+
+
/*
* "Unknown" Message.
* (Data structure in memory)