メインコンテンツまでスキップ
メインコンテンツまでスキップ

Confluent CloudとClickHouseの統合

前提条件

以下に精通していることを前提としています:

Confluent Cloudとの公式Kafkaコネクタ

トピックの作成

Confluent Cloudでトピックを作成するのは非常に簡単で、詳細な手順はこちらにあります。

重要な注意事項

  • Kafkaのトピック名はClickHouseのテーブル名と同じでなければなりません。この調整方法はトランスフォーマーを使用することです(例えば ExtractTopic)。
  • パーティションが多いことが常にパフォーマンスを向上させるわけではありません - 詳細やパフォーマンスのヒントについては、今後のガイドを参照してください。

接続情報を収集する

To connect to ClickHouse with HTTP(S) you need this information:

  • The HOST and PORT: typically, the port is 8443 when using TLS or 8123 when not using TLS.

  • The DATABASE NAME: out of the box, there is a database named default, use the name of the database that you want to connect to.

  • The USERNAME and PASSWORD: out of the box, the username is default. Use the username appropriate for your use case.

The details for your ClickHouse Cloud service are available in the ClickHouse Cloud console. Select the service that you will connect to and click Connect:

ClickHouse Cloud service connect button

Choose HTTPS, and the details are available in an example curl command.

ClickHouse Cloud HTTPS connection details

If you are using self-managed ClickHouse, the connection details are set by your ClickHouse administrator.


以下は、ClickHouseにHTTP(S)で接続するために必要な情報です:

  • HOSTとPORT: 通常、TLSを使用する場合はポートが8443、使用しない場合は8123です。

  • DATABASE NAME: デフォルトでは、defaultという名前のデータベースがあります。接続したいデータベースの名前を使用します。

  • USERNAMEとPASSWORD: デフォルトでは、ユーザー名はdefaultです。使用ケースに適したユーザー名を使用します。

ClickHouse Cloudサービスの詳細は、ClickHouse Cloudコンソールで確認できます。 接続するサービスを選択し、Connectをクリックしてください:

ClickHouse Cloud service connect button

HTTPSを選択すると、詳細はexample curlコマンドで確認できます。

ClickHouse Cloud HTTPS connection details

セルフマネージドのClickHouseを使用している場合は、接続の詳細がClickHouse管理者によって設定されます。

コネクタのインストール

Confluent Cloud上に完全に管理されたClickHouse Sink Connectorをインストールするには、公式ドキュメントに従ってください。

コネクタの設定

ClickHouse Sink Connectorの設定中に、以下の情報を提供する必要があります:

  • ClickHouseサーバーのホスト名
  • ClickHouseサーバーのポート(デフォルトは8443)
  • ClickHouseサーバーのユーザー名とパスワード
  • データが書き込まれるClickHouseのデータベース名
  • ClickHouseにデータを書き込むために使用されるKafkaのトピック名

Confluent CloudのUIは、パフォーマンスを最適化するためにポーリング間隔、バッチサイズ、およびその他のパラメータを調整するための高度な設定オプションをサポートしています。

知られている制限事項