Repository: ode
Updated Branches:
  refs/heads/master 34b4e766b -> 4900097f4


http://git-wip-us.apache.org/repos/asf/ode/blob/dec47e4b/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/BaseTestDAO.java
----------------------------------------------------------------------
diff --git 
a/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/BaseTestDAO.java 
b/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/BaseTestDAO.java
index a6d10c4..6fcc76c 100644
--- a/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/BaseTestDAO.java
+++ b/dao-hibernate/src/test/java/org/apache/ode/daohib/bpel/BaseTestDAO.java
@@ -21,7 +21,6 @@ package org.apache.ode.daohib.bpel;
 
 import java.util.Properties;
 
-import javax.resource.spi.ConnectionManager;
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
 
@@ -43,7 +42,6 @@ public abstract class BaseTestDAO extends TestCase {
 
     protected BpelDAOConnection daoConn;
     protected TransactionManager txm;
-    protected ConnectionManager connectionManager;
     private DataSource ds;
     /*
      * Make this true and change the getDataSource
@@ -53,7 +51,6 @@ public abstract class BaseTestDAO extends TestCase {
 
     protected void initTM() throws Exception {
         EmbeddedGeronimoFactory factory = new EmbeddedGeronimoFactory();
-        connectionManager = new 
org.apache.geronimo.connector.outbound.GenericConnectionManager();
         txm = factory.getTransactionManager();
         ds = getDataSource();
         
org.springframework.mock.jndi.SimpleNamingContextBuilder.emptyActivatedContextBuilder().bind("java:comp/UserTransaction",
 txm);

http://git-wip-us.apache.org/repos/asf/ode/blob/dec47e4b/dao-jpa-ojpa-derby/src/main/descriptors/persistence.h2.xml
----------------------------------------------------------------------
diff --git a/dao-jpa-ojpa-derby/src/main/descriptors/persistence.h2.xml 
b/dao-jpa-ojpa-derby/src/main/descriptors/persistence.h2.xml
new file mode 100644
index 0000000..02cbd2d
--- /dev/null
+++ b/dao-jpa-ojpa-derby/src/main/descriptors/persistence.h2.xml
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~    http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+  -->
+<persistence xmlns="http://java.sun.com/xml/ns/persistence"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; version="1.0">
+    <persistence-unit name="ode-unit-test-embedded">
+        
<provider>org.apache.openjpa.persistence.PersistenceProviderImpl</provider>
+        <class>org.apache.ode.dao.jpa.ActivityRecoveryDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.CorrelationSetDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.CorrelatorDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.EventDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.FaultDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.MessageDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.MessageExchangeDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.MessageRouteDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.PartnerLinkDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.ProcessDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.ProcessInstanceDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.ScopeDAOImpl</class>
+        <class>org.apache.ode.dao.jpa.XmlDataDAOImpl</class>
+
+        <class>org.apache.ode.store.jpa.ProcessConfDaoImpl</class>
+        <class>org.apache.ode.store.jpa.ProcessConfPropertyDaoImpl</class>
+        <class>org.apache.ode.store.jpa.DeploymentUnitDaoImpl</class>
+        <class>org.apache.ode.store.jpa.VersionTrackerDAOImpl</class>
+
+        <properties>
+            <!-- Properties for an embedded H2 connection -->
+            <property name="openjpa.ConnectionDriverName" 
value="org.apache.commons.dbcp.BasicDataSource"/>
+            <property name="openjpa.jdbc.DBDictionary" 
value="org.apache.openjpa.jdbc.sql.H2Dictionary"/>
+            <!-- To validate DBSchema and create DDL at runtime - use this 
property. Currently the DDL is created at build time -->
+            <property name="openjpa.jdbc.SynchronizeMappings" 
value="buildSchema(ForeignKeys=true)"/>
+
+            <property name="openjpa.ConnectionProperties"
+                      
value="DriverClassName=org.apache.derby.jdbc.EmbeddedDriver,Url=jdbc:derby:target/database/openjpa-test-database;create=true,MaxActive=100,MaxWait=10000,TestOnBorrow=true"/>
+
+        </properties>
+    </persistence-unit>
+</persistence>
+

http://git-wip-us.apache.org/repos/asf/ode/blob/dec47e4b/dao-jpa-ojpa-derby/src/main/scripts/simplesched-h2.sql
----------------------------------------------------------------------
diff --git a/dao-jpa-ojpa-derby/src/main/scripts/simplesched-h2.sql 
b/dao-jpa-ojpa-derby/src/main/scripts/simplesched-h2.sql
new file mode 100644
index 0000000..2ee1bc9
--- /dev/null
+++ b/dao-jpa-ojpa-derby/src/main/scripts/simplesched-h2.sql
@@ -0,0 +1,31 @@
+-- Apache ODE - SimpleScheduler Database Schema
+--
+-- MySQL scripts by Maciej Szefler.
+--
+--
+DROP TABLE IF EXISTS ODE_JOB;
+
+CREATE TABLE ODE_JOB (
+  jobid CHAR(64)  NOT NULL DEFAULT '',
+  ts BIGINT  NOT NULL DEFAULT 0,
+  nodeid char(64)  NULL,
+  scheduled int  NOT NULL DEFAULT 0,
+  transacted int  NOT NULL DEFAULT 0,
+
+  instanceId BIGINT,
+  mexId varchar(255),
+  processId varchar(255),
+  type varchar(255),
+  channel varchar(255),
+  correlatorId varchar(255),
+  correlationKeySet varchar(255),
+  retryCount int,
+  inMem int,
+  detailsExt blob(4096),
+
+  PRIMARY KEY(jobid)
+);
+
+create index IDX_ODE_JOB_TS on ODE_JOB(ts);
+create index IDX_ODE_JOB_NODEID on ODE_JOB(nodeid);
+

http://git-wip-us.apache.org/repos/asf/ode/blob/dec47e4b/jbi/src/test/resources/smx-base.xml
----------------------------------------------------------------------
diff --git a/jbi/src/test/resources/smx-base.xml 
b/jbi/src/test/resources/smx-base.xml
index 880bc4c..d3e4d66 100644
--- a/jbi/src/test/resources/smx-base.xml
+++ b/jbi/src/test/resources/smx-base.xml
@@ -54,7 +54,7 @@
             />
 
     <bean id="odeMCF" class="org.tranql.connector.derby.EmbeddedLocalMCF">
-      <property name="databaseName" value="target/test/smx/ode/hibdb"/>
+      <property name="databaseName" value="target/test/smx/ode/derby-hibdb"/>
       <property name="createDatabase" value="false"/>
     <property name="userName" value = "sa"/>
         <property name="password" value = ""/>

http://git-wip-us.apache.org/repos/asf/ode/blob/dec47e4b/tasks/derby.rake
----------------------------------------------------------------------
diff --git a/tasks/derby.rake b/tasks/derby.rake
index 4cb9f26..c32ab92 100644
--- a/tasks/derby.rake
+++ b/tasks/derby.rake
@@ -17,7 +17,7 @@
 
 module Derby
 
-  REQUIRES = Buildr.group("derby", "derbytools", :under=>"org.apache.derby", 
:version=>"10.1.2.1")
+  REQUIRES = Buildr.group("derby", "derbytools", :under=>"org.apache.derby", 
:version=>"10.5.3.0_1")
 
   Java.classpath << REQUIRES
 

http://git-wip-us.apache.org/repos/asf/ode/blob/dec47e4b/tasks/h2.rake
----------------------------------------------------------------------
diff --git a/tasks/h2.rake b/tasks/h2.rake
index b791f69..892c9e5 100644
--- a/tasks/h2.rake
+++ b/tasks/h2.rake
@@ -17,7 +17,7 @@
 
 module H2
 
-  REQUIRES = "com.h2database:h2:jar:1.1.117"
+  REQUIRES = "com.h2database:h2:jar:1.3.176"
 
   #Java.classpath << REQUIRES
 
@@ -32,8 +32,8 @@ module H2
       db, prereqs = args.keys.first, args.values.first
       targetDir=File.expand_path(db)
       file(targetDir=>prereqs) do |task|
-        rm_rf dbname if File.exist?(dbname)
-        Java::Commands.java "org.h2.tools.RunScript", "-url", 
"jdbc:h2:file:"+Util.normalize_path("#{targetDir}/#{dbname}")+";DB_CLOSE_ON_EXIT=false;user=sa",
 "-showResults", "-script", prereqs, :classpath => REQUIRES
+        rm_rf task.name if File.exist?(task.name)
+        Java::Commands.java "org.h2.tools.RunScript", "-url", 
"jdbc:h2:file:"+Util.normalize_path("#{targetDir}/#{dbname}")+";DB_CLOSE_ON_EXIT=false",
 "-user", "sa", "-checkResults", "-script", prereqs, :classpath => REQUIRES
         #Buildr.filter(prereqs).into(dbname).run
         #touch task.name, :verbose=>false
       end

Reply via email to