You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user-zh@flink.apache.org by yangxusun9 <ya...@163.com> on 2020/10/30 09:58:31 UTC

flink-cdc-mysql 使用时遇到的问题

我的flink/lib下的文件列表如下
<http://apache-flink.147419.n8.nabble.com/file/t1061/flink_lib.png> 
当我使用flink-sql client 时,查询表报错如下
<http://apache-flink.147419.n8.nabble.com/file/t1061/flink_sql_client_error.png> 

而当我尝试使用API来测试时,同样遇到了一个bug,Caused by:
org.apache.kafka.connect.errors.ConnectException: Encountered change event
for table test.order_info whose schema isn't known to this connector
代码如下:


请各位大佬帮帮孩子吧。。。。



--
Sent from: http://apache-flink.147419.n8.nabble.com/

Re: Re: flink-cdc-mysql 使用时遇到的问题

Posted by "chengyanan1008@foxmail.com" <ch...@foxmail.com>.
你好:
 这个问题我也遇到过,这是因为相关的依赖没有起作用,建议你重新启动一下Flink集群。



 
发件人: zapjone
发送时间: 2020-10-31 10:34
收件人: user-zh
主题: Re: flink-cdc-mysql 使用时遇到的问题
感觉是不是表的权限没有开哦?
 
Sent from my iPhone
 
> On Oct 31, 2020, at 10:07, yangxusun9 <ya...@163.com> wrote:
> 
> 我的flink/lib下的文件列表如下
> <http://apache-flink.147419.n8.nabble.com/file/t1061/flink_lib.png> 
> 当我使用flink-sql client 时,查询表报错如下
> <http://apache-flink.147419.n8.nabble.com/file/t1061/flink_sql_client_error.png> 
> 
> 而当我尝试使用API来测试时,同样遇到了一个bug,Caused by:
> org.apache.kafka.connect.errors.ConnectException: Encountered change event
> for table test.order_info whose schema isn't known to this connector
> 代码如下:
> 
> 
> 请各位大佬帮帮孩子吧。。。。
> 
> 
> 
> --
> Sent from: http://apache-flink.147419.n8.nabble.com/
 
 

回复: flink-cdc-mysql 使用时遇到的问题

Posted by 史 正超 <sh...@outlook.com>.
建议你发下完整的错误信息,然后不要发图片(看不到图片),这样让更多人看到后,问题就解决快了。😁
________________________________
发件人: yangxusun9 <ya...@163.com>
发送时间: 2020年11月2日 3:44
收件人: user-zh@flink.apache.org <us...@flink.apache.org>
主题: Re: flink-cdc-mysql 使用时遇到的问题

应该不是的,我用的是root账户



--
Sent from: http://apache-flink.147419.n8.nabble.com/

Re: flink-cdc-mysql 使用时遇到的问题

Posted by yangxusun9 <ya...@163.com>.
应该不是的,我用的是root账户



--
Sent from: http://apache-flink.147419.n8.nabble.com/

Re: Re: flink-cdc-mysql 使用时遇到的问题

Posted by Jark Wu <im...@gmail.com>.
你上面flink sql client 中的 ClassNotFound 异常,应该是你 flink cluster 没重启导致的 (你的 sql
client 是重启了,但是cluster 应该没重启)。

API 测试是另外的问题?能 share 以下你的 API 测试代码吗?

Best,
Jark

On Mon, 2 Nov 2020 at 11:53, yangxusun9 <ya...@163.com> wrote:

> 我在使用API的时候导入的依赖如下,
> <dependencies>
>
>     <dependency>
>         <groupId>org.apache.flink</groupId>
>         <artifactId>flink-clients_${scala.binary.version}</artifactId>
>         <version>${flink.version}</version>
>     </dependency>
>     <dependency>
>         <groupId>com.alibaba.ververica</groupId>
>
>         <artifactId>flink-connector-mysql-cdc</artifactId>
>         <version>1.1.0</version>
>     </dependency>
> </dependencies>,
> 其中flink 版本是1.11.1,<scala.binary.version>2.11</scala.binary.version>,
> *当我刚运行的时候是能读到数据的*,但是我一旦对mysql中的表执行了变更操作,程序就会抛出Encountered change event for
> table test.order_info whose schema isn't known to this connector
>
>
>
>
> --
> Sent from: http://apache-flink.147419.n8.nabble.com/
>

Re: Re: flink-cdc-mysql 使用时遇到的问题

Posted by yangxusun9 <ya...@163.com>.
我在使用API的时候导入的依赖如下,
<dependencies>

    <dependency>
        <groupId>org.apache.flink</groupId>
        <artifactId>flink-clients_${scala.binary.version}</artifactId>
        <version>${flink.version}</version>
    </dependency>
    <dependency>
        <groupId>com.alibaba.ververica</groupId>
        
        <artifactId>flink-connector-mysql-cdc</artifactId>
        <version>1.1.0</version>
    </dependency>
</dependencies>,
其中flink 版本是1.11.1,<scala.binary.version>2.11</scala.binary.version>,
*当我刚运行的时候是能读到数据的*,但是我一旦对mysql中的表执行了变更操作,程序就会抛出Encountered change event for
table test.order_info whose schema isn't known to this connector




--
Sent from: http://apache-flink.147419.n8.nabble.com/

Re: flink-cdc-mysql 使用时遇到的问题

Posted by za...@163.com.
感觉是不是表的权限没有开哦?

Sent from my iPhone

> On Oct 31, 2020, at 10:07, yangxusun9 <ya...@163.com> wrote:
> 
> 我的flink/lib下的文件列表如下
> <http://apache-flink.147419.n8.nabble.com/file/t1061/flink_lib.png> 
> 当我使用flink-sql client 时,查询表报错如下
> <http://apache-flink.147419.n8.nabble.com/file/t1061/flink_sql_client_error.png> 
> 
> 而当我尝试使用API来测试时,同样遇到了一个bug,Caused by:
> org.apache.kafka.connect.errors.ConnectException: Encountered change event
> for table test.order_info whose schema isn't known to this connector
> 代码如下:
> 
> 
> 请各位大佬帮帮孩子吧。。。。
> 
> 
> 
> --
> Sent from: http://apache-flink.147419.n8.nabble.com/