[rhmessaging-commits] rhmessaging commits: r2102 - in store/trunk: specs and 1 other directory.
rhmessaging-commits at lists.jboss.org
rhmessaging-commits at lists.jboss.org
Mon Jun 2 12:02:23 EDT 2008
Author: tedross
Date: 2008-06-02 12:02:23 -0400 (Mon, 02 Jun 2008)
New Revision: 2102
Modified:
store/trunk/cpp/lib/gen/qpid/management/Journal.cpp
store/trunk/cpp/lib/gen/qpid/management/Journal.h
store/trunk/cpp/lib/gen/qpid/management/Store.cpp
store/trunk/cpp/lib/gen/qpid/management/Store.h
store/trunk/specs/management-schema.xml
Log:
Update to match schema-generation changes in qpid
Modified: store/trunk/cpp/lib/gen/qpid/management/Journal.cpp
===================================================================
--- store/trunk/cpp/lib/gen/qpid/management/Journal.cpp 2008-06-02 14:29:56 UTC (rev 2101)
+++ store/trunk/cpp/lib/gen/qpid/management/Journal.cpp 2008-06-02 16:02:23 UTC (rev 2102)
@@ -36,7 +36,7 @@
string Journal::packageName = string ("mrgstore");
string Journal::className = string ("journal");
uint8_t Journal::md5Sum[16] =
- {0xef,0x11,0x33,0x24,0xfb,0x0,0x5e,0x3e,0xe5,0x3c,0x58,0x81,0x1f,0xfb,0x36,0x66};
+ {0xcd,0x98,0xdb,0x90,0xd7,0x0,0xc5,0x9f,0x17,0x0,0x50,0x0,0xfc,0xc2,0x45,0x86};
Journal::Journal (Manageable* _core) :
ManagementObject(_core)
@@ -99,12 +99,12 @@
buf.putShortString (packageName); // Package Name
buf.putShortString (className); // Class Name
buf.putBin128 (md5Sum); // Schema Hash
- buf.putShort (7); // Config Element Count
+ buf.putShort (8); // Config Element Count
buf.putShort (27); // Inst Element Count
buf.putShort (1); // Method Count
buf.putShort (0); // Event Count
- // Config Elements
+ // Properties
ft = FieldTable ();
ft.setString (NAME, "name");
ft.setInt (TYPE, TYPE_SSTR);
@@ -113,6 +113,13 @@
buf.put (ft);
ft = FieldTable ();
+ ft.setString (NAME, "queueRef");
+ ft.setInt (TYPE, TYPE_REF);
+ ft.setInt (ACCESS, ACCESS_RO);
+ ft.setInt (INDEX, 0);
+ buf.put (ft);
+
+ ft = FieldTable ();
ft.setString (NAME, "journalDirectory");
ft.setInt (TYPE, TYPE_SSTR);
ft.setInt (ACCESS, ACCESS_RO);
@@ -165,7 +172,7 @@
buf.put (ft);
- // Inst Elements
+ // Statistics
ft = FieldTable ();
ft.setString (NAME, "initialFileCount");
ft.setInt (TYPE, TYPE_U16);
@@ -382,6 +389,7 @@
writeTimestamps (buf);
buf.putShortString (name);
+ buf.putLongLong (queueRef);
buf.putShortString (journalDirectory);
buf.putShortString (journalBaseFileName);
buf.putLong (journalWritePageSize);
Modified: store/trunk/cpp/lib/gen/qpid/management/Journal.h
===================================================================
--- store/trunk/cpp/lib/gen/qpid/management/Journal.h 2008-06-02 14:29:56 UTC (rev 2101)
+++ store/trunk/cpp/lib/gen/qpid/management/Journal.h 2008-06-02 16:02:23 UTC (rev 2102)
@@ -27,6 +27,7 @@
#include "qpid/management/ManagementObject.h"
#include "qpid/framing/FieldTable.h"
#include "qpid/framing/Uuid.h"
+#include "qpid/sys/AtomicCount.h"
namespace qpid {
namespace management {
@@ -39,8 +40,9 @@
static std::string className;
static uint8_t md5Sum[16];
- // Configuration Elements
+ // Properties
std::string name;
+ uint64_t queueRef;
std::string journalDirectory;
std::string journalBaseFileName;
uint32_t journalWritePageSize;
@@ -48,7 +50,7 @@
uint32_t journalReadPageSize;
uint32_t journalReadPages;
- // Instrumentation Elements
+ // Statistics
uint16_t initialFileCount;
uint32_t dataFileSize;
uint32_t journalCurrentFileCount;
@@ -96,6 +98,9 @@
Journal (Manageable* coreObject);
~Journal (void);
+ void setReference(uint64_t objectId) { queueRef = objectId; }
+
+
std::string getPackageName (void) { return packageName; }
std::string getClassName (void) { return className; }
uint8_t* getMd5Sum (void) { return md5Sum; }
@@ -109,6 +114,11 @@
name = val;
configChanged = true;
}
+ inline void set_queueRef (uint64_t val){
+ sys::Mutex::ScopedLock mutex(accessLock);
+ queueRef = val;
+ configChanged = true;
+ }
inline void set_journalDirectory (std::string val){
sys::Mutex::ScopedLock mutex(accessLock);
journalDirectory = val;
@@ -155,13 +165,19 @@
instChanged = true;
}
inline void inc_journalRecordDepth (uint32_t by = 1){
- journalRecordDepth += by;
+ if (by == 1)
+ ++journalRecordDepth;
+ else
+ journalRecordDepth += by;
if (journalRecordDepthHigh < journalRecordDepth)
journalRecordDepthHigh = journalRecordDepth;
instChanged = true;
}
inline void dec_journalRecordDepth (uint32_t by = 1){
- journalRecordDepth -= by;
+ if (by == 1)
+ journalRecordDepth--;
+ else
+ journalRecordDepth -= by;
if (journalRecordDepthLow > journalRecordDepth)
journalRecordDepthLow = journalRecordDepth;
instChanged = true;
@@ -176,11 +192,17 @@
instChanged = true;
}
inline void inc_journalRecordEnqueues (uint64_t by = 1){
- journalRecordEnqueues += by;
+ if (by == 1)
+ ++journalRecordEnqueues;
+ else
+ journalRecordEnqueues += by;
instChanged = true;
}
inline void dec_journalRecordEnqueues (uint64_t by = 1){
- journalRecordEnqueues -= by;
+ if (by == 1)
+ journalRecordEnqueues--;
+ else
+ journalRecordEnqueues -= by;
instChanged = true;
}
inline void set_journalRecordEnqueues (uint64_t val){
@@ -189,11 +211,17 @@
instChanged = true;
}
inline void inc_journalRecordDequeues (uint64_t by = 1){
- journalRecordDequeues += by;
+ if (by == 1)
+ ++journalRecordDequeues;
+ else
+ journalRecordDequeues += by;
instChanged = true;
}
inline void dec_journalRecordDequeues (uint64_t by = 1){
- journalRecordDequeues -= by;
+ if (by == 1)
+ journalRecordDequeues--;
+ else
+ journalRecordDequeues -= by;
instChanged = true;
}
inline void set_journalRecordDequeues (uint64_t val){
@@ -202,13 +230,19 @@
instChanged = true;
}
inline void inc_journalOutstandingAIOs (uint32_t by = 1){
- journalOutstandingAIOs += by;
+ if (by == 1)
+ ++journalOutstandingAIOs;
+ else
+ journalOutstandingAIOs += by;
if (journalOutstandingAIOsHigh < journalOutstandingAIOs)
journalOutstandingAIOsHigh = journalOutstandingAIOs;
instChanged = true;
}
inline void dec_journalOutstandingAIOs (uint32_t by = 1){
- journalOutstandingAIOs -= by;
+ if (by == 1)
+ journalOutstandingAIOs--;
+ else
+ journalOutstandingAIOs -= by;
if (journalOutstandingAIOsLow > journalOutstandingAIOs)
journalOutstandingAIOsLow = journalOutstandingAIOs;
instChanged = true;
@@ -223,13 +257,19 @@
instChanged = true;
}
inline void inc_journalFreeFileCount (uint32_t by = 1){
- journalFreeFileCount += by;
+ if (by == 1)
+ ++journalFreeFileCount;
+ else
+ journalFreeFileCount += by;
if (journalFreeFileCountHigh < journalFreeFileCount)
journalFreeFileCountHigh = journalFreeFileCount;
instChanged = true;
}
inline void dec_journalFreeFileCount (uint32_t by = 1){
- journalFreeFileCount -= by;
+ if (by == 1)
+ journalFreeFileCount--;
+ else
+ journalFreeFileCount -= by;
if (journalFreeFileCountLow > journalFreeFileCount)
journalFreeFileCountLow = journalFreeFileCount;
instChanged = true;
@@ -244,13 +284,19 @@
instChanged = true;
}
inline void inc_journalAvailableFileCount (uint32_t by = 1){
- journalAvailableFileCount += by;
+ if (by == 1)
+ ++journalAvailableFileCount;
+ else
+ journalAvailableFileCount += by;
if (journalAvailableFileCountHigh < journalAvailableFileCount)
journalAvailableFileCountHigh = journalAvailableFileCount;
instChanged = true;
}
inline void dec_journalAvailableFileCount (uint32_t by = 1){
- journalAvailableFileCount -= by;
+ if (by == 1)
+ journalAvailableFileCount--;
+ else
+ journalAvailableFileCount -= by;
if (journalAvailableFileCountLow > journalAvailableFileCount)
journalAvailableFileCountLow = journalAvailableFileCount;
instChanged = true;
@@ -265,11 +311,17 @@
instChanged = true;
}
inline void inc_journalWriteWaitFailures (uint64_t by = 1){
- journalWriteWaitFailures += by;
+ if (by == 1)
+ ++journalWriteWaitFailures;
+ else
+ journalWriteWaitFailures += by;
instChanged = true;
}
inline void dec_journalWriteWaitFailures (uint64_t by = 1){
- journalWriteWaitFailures -= by;
+ if (by == 1)
+ journalWriteWaitFailures--;
+ else
+ journalWriteWaitFailures -= by;
instChanged = true;
}
inline void set_journalWriteWaitFailures (uint64_t val){
@@ -278,11 +330,17 @@
instChanged = true;
}
inline void inc_journalWriteBusyFailures (uint64_t by = 1){
- journalWriteBusyFailures += by;
+ if (by == 1)
+ ++journalWriteBusyFailures;
+ else
+ journalWriteBusyFailures += by;
instChanged = true;
}
inline void dec_journalWriteBusyFailures (uint64_t by = 1){
- journalWriteBusyFailures -= by;
+ if (by == 1)
+ journalWriteBusyFailures--;
+ else
+ journalWriteBusyFailures -= by;
instChanged = true;
}
inline void set_journalWriteBusyFailures (uint64_t val){
@@ -291,11 +349,17 @@
instChanged = true;
}
inline void inc_journalReadRecordCount (uint64_t by = 1){
- journalReadRecordCount += by;
+ if (by == 1)
+ ++journalReadRecordCount;
+ else
+ journalReadRecordCount += by;
instChanged = true;
}
inline void dec_journalReadRecordCount (uint64_t by = 1){
- journalReadRecordCount -= by;
+ if (by == 1)
+ journalReadRecordCount--;
+ else
+ journalReadRecordCount -= by;
instChanged = true;
}
inline void set_journalReadRecordCount (uint64_t val){
@@ -304,11 +368,17 @@
instChanged = true;
}
inline void inc_journalReadBusyFailures (uint64_t by = 1){
- journalReadBusyFailures += by;
+ if (by == 1)
+ ++journalReadBusyFailures;
+ else
+ journalReadBusyFailures += by;
instChanged = true;
}
inline void dec_journalReadBusyFailures (uint64_t by = 1){
- journalReadBusyFailures -= by;
+ if (by == 1)
+ journalReadBusyFailures--;
+ else
+ journalReadBusyFailures -= by;
instChanged = true;
}
inline void set_journalReadBusyFailures (uint64_t val){
@@ -317,13 +387,19 @@
instChanged = true;
}
inline void inc_journalWritePageCacheDepth (uint32_t by = 1){
- journalWritePageCacheDepth += by;
+ if (by == 1)
+ ++journalWritePageCacheDepth;
+ else
+ journalWritePageCacheDepth += by;
if (journalWritePageCacheDepthHigh < journalWritePageCacheDepth)
journalWritePageCacheDepthHigh = journalWritePageCacheDepth;
instChanged = true;
}
inline void dec_journalWritePageCacheDepth (uint32_t by = 1){
- journalWritePageCacheDepth -= by;
+ if (by == 1)
+ journalWritePageCacheDepth--;
+ else
+ journalWritePageCacheDepth -= by;
if (journalWritePageCacheDepthLow > journalWritePageCacheDepth)
journalWritePageCacheDepthLow = journalWritePageCacheDepth;
instChanged = true;
@@ -338,13 +414,19 @@
instChanged = true;
}
inline void inc_journalReadPageCacheDepth (uint32_t by = 1){
- journalReadPageCacheDepth += by;
+ if (by == 1)
+ ++journalReadPageCacheDepth;
+ else
+ journalReadPageCacheDepth += by;
if (journalReadPageCacheDepthHigh < journalReadPageCacheDepth)
journalReadPageCacheDepthHigh = journalReadPageCacheDepth;
instChanged = true;
}
inline void dec_journalReadPageCacheDepth (uint32_t by = 1){
- journalReadPageCacheDepth -= by;
+ if (by == 1)
+ journalReadPageCacheDepth--;
+ else
+ journalReadPageCacheDepth -= by;
if (journalReadPageCacheDepthLow > journalReadPageCacheDepth)
journalReadPageCacheDepthLow = journalReadPageCacheDepth;
instChanged = true;
Modified: store/trunk/cpp/lib/gen/qpid/management/Store.cpp
===================================================================
--- store/trunk/cpp/lib/gen/qpid/management/Store.cpp 2008-06-02 14:29:56 UTC (rev 2101)
+++ store/trunk/cpp/lib/gen/qpid/management/Store.cpp 2008-06-02 16:02:23 UTC (rev 2102)
@@ -35,7 +35,7 @@
string Store::packageName = string ("mrgstore");
string Store::className = string ("store");
uint8_t Store::md5Sum[16] =
- {0x67,0x86,0x77,0xd2,0x1e,0x27,0x3e,0x46,0xf9,0xec,0x38,0xa4,0x9a,0xf5,0xf9,0x89};
+ {0x91,0xcf,0xc4,0xa7,0x9b,0x4a,0x2a,0x88,0x32,0x6f,0xef,0xec,0x82,0xd7,0x12,0x6a};
Store::Store (Manageable* _core, Manageable* _parent) :
ManagementObject(_core)
@@ -76,7 +76,7 @@
buf.putShort (0); // Method Count
buf.putShort (0); // Event Count
- // Config Elements
+ // Properties
ft = FieldTable ();
ft.setString (NAME, "brokerRef");
ft.setInt (TYPE, TYPE_REF);
@@ -119,7 +119,7 @@
buf.put (ft);
- // Inst Elements
+ // Statistics
// Methods
Modified: store/trunk/cpp/lib/gen/qpid/management/Store.h
===================================================================
--- store/trunk/cpp/lib/gen/qpid/management/Store.h 2008-06-02 14:29:56 UTC (rev 2101)
+++ store/trunk/cpp/lib/gen/qpid/management/Store.h 2008-06-02 16:02:23 UTC (rev 2102)
@@ -27,6 +27,7 @@
#include "qpid/management/ManagementObject.h"
#include "qpid/framing/FieldTable.h"
#include "qpid/framing/Uuid.h"
+#include "qpid/sys/AtomicCount.h"
namespace qpid {
namespace management {
@@ -39,14 +40,14 @@
static std::string className;
static uint8_t md5Sum[16];
- // Configuration Elements
+ // Properties
uint64_t brokerRef;
std::string location;
uint8_t async;
uint16_t defaultInitialFileCount;
uint32_t defaultDataFileSize;
- // Instrumentation Elements
+ // Statistics
// Private Methods
static void writeSchema (qpid::framing::Buffer& buf);
@@ -69,6 +70,8 @@
Store (Manageable* coreObject, Manageable* _parent);
~Store (void);
+
+
std::string getPackageName (void) { return packageName; }
std::string getClassName (void) { return className; }
uint8_t* getMd5Sum (void) { return md5Sum; }
Modified: store/trunk/specs/management-schema.xml
===================================================================
--- store/trunk/specs/management-schema.xml 2008-06-02 14:29:56 UTC (rev 2101)
+++ store/trunk/specs/management-schema.xml 2008-06-02 16:02:23 UTC (rev 2102)
@@ -3,42 +3,43 @@
<!--
License Text
-->
- <class name="store">
- <configElement name="brokerRef" type="objId" access="RO" index="y" parentRef="y"/>
- <configElement name="location" type="sstr" access="RO" desc="Logical directory on disk"/>
- <configElement name="async" type="bool" access="RO" desc="Asynchronous IO"/>
- <configElement name="defaultInitialFileCount" type="uint16" access="RO" unit="file" desc="Default number of files initially allocated to each journal"/>
- <configElement name="defaultDataFileSize" type="uint32" access="RO" unit="RdPg" desc="Default size of each journal data file"/>
+ <class name="Store">
+ <property name="brokerRef" type="objId" references="qpid.Broker" access="RO" index="y" parentRef="y"/>
+ <property name="location" type="sstr" access="RO" desc="Logical directory on disk"/>
+ <property name="async" type="bool" access="RO" desc="Asynchronous IO"/>
+ <property name="defaultInitialFileCount" type="uint16" access="RO" unit="file" desc="Default number of files initially allocated to each journal"/>
+ <property name="defaultDataFileSize" type="uint32" access="RO" unit="RdPg" desc="Default size of each journal data file"/>
</class>
- <class name="journal">
- <configElement name="name" type="sstr" access="RO" index="y"/>
- <configElement name="journalDirectory" type="sstr" access="RO" desc="Directory containing journal files"/>
- <configElement name="journalBaseFileName" type="sstr" access="RO" desc="Base filename prefix for journal"/>
- <configElement name="journalWritePageSize" type="uint32" access="RO" unit="byte" desc="Page size in write-page-cache"/>
- <configElement name="journalWritePages" type="uint32" access="RO" unit="wpage" desc="Number of pages in write-page-cache"/>
- <configElement name="journalReadPageSize" type="uint32" access="RO" unit="byte" desc="Page size in read-page-cache"/>
- <configElement name="journalReadPages" type="uint32" access="RO" unit="rpage" desc="Number of pages in read-page-cache"/>
+ <class name="Journal">
+ <property name="name" type="sstr" access="RO" index="y"/>
+ <property name="queueRef" type="objId" access="RO" references="qpid.Queue" isGeneralReference="y"/>
+ <property name="journalDirectory" type="sstr" access="RO" desc="Directory containing journal files"/>
+ <property name="journalBaseFileName" type="sstr" access="RO" desc="Base filename prefix for journal"/>
+ <property name="journalWritePageSize" type="uint32" access="RO" unit="byte" desc="Page size in write-page-cache"/>
+ <property name="journalWritePages" type="uint32" access="RO" unit="wpage" desc="Number of pages in write-page-cache"/>
+ <property name="journalReadPageSize" type="uint32" access="RO" unit="byte" desc="Page size in read-page-cache"/>
+ <property name="journalReadPages" type="uint32" access="RO" unit="rpage" desc="Number of pages in read-page-cache"/>
- <instElement name="initialFileCount" type="uint16" unit="file" desc="Number of files initially allocated to this journal"/>
- <instElement name="dataFileSize" type="uint32" unit="byte" desc="Size of each journal data file"/>
- <instElement name="journalCurrentFileCount" type="uint32" unit="file" desc="Number of files currently allocated to this journal"/>
- <instElement name="journalRecordDepth" type="hilo32" unit="record" desc="Number of enqueued records (durable messages)"/>
- <instElement name="journalRecordEnqueues" type="count64" unit="record" desc="Total enqueued records on journal"/>
- <instElement name="journalRecordDequeues" type="count64" unit="record" desc="Total dequeued records on journal"/>
- <instElement name="journalOutstandingAIOs" type="hilo32" unit="aio_op" desc="Number of outstanding AIO requests in Async IO system"/>
+ <statistic name="initialFileCount" type="uint16" unit="file" desc="Number of files initially allocated to this journal"/>
+ <statistic name="dataFileSize" type="uint32" unit="byte" desc="Size of each journal data file"/>
+ <statistic name="journalCurrentFileCount" type="uint32" unit="file" desc="Number of files currently allocated to this journal"/>
+ <statistic name="journalRecordDepth" type="hilo32" unit="record" desc="Number of enqueued records (durable messages)"/>
+ <statistic name="journalRecordEnqueues" type="count64" unit="record" desc="Total enqueued records on journal"/>
+ <statistic name="journalRecordDequeues" type="count64" unit="record" desc="Total dequeued records on journal"/>
+ <statistic name="journalOutstandingAIOs" type="hilo32" unit="aio_op" desc="Number of outstanding AIO requests in Async IO system"/>
<!--
The following are not yet "wired up" in JournalImpl.cpp
-->
- <instElement name="journalFreeFileCount" type="hilo32" unit="file" desc="Number of files free on this journal. Includes free files trapped in holes."/>
- <instElement name="journalAvailableFileCount" type="hilo32" unit="file" desc="Number of files available to be written. Excluding holes"/>
- <instElement name="journalWriteWaitFailures" type="count64" unit="record" desc="AIO Wait failures on write"/>
- <instElement name="journalWriteBusyFailures" type="count64" unit="record" desc="AIO Busy failures on write"/>
- <instElement name="journalReadRecordCount" type="count64" unit="record" desc="Records read from the journal"/>
- <instElement name="journalReadBusyFailures" type="count64" unit="record" desc="AIO Busy failures on read"/>
- <instElement name="journalWritePageCacheDepth" type="hilo32" unit="wpage" desc="Current depth of write-page-cache"/>
- <instElement name="journalReadPageCacheDepth" type="hilo32" unit="rpage" desc="Current depth of read-page-cache"/>
+ <statistic name="journalFreeFileCount" type="hilo32" unit="file" desc="Number of files free on this journal. Includes free files trapped in holes."/>
+ <statistic name="journalAvailableFileCount" type="hilo32" unit="file" desc="Number of files available to be written. Excluding holes"/>
+ <statistic name="journalWriteWaitFailures" type="count64" unit="record" desc="AIO Wait failures on write"/>
+ <statistic name="journalWriteBusyFailures" type="count64" unit="record" desc="AIO Busy failures on write"/>
+ <statistic name="journalReadRecordCount" type="count64" unit="record" desc="Records read from the journal"/>
+ <statistic name="journalReadBusyFailures" type="count64" unit="record" desc="AIO Busy failures on read"/>
+ <statistic name="journalWritePageCacheDepth" type="hilo32" unit="wpage" desc="Current depth of write-page-cache"/>
+ <statistic name="journalReadPageCacheDepth" type="hilo32" unit="rpage" desc="Current depth of read-page-cache"/>
<method name="expand" desc="Increase number of files allocated for this journal">
<arg name="by" type="uint32" dir="I" desc="Number of files to increase journal size by"/>
More information about the rhmessaging-commits
mailing list