]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-7158 Time limit for calculation of duplications is ineffective
authorDuarte Meneses <duarte.meneses@sonarsource.com>
Tue, 15 Mar 2016 14:31:06 +0000 (15:31 +0100)
committerDuarte Meneses <duarte.meneses@sonarsource.com>
Tue, 15 Mar 2016 14:31:06 +0000 (15:31 +0100)
sonar-batch/src/main/java/org/sonar/batch/cpd/CpdExecutor.java

index 48ad1edb6824ec4b034257cf43d49029825f5828..59a48f83fcff1b5ffcff32c1861a431dae9dcd78 100644 (file)
@@ -110,7 +110,7 @@ public class CpdExecutor {
     }
 
     InputFile inputFile = (InputFile) component.inputComponent();
-    progressReport.message(String.format("%d/%d - current file: %s", count, total, inputFile));
+    progressReport.message(String.format("%d/%d - current file: %s", count, total, inputFile.absolutePath()));
 
     List<CloneGroup> duplications;
     Future<List<CloneGroup>> futureResult = null;
@@ -123,13 +123,13 @@ public class CpdExecutor {
       });
       duplications = futureResult.get(TIMEOUT, TimeUnit.SECONDS);
     } catch (TimeoutException e) {
-      LOG.warn("Timeout during detection of duplications for " + inputFile, e);
+      LOG.warn("Timeout during detection of duplications for " + inputFile.absolutePath());
       if (futureResult != null) {
         futureResult.cancel(true);
       }
       return;
     } catch (Exception e) {
-      throw new IllegalStateException("Fail during detection of duplication for " + inputFile, e);
+      throw new IllegalStateException("Fail during detection of duplication for " + inputFile.absolutePath(), e);
     }
 
     List<CloneGroup> filtered;