From f008d164395a01e34f0cd0da3d3a7e76fd8bca3f Mon Sep 17 00:00:00 2001 From: Fabrice Bellingard Date: Tue, 31 Jan 2012 17:53:02 +0100 Subject: [PATCH] SONAR-3228 Set the wieghted_violations metric's best value to 0 => To optimize the number of entries persisted in the DB --- .../src/main/java/org/sonar/api/measures/CoreMetrics.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java b/sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java index 33f91b7db5f..e178bb90e21 100644 --- a/sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java +++ b/sonar-plugin-api/src/main/java/org/sonar/api/measures/CoreMetrics.java @@ -1026,6 +1026,8 @@ public final class CoreMetrics { .setDirection(Metric.DIRECTION_WORST) .setQualitative(true) .setDomain(DOMAIN_RULES) + .setBestValue(0.0) + .setOptimizedBestValue(true) .create(); public static final String VIOLATIONS_DENSITY_KEY = "violations_density"; -- 2.39.5