> ## Documentation Index
> Fetch the complete documentation index at: https://clickhouse.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

> 最初の Amazon S3 ClickPipe を作成するためのステップごとのガイド。

# 最初の Amazon S3 ClickPipe を作成する

export const Image = ({img, alt, size = "lg"}) => {
  const normalizedSize = ["sm", "md", "lg"].includes(size) ? size : "lg";
  return <div className={`ch-image-${normalizedSize}`}>
      <Frame>
        <img src={img} alt={alt} />
      </Frame>
    </div>;
};

S3 ClickPipe は、Amazon S3 および S3互換オブジェクトストアから ClickHouse Cloud にデータを取り込むための、フルマネージドで耐障害性に優れた仕組みです。**一回限り**と**継続的インジェスト**の両方に対応し、exactly-once セマンティクスを備えています。

<Steps>
  <Step title="データソースを選択" id="1-select-the-data-source">
    **1.** ClickHouse Cloud のメインナビゲーションメニューで **Data sources** を選択し、**Create ClickPipe** をクリックします。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_step0.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=fb04bb07245be43cb784fa68cee62287" alt="インポートを選択" width="2606" height="790" data-path="images/integrations/data-ingestion/clickpipes/cp_step0.webp" />
    </Frame>

    **2.** **Amazon S3** タイルをクリックします。このタイルを使用すると、ClickPipes UI に表示されていないその他の S3 互換サービスにも接続できます。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/object-storage/amazon-s3/cp_step1.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=5df9a6650380fcad80cc09d0324fff66" alt="インポートを選択" width="3016" height="954" data-path="images/integrations/data-ingestion/clickpipes/object-storage/amazon-s3/cp_step1.webp" />
    </Frame>

    <Tip>
      オブジェクトストレージサービスプロバイダーごとに URL 形式や API 実装が異なるため、すべての S3 互換サービスがそのままサポートされているわけではありません。[サポートされているデータソース](/docs/ja/integrations/clickpipes/object-storage/amazon-s3/overview#supported-data-sources) に記載されていないサービスで問題が発生した場合は、[当社チームまでお問い合わせください](https://clickhouse.com/company/contact?loc=clickpipes)。
    </Tip>
  </Step>

  <Step title="ClickPipe 接続を設定する" id="2-setup-your-clickpipe-connection">
    **1.** 新しい ClickPipe を設定するには、オブジェクトストレージサービスへの接続方法と認証方法に関する詳細を入力する必要があります。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/object-storage/amazon-s3/cp_step2.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=4b560decaf2b046c1ecd43fc4ace8902" alt="接続の詳細を入力" width="3014" height="1402" data-path="images/integrations/data-ingestion/clickpipes/object-storage/amazon-s3/cp_step2.webp" />
    </Frame>

    * **認証方法**: S3 ClickPipe は、[IAM credentials](/docs/ja/integrations/clickpipes/object-storage/amazon-s3/overview#iam-credentials) (`Credentials`) および [IAM role-based authentication](/docs/ja/integrations/clickpipes/object-storage/amazon-s3/overview#iam-role) (`IAM role`) をサポートしています。認証と権限の詳細については、[リファレンスドキュメント](/docs/ja/integrations/clickpipes/object-storage/amazon-s3/overview#access-control)を参照してください。

      * **S3 ファイルパス**: S3 ClickPipe では、[virtual-hosted-style URI](https://docs.aws.amazon.com/AmazonS3/latest/userguide/VirtualHosting.html#virtual-hosted-style-access) 形式の URI を想定しています。

        ```bash theme={null}
        https://bucket-name.s3.region-code.amazonaws.com/key-name
        ```

        POSIX ワイルドカードを使って、複数のファイルやプレフィックスに一致させることができます。サポートされているパターンの詳細については、[リファレンスドキュメント](/docs/ja/integrations/clickpipes/object-storage/amazon-s3/overview#file-pattern-matching)を参照してください。

    **2.** **Incoming data** をクリックします。ClickPipes が次の手順に向けてバケットからメタデータを取得します。
  </Step>

  <Step title="データフォーマットを選択" id="3-select-data-format">
    UI に、指定した bucket 内のファイル一覧が表示されます。
    データフォーマット (現在対応しているのは ClickHouse のフォーマットの一部です) と、継続的インジェストを有効にするかどうかを選択してください。
    詳細は、概要ページの「continuous ingest」セクションを参照してください。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_step3_object_storage.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=e3c03fbaec5b6db3810a4380343c42b9" alt="データフォーマットと topic を設定" width="2336" height="1566" data-path="images/integrations/data-ingestion/clickpipes/cp_step3_object_storage.webp" />
    </Frame>
  </Step>

  <Step title="テーブル、スキーマ、設定を構成" id="5-configure-table-schema-settings">
    次のステップでは、新しい ClickHouse テーブルにデータを取り込むか、既存のテーブルを再利用するかを選択できます。
    画面の指示に従って、テーブル名、スキーマ、設定を変更してください。
    上部のサンプルテーブルで、変更内容のリアルタイムプレビューを確認できます。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_step4a.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=e0cdb9469f6867e897cc77541af7f59b" alt="テーブル、スキーマ、設定を設定" width="2734" height="1328" data-path="images/integrations/data-ingestion/clickpipes/cp_step4a.webp" />
    </Frame>

    用意されているコントロールを使って、高度な設定をカスタマイズすることもできます。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_step4a3.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=db7cb839e136d26563b239937f029c7a" alt="高度なコントロールを設定" width="1592" height="338" data-path="images/integrations/data-ingestion/clickpipes/cp_step4a3.webp" />
    </Frame>

    または、既存の ClickHouse テーブルにデータを取り込むこともできます。
    その場合、UI でソースのフィールドを、選択した宛先テーブル内の ClickHouse のフィールドにマッピングできます。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_step4b.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=a5cb66aa9b3855c5d53b340dbd89b108" alt="既存のテーブルを使用" width="2738" height="1322" data-path="images/integrations/data-ingestion/clickpipes/cp_step4b.webp" />
    </Frame>

    <Info>
      [仮想カラム](/docs/ja/reference/functions/table-functions/s3#virtual-columns) (`_path` や `_size` など) をフィールドにマッピングすることもできます。
    </Info>
  </Step>

  <Step title="権限を構成" id="6-configure-permissions">
    最後に、内部 ClickPipes ユーザーの権限を構成できます。

    **権限:** ClickPipes は、宛先テーブルにデータを書き込むための専用ユーザーを作成します。カスタムロール、または事前定義されたロールのいずれかを使って、この内部ユーザーに割り当てるロールを選択できます。

    * `Full access`: クラスターへのフルアクセス。宛先テーブルで materialized view または Dictionary を使用する場合に必要です。
    * `Only destination table`: 宛先テーブルに対する `INSERT` 権限のみ。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_step5.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=71ea5baaa2c38fcc83b160f4856264ab" alt="権限" width="2736" height="1318" data-path="images/integrations/data-ingestion/clickpipes/cp_step5.webp" />
    </Frame>
  </Step>

  <Step title="セットアップを完了" id="7-complete-setup">
    「Complete Setup」をクリックすると、システムに ClickPipe が登録され、サマリーテーブルに表示されるようになります。

    <div className="ch-image-sm">
      <Frame>
        <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_success.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=ce045b4a85e7f294d23c03897e9ce11f" alt="成功通知" width="613" height="212" data-path="images/integrations/data-ingestion/clickpipes/cp_success.webp" />
      </Frame>
    </div>

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_remove.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=83b452ee5d8017da1b1c0d50cf8a491d" alt="削除通知" width="2756" height="1320" data-path="images/integrations/data-ingestion/clickpipes/cp_remove.webp" />
    </Frame>

    サマリーテーブルには、ソースまたは ClickHouse 内の宛先テーブルからサンプルデータを表示するためのコントロールがあります。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_destination.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=cb3ebed0c324cb30c6cbf35726b3bec7" alt="宛先を表示" width="2758" height="1316" data-path="images/integrations/data-ingestion/clickpipes/cp_destination.webp" />
    </Frame>

    また、ClickPipe を削除したり、インジェストジョブの概要を表示したりするためのコントロールもあります。

    <Frame>
      <img src="https://mintcdn.com/private-7c7dfe99/Rm4A9_kDxZf0ApeE/images/integrations/data-ingestion/clickpipes/cp_overview.webp?fit=max&auto=format&n=Rm4A9_kDxZf0ApeE&q=85&s=1ce91f5079842cfc66a4c88919f2e061" alt="概要を表示" width="3436" height="1076" data-path="images/integrations/data-ingestion/clickpipes/cp_overview.webp" />
    </Frame>

    **おめでとうございます！** 最初の ClickPipe のセットアップが正常に完了しました。
    この ClickPipe が継続的インジェスト用に構成されている場合は、継続的に稼働し、リモートのデータソースからデータをリアルタイムで取り込み続けます。
    それ以外の場合は、Batch を取り込んで完了します。
  </Step>
</Steps>
