[jboss-svn-commits] JBL Code SVN: r7338 - in labs/jbossesb/trunk/product/core: rosetta/src/org/jboss/soa/esb/common rosetta/src/org/jboss/soa/esb/services/persistence services/tests/src/org/jboss/soa/esb/services/tests/objectstore
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Thu Nov 2 13:07:37 EST 2006
Author: daniel.brum at jboss.com
Date: 2006-11-02 13:07:32 -0500 (Thu, 02 Nov 2006)
New Revision: 7338
Removed:
labs/jbossesb/trunk/product/core/services/tests/src/org/jboss/soa/esb/services/tests/objectstore/ObjectStoreFuncTest.java
Modified:
labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/common/Configuration.java
labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/common/Environment.java
labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/persistence/MessageStoreFactory.java
Log:
Modified: labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/common/Configuration.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/common/Configuration.java 2006-11-02 16:55:33 UTC (rev 7337)
+++ labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/common/Configuration.java 2006-11-02 18:07:32 UTC (rev 7338)
@@ -59,6 +59,7 @@
new KeyValuePair(Environment.MSG_STORE_DB_POOL_INITIAL_SIZE,getStorePoolInitialSize()),
new KeyValuePair(Environment.MSG_STORE_DB_POOL_TEST_TABLE, getStorePoolTestTable()),
new KeyValuePair(Environment.MSG_STORE_DB_POOL_TIMEOUT_MILLIS,getStorePoolTimeoutMillis()),
+ new KeyValuePair(Environment.MSG_STORE_CONN_FACTORY ,getStoreConnectionFactory()),
new KeyValuePair(Environment.ROUTER_CBR_CLASS, getContentBasedRouterImplementationClass())
};
@@ -270,6 +271,12 @@
return property;
}
+ public static String getStoreConnectionFactory()
+ {
+ String property = ModulePropertyManager.getPropertyManager(ModulePropertyManager.CORE_MODULE).getProperty(Environment.MSG_STORE_CONN_FACTORY);
+ return property;
+ }
+
public static String getContentBasedRouterImplementationClass()
{
String property = ModulePropertyManager.getPropertyManager(ModulePropertyManager.ROUTER_MODULE).getProperty(Environment.ROUTER_CBR_CLASS);
Modified: labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/common/Environment.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/common/Environment.java 2006-11-02 16:55:33 UTC (rev 7337)
+++ labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/common/Environment.java 2006-11-02 18:07:32 UTC (rev 7338)
@@ -103,6 +103,7 @@
/*
* DatabaseMessageStore Persistence Store properties.
*/
+ public static final String MSG_STORE_CONN_FACTORY = "org.jboss.soa.esb.persistence.connection.factory";
public static final String MSG_STORE_DB_CONNECTION_URL = "org.jboss.soa.esb.persistence.db.connection.url";
public static final String MSG_STORE_DB_CONNECTION_USER = "org.jboss.soa.esb.persistence.db.user";
public static final String MSG_STORE_DB_CONNECTION_PWD = "org.jboss.soa.esb.persistence.db.pwd";
Modified: labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/persistence/MessageStoreFactory.java
===================================================================
--- labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/persistence/MessageStoreFactory.java 2006-11-02 16:55:33 UTC (rev 7337)
+++ labs/jbossesb/trunk/product/core/rosetta/src/org/jboss/soa/esb/services/persistence/MessageStoreFactory.java 2006-11-02 18:07:32 UTC (rev 7338)
@@ -5,9 +5,11 @@
import java.lang.reflect.Constructor;
import java.net.URI;
+import org.jboss.soa.esb.common.Configuration;
+
@SuppressWarnings("unchecked")
public abstract class MessageStoreFactory {
@@ -18,6 +20,7 @@
try {
Class cls = Class.forName("org.jboss.internal.soa.esb.persistence.format.MessageStoreFactoryImpl");
+// Class cls = Class.forName(Configuration.getStoreConnectionFactory());
Constructor<MessageStoreFactory> c = cls.getConstructor(new Class[]{});
theFactory = c.newInstance(new Object[]{});
} catch (Exception e) {
Deleted: labs/jbossesb/trunk/product/core/services/tests/src/org/jboss/soa/esb/services/tests/objectstore/ObjectStoreFuncTest.java
===================================================================
--- labs/jbossesb/trunk/product/core/services/tests/src/org/jboss/soa/esb/services/tests/objectstore/ObjectStoreFuncTest.java 2006-11-02 16:55:33 UTC (rev 7337)
+++ labs/jbossesb/trunk/product/core/services/tests/src/org/jboss/soa/esb/services/tests/objectstore/ObjectStoreFuncTest.java 2006-11-02 18:07:32 UTC (rev 7338)
@@ -1,91 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.soa.esb.services.tests.objectstore;
-
-import org.jboss.soa.esb.common.tests.BaseTest;
-
-// DON'T FORGET !!
-// The Rosetta Application server has to be up and running
-// (set JNDI_SERVER appropriately)
-
-public class ObjectStoreFuncTest extends BaseTest
-{
- public ObjectStoreFuncTest() {
- }
-
- public void testNotImplementedFuncTest() {
- log.info("*******************************************");
- log.info("Requires Implementation");
- log.info("*******************************************");
- }
-
- /*
- public ObjectStoreFuncTest () throws Exception
- { performTest(); }
-
- static void performTest() throws Exception
- {
- // get a handle to your business delegate
- m_oH = PersistHandlerFactory.getPersistHandler
- ("remote"
- ,SystemProperties.getJndiServerType()
- ,SystemProperties.getJndiServerURL()
- );
-
- // request UID chunks for your own use
- // int[] ia = {10,20,30};
- // for (int iCurr : ia)
- // System.out.println
- // ("Requesting "+iCurr+" uids "
- // +" - First UID returned = " +m_oH.getUidChunk(iCurr)
- // );
-
- storeAndRetrievePerson();
- } //________________________________
-
- static void storeAndRetrievePerson() throws Exception
- {
- // set up a Person (see TestPersonAddrPhone.class)
- Person oPrs = PersonUnitTest.getPerson();
- // timestamp, uid and snap Uid are added just to make it easier
- // to compare output text
- oPrs.setStamp(System.currentTimeMillis());
- long lUid = m_oH.addObject(oPrs);
- oPrs.setUid(lUid);
- oPrs.setSnap(lUid);
-
- // retrieve it from the Object Store
- Person oP2 = (Person)m_oH.getObject(Person.class,lUid);
-
- // output in XML format both objects, and compare
- // timestamps will differ slightly because first object
- // has a dummy timestamp (just before "store" request)
- System.out.println(oPrs.toDTO().toXml());
- System.out.println(oP2.toDTO().toXml());
-
- // if you used the "ObjStoreExample.xml" that comes with the
- // standard example, you'll be able to see your objects
- // in the "object_snap" and "people_index" tables
-
- } //________________________________
- */
-} //____________________________________________________________________________
More information about the jboss-svn-commits
mailing list