diff --git a/extensions/jdbc/jdbc-mssql/runtime/pom.xml b/extensions/jdbc/jdbc-mssql/runtime/pom.xml index d3294c09bbd49..4fccb29c09cc3 100644 --- a/extensions/jdbc/jdbc-mssql/runtime/pom.xml +++ b/extensions/jdbc/jdbc-mssql/runtime/pom.xml @@ -27,13 +27,6 @@ com.microsoft.sqlserver mssql-jdbc - - - com.microsoft.azure - adal4j - org.graalvm.nativeimage svm diff --git a/extensions/jdbc/jdbc-mssql/runtime/src/main/java/io/quarkus/jdbc/mssql/runtime/graal/com/microsoft/sqlserver/jdbc/SQLServerJDBCSubstitutions.java b/extensions/jdbc/jdbc-mssql/runtime/src/main/java/io/quarkus/jdbc/mssql/runtime/graal/com/microsoft/sqlserver/jdbc/SQLServerJDBCSubstitutions.java index 505f48c02a14e..6e4315cc99c99 100644 --- a/extensions/jdbc/jdbc-mssql/runtime/src/main/java/io/quarkus/jdbc/mssql/runtime/graal/com/microsoft/sqlserver/jdbc/SQLServerJDBCSubstitutions.java +++ b/extensions/jdbc/jdbc-mssql/runtime/src/main/java/io/quarkus/jdbc/mssql/runtime/graal/com/microsoft/sqlserver/jdbc/SQLServerJDBCSubstitutions.java @@ -1,29 +1,12 @@ package io.quarkus.jdbc.mssql.runtime.graal.com.microsoft.sqlserver.jdbc; -import com.oracle.svm.core.annotate.Alias; -import com.oracle.svm.core.annotate.RecomputeFieldValue; +import com.oracle.svm.core.annotate.Delete; import com.oracle.svm.core.annotate.Substitute; import com.oracle.svm.core.annotate.TargetClass; @TargetClass(className = "com.microsoft.sqlserver.jdbc.SQLServerADAL4JUtils") -@Substitute +@Delete final class SQLServerADAL4JUtils { - - @Alias - @RecomputeFieldValue(kind = RecomputeFieldValue.Kind.Reset) - static final private java.util.logging.Logger adal4jLogger = null; - - @Substitute - static QuarkusSqlFedAuthToken getSqlFedAuthToken(QuarkusSqlFedAuthInfo fedAuthInfo, String user, String password, - String authenticationString) { - throw new IllegalStateException("Quarkus does not support Active Directory based authentication"); - } - - @Substitute - static QuarkusSqlFedAuthToken getSqlFedAuthTokenIntegrated(QuarkusSqlFedAuthInfo fedAuthInfo, String authenticationString) { - throw new IllegalStateException("Quarkus does not support Active Directory based authentication"); - } - } @TargetClass(className = "com.microsoft.sqlserver.jdbc.SqlFedAuthToken") @@ -39,6 +22,16 @@ final class QuarkusSqlFedAuthInfo { @TargetClass(className = "com.microsoft.sqlserver.jdbc.SQLServerConnection") final class QuarkusSQLServerConnection { + @Substitute + private void validateAdalLibrary(String errorMessage) { + throw new IllegalStateException("Quarkus does not support Active Directory based authentication"); + } + + @Substitute + private QuarkusSqlFedAuthToken getFedAuthToken(QuarkusSqlFedAuthInfo fedAuthInfo) { + throw new IllegalStateException("Quarkus does not support Active Directory based authentication"); + } + @Substitute private QuarkusSqlFedAuthToken getMSIAuthToken(String resource, String msiClientId) { throw new IllegalStateException("Quarkus does not support MSI based authentication"); @@ -48,4 +41,4 @@ private QuarkusSqlFedAuthToken getMSIAuthToken(String resource, String msiClient class SQLServerJDBCSubstitutions { -} \ No newline at end of file +}