Kafka Connect 实现错误 [英] Kafka Connect implementation errors

查看:35
本文介绍了Kafka Connect 实现错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在这里运行教程:http://kafka.apache.org/documentation.html#介绍

当我进入第 7 步:使用 Kafka Connect 导入/导出数据"并尝试启动两个连接器时,我收到以下错误:

When I get to "Step 7: Use Kafka Connect to import/export data" and attempt to start two connectors I am getting the following errors:

ERROR Failed to flush WorkerSourceTask{id=local-file-source-0}, timed out while waiting for producer to flush outstanding messages, 1 left

ERROR Failed to commit offsets for WorkerSourceTask

这是教程的一部分:

接下来,我们将启动两个以独立模式运行的连接器,这意味着它们在单个本地专用进程中运行.我们提供三个配置文件作为参数.第一个始终是 Kafka Connect 进程的配置,包含常见配置,例如要连接的 Kafka 代理和数据的序列化格式.其余的配置文件各自指定要创建的连接器.这些文件包括唯一的连接器名称、要实例化的连接器类以及连接器所需的任何其他配置.bin/connect-standalone.sh config/connect-standalone.properties config/connect-file-source.properties config/connect-file-sink.properties

Next, we'll start two connectors running in standalone mode, which means they run in a single, local, dedicated process. We provide three configuration files as parameters. The first is always the configuration for the Kafka Connect process, containing common configuration such as the Kafka brokers to connect to and the serialization format for data. The remaining configuration files each specify a connector to create. These files include a unique connector name, the connector class to instantiate, and any other configuration required by the connector. bin/connect-standalone.sh config/connect-standalone.properties config/connect-file-source.properties config/connect-file-sink.properties

我花了一些时间寻找解决方案,但找不到任何有用的东西.任何帮助表示赞赏.

I have spent some time looking for a solution, but was unable to find anything useful. Any help is appreciated.

谢谢!

推荐答案

我收到此错误的原因是我使用 config/server.properties 创建的第一台服务器没有运行.我假设因为它是主题的主角,所以无法刷新消息并且无法提交偏移量.

The reason I was getting this error was because the first server I created using the config/server.properties was not running. I am assuming that because it is the lead of the topic, the messages could not be flushed and the offsets could not be committed.

一旦我使用服务器属性 (config/server.properties) 启动了 kafka 服务器,这个问题就解决了.

Once I started the kafka server using the server propertes (config/server.properties) This issue was resolved.

这篇关于Kafka Connect 实现错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆