Author: ritchiem
Date: 2008-01-11 06:41:52 -0500 (Fri, 11 Jan 2008)
New Revision: 1548
Modified:
store/branches/java/M2/java/bdbstore/pom.xml
store/branches/java/M2/java/bdbstore/src/test/java/org/apache/qpid/server/store/berkeleydb/BDBStoreTest.java
Log:
Patch to change the VirtualHost constructor to provide an empty configuration. This was
causing a NPE due to the lack of configuration.
Modified: store/branches/java/M2/java/bdbstore/pom.xml
===================================================================
--- store/branches/java/M2/java/bdbstore/pom.xml 2008-01-10 22:37:28 UTC (rev 1547)
+++ store/branches/java/M2/java/bdbstore/pom.xml 2008-01-11 11:41:52 UTC (rev 1548)
@@ -22,14 +22,14 @@
<groupId>org.etp.qpid</groupId>
<artifactId>qpid-bdbstore</artifactId>
<packaging>jar</packaging>
- <version>1.0-incubating-M2-SNAPSHOT</version>
+ <version>1.0-incubating-M2</version>
<name>Qpid BDB Store</name>
<
url>http://cwiki.apache.org/confluence/display/qpid</url>
<parent>
<groupId>org.apache.qpid</groupId>
<artifactId>qpid</artifactId>
- <version>1.0-incubating-M2-SNAPSHOT</version>
+ <version>1.0-incubating-M2</version>
</parent>
<!-- Local repository for the BerkelyDB-je so we don't have to use the
installer script -->
Modified:
store/branches/java/M2/java/bdbstore/src/test/java/org/apache/qpid/server/store/berkeleydb/BDBStoreTest.java
===================================================================
---
store/branches/java/M2/java/bdbstore/src/test/java/org/apache/qpid/server/store/berkeleydb/BDBStoreTest.java 2008-01-10
22:37:28 UTC (rev 1547)
+++
store/branches/java/M2/java/bdbstore/src/test/java/org/apache/qpid/server/store/berkeleydb/BDBStoreTest.java 2008-01-11
11:41:52 UTC (rev 1548)
@@ -49,7 +49,7 @@
private static final Logger _log = Logger.getLogger(BDBStoreTest.class);
private BDBMessageStore _store;
-
+ private PropertiesConfiguration _env;
private StoreContext _storeContext = new StoreContext();
private VirtualHost _virtualHost;
@@ -80,7 +80,8 @@
_store.createEnvironment(bdbDir);
_store.openDatabases();
- _virtualHost = new VirtualHost("test", _store);
+ _env = new PropertiesConfiguration();
+ _virtualHost = new VirtualHost("test", _env, _store);
_store.setVirtualHost(_virtualHost);
_store.startCommitThread();
@@ -380,13 +381,11 @@
_store = new BDBMessageStore();
- PropertiesConfiguration env = new PropertiesConfiguration();
+ _env.addProperty("store.environment-path", "bdbTestEnv");
+ _env.addProperty("store.class",
"org.apache.qpid.server.store.berkeleydb.BDBMessageStore");
- env.addProperty("store.environment-path", "bdbTestEnv");
- env.addProperty("store.class",
"org.apache.qpid.server.store.berkeleydb.BDBMessageStore");
+ _virtualHost = new VirtualHost("test", _env);
- _virtualHost = new VirtualHost("test", env);
-
try
{
AMQQueue q1 = _virtualHost.getQueueRegistry().getQueue(QUEUE1);