airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lah...@apache.org
Subject svn commit: r1387362 - /incubator/airavata/trunk/modules/registry/airavata-registry-service/src/main/java/org/apache/airavata/registry/services/RegistryService.java
Date Tue, 18 Sep 2012 21:08:21 GMT
Author: lahiru
Date: Tue Sep 18 21:08:20 2012
New Revision: 1387362

URL: http://svn.apache.org/viewvc?rev=1387362&view=rev
Log:
fixing an issue during restart.

Modified:
    incubator/airavata/trunk/modules/registry/airavata-registry-service/src/main/java/org/apache/airavata/registry/services/RegistryService.java

Modified: incubator/airavata/trunk/modules/registry/airavata-registry-service/src/main/java/org/apache/airavata/registry/services/RegistryService.java
URL: http://svn.apache.org/viewvc/incubator/airavata/trunk/modules/registry/airavata-registry-service/src/main/java/org/apache/airavata/registry/services/RegistryService.java?rev=1387362&r1=1387361&r2=1387362&view=diff
==============================================================================
--- incubator/airavata/trunk/modules/registry/airavata-registry-service/src/main/java/org/apache/airavata/registry/services/RegistryService.java
(original)
+++ incubator/airavata/trunk/modules/registry/airavata-registry-service/src/main/java/org/apache/airavata/registry/services/RegistryService.java
Tue Sep 18 21:08:20 2012
@@ -35,6 +35,7 @@ import org.slf4j.LoggerFactory;
 import java.io.IOException;
 import java.net.URL;
 import java.sql.Connection;
+import java.sql.SQLException;
 import java.util.Properties;
 
 public class RegistryService implements ServiceLifeCycle {
@@ -83,6 +84,11 @@ public class RegistryService implements 
             throw new RuntimeException("Database failure");
         } finally {
             db.closeConnection(conn);
+            try {
+                conn.close();
+            } catch (SQLException e) {
+                e.printStackTrace();  //To change body of catch statement use File | Settings
| File Templates.
+            }
         }
         GatewayResource gatewayResource = new GatewayResource();
         gatewayResource.setGatewayName((String)properties.get(GATEWAY_ID));



Mime
View raw message