ode-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sean...@apache.org
Subject svn commit: r782488 - /ode/trunk/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
Date Mon, 08 Jun 2009 01:16:16 GMT
Author: seanahn
Date: Mon Jun  8 01:16:16 2009
New Revision: 782488

URL: http://svn.apache.org/viewvc?rev=782488&view=rev
Log:
Was not shutting down the cron scheduler when server shuts down

Modified:
    ode/trunk/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java

Modified: ode/trunk/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
URL: http://svn.apache.org/viewvc/ode/trunk/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java?rev=782488&r1=782487&r2=782488&view=diff
==============================================================================
--- ode/trunk/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java (original)
+++ ode/trunk/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java Mon Jun  8 01:16:16
2009
@@ -247,7 +247,6 @@
      * @throws AxisFault if the engine is unable to shut down.
      */
     public void shutDown() throws AxisFault {
-
         ClassLoader old = Thread.currentThread().getContextClassLoader();
         Thread.currentThread().setContextClassLoader(getClass().getClassLoader());
         try {
@@ -258,7 +257,7 @@
                     _poller = null;
                 } catch (Throwable t) {
                     __log.debug("Error stopping poller.", t);
-                }
+            }
 
             if (_bpelServer != null)
                 try {
@@ -267,7 +266,17 @@
                     _bpelServer = null;
                 } catch (Throwable ex) {
                     __log.debug("Error stopping services.", ex);
+            }
+
+            if( _cronScheduler != null ) {
+                try {
+                    __log.debug("shutting down cron scheduler.");
+                    _cronScheduler.shutdown();
+                    _cronScheduler = null;
+                } catch (Exception ex) {
+                    __log.debug("Cron scheduler couldn't be shutdown.", ex);
                 }
+            }
 
             if (_scheduler != null)
                 try {
@@ -340,6 +349,7 @@
         }
     }
 
+    @SuppressWarnings("unchecked")
     public ODEService createService(ProcessConf pconf, QName serviceName, String portName)
throws AxisFault {
         AxisService axisService = ODEAxisService.createService(_axisConfig, pconf, serviceName,
portName);
         ODEService odeService = new ODEService(axisService, pconf, serviceName, portName,
_bpelServer);
@@ -418,6 +428,7 @@
         return null;
     }
 
+    @SuppressWarnings("unchecked")
     private void initTxMgr() throws ServletException {
         String txFactoryName = _odeConfig.getTxFactoryClass();
         __log.debug("Initializing transaction manager using " + txFactoryName);



Mime
View raw message