aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-db-core/src
diff options
context:
space:
mode:
authorBruno Andrade <bruno@artsman.dev>2021-07-14 07:10:09 -0300
committersonartech <sonartech@sonarsource.com>2021-07-29 20:04:50 +0000
commit8eae78c9476d0d5dab0c6f51b2e72267916b2574 (patch)
tree722065a4aab58f7f3b83a8f28dc15d0988f5990b /server/sonar-db-core/src
parentf827bdec3dd63f407ccba44fc5a8462528e0717f (diff)
downloadsonarqube-8eae78c9476d0d5dab0c6f51b2e72267916b2574.tar.gz
sonarqube-8eae78c9476d0d5dab0c6f51b2e72267916b2574.zip
Code smell fix: Replacing ImmutableList from List
Diffstat (limited to 'server/sonar-db-core/src')
-rw-r--r--server/sonar-db-core/src/main/java/org/sonar/db/dialect/Oracle.java5
-rw-r--r--server/sonar-db-core/src/main/java/org/sonar/db/dialect/PostgreSql.java4
2 files changed, 2 insertions, 7 deletions
diff --git a/server/sonar-db-core/src/main/java/org/sonar/db/dialect/Oracle.java b/server/sonar-db-core/src/main/java/org/sonar/db/dialect/Oracle.java
index 36731c12f77..e374d7934b1 100644
--- a/server/sonar-db-core/src/main/java/org/sonar/db/dialect/Oracle.java
+++ b/server/sonar-db-core/src/main/java/org/sonar/db/dialect/Oracle.java
@@ -19,7 +19,6 @@
*/
package org.sonar.db.dialect;
-import com.google.common.collect.ImmutableList;
import java.sql.DatabaseMetaData;
import java.sql.SQLException;
import java.util.List;
@@ -28,12 +27,10 @@ import org.sonar.api.utils.MessageException;
import org.sonar.api.utils.Version;
public class Oracle extends AbstractDialect {
-
public static final String ID = "oracle";
- private static final List<String> INIT_STATEMENTS = ImmutableList.of("ALTER SESSION SET NLS_SORT='BINARY'");
+ private static final List<String> INIT_STATEMENTS = List.of("ALTER SESSION SET NLS_SORT='BINARY'");
private static final Version MIN_SUPPORTED_VERSION = Version.create(11, 0, 0);
-
public Oracle() {
super(ID, "oracle.jdbc.OracleDriver", "1", "0", "SELECT 1 FROM DUAL");
}
diff --git a/server/sonar-db-core/src/main/java/org/sonar/db/dialect/PostgreSql.java b/server/sonar-db-core/src/main/java/org/sonar/db/dialect/PostgreSql.java
index ce441f099d6..de38c155669 100644
--- a/server/sonar-db-core/src/main/java/org/sonar/db/dialect/PostgreSql.java
+++ b/server/sonar-db-core/src/main/java/org/sonar/db/dialect/PostgreSql.java
@@ -19,7 +19,6 @@
*/
package org.sonar.db.dialect;
-import com.google.common.collect.ImmutableList;
import java.sql.DatabaseMetaData;
import java.sql.SQLException;
import java.util.List;
@@ -30,9 +29,8 @@ import org.sonar.api.utils.log.Loggers;
import static com.google.common.base.Preconditions.checkState;
public class PostgreSql extends AbstractDialect {
-
public static final String ID = "postgresql";
- static final List<String> INIT_STATEMENTS = ImmutableList.of("SET standard_conforming_strings=on", "SET backslash_quote=off");
+ static final List<String> INIT_STATEMENTS = List.of("SET standard_conforming_strings=on", "SET backslash_quote=off");
private static final Version MIN_SUPPORTED_VERSION = Version.create(9, 3, 0);
private static final Version MIN_UPSERT_VERSION = Version.create(9, 5, 0);