1 Reply Latest reply on Nov 13, 2019 1:20 AM by gopib1

    WARN  | -redhat-00001/deploy | e.j.e.i.JdbcEnvironmentInitiator | 261 - org.jboss.logging.jboss-logging - 3.3.2.Final-redhat-00001 | HHH000342: Could not obtain connection to query metadata : Cannot load JDBC driver class 'com.microsoft.sqlserver.jdbc.SQL

    gopib1

      Hi Team,

       

                     Iam trying to use FUSE7.4 with MS-SQL DB, keep getting the below warning, I have tried multiple ways. But unable to resolve. Can you please help me to resolve this issue

       

      393 | Active | 80 | 1.0.1.RELEASE | EGov-Fuse-Datasource
      394 | Active | 80 | 1.0.0.RELEASE | EGov-Interop-Util
      395 | Active | 80 | 7.0.0 | Microsoft JDBC Driver for SQL Server
      karaf@root()>
      karaf@root()>
      karaf@root()> bundle:headers 395

      Microsoft JDBC Driver for SQL Server (395)

      Bnd-LastModified = 1533057440087
      Build-Jdk = 10.0.1
      Built-By = BLD-003-W81-64$
      Created-By = Apache Maven Bundle Plugin
      Manifest-Version = 1.0
      Tool = Bnd-3.5.0.201709291849

      Bundle-Description = Microsoft JDBC Driver for SQL Server.
      Bundle-License = http://www.opensource.org/licenses/mit-license.php
      Bundle-ManifestVersion = 2
      Bundle-Name = Microsoft JDBC Driver for SQL Server
      Bundle-SymbolicName = com.microsoft.sqlserver.mssql-jdbc
      Bundle-Vendor = Microsoft Corporation
      Bundle-Version = 7.0.0

      Require-Capability =
      osgi.ee;filter:=(&(osgi.ee=JavaSE)(version=1.8))

      Export-Package =
      com.microsoft.sqlserver.jdbc;
      uses:="javax.naming,
      javax.naming.spi,
      javax.security.auth.callback,
      javax.security.auth.login,
      javax.sql,
      javax.transaction.xa,
      microsoft.sql,
      org.ietf.jgss";
      version=7.0.0,
      microsoft.sql;version=7.0.0
      Import-Package =
      com.microsoft.aad.adal4j;resolution:=optional,
      com.microsoft.azure;resolution:=optional,
      com.microsoft.azure.keyvault;resolution:=optional,
      com.microsoft.azure.keyvault.authentication;resolution:=optional,
      com.microsoft.azure.keyvault.models;resolution:=optional,
      com.microsoft.azure.keyvault.webkey;resolution:=optional,
      com.microsoft.azure.serializer;resolution:=optional,
      com.microsoft.rest;resolution:=optional,
      com.microsoft.rest.credentials;resolution:=optional,
      com.microsoft.rest.protocol;resolution:=optional,
      javax.crypto,
      javax.crypto.spec,
      javax.naming,
      javax.naming.directory,
      javax.naming.spi,
      javax.net.ssl,
      javax.security.auth,
      javax.security.auth.callback,
      javax.security.auth.kerberos,
      javax.security.auth.login,
      javax.security.auth.x500,
      javax.sql,
      javax.transaction.xa,
      javax.xml.parsers,
      javax.xml.stream,
      javax.xml.transform,
      javax.xml.transform.dom,
      javax.xml.transform.sax,
      javax.xml.transform.stax,
      javax.xml.transform.stream,
      okhttp3;resolution:=optional,
      org.ietf.jgss,
      org.w3c.dom,
      org.xml.sax,
      retrofit2;resolution:=optional

      karaf@root()>

      --
      Below the Pom.xml what I have added the depency and import packg.

      I have added the mssql-jdbc-7.0.0.jre8 & import packg added this (com.microsoft.sqlserver.jdbc,*)

      com.microsoft.sqlservermssql-jdbc7.0.0.jre8

      com.microsoft.sqlserver.jdbc, *

      2019-11-09 12:14:55,074 | WARN | -redhat-00001/deploy | e.j.e.i.JdbcEnvironmentInitiator | 261 - org.jboss.logging.jboss-logging - 3.3.2.Final-redhat-00001 | HHH000342: Could not obtain connection to query metadata : Cannot load JDBC driver class 'com.microsoft.sqlserver.jdbc.SQLServerDriver'

      Thanks,
      Gopi.