ode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From va...@apache.org
Subject [3/9] git commit: ODE-997: Throw an exception if an external datasource is configured but no JTA transaction manager is passed in (which is needed to let ODE do its work properly).
Date Mon, 26 Aug 2013 23:19:57 GMT
ODE-997: Throw an exception if an external datasource is configured but no JTA transaction
manager is passed in (which is needed to let ODE do its work properly).


Project: http://git-wip-us.apache.org/repos/asf/ode/repo
Commit: http://git-wip-us.apache.org/repos/asf/ode/commit/4a281a73
Tree: http://git-wip-us.apache.org/repos/asf/ode/tree/4a281a73
Diff: http://git-wip-us.apache.org/repos/asf/ode/diff/4a281a73

Branch: refs/heads/master
Commit: 4a281a73c9645b2fd1b92659b999a1371ecfb9b0
Parents: ce03197
Author: Tammo van Lessen <tvanlessen@gmail.com>
Authored: Fri Aug 23 19:38:51 2013 +0200
Committer: Tammo van Lessen <tvanlessen@gmail.com>
Committed: Tue Aug 27 00:09:52 2013 +0200

----------------------------------------------------------------------
 axis2/src/main/java/org/apache/ode/axis2/ODEServer.java | 6 ++++++
 1 file changed, 6 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ode/blob/4a281a73/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
----------------------------------------------------------------------
diff --git a/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java b/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
index 8237acc..7ed6483 100644
--- a/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
+++ b/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
@@ -73,6 +73,7 @@ import org.apache.ode.bpel.intercept.MessageExchangeInterceptor;
 import org.apache.ode.bpel.memdao.BpelDAOConnectionFactoryImpl;
 import org.apache.ode.bpel.pmapi.InstanceManagement;
 import org.apache.ode.bpel.pmapi.ProcessManagement;
+import org.apache.ode.il.config.OdeConfigProperties;
 import org.apache.ode.il.dbutil.Database;
 import org.apache.ode.scheduler.simple.JdbcDelegate;
 import org.apache.ode.scheduler.simple.SimpleScheduler;
@@ -416,6 +417,11 @@ public class ODEServer {
 
     @SuppressWarnings("unchecked")
      private void initTxMgr() throws ServletException {
+        if (_odeConfig.getDbMode().equals(OdeConfigProperties.DatabaseMode.EXTERNAL) &&
+                _odeConfig.getTxFactoryClass().equals(OdeConfigProperties.DEFAULT_TX_FACTORY_CLASS_NAME))
{
+            throw new ServletException("No external transaction manager factory configured.
Please use the INTERNAL mode or configure an external transaction manager that is associated
with external datasource.");
+        }
+        
         String txFactoryName = _odeConfig.getTxFactoryClass();
         __log.debug("Initializing transaction manager using " + txFactoryName);
         try {


Mime
View raw message