[rhmessaging-commits] rhmessaging commits: r4450 - in store/trunk/cpp: lib and 1 other directory.

rhmessaging-commits at lists.jboss.org rhmessaging-commits at lists.jboss.org
Tue Apr 12 10:46:51 EDT 2011


Author: kpvdr
Date: 2011-04-12 10:46:51 -0400 (Tue, 12 Apr 2011)
New Revision: 4450

Modified:
   store/trunk/cpp/configure.ac
   store/trunk/cpp/lib/MessageStoreImpl.cpp
Log:
Updated store help to include the store file size and number limits. Fixed error text for when qpid lib headers are not found.

Modified: store/trunk/cpp/configure.ac
===================================================================
--- store/trunk/cpp/configure.ac	2011-03-30 16:03:06 UTC (rev 4449)
+++ store/trunk/cpp/configure.ac	2011-04-12 14:46:51 UTC (rev 4450)
@@ -117,7 +117,7 @@
     fail=1
   # Give any/all diagnostics before failing.
   test $fail = 1 &&
-    AC_MSG_ERROR([Missing required qpid libraries/headers. Install package qpidd-devel or use --with-qpid-checkout])
+    AC_MSG_ERROR([Missing required qpid libraries/headers. Install source rpms or use one of --with-qpid-checkout or --with-qpid-prefix])
   QPID_CXXFLAGS="-I$QPID_INCLUDE"
   QPID_LIBS="-L$QPID_LIB -lqpidbroker -lqpidcommon"
 fi

Modified: store/trunk/cpp/lib/MessageStoreImpl.cpp
===================================================================
--- store/trunk/cpp/lib/MessageStoreImpl.cpp	2011-03-30 16:03:06 UTC (rev 4449)
+++ store/trunk/cpp/lib/MessageStoreImpl.cpp	2011-04-12 14:46:51 UTC (rev 4450)
@@ -1684,20 +1684,30 @@
                                              tplJrnlFsizePgs(defTplJrnlFileSizePgs),
                                              tplWCachePageSizeKib(defTplWCachePageSize)
 {
+    std::ostringstream oss1;
+    oss1 << "Default number of files for each journal instance (queue). [Allowable values: " <<
+                    JRNL_MIN_NUM_FILES << " - " << JRNL_MAX_NUM_FILES << "]";
+    std::ostringstream oss2;
+    oss2 << "Default size for each journal file in multiples of read pages (1 read page = 64kiB). [Allowable values: " <<
+                    JRNL_MIN_FILE_SIZE / JRNL_RMGR_PAGE_SIZE << " - " << JRNL_MAX_FILE_SIZE / JRNL_RMGR_PAGE_SIZE << "]";
+    std::ostringstream oss3;
+    oss3 << "Number of files for transaction prepared list journal instance. [Allowable values: " <<
+                    JRNL_MIN_NUM_FILES << " - " << JRNL_MAX_NUM_FILES << "]";
+    std::ostringstream oss4;
+    oss4 << "Size of each transaction prepared list journal file in multiples of read pages (1 read page = 64kiB) [Allowable values: " <<
+                    JRNL_MIN_FILE_SIZE / JRNL_RMGR_PAGE_SIZE << " - " << JRNL_MAX_FILE_SIZE / JRNL_RMGR_PAGE_SIZE << "]";
     addOptions()
         ("store-dir", qpid::optValue(storeDir, "DIR"),
                 "Store directory location for persistence (instead of using --data-dir value). "
                 "Required if --no-data-dir is also used.")
-        ("num-jfiles", qpid::optValue(numJrnlFiles, "N"),
-                "Default number of files for each journal instance (queue).")
+        ("num-jfiles", qpid::optValue(numJrnlFiles, "N"), oss1.str().c_str())
+        ("jfile-size-pgs", qpid::optValue(jrnlFsizePgs, "N"), oss2.str().c_str())
 // TODO: Uncomment these lines when auto-expand is enabled.
 //         ("auto-expand", qpid::optValue(autoJrnlExpand, "yes|no"),
 //                 "If yes|true|1, allows journal to auto-expand by adding additional journal files as needed. "
 //                 "If no|false|0, the number of journal files will remain fixed (num-jfiles).")
 //         ("max-auto-expand-jfiles", qpid::optValue(autoJrnlExpandMaxFiles, "N"),
 //                 "Maximum number of journal files allowed from auto-expanding; must be greater than --num-jfiles parameter.")
-         ("jfile-size-pgs", qpid::optValue(jrnlFsizePgs, "N"),
-                "Default size for each journal file in multiples of read pages (1 read page = 64kiB)")
         ("truncate", qpid::optValue(truncateFlag, "yes|no"),
                 "If yes|true|1, will truncate the store (discard any existing records). If no|false|0, will preserve "
                 "the existing store files for recovery.")
@@ -1705,10 +1715,8 @@
                 "Size of the pages in the write page cache in KiB. "
                 "Allowable values - powers of 2: 1, 2, 4, ... , 128. "
                 "Lower values decrease latency at the expense of throughput.")
-        ("tpl-num-jfiles", qpid::optValue(tplNumJrnlFiles, "N"),
-                "Number of files for transaction prepared list journal instance")
-        ("tpl-jfile-size-pgs", qpid::optValue(tplJrnlFsizePgs, "N"),
-                "Size of each transaction prepared list journal file in multiples of read pages (1 read page = 64kiB)")
+        ("tpl-num-jfiles", qpid::optValue(tplNumJrnlFiles, "N"), oss3.str().c_str())
+        ("tpl-jfile-size-pgs", qpid::optValue(tplJrnlFsizePgs, "N"), oss4.str().c_str())
         ("tpl-wcache-page-size", qpid::optValue(tplWCachePageSizeKib, "N"),
                 "Size of the pages in the transaction prepared list write page cache in KiB. "
                 "Allowable values - powers of 2: 1, 2, 4, ... , 128. "



More information about the rhmessaging-commits mailing list