]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-5735 Deprecate "sonar.importSources"
authorJulien HENRY <julien.henry@sonarsource.com>
Fri, 17 Oct 2014 10:12:17 +0000 (12:12 +0200)
committerJulien HENRY <julien.henry@sonarsource.com>
Fri, 17 Oct 2014 10:24:23 +0000 (12:24 +0200)
sonar-batch/src/main/java/org/sonar/batch/scan/filesystem/ComponentIndexer.java
sonar-core/src/main/java/org/sonar/core/config/SecurityProperties.java
sonar-plugin-api/src/main/java/org/sonar/api/CoreProperties.java

index 65a7585555e09fd73f273d60917f05a525f59631..6492058df7426dd2b790f964c1fcb3ef292e135f 100644 (file)
@@ -67,7 +67,8 @@ public class ComponentIndexer implements BatchComponent {
 
     boolean shouldImportSource = settings.getBoolean(CoreProperties.CORE_IMPORT_SOURCES_PROPERTY);
     if (!shouldImportSource) {
-      LOG.warn("Not importing source will prevent issues to be properly tracked between consecutive analyses");
+      LOG.warn("/!\\ Property '" + CoreProperties.CORE_IMPORT_SOURCES_PROPERTY
+        + "' is deprecated. Not importing source will prevent issues to be properly tracked between consecutive analyses.");
     }
     for (InputFile inputFile : fs.inputFiles(fs.predicates().all())) {
       String languageKey = inputFile.language();
index 39157443966cff0b09871936bc28b8c83afc9c4d..8564ce61a049094cd94aab308bec7701ea764f99 100644 (file)
@@ -38,7 +38,7 @@ class SecurityProperties {
       PropertyDefinition.builder(CoreProperties.CORE_IMPORT_SOURCES_PROPERTY)
         .defaultValue("" + CoreProperties.CORE_IMPORT_SOURCES_DEFAULT_VALUE)
         .name("Import sources")
-        .description("Set to false if sources should not be imported and therefore not available in the Web UI (e.g. for security reasons).")
+        .description("[DEPRECATED] Set to false if sources should not be imported and therefore not available in the Web UI (e.g. for security reasons).")
         .type(PropertyType.BOOLEAN)
         .onQualifiers(Qualifiers.PROJECT, Qualifiers.MODULE)
         .category(CoreProperties.CATEGORY_SECURITY)
@@ -74,7 +74,7 @@ class SecurityProperties {
         .type(PropertyType.BOOLEAN)
         .category(CoreProperties.CATEGORY_SECURITY)
         .build()
-    );
+      );
 
   }
 }
index 0705779f120bb0b82f6373412e952a6d8de213c5..e135d4fcb78839e7ff264b7952c144bd85d15421 100644 (file)
@@ -204,6 +204,10 @@ public interface CoreProperties {
   String CORE_VIOLATION_LOCALE_PROPERTY = "sonar.violationLocale";
 
   String CORE_VIOLATION_LOCALE_DEFAULT_VALUE = "en";
+  /**
+   * @deprecated since 4.5.1.
+   */
+  @Deprecated
   String CORE_IMPORT_SOURCES_PROPERTY = "sonar.importSources";
   boolean CORE_IMPORT_SOURCES_DEFAULT_VALUE = true;