[ 
https://issues.apache.org/jira/browse/NIFI-8517?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17339872#comment-17339872
 ] 

Lukasz Borawski commented on NIFI-8517:
---------------------------------------

Here is the full error log:
{code:java}
2021-05-05 18:20:52,692 ERROR [Timer-Driven Process Thread-6] 
o.a.n.c.m.processors.CaptureChangeMySQL 
CaptureChangeMySQL[id=c36acae4-6dd9-3c4c-9fa9-20dcfcb46759] Failed to process 
session due to org.apache.nifi.processor.exception.ProcessException: Error 
creating binlog enrichment JDBC connection to any of the specified hosts: 
org.apache.nifi.processor.exception.ProcessException: Error creating binlog 
enrichment JDBC connection to any of the specified hosts
org.apache.nifi.processor.exception.ProcessException: Error creating binlog 
enrichment JDBC connection to any of the specified hosts 
    at 
org.apache.nifi.cdc.mysql.processors.CaptureChangeMySQL.setup(CaptureChangeMySQL.java:662)
    at 
org.apache.nifi.cdc.mysql.processors.CaptureChangeMySQL.onTrigger(CaptureChangeMySQL.java:676)
    at 
org.apache.nifi.controller.StandardProcessorNode.onTrigger(StandardProcessorNode.java:1173)
    at 
org.apache.nifi.controller.tasks.ConnectableTask.invoke(ConnectableTask.java:214)
    at 
org.apache.nifi.controller.scheduling.TimerDrivenSchedulingAgent$1.run(TimerDrivenSchedulingAgent.java:117)
    at org.apache.nifi.engine.FlowEngine$2.run(FlowEngine.java:110)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)
    at 
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
    at 
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
    at 
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)
Caused by: java.io.IOException: Error creating binlog enrichment JDBC 
connection to any of the specified hosts
    at 
org.apache.nifi.cdc.mysql.processors.CaptureChangeMySQL.connect(CaptureChangeMySQL.java:848)
    at 
org.apache.nifi.cdc.mysql.processors.CaptureChangeMySQL.setup(CaptureChangeMySQL.java:658)
    ... 12 common frames omitted
Caused by: java.sql.SQLException: No suitable driver found for 
jdbc:mysql://mysql.mysql.svc:3306
    at java.sql.DriverManager.getConnection(DriverManager.java:689)
    at java.sql.DriverManager.getConnection(DriverManager.java:208)
    at 
org.apache.nifi.cdc.mysql.processors.CaptureChangeMySQL$JDBCConnectionHolder.getConnection(CaptureChangeMySQL.java:1237)
    at 
org.apache.nifi.cdc.mysql.processors.CaptureChangeMySQL$JDBCConnectionHolder.access$200(CaptureChangeMySQL.java:1210)
    at 
org.apache.nifi.cdc.mysql.processors.CaptureChangeMySQL.getJdbcConnection(CaptureChangeMySQL.java:1207)
    at 
org.apache.nifi.cdc.mysql.processors.CaptureChangeMySQL.connect(CaptureChangeMySQL.java:844)
    ... 13 common frames omitted{code}
What I find weird is that when the Distributed Map Cache Client is disabled 
then the whole dataflow works fine.

May it be the case that a different driver is being used depending on if the 
Distributed Map Cache Client is enabled or not?

Thanks

> Cannot enable Distributed Map Cache Client in CaptureChangeMySQL
> ----------------------------------------------------------------
>
>                 Key: NIFI-8517
>                 URL: https://issues.apache.org/jira/browse/NIFI-8517
>             Project: Apache NiFi
>          Issue Type: Bug
>          Components: Core Framework
>    Affects Versions: 1.12.1, 1.13.2
>            Reporter: Lukasz Borawski
>            Priority: Major
>              Labels: features
>         Attachments: Screen Shot 2021-05-05 at 19.50.24.png, reproduction.xml
>
>
> If I don't enable the Distributed Map Cache Client property in the 
> CaptureChangeMySQL processor I get a warning log:
> {{"No Distributed Map Cache Client is specified, so no event enrichment 
> (resolution of column names, e.g.) will be performed."}}
>  
> If I enable the Distributed Map Cache Client I get the following error:
> {{"Error creating binlog enrichment JDBC connection to any of the specified 
> hosts"}}
>  
> Both DistributedMapCacheServer and DistributedMapCacheClientService are 
> running fine, I can communicate with the server on localhost:4557.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to