Snowflake High Performance connector for Kafka¶
本主题介绍 Snowflake High Performance connector for Kafka 的基本概念、用例、优势、主要功能和限制。
备注
Snowflake High Performance connector for Kafka 是一个 接收器连接器,用于从 Kafka 主题读取数据并将该数据加载到 Snowflake 表中。有关 Kafka Connect 及其框架的更多信息,请参阅 Apache Kafka 与 Kafka Connect 框架。
优势¶
Snowflake High Performance connector for Kafka 利用了 Snowflake 的 高性能 Snowpipe Streaming 架构,该架构专为数据密集型的现代组织打造,能够实现近实时见解。这种下一代架构显著提高了实时引入 Snowflake 的吞吐量、效率和灵活性。
高性能架构具有以下几个关键优势:
卓越的吞吐量和延迟:旨在支持每个表高达 10 GB/秒的引入速度,端到端引入到查询的延迟在 5 到 10 秒内,从而实现近乎实时的分析。
简化计费:提供基于吞吐量的透明计费,使成本更具可预测性且更易于理解。
增强的性能:使用基于 Rust 的客户端核心,与之前的实现相比,它提供了更高的客户端性能和更低的资源占用。
传输中的数据转换:支持在引入过程中使用 PIPE 对象中的 COPY 命令语法进行数据清洗和整形,允许您在数据到达目标表之前对其进行转换。
服务器端架构验证:通过 PIPE 对象将架构验证从客户端移动到服务器端,确保了数据质量并降低了客户端的复杂性。
预聚类功能:当目标表定义了聚类键时,可以在数据引入期间对数据进行聚类,从而在无需引入后维护的情况下提高查询性能。
连接器使用 Snowflake PIPE 对象作为管理引入的核心组件。PIPE 对象充当所有流数据的入口点和定义层,定义了数据在提交到目标表之前如何进行处理、转换和验证。有关连接器如何与表和管道配合工作的更多信息,请参阅 连接器如何与表和管道配合使用。
选择连接器版本¶
Kafka Connector 在 Kafka Connect 集群中运行,从 Kafka 主题读取数据并写入 Snowflake 表。
Snowflake 提供两个版本的连接器。两个版本的连接器都为从 Kafka 到 Snowflake 的流式传输数据提供相同的核心功能。
Confluent version of the connector
高性能 Snowflake Connector for Kafka 尚未在 Confluent Cloud 上提供。如果您使用的是 Confluent Cloud,则必须作为自定义插件连接器手动安装连接器。
The Confluent version is packaged as a zip file for installation through Confluent Hub or Confluent Control Center and includes all external libraries required to run the connector.
Choose this version if you're using the Confluent Platform or Confluent Cloud.
请联系 Snowflake 支持部门以获取并安装 Confluent 版本的连接器。
For more information, see Kafka Connect (https://docs.confluent.io/current/connect/).
OSS Apache Kafka version of the connector
可从 开源软件 (OSS) Apache Kafka 包 (https://mvnrepository.com/artifact/com.snowflake/snowflake-kafka-connector/) 获取。
The Apache version is distributed as a standard fat JAR file and requires manual installation into your Apache Kafka Connect cluster. This version requires Bouncy Castle (https://www.bouncycastle.org/) cryptography libraries that must be downloaded separately.
For more information, see Apache Kafka (https://kafka.apache.org/).
限制¶
Snowflake High Performance connector for Kafka 有以下限制。
- 从 3.x 及更低版本迁移现有管道
The connector does not support migration of the existing pipelines from version 3.x and earlier. You must manually migrate the existing pipelines to the new connector. Ensure that existing pipelines don't rely on any features that are not yet available with this connector.
- 单消息转换 (SMTs):
使用社区转换器时,大多数单消息转换 (SMTs) 均受支持,但
regex.router目前尚未支持。
有关 SMTs 的更多信息,请参阅 针对 Confluent Cloud 或 Confluent Platform 的 Kafka Connect 单消息转换参考 (https://docs.confluent.io/current/connect/transforms/index.html)。
Snowflake support for the connector¶
The following table describes the supported versions and information about pre-release and release candidates.
版本系列 |
状态 |
备注 |
|---|---|---|
4.x.x |
私密预览版 |
Early access. Currently the migration from 3.x and 2.x is not supported. |
3.x.x |
官方支持 |
最新版本,强烈推荐。 |
2.xx |
官方支持 |
建议升级。 |
1.x.x |
不支持 |
不支持的功能¶
不支持以下功能:
- Iceberg 表
不支持引入到 Iceberg 表中。
- Not all broken records are sent to Dead Letter Queue (DLQ) by the connector
在配置了
errors.tolerance=all和errors.deadletterqueue.topic.name的情况下,连接器保证 最多一次 交付。只有不可转换的记录会由 Kafka Connect 发送到 DLQ。Snowflake 摄取失败的记录不会路由到该处;Snowpipe Streaming 可以检测到记录失败,但无法确定具体是哪些记录。- 引入失败的损坏记录需要手动重试
When
errors.tolerance=noneandrows_error_countincreases, the connector task fails. To retry broken records, review the channel history to find the broken records. For more information about troubleshooting broken records and ingestion errors see error handling. You can also use gap finding technique described in 使用元数据偏移检测并恢复错误. Kafka offset information needed to use this technique is available in theRECORD_METADATAcolumn.
Breaking changes in the Preview version¶
See the release notes for the Preview versions for a list of breaking changes
4.0.0-rc1 (https://github.com/snowflakedb/snowflake-kafka-connector/releases/tag/v4.0.0-rc1)
4.0.0-rc2 (https://github.com/snowflakedb/snowflake-kafka-connector/releases/tag/v4.0.0-rc2)
4.0.0-rc3 (https://github.com/snowflakedb/snowflake-kafka-connector/releases/tag/v4.0.0-rc3)
4.0.0-rc4 (https://github.com/snowflakedb/snowflake-kafka-connector/releases/tag/v4.0.0-rc4)
4.0.0-rc5 (https://github.com/snowflakedb/snowflake-kafka-connector/releases/tag/v4.0.0-rc5)
后续步骤¶
Review how the connector works topic for more information about how the connector works with tables and pipes. . Review 为 Snowflake High Performance connector for Kafka 设置任务 topic for the steps to set up the Snowflake High Performance connector for Kafka.