]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-2346 Failing with Current container state was: CONSTRUCTED
authorsimonbrandhof <simon.brandhof@gmail.com>
Wed, 4 May 2011 09:15:20 +0000 (11:15 +0200)
committersimonbrandhof <simon.brandhof@gmail.com>
Wed, 4 May 2011 09:18:20 +0000 (11:18 +0200)
sonar-batch/src/main/java/org/sonar/batch/Batch.java

index c2b15adda09d6d3af6cb9181a5318e119f6dc242..623192824fec3e01cde345d095d013a4d5431c84 100644 (file)
@@ -62,7 +62,13 @@ public class Batch {
       analyzeModules(bootstrapComponents);
     } finally {
       if (bootstrapComponents != null) {
-        bootstrapComponents.stop();
+        try {
+          bootstrapComponents.stop();
+        } catch (Exception e) {
+          // See http://jira.codehaus.org/browse/SONAR-2346
+          // This exception must not override the exception thrown during start() phase.
+          LOG.error("Fail to stop IoC container", e);
+        }
       }
     }
   }