aboutsummaryrefslogtreecommitdiffstats
path: root/server
diff options
context:
space:
mode:
authorKlaudio Sinani <klaudio.sinani@sonarsource.com>2022-01-27 18:28:45 +0100
committersonartech <sonartech@sonarsource.com>2022-01-28 09:11:21 +0000
commit20afbdaec8a746a8d07624f5927f8ee14b32cf7f (patch)
tree771903be7498507cbeb6c83e0f9e7c70beb583d3 /server
parent91e059b8104fd65daa556f66199b4e7401d696e1 (diff)
downloadsonarqube-20afbdaec8a746a8d07624f5927f8ee14b32cf7f.tar.gz
sonarqube-20afbdaec8a746a8d07624f5927f8ee14b32cf7f.zip
[NO-JIRA] Fix reported code smells9.3.0.51899
Diffstat (limited to 'server')
-rw-r--r--server/sonar-ce-task-projectanalysis/src/main/java/org/sonar/ce/task/projectanalysis/period/NewCodePeriodResolver.java2
-rw-r--r--server/sonar-db-dao/src/main/java/org/sonar/db/ce/CeTaskCharacteristicDto.java4
-rw-r--r--server/sonar-webserver-webapi/src/main/java/org/sonar/server/monitoring/package-info.java23
3 files changed, 24 insertions, 5 deletions
diff --git a/server/sonar-ce-task-projectanalysis/src/main/java/org/sonar/ce/task/projectanalysis/period/NewCodePeriodResolver.java b/server/sonar-ce-task-projectanalysis/src/main/java/org/sonar/ce/task/projectanalysis/period/NewCodePeriodResolver.java
index 257c3fd02f2..4e83d5e6310 100644
--- a/server/sonar-ce-task-projectanalysis/src/main/java/org/sonar/ce/task/projectanalysis/period/NewCodePeriodResolver.java
+++ b/server/sonar-ce-task-projectanalysis/src/main/java/org/sonar/ce/task/projectanalysis/period/NewCodePeriodResolver.java
@@ -84,7 +84,7 @@ public class NewCodePeriodResolver {
}
}
- private Period resolveByReferenceBranch(String value) {
+ private static Period resolveByReferenceBranch(String value) {
return newPeriod(NewCodePeriodType.REFERENCE_BRANCH, value, null);
}
diff --git a/server/sonar-db-dao/src/main/java/org/sonar/db/ce/CeTaskCharacteristicDto.java b/server/sonar-db-dao/src/main/java/org/sonar/db/ce/CeTaskCharacteristicDto.java
index 75928668ec8..c67ddfa69b5 100644
--- a/server/sonar-db-dao/src/main/java/org/sonar/db/ce/CeTaskCharacteristicDto.java
+++ b/server/sonar-db-dao/src/main/java/org/sonar/db/ce/CeTaskCharacteristicDto.java
@@ -19,12 +19,8 @@
*/
package org.sonar.db.ce;
-import java.util.HashSet;
import java.util.Set;
-import static java.util.Arrays.asList;
-import static java.util.Collections.unmodifiableSet;
-
public class CeTaskCharacteristicDto {
public static final String BRANCH_KEY = "branch";
diff --git a/server/sonar-webserver-webapi/src/main/java/org/sonar/server/monitoring/package-info.java b/server/sonar-webserver-webapi/src/main/java/org/sonar/server/monitoring/package-info.java
new file mode 100644
index 00000000000..88f058e64bf
--- /dev/null
+++ b/server/sonar-webserver-webapi/src/main/java/org/sonar/server/monitoring/package-info.java
@@ -0,0 +1,23 @@
+/*
+ * SonarQube
+ * Copyright (C) 2009-2021 SonarSource SA
+ * mailto:info AT sonarsource DOT com
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 3 of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this program; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+@ParametersAreNonnullByDefault
+package org.sonar.server.monitoring;
+
+import javax.annotation.ParametersAreNonnullByDefault;