nifi-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wayne Richard <Wayne.Rich...@xpo.com>
Subject Having trouble connecting to SQL Server
Date Thu, 12 Jan 2017 15:41:44 GMT
Hello,
I am a newbie with Nifi. I am working on a simple task to use as a proof of concept. However,
I am not able to connect to SQL Server. It seems that I have not configured this correctly.

Here are the DB and Driver settings that I have:
Database Connection URL - jdbc:microsoft:sqlserver://HOST:XXXXXXXXXX;DatabaseName=XXXXXXX
Database Driver Class Name - com.microsoft.sqlserver.jdbc.SQLServerDriver
Database Driver Location - C:\NIFI\nifi-1.1.1\lib\sqljdbc_6.0\enu\sqljdbc41.jar

Here is a portion of the nifi-app.log file:
2017-01-12 10:36:17,112 ERROR [Timer-Driven Process Thread-7] o.a.nifi.processors.standard.ExecuteSQL
org.apache.nifi.processor.exception.ProcessException: org.apache.commons.dbcp.SQLNestedException:
Cannot create JDBC driver of class 'com.microsoft.sqlserver.jdbc.SQLServerDriver' for connect
URL 'jdbc:microsoft:sqlserver://HOST:COLSQLUAT6;DatabaseName=ReplicaFreightOptimizer
'
                at org.apache.nifi.dbcp.DBCPConnectionPool.getConnection(DBCPConnectionPool.java:252)
~[na:na]
                at sun.reflect.GeneratedMethodAccessor607.invoke(Unknown Source) ~[na:na]
                at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
                at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_111]
                at org.apache.nifi.controller.service.StandardControllerServiceProvider$1.invoke(StandardControllerServiceProvider.java:177)
~[na:na]
                at com.sun.proxy.$Proxy128.getConnection(Unknown Source) ~[na:na]
                at org.apache.nifi.processors.standard.ExecuteSQL.onTrigger(ExecuteSQL.java:192)
~[nifi-standard-processors-1.1.1.jar:1.1.1]
                at org.apache.nifi.processor.AbstractProcessor.onTrigger(AbstractProcessor.java:27)
[nifi-api-1.1.1.jar:1.1.1]
                at org.apache.nifi.controller.StandardProcessorNode.onTrigger(StandardProcessorNode.java:1099)
[nifi-framework-core-1.1.1.jar:1.1.1]
                at org.apache.nifi.controller.tasks.ContinuallyRunProcessorTask.call(ContinuallyRunProcessorTask.java:136)
[nifi-framework-core-1.1.1.jar:1.1.1]
                at org.apache.nifi.controller.tasks.ContinuallyRunProcessorTask.call(ContinuallyRunProcessorTask.java:47)
[nifi-framework-core-1.1.1.jar:1.1.1]
                at org.apache.nifi.controller.scheduling.TimerDrivenSchedulingAgent$1.run(TimerDrivenSchedulingAgent.java:132)
[nifi-framework-core-1.1.1.jar:1.1.1]
                at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [na:1.8.0_111]
                at java.util.concurrent.FutureTask.runAndReset(Unknown Source) [na:1.8.0_111]
                at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown
Source) [na:1.8.0_111]
                at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown
Source) [na:1.8.0_111]
                at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [na:1.8.0_111]
                at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [na:1.8.0_111]
                at java.lang.Thread.run(Unknown Source) [na:1.8.0_111]
Caused by: org.apache.commons.dbcp.SQLNestedException: Cannot create JDBC driver of class
'com.microsoft.sqlserver.jdbc.SQLServerDriver' for connect URL 'jdbc:microsoft:sqlserver://HOST:COLSQLUAT6;DatabaseName=ReplicaFreightOptimizer
'
                at org.apache.commons.dbcp.BasicDataSource.createConnectionFactory(BasicDataSource.java:1452)
~[na:na]
                at org.apache.commons.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:1371)
~[na:na]
                at org.apache.commons.dbcp.BasicDataSource.getConnection(BasicDataSource.java:1044)
~[na:na]
                at org.apache.nifi.dbcp.DBCPConnectionPool.getConnection(DBCPConnectionPool.java:249)
~[na:na]
                ... 18 common frames omitted
Caused by: java.sql.SQLException: No suitable driver
                at java.sql.DriverManager.getDriver(Unknown Source) ~[na:1.8.0_111]
                at org.apache.commons.dbcp.BasicDataSource.createConnectionFactory(BasicDataSource.java:1437)
~[na:na]
                ... 21 common frames omitted

Thanks in advance for any assistance!


Wayne Richard
Business Intelligence Engineer II
XPOLogistics
13777 Ballantyne Corporate
Charlotte, NC 28277 US
O: 980-224-5110  | M: 704-798-7941




Unless otherwise agreed to in a written agreement signed by the applicable XPO company, any
transportation or logistics services provided by that XPO company are subject to the limitations
of liability (including cargo loss and damage) and terms and conditions in the applicable
tariff or terms for the mode or type of transportation or services requested. These tariffs
or terms, which set forth XPO and its customers' respective rights and responsibilities, are
available in the business terms section of XPO website at www.xpo.com or by emailing stc@xpo.com.

Mime
View raw message