rhmessaging commits: r1908 - in store/trunk/cpp: tests and 1 other directory.
by rhmessaging-commits@lists.jboss.org
Author: kpvdr
Date: 2008-04-14 13:05:54 -0400 (Mon, 14 Apr 2008)
New Revision: 1908
Modified:
store/trunk/cpp/configure.ac
store/trunk/cpp/rhm.spec.in
store/trunk/cpp/tests/system_test.sh
Log:
Packaging fixes. Removed cppunit checks and rpm dependencies. Added check for db4-devel (BZ438378). Added a "--auth no" to system tests broker start.
Modified: store/trunk/cpp/configure.ac
===================================================================
--- store/trunk/cpp/configure.ac 2008-04-14 16:16:58 UTC (rev 1907)
+++ store/trunk/cpp/configure.ac 2008-04-14 17:05:54 UTC (rev 1908)
@@ -106,7 +106,7 @@
AC_CHECK_LIB([aio], [io_setup], ,[libaio_fail=1])
AC_CHECK_HEADER([libaio.h], ,[libaio_fail=1])
test $libaio_fail == 1 && \
- AC_MSG_ERROR([libaio-devel package missing. Please ensure both libaio and libaio-devel are installed. (hint: yum install libaio-devel should do it...)])
+ AC_MSG_ERROR([libaio-devel package missing. Please ensure both libaio and libaio-devel are installed. (hint: "yum install libaio-devel" should do it...)])
# For libraries (libcommon) that use dlopen, dlerror, etc.,
# test whether we need to link with -ldl.
@@ -118,6 +118,11 @@
LIBS=$gl_saved_libs
# Require libdb_cxx-4.3, for the library, and for db_cxx.h.
+db4_devel_fail=0
+AC_CHECK_HEADER([db_cxx.h], ,[db4_devel_fail=1])
+test $db4_devel_fail == 1 && \
+ AC_MSG_ERROR([db4-devel package missing. Please ensure both db4 and db4-devel are installed. (hint: "yum install db4-devel" should do it...)])
+
gl_saved_libs=$LIBS
AC_SEARCH_LIBS([__db_open], [db_cxx-4.6 db_cxx-4.5 db_cxx-4.4 db_cxx-4.3],
[test "$ac_cv_search___db_open" = "none required" ||
@@ -145,13 +150,6 @@
gl_CLOCK_TIME
-# Check for cppunit support.
-CPPUNIT_MINIMUM_VERSION=1.10.2
-AM_PATH_CPPUNIT([$CPPUNIT_MINIMUM_VERSION], , [CPPUNIT_LIBS=-lcppunit])
-CPPUNIT_CXXFLAGS=$CPPUNIT_CFLAGS
-AC_SUBST(CPPUNIT_LIBS)
-AC_SUBST(CPPUNIT_CXXFLAGS)
-
AC_ARG_ENABLE([apr-platform],
[AS_HELP_STRING([--enable-apr-platform],
[use the Apache Portable Runtime library for platform (default no)])],
Modified: store/trunk/cpp/rhm.spec.in
===================================================================
--- store/trunk/cpp/rhm.spec.in 2008-04-14 16:16:58 UTC (rev 1907)
+++ store/trunk/cpp/rhm.spec.in 2008-04-14 17:05:54 UTC (rev 1908)
@@ -3,7 +3,7 @@
#
Name: rhm
Version: @VERSION@
-Release: 19%{?dist}
+Release: 20%{?dist}
Summary: Red Hat extensions to the Qpid messaging system
Group: System Environment/Libraries
License: LGPL
@@ -20,7 +20,6 @@
# when qpid-devel is updated.
BuildRequires: e2fsprogs-devel
BuildRequires: libaio-devel
-BuildRequires: cppunit-devel
BuildRequires: python
Requires: qpidd
@@ -87,6 +86,9 @@
%changelog
+* Mon Apr 14 2008 Kim van der Riet <kim.vdriet(a)redhat.com> - 0.2-20
+- removed cppunit as build dependency - all tests now boost test
+
* Fri Apr 11 2008 Kim van der Riet <kim.vdriet(a)redhat.com> - 0.2-19
- added python package as build dependency
Modified: store/trunk/cpp/tests/system_test.sh
===================================================================
--- store/trunk/cpp/tests/system_test.sh 2008-04-14 16:16:58 UTC (rev 1907)
+++ store/trunk/cpp/tests/system_test.sh 2008-04-14 17:05:54 UTC (rev 1908)
@@ -75,7 +75,7 @@
for p in `seq 1 8`; do
log="$abs_srcdir/vg-log.$mode.$p"
#echo "$vg $QPIDD -m 0 --data dir "" --load-module $LIBBDBSTORE $JRNLFLAGS"
- $vg $QPIDD -m 0 --data-dir "" --load-module $LIBBDBSTORE $JRNLFLAGS >> "$abs_srcdir/qpid.log" 2> $log & pid=$!
+ $vg $QPIDD -m 0 --data-dir "" --load-module $LIBBDBSTORE --auth no $JRNLFLAGS >> "$abs_srcdir/qpid.log" 2> $log & pid=$!
sleep 5
echo phase $p...
16 years, 8 months
rhmessaging commits: r1907 - mgmt/cumin/python/wooly.
by rhmessaging-commits@lists.jboss.org
Author: justi9
Date: 2008-04-14 12:16:58 -0400 (Mon, 14 Apr 2008)
New Revision: 1907
Modified:
mgmt/cumin/python/wooly/server.py
Log:
Set the content length on 30x responses
Modified: mgmt/cumin/python/wooly/server.py
===================================================================
--- mgmt/cumin/python/wooly/server.py 2008-04-14 15:47:46 UTC (rev 1906)
+++ mgmt/cumin/python/wooly/server.py 2008-04-14 16:16:58 UTC (rev 1907)
@@ -68,7 +68,8 @@
redirect = page.get_redirect_url(session)
if redirect:
- respond("303 See Other", (("Location", redirect),))
+ respond("303 See Other", (("Location", redirect),
+ ("Content-Length", "0")))
return ()
ims = env.get("HTTP_IF_MODIFIED_SINCE")
@@ -78,7 +79,7 @@
since = datetime(*strptime(str(ims), self.http_date)[0:6])
if modified <= since:
- respond("304 Not Modified", ())
+ respond("304 Not Modified", (("Content-Length", "0"),))
return ()
try:
16 years, 8 months
rhmessaging commits: r1906 - mgmt/cumin/python/wooly.
by rhmessaging-commits@lists.jboss.org
Author: justi9
Date: 2008-04-14 11:47:46 -0400 (Mon, 14 Apr 2008)
New Revision: 1906
Modified:
mgmt/cumin/python/wooly/server.py
Log:
A couple changes that make the web server faster.
Restore if-modified-since support under the new web server.
Set the content length on response and thus avoid the slightly slower
chunked-encoding path.
Modified: mgmt/cumin/python/wooly/server.py
===================================================================
--- mgmt/cumin/python/wooly/server.py 2008-04-14 14:23:46 UTC (rev 1905)
+++ mgmt/cumin/python/wooly/server.py 2008-04-14 15:47:46 UTC (rev 1906)
@@ -37,8 +37,8 @@
session.unmarshal_url_vars(env["QUERY_STRING"])
if "HTTP_AUTHORIZATION" in env:
- str = env["HTTP_AUTHORIZATION"].split(" ")[1]
- name, password = decodestring(str).split(":", 1)
+ auth = env["HTTP_AUTHORIZATION"].split(" ")[1]
+ name, password = decodestring(auth).split(":", 1)
session.credentials["name"] = name
session.credentials["password"] = password
@@ -68,20 +68,18 @@
redirect = page.get_redirect_url(session)
if redirect:
- respond("303 See Other", [("Location", redirect)])
+ respond("303 See Other", (("Location", redirect),))
return ()
-# ims = self.headers.getheader("if-modified-since")
-# modified = page.get_last_modified(session).replace \
-# (microsecond=0)
+ ims = env.get("HTTP_IF_MODIFIED_SINCE")
+ modified = page.get_last_modified(session).replace(microsecond=0)
-# if ims:
-# since = datetime(*strptime(str(ims), self.http_date)[0:6])
+ if ims:
+ since = datetime(*strptime(str(ims), self.http_date)[0:6])
-# if modified <= since:
-# self.send_response(304)
-# self.end_headers()
-# return
+ if modified <= since:
+ respond("304 Not Modified", ())
+ return ()
try:
response = page.render(session)
@@ -89,10 +87,11 @@
return self.error(session, respond)
headers = list()
+ headers.append(("Content-Length", str(len(response))))
-# if modified:
-# ts = modified.strftime("%a, %d %b %Y %H:%M:%S GMT")
-# list.append(("Last-Modified", ts))
+ if modified:
+ ts = modified.strftime("%a, %d %b %Y %H:%M:%S GMT")
+ headers.append(("Last-Modified", ts))
type = page.get_content_type(session)
16 years, 8 months
rhmessaging commits: r1905 - store/trunk/cpp/tests.
by rhmessaging-commits@lists.jboss.org
Author: gordonsim
Date: 2008-04-14 10:23:46 -0400 (Mon, 14 Apr 2008)
New Revision: 1905
Modified:
store/trunk/cpp/tests/persistence.py
Log:
Use PLAIN rather than the unsupported and non-standard AMQPLAIN
Modified: store/trunk/cpp/tests/persistence.py
===================================================================
--- store/trunk/cpp/tests/persistence.py 2008-04-11 20:02:49 UTC (rev 1904)
+++ store/trunk/cpp/tests/persistence.py 2008-04-14 14:23:46 UTC (rev 1905)
@@ -416,7 +416,7 @@
def connect(self):
""" Connects to the broker """
self.client = qpid.client.Client(self.host, self.port, qpid.spec.load(self.spec, *self.errata))
- self.client.start({"LOGIN": self.user, "PASSWORD": self.password})
+ self.client.start("\x00" + self.user + "\x00" + self.password, mechanism="PLAIN")
self.channel = self.client.channel(1)
self.channel.session_open()
16 years, 8 months
rhmessaging commits: r1904 - mgmt/cumin/python/cumin.
by rhmessaging-commits@lists.jboss.org
Author: justi9
Date: 2008-04-11 16:02:49 -0400 (Fri, 11 Apr 2008)
New Revision: 1904
Modified:
mgmt/cumin/python/cumin/model.py
Log:
Brokers don't have name attrs
Modified: mgmt/cumin/python/cumin/model.py
===================================================================
--- mgmt/cumin/python/cumin/model.py 2008-04-11 19:38:47 UTC (rev 1903)
+++ mgmt/cumin/python/cumin/model.py 2008-04-11 20:02:49 UTC (rev 1904)
@@ -531,6 +531,9 @@
reg = broker.registrations[0]
return self.cumin_model.show_main(session).show_broker(session, reg)
+ def get_object_name(self, broker):
+ return broker.id
+
class CuminQueue(RemoteClass):
def __init__(self, model):
super(CuminQueue, self).__init__(model, "queue", Queue, QueueStats)
16 years, 9 months
rhmessaging commits: r1903 - in store/trunk: cpp/lib/gen/qpid/management and 2 other directories.
by rhmessaging-commits@lists.jboss.org
Author: kpvdr
Date: 2008-04-11 15:38:47 -0400 (Fri, 11 Apr 2008)
New Revision: 1903
Modified:
store/trunk/cpp/lib/JournalImpl.cpp
store/trunk/cpp/lib/gen/qpid/management/Journal.cpp
store/trunk/cpp/lib/gen/qpid/management/Journal.h
store/trunk/cpp/lib/jrnl/jcntl.cpp
store/trunk/specs/management-schema.xml
Log:
Minor management changes for the journal which take advantage of the new hilo set functions from the new generator. Adjusted some units in management schema.
Modified: store/trunk/cpp/lib/JournalImpl.cpp
===================================================================
--- store/trunk/cpp/lib/JournalImpl.cpp 2008-04-11 15:20:16 UTC (rev 1902)
+++ store/trunk/cpp/lib/JournalImpl.cpp 2008-04-11 19:38:47 UTC (rev 1903)
@@ -181,8 +181,8 @@
}
}
std::ostringstream oss2;
- oss2 << "Recover complete; highest rid found = 0x" << std::hex << highest_rid << std::dec;
- oss2 << "; emap.size=" << _emap.size() << "; tmap.size=" << _tmap.size();
+ oss2 << "Recover phase I complete; highest rid found = 0x" << std::hex << highest_rid;
+ oss2 << std::dec << "; emap.size=" << _emap.size() << "; tmap.size=" << _tmap.size();
log(LOG_DEBUG, oss2.str());
if (_mgmtObject.get() != 0)
@@ -190,9 +190,7 @@
_mgmtObject->set_initialFileCount(_num_jfiles);
_mgmtObject->set_dataFileSize(_jfsize_sblks * JRNL_SBLK_SIZE * JRNL_DBLK_SIZE);
_mgmtObject->set_journalCurrentFileCount(_num_jfiles);
-
- //TODO - swap this with a set method as soon as it becomes available in the generated code.
- _mgmtObject->inc_journalRecordDepth(_emap.size());
+ _mgmtObject->set_journalRecordDepth(_emap.size());
}
}
@@ -465,7 +463,7 @@
_mgmtObject->set_initialFileCount(_num_jfiles);
_mgmtObject->set_dataFileSize(_jfsize_sblks * JRNL_SBLK_SIZE * JRNL_DBLK_SIZE);
_mgmtObject->set_journalCurrentFileCount(_num_jfiles);
- //TODO - set record depth to 0 when set function becomes available.
+ _mgmtObject->set_journalRecordDepth(0);
}
}
Modified: store/trunk/cpp/lib/gen/qpid/management/Journal.cpp
===================================================================
--- store/trunk/cpp/lib/gen/qpid/management/Journal.cpp 2008-04-11 15:20:16 UTC (rev 1902)
+++ store/trunk/cpp/lib/gen/qpid/management/Journal.cpp 2008-04-11 19:38:47 UTC (rev 1903)
@@ -37,7 +37,7 @@
string Journal::packageName = string ("mrgstore");
string Journal::className = string ("journal");
uint8_t Journal::md5Sum[16] =
- {0x7f,0x89,0x7d,0x90,0xac,0xec,0x28,0xb2,0x5a,0xe3,0x4a,0xea,0xf4,0x79,0xee,0xbe};
+ {0xce,0x1f,0xf,0xaa,0xec,0x9,0x32,0x8,0x4d,0xb1,0x98,0x2e,0x8d,0x5d,0xa4,0xaf};
Journal::Journal (Manageable* _core) :
ManagementObject(_core)
@@ -226,21 +226,21 @@
ft = FieldTable ();
ft.setString (NAME, "journalOutstandingAIOs");
ft.setInt (TYPE, TYPE_U32);
- ft.setString (UNIT, "record");
+ ft.setString (UNIT, "aio_op");
ft.setString (DESC, "Number of outstanding AIO requests in Async IO system");
buf.put (ft);
ft = FieldTable ();
ft.setString (NAME, "journalOutstandingAIOsHigh");
ft.setInt (TYPE, TYPE_U32);
- ft.setString (UNIT, "record");
+ ft.setString (UNIT, "aio_op");
ft.setString (DESC, "Number of outstanding AIO requests in Async IO system (High)");
buf.put (ft);
ft = FieldTable ();
ft.setString (NAME, "journalOutstandingAIOsLow");
ft.setInt (TYPE, TYPE_U32);
- ft.setString (UNIT, "record");
+ ft.setString (UNIT, "aio_op");
ft.setString (DESC, "Number of outstanding AIO requests in Async IO system (Low)");
buf.put (ft);
@@ -317,42 +317,42 @@
ft = FieldTable ();
ft.setString (NAME, "journalWritePageCacheDepth");
ft.setInt (TYPE, TYPE_U32);
- ft.setString (UNIT, "page");
+ ft.setString (UNIT, "wpage");
ft.setString (DESC, "Current depth of write-page-cache");
buf.put (ft);
ft = FieldTable ();
ft.setString (NAME, "journalWritePageCacheDepthHigh");
ft.setInt (TYPE, TYPE_U32);
- ft.setString (UNIT, "page");
+ ft.setString (UNIT, "wpage");
ft.setString (DESC, "Current depth of write-page-cache (High)");
buf.put (ft);
ft = FieldTable ();
ft.setString (NAME, "journalWritePageCacheDepthLow");
ft.setInt (TYPE, TYPE_U32);
- ft.setString (UNIT, "page");
+ ft.setString (UNIT, "wpage");
ft.setString (DESC, "Current depth of write-page-cache (Low)");
buf.put (ft);
ft = FieldTable ();
ft.setString (NAME, "journalReadPageCacheDepth");
ft.setInt (TYPE, TYPE_U32);
- ft.setString (UNIT, "page");
+ ft.setString (UNIT, "rpage");
ft.setString (DESC, "Current depth of read-page-cache");
buf.put (ft);
ft = FieldTable ();
ft.setString (NAME, "journalReadPageCacheDepthHigh");
ft.setInt (TYPE, TYPE_U32);
- ft.setString (UNIT, "page");
+ ft.setString (UNIT, "rpage");
ft.setString (DESC, "Current depth of read-page-cache (High)");
buf.put (ft);
ft = FieldTable ();
ft.setString (NAME, "journalReadPageCacheDepthLow");
ft.setInt (TYPE, TYPE_U32);
- ft.setString (UNIT, "page");
+ ft.setString (UNIT, "rpage");
ft.setString (DESC, "Current depth of read-page-cache (Low)");
buf.put (ft);
Modified: store/trunk/cpp/lib/gen/qpid/management/Journal.h
===================================================================
--- store/trunk/cpp/lib/gen/qpid/management/Journal.h 2008-04-11 15:20:16 UTC (rev 1902)
+++ store/trunk/cpp/lib/gen/qpid/management/Journal.h 2008-04-11 19:38:47 UTC (rev 1903)
@@ -168,6 +168,15 @@
journalRecordDepthLow = journalRecordDepth;
instChanged = true;
}
+ inline void set_journalRecordDepth (uint32_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalRecordDepth = val;
+ if (journalRecordDepthLow > val)
+ journalRecordDepthLow = val;
+ if (journalRecordDepthHigh < val)
+ journalRecordDepthHigh = val;
+ instChanged = true;
+ }
inline void inc_journalRecordEnqueues (uint64_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalRecordEnqueues += by;
@@ -178,6 +187,11 @@
journalRecordEnqueues -= by;
instChanged = true;
}
+ inline void set_journalRecordEnqueues (uint64_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalRecordEnqueues = val;
+ instChanged = true;
+ }
inline void inc_journalRecordDequeues (uint64_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalRecordDequeues += by;
@@ -188,6 +202,11 @@
journalRecordDequeues -= by;
instChanged = true;
}
+ inline void set_journalRecordDequeues (uint64_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalRecordDequeues = val;
+ instChanged = true;
+ }
inline void inc_journalOutstandingAIOs (uint32_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalOutstandingAIOs += by;
@@ -202,6 +221,15 @@
journalOutstandingAIOsLow = journalOutstandingAIOs;
instChanged = true;
}
+ inline void set_journalOutstandingAIOs (uint32_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalOutstandingAIOs = val;
+ if (journalOutstandingAIOsLow > val)
+ journalOutstandingAIOsLow = val;
+ if (journalOutstandingAIOsHigh < val)
+ journalOutstandingAIOsHigh = val;
+ instChanged = true;
+ }
inline void inc_journalFreeFileCount (uint32_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalFreeFileCount += by;
@@ -216,6 +244,15 @@
journalFreeFileCountLow = journalFreeFileCount;
instChanged = true;
}
+ inline void set_journalFreeFileCount (uint32_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalFreeFileCount = val;
+ if (journalFreeFileCountLow > val)
+ journalFreeFileCountLow = val;
+ if (journalFreeFileCountHigh < val)
+ journalFreeFileCountHigh = val;
+ instChanged = true;
+ }
inline void inc_journalAvailableFileCount (uint32_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalAvailableFileCount += by;
@@ -230,6 +267,15 @@
journalAvailableFileCountLow = journalAvailableFileCount;
instChanged = true;
}
+ inline void set_journalAvailableFileCount (uint32_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalAvailableFileCount = val;
+ if (journalAvailableFileCountLow > val)
+ journalAvailableFileCountLow = val;
+ if (journalAvailableFileCountHigh < val)
+ journalAvailableFileCountHigh = val;
+ instChanged = true;
+ }
inline void inc_journalWriteWaitFailures (uint64_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalWriteWaitFailures += by;
@@ -240,6 +286,11 @@
journalWriteWaitFailures -= by;
instChanged = true;
}
+ inline void set_journalWriteWaitFailures (uint64_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalWriteWaitFailures = val;
+ instChanged = true;
+ }
inline void inc_journalWriteBusyFailures (uint64_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalWriteBusyFailures += by;
@@ -250,6 +301,11 @@
journalWriteBusyFailures -= by;
instChanged = true;
}
+ inline void set_journalWriteBusyFailures (uint64_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalWriteBusyFailures = val;
+ instChanged = true;
+ }
inline void inc_journalReadRecordCount (uint64_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalReadRecordCount += by;
@@ -260,6 +316,11 @@
journalReadRecordCount -= by;
instChanged = true;
}
+ inline void set_journalReadRecordCount (uint64_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalReadRecordCount = val;
+ instChanged = true;
+ }
inline void inc_journalReadBusyFailures (uint64_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalReadBusyFailures += by;
@@ -270,6 +331,11 @@
journalReadBusyFailures -= by;
instChanged = true;
}
+ inline void set_journalReadBusyFailures (uint64_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalReadBusyFailures = val;
+ instChanged = true;
+ }
inline void inc_journalWritePageCacheDepth (uint32_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalWritePageCacheDepth += by;
@@ -284,6 +350,15 @@
journalWritePageCacheDepthLow = journalWritePageCacheDepth;
instChanged = true;
}
+ inline void set_journalWritePageCacheDepth (uint32_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalWritePageCacheDepth = val;
+ if (journalWritePageCacheDepthLow > val)
+ journalWritePageCacheDepthLow = val;
+ if (journalWritePageCacheDepthHigh < val)
+ journalWritePageCacheDepthHigh = val;
+ instChanged = true;
+ }
inline void inc_journalReadPageCacheDepth (uint32_t by = 1){
sys::RWlock::ScopedWlock writeLock (accessLock);
journalReadPageCacheDepth += by;
@@ -298,6 +373,15 @@
journalReadPageCacheDepthLow = journalReadPageCacheDepth;
instChanged = true;
}
+ inline void set_journalReadPageCacheDepth (uint32_t val){
+ sys::RWlock::ScopedWlock writeLock (accessLock);
+ journalReadPageCacheDepth = val;
+ if (journalReadPageCacheDepthLow > val)
+ journalReadPageCacheDepthLow = val;
+ if (journalReadPageCacheDepthHigh < val)
+ journalReadPageCacheDepthHigh = val;
+ instChanged = true;
+ }
};
Modified: store/trunk/cpp/lib/jrnl/jcntl.cpp
===================================================================
--- store/trunk/cpp/lib/jrnl/jcntl.cpp 2008-04-11 15:20:16 UTC (rev 1902)
+++ store/trunk/cpp/lib/jrnl/jcntl.cpp 2008-04-11 19:38:47 UTC (rev 1903)
@@ -219,6 +219,7 @@
_rrfc.initialize(_num_jfiles, (nlfh**)_datafh, _rcvdat._ffid);
_rmgr.recover_complete(_rcvdat._fro);
_readonly_flag = false;
+ this->log(LOG_DEBUG, "Recover phase II complete; journal now writable.");
}
void
Modified: store/trunk/specs/management-schema.xml
===================================================================
--- store/trunk/specs/management-schema.xml 2008-04-11 15:20:16 UTC (rev 1902)
+++ store/trunk/specs/management-schema.xml 2008-04-11 19:38:47 UTC (rev 1903)
@@ -26,7 +26,7 @@
<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="record" desc="Number of outstanding AIO requests in Async IO system"/>
+ <instElement 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
@@ -37,8 +37,8 @@
<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="page" desc="Current depth of write-page-cache"/>
- <instElement name="journalReadPageCacheDepth" type="hilo32" unit="page" desc="Current depth of read-page-cache"/>
+ <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"/>
<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"/>
16 years, 9 months
rhmessaging commits: r1902 - store/trunk/cpp.
by rhmessaging-commits@lists.jboss.org
Author: kpvdr
Date: 2008-04-11 11:20:16 -0400 (Fri, 11 Apr 2008)
New Revision: 1902
Modified:
store/trunk/cpp/rhm.spec.in
Log:
Added python to rpm build requirements
Modified: store/trunk/cpp/rhm.spec.in
===================================================================
--- store/trunk/cpp/rhm.spec.in 2008-04-11 12:58:31 UTC (rev 1901)
+++ store/trunk/cpp/rhm.spec.in 2008-04-11 15:20:16 UTC (rev 1902)
@@ -3,7 +3,7 @@
#
Name: rhm
Version: @VERSION@
-Release: 18%{?dist}
+Release: 19%{?dist}
Summary: Red Hat extensions to the Qpid messaging system
Group: System Environment/Libraries
License: LGPL
@@ -21,6 +21,7 @@
BuildRequires: e2fsprogs-devel
BuildRequires: libaio-devel
BuildRequires: cppunit-devel
+BuildRequires: python
Requires: qpidd
Requires: db4
@@ -86,6 +87,9 @@
%changelog
+* Fri Apr 11 2008 Kim van der Riet <kim.vdriet(a)redhat.com> - 0.2-19
+- added python package as build dependency
+
* Tue Feb 12 2008 Rafael Schloming <rafaels(a)redhat.com> - 0.2-17
- bump release for Beta 3 bug fixes
16 years, 9 months
rhmessaging commits: r1901 - in store/trunk/cpp: lib/jrnl and 1 other directories.
by rhmessaging-commits@lists.jboss.org
Author: kpvdr
Date: 2008-04-11 08:58:31 -0400 (Fri, 11 Apr 2008)
New Revision: 1901
Modified:
store/trunk/cpp/lib/JournalImpl.cpp
store/trunk/cpp/lib/jrnl/enq_map.hpp
store/trunk/cpp/lib/jrnl/txn_map.hpp
store/trunk/cpp/tests/jrnl/_ut_enq_map.cpp
store/trunk/cpp/tests/jrnl/_ut_txn_map.cpp
Log:
Bugfix for emap/tmap size() function: return type overflow
Modified: store/trunk/cpp/lib/JournalImpl.cpp
===================================================================
--- store/trunk/cpp/lib/JournalImpl.cpp 2008-04-10 19:11:00 UTC (rev 1900)
+++ store/trunk/cpp/lib/JournalImpl.cpp 2008-04-11 12:58:31 UTC (rev 1901)
@@ -181,7 +181,8 @@
}
}
std::ostringstream oss2;
- oss2 << "Recover complete; highest rid found = 0x" << std::hex << highest_rid;
+ oss2 << "Recover complete; highest rid found = 0x" << std::hex << highest_rid << std::dec;
+ oss2 << "; emap.size=" << _emap.size() << "; tmap.size=" << _tmap.size();
log(LOG_DEBUG, oss2.str());
if (_mgmtObject.get() != 0)
@@ -189,6 +190,9 @@
_mgmtObject->set_initialFileCount(_num_jfiles);
_mgmtObject->set_dataFileSize(_jfsize_sblks * JRNL_SBLK_SIZE * JRNL_DBLK_SIZE);
_mgmtObject->set_journalCurrentFileCount(_num_jfiles);
+
+ //TODO - swap this with a set method as soon as it becomes available in the generated code.
+ _mgmtObject->inc_journalRecordDepth(_emap.size());
}
}
@@ -461,6 +465,7 @@
_mgmtObject->set_initialFileCount(_num_jfiles);
_mgmtObject->set_dataFileSize(_jfsize_sblks * JRNL_SBLK_SIZE * JRNL_DBLK_SIZE);
_mgmtObject->set_journalCurrentFileCount(_num_jfiles);
+ //TODO - set record depth to 0 when set function becomes available.
}
}
Modified: store/trunk/cpp/lib/jrnl/enq_map.hpp
===================================================================
--- store/trunk/cpp/lib/jrnl/enq_map.hpp 2008-04-10 19:11:00 UTC (rev 1900)
+++ store/trunk/cpp/lib/jrnl/enq_map.hpp 2008-04-11 12:58:31 UTC (rev 1901)
@@ -96,7 +96,7 @@
bool is_locked(const u_int64_t rid);
inline void clear() { _map.clear(); }
inline bool empty() const { return _map.empty(); }
- inline u_int16_t size() const { return (u_int16_t)_map.size(); }
+ inline u_int32_t size() const { return u_int32_t(_map.size()); }
void rid_list(std::vector<u_int64_t>& rv);
void fid_list(std::vector<u_int16_t>& fv);
};
Modified: store/trunk/cpp/lib/jrnl/txn_map.hpp
===================================================================
--- store/trunk/cpp/lib/jrnl/txn_map.hpp 2008-04-10 19:11:00 UTC (rev 1900)
+++ store/trunk/cpp/lib/jrnl/txn_map.hpp 2008-04-11 12:58:31 UTC (rev 1901)
@@ -130,7 +130,7 @@
const txn_data& get_data(const std::string& xid, const u_int64_t rid);
inline void clear() { _map.clear(); }
inline bool empty() const { return _map.empty(); }
- inline u_int16_t size() const { return (u_int16_t)_map.size(); }
+ inline u_int32_t size() const { return u_int32_t(_map.size()); }
void xid_list(std::vector<std::string>& xv);
private:
static std::string xid_format(const std::string& xid);
Modified: store/trunk/cpp/tests/jrnl/_ut_enq_map.cpp
===================================================================
--- store/trunk/cpp/tests/jrnl/_ut_enq_map.cpp 2008-04-10 19:11:00 UTC (rev 1900)
+++ store/trunk/cpp/tests/jrnl/_ut_enq_map.cpp 2008-04-11 12:58:31 UTC (rev 1901)
@@ -46,7 +46,7 @@
cout << test_filename << ".constructor: " << flush;
enq_map e1;
BOOST_CHECK(e1.empty());
- BOOST_CHECK_EQUAL(e1.size(), 0);
+ BOOST_CHECK_EQUAL(e1.size(), u_int32_t(0));
cout << "ok" << endl;
}
@@ -65,7 +65,7 @@
for (rid = rid_begin, fid = fid_start; rid < rid_end; rid += rid_incr_1, fid++)
e2.insert_fid(rid, fid);
BOOST_CHECK(!e2.empty());
- BOOST_CHECK_EQUAL(e2.size(), 128);
+ BOOST_CHECK_EQUAL(e2.size(), u_int32_t(128));
// get
u_int64_t rid_incr_2 = 6ULL;
@@ -102,10 +102,10 @@
BOOST_CHECK(rid%rid_incr_1 == 0);
}
}
- BOOST_CHECK_EQUAL(e2.size(), 171ULL);
+ BOOST_CHECK_EQUAL(e2.size(), u_int32_t(171));
e2.clear();
BOOST_CHECK(e2.empty());
- BOOST_CHECK_EQUAL(e2.size(), 0);
+ BOOST_CHECK_EQUAL(e2.size(), u_int32_t(0));
cout << "ok" << endl;
}
@@ -141,7 +141,7 @@
BOOST_CHECK(rid%rid_incr_1);
}
}
- BOOST_CHECK_EQUAL(e3.size(), 85ULL);
+ BOOST_CHECK_EQUAL(e3.size(), u_int32_t(85));
cout << "ok" << endl;
}
@@ -250,4 +250,31 @@
cout << "ok" << endl;
}
+QPID_AUTO_TEST_CASE(stress)
+{
+ cout << test_filename << ".stress: " << flush;
+ u_int64_t rid;
+ u_int64_t rid_cnt;
+ u_int64_t rid_begin = 0xffffffff00000000ULL;
+ u_int64_t num_rid = 0x800000ULL;
+
+ enq_map e6;
+
+ // insert even rids with no dups
+ for (rid = rid_begin, rid_cnt = u_int64_t(0); rid_cnt < num_rid; rid += 2ULL, rid_cnt++)
+ e6.insert_fid(rid, u_int16_t(0));
+ BOOST_CHECK_EQUAL(e6.size(), num_rid);
+
+ // insert odd rids with no dups
+ for (rid = rid_begin + 1, rid_cnt = u_int64_t(0); rid_cnt < num_rid; rid += 2ULL, rid_cnt++)
+ e6.insert_fid(rid, u_int16_t(0));
+ BOOST_CHECK_EQUAL(e6.size(), num_rid * 2);
+ cout << "ok" << endl;
+
+ // remove even rids
+ for (rid = rid_begin, rid_cnt = u_int64_t(0); rid_cnt < num_rid; rid += 2ULL, rid_cnt++)
+ e6.get_remove_fid(rid);
+ BOOST_CHECK_EQUAL(e6.size(), num_rid);
+}
+
QPID_AUTO_TEST_SUITE_END()
Modified: store/trunk/cpp/tests/jrnl/_ut_txn_map.cpp
===================================================================
--- store/trunk/cpp/tests/jrnl/_ut_txn_map.cpp 2008-04-10 19:11:00 UTC (rev 1900)
+++ store/trunk/cpp/tests/jrnl/_ut_txn_map.cpp 2008-04-11 12:58:31 UTC (rev 1901)
@@ -79,7 +79,7 @@
txn_map t1;
BOOST_CHECK(t1.empty());
- BOOST_CHECK_EQUAL(t1.size(), 0);
+ BOOST_CHECK_EQUAL(t1.size(), u_int32_t(0));
cout << "ok" << endl;
}
@@ -98,7 +98,7 @@
for (rid = rid_begin, fid = fid_start; rid < rid_end; rid += rid_incr_1, fid++)
t2.insert_txn_data(make_xid(rid), txn_data(rid, ~rid, fid, false));
BOOST_CHECK(!t2.empty());
- BOOST_CHECK_EQUAL(t2.size(), 128);
+ BOOST_CHECK_EQUAL(t2.size(), u_int32_t(128));
// get
u_int64_t rid_incr_2 = 6ULL;
16 years, 9 months
rhmessaging commits: r1900 - mgmt/mint/python/mint.
by rhmessaging-commits@lists.jboss.org
Author: justi9
Date: 2008-04-10 15:11:00 -0400 (Thu, 10 Apr 2008)
New Revision: 1900
Modified:
mgmt/mint/python/mint/__init__.py
Log:
Rollback if the create schema fails
Modified: mgmt/mint/python/mint/__init__.py
===================================================================
--- mgmt/mint/python/mint/__init__.py 2008-04-10 13:27:02 UTC (rev 1899)
+++ mgmt/mint/python/mint/__init__.py 2008-04-10 19:11:00 UTC (rev 1900)
@@ -436,6 +436,7 @@
try:
cursor.execute("create schema public");
except:
+ conn.rollback()
pass
for path, text in scripts:
16 years, 9 months
rhmessaging commits: r1899 - store/trunk/cpp/lib.
by rhmessaging-commits@lists.jboss.org
Author: kpvdr
Date: 2008-04-10 09:27:02 -0400 (Thu, 10 Apr 2008)
New Revision: 1899
Modified:
store/trunk/cpp/lib/BdbMessageStore.cpp
store/trunk/cpp/lib/StorePlugin.cpp
Log:
Updated ambiguous help info and exception messages relating to store options
Modified: store/trunk/cpp/lib/BdbMessageStore.cpp
===================================================================
--- store/trunk/cpp/lib/BdbMessageStore.cpp 2008-04-09 20:31:55 UTC (rev 1898)
+++ store/trunk/cpp/lib/BdbMessageStore.cpp 2008-04-10 13:27:02 UTC (rev 1899)
@@ -1485,7 +1485,8 @@
{
addOptions()
("store-directory", qpid::optValue(storeDir,"DIR"),
- "Store directory location for persistence (overrides --data-dir)")
+ "Store directory location for persistence (instead of using --data-dir value). "
+ "Must be supplied if --no-data-dir is also used.")
("store-async", qpid::optValue(storeAsync,"yes|no"),
"Use async persistence storage - if store supports it, enables AIO O_DIRECT.")
("store-force", qpid::optValue(storeForce,"yes|no"),
Modified: store/trunk/cpp/lib/StorePlugin.cpp
===================================================================
--- store/trunk/cpp/lib/StorePlugin.cpp 2008-04-09 20:31:55 UTC (rev 1898)
+++ store/trunk/cpp/lib/StorePlugin.cpp 2008-04-10 13:27:02 UTC (rev 1899)
@@ -49,15 +49,17 @@
if (options.storeDir.empty ())
{
if (!dataDir.isEnabled ())
- throw Exception ("If --data-dir is blank, --store-directory must be set");
+ throw Exception ("If --data-dir is blank or --no-data-dir is specified, "
+ "--store-directory must be present.");
options.storeDir = dataDir.getPath ();
}
if (!store->init (&options))
{
- throw Exception("Existing Journal in different mode, backup/move existing data "
- "before changing modes. Or use '--store-force yes' to blow existing data away.");
+ throw Exception("Existing journal found in different bdb/async mode. "
+ "Move or delete existing data files before changing modes, or use "
+ "'--store-force yes' to discard existing data.");
}
broker->setStore (store);
16 years, 9 months