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

# Google Cloud Storage

CData Sync アプリケーションからGoogle Cloud Storage コネクタを使用して、サポートされている任意のデータソースから同期先のGoogle Cloud Storage へデータを移動できます。これを行うには、コネクタを追加し、コネクタへの認証を行い、接続を完了する必要があります。## LakeBridge Connector for Delta Parquet and Apache Iceberg**Delta Parquet** および**Apache Iceberg** ファイル形式には、LakeBridge コネクタが必要です。Google Cloud Storage 同期先をこれらのいずれかのファイル形式で構成する前に、Sync にLakeBridge コネクタをインストールしてください。Sync は、起動時に、ローカルマシン上でLakeBridge サーバーをバックグラウンドサービスとして起動します。Delta Parquet またはApache Iceberg のジョブが実行されると、LakeBridge サーバーはそのジョブ専用のSpark JVM を起動し、ジョブの終了後にシャットダウンします。これにより、各ジョブのメモリが分離され、独立したSpark セッションで複数のジョブを並列に実行できます。デフォルトでは、最大3つのLakeBridge ジョブを同時に実行できます。この上限は、**システム設定** > **高度な設定** > **その他の設定**の`MaxConcurrentLakeBridgeJobs` 設定で変更できます。詳細については、[メモリ管理](https://docs.sync.cdata.com/26.4/ja/getting-started/installation-and-configuration/memory-management.md)を参照してください。LakeBridge コネクタをインストールするには：<ol>
  <li>Sync で、**接続**に移動します。</li>

  <li>
    Google Cloud Storage の行の末尾にある\*\*... > コネクタをアップデート\*\*を選択します。

    > [!NOTE]
    >
    > この手順を完了する前に、Google Cloud Storage コネクタを追加する必要があります。手順については、以下の「Google Cloud Storage コネクタを追加」を参照してください。
  </li>

  <li>**コネクタをアップデート**ダイアログで**新しいバージョンを追加**を選択します。</li>
  <li>CData Sync サポートチームから提供された`lakebridge.zip` ファイルをアップロードします。</li>
  <li>**更新**をクリックします。</li>
</ol>新しいバージョンのLakeBridge コネクタをインストールすると、LakeBridge サーバーが停止し、次回のジョブ実行時に自動的に再起動します。Sync の再起動は不要です。## Microsoft Windows Prerequisites for Delta ParquetMicrosoft Windows オペレーティングシステム（OS）でGoogle Cloud Storage 同期先を**Delta Parquet** ファイル形式で設定する前に、お使いの環境が以下で説明する要件を満たしていることを確認してください。これらの前提条件により、Sync がWindows 環境下で必要なHadoop バイナリを検出し、Delta Lake と正しく連携できるようになります。以下のようにWindows OS を設定します：<ul><li>Hadoop バイナリをダウンロードします（推奨バージョン：2.8.1 以降）。</li>
<li>`HADOOP_HOME` 環境変数がHadoop のインストールディレクトリを指すようにします。</li>
<li>`%HADOOP_HOME%\bin` が`PATH` システム変数に含まれていることを確認します（具体的には、`%HADOOP_HOME%\bin\winutils.exe` にアクセスできる必要があります）。</li></ul>この設定が必要な理由は、Delta Lake（Spark 上）がHadoop のファイルシステムAPI を使用して、ローカルストレージ、Hadoop 分散ファイルシステム（HDFS）、およびGoogle Cloud Storage のようなクラウドオブジェクトストアにアクセスするためです。Windows 環境下では、Spark が正しく機能するために、Hadoop バイナリ（winutils.exe やその他のネイティブライブラリを含む）を検出できる必要があります。この設定を行わないと、Delta テーブルへの書き込み、チェックポイントの管理、クラウドストレージへのアクセスなどの操作が、権限エラーやファイルシステムエラーで失敗することがあります。## Supported File FormatsWhen Sync writes data to Google Cloud Storage, you can choose the file format for the exported data. The following file formats are supported for the Google Cloud Storage destination:- (Default) **Delta Parquet：** A format that uses a Delta Lake storage layer on top of the Parquet file format that is used by Sync to support delta processing. *Delta processing* is a method where, after your initial job run, only new or modified files are written or read in subsequent runs, which can reduce job times and resource use.

  **Limitations:**

  * **Naming restrictions:** Table and column names cannot include special characters or reserved SQL and Delta Lake keywords. Examples of special characters include spaces, commas, semicolons, braces, parentheses, equal signs, and the newline (`\n`) and tab (`\t`) characters.
  * **Primary keys:** Primary key constraints are not supported. Sync uses the source primary keys for incremental replication.
  * **Data types:** Unlike traditional databases, Delta Lake does not support column-size definitions (for example, `VARCHAR(100)`). It supports only a fixed set of data types and allows type widening when necessary.
  * **Schema changes:** The ALTER TABLE command supports only adding new columns. Changing the data type of an existing column (for example, from INT to VARCHAR) is not supported.
  * **Delete operations:** In standard jobs, both hard and soft deletions are supported. In CDC and enhanced CDC jobs, only soft deletions are supported.
- **Apache Iceberg：** A high-performance table format that supports atomicity, consistency, isolation, and durability (ACID) transactions and schema evolution.
- **CSV：** Plain text comma-separated values.
- **Avro：** A row-based binary format that supports schema evolution.
- **Parquet：** A columnar storage format that is optimized for analytics.## Authentication PrerequisitesIf you want to authenticate with a Google Cloud service account (for silent authentication or delegated organization-wide access), do the following before you configure your connection in Sync:- Create a service account in Google Cloud and grant it the required permissions on your bucket or project.
- For OAuth JWT authentication, register a custom OAuth application and download the certificate file (.p12 or .pfx).
- For Service Account Key File authentication (**Delta Parquet** only), download the JSON key file for the service account.Then proceed to the relevant authentication method below.## Google Cloud Storage コネクタを追加Sync でGoogle Cloud Storage のデータを使用できるようにするには、まず以下の手順でコネクタを追加する必要があります：<ol>
  <li>Sync のダッシュボードから**接続**ページを開きます。</li>
  <li>**接続を追加**をクリックして**コネクタを選択**ページを開きます。</li>
  <li>**同期先**タブをクリックして
  **Google Cloud Storage** 行に移動します。</li>

  <li>
    行末にある**接続を設定**アイコンをクリックして、**新しい接続**ページを開きます。この操作により、
    **接続を追加**ダイアログボックスが開きます。

    **Note：** **接続を設定**アイコンが表示されない場合は、**コネクタをダウンロード**アイコンをクリックして Google Cloud Storage コネクタをインストールしてください。
  </li>

  <li>**接続を追加**ダイアログボックスに接続名を入力します。</li>
  <li>**追加**をクリックして、コネクタの**設定**タブを開きます。</li>
</ol>新しいコネクタのインストールについての詳細は、
[接続](https://docs.sync.cdata.com/26.4/ja/connections/connections.md)を参照してください。## Google Cloud Storage への認証After you add the connector, you need to set the required properties.- **File Format:** Select the file format that you want to use: **Delta Parquet** (default), **Apache Iceberg**, **CSV**, **Avro**, or **Parquet**.
- **URI:** Enter the path to the name of the bucket and folder that contain your files (for example, `gs://_BucketName/RemotePath`).
- **Project Id**: Enter the identifier (Id) of the project where your Google Cloud Storage instance resides.

  **Note:** This property is **required** only with the Avro file format. For other file formats, the property is optional and it is set in [Complete Your Connection](#接続を完了する).CData Sync supports authenticating to Google Cloud Storage in several ways. Select your authentication method below to proceed to the relevant section that contains the authentication details.- [**Service Account Key File**](#service-account-key-file) (**Delta Parquet** file format only)
- [**OAuth**](#oauth) (default)
- [**OAuth PKCE**](#oauth-pkce)
- [**OAuth JWT**](#oauth-jwt)
- [**GCP Instance Account**](#gcp-instance-account)**Note:** The full list of authentication methods above are for all file formats except **Delta Parquet**. That format uses only the **Service Account Key File** method.### Service Account Key FileTo connect with a service account key file, specify the following properties:- **Auth Scheme:** Select **ServiceAccountKeyFile**.
- **Key file path:** Enter the path where the JSON key file for the service account is located.### OAuthTo connect with OAuth custom credentials, specify the following properties:- **Auth Scheme:** Select **OAuth**.
- **OAuth Version:** Select the version of OAuth that you want to use. The default version is **2.0**.
- (Optional) **Scope:** Specify the scope of your access to the application.
- (Optional) **OAuth Authorization URL:** Enter the OAuth authorization URL for the OAuth service.
- (Optional) **OAuth Access Token URL:** Enter the URL from which to retrieve the access token.
- (Optional) **OAuth Refresh Token URL:** Enter the URL from which to refresh the OAuth token.### OAuth PKCECData Sync provides an embedded OAuth application with which to connect. To connect with the OAuth PKCE extension, specify the following properties:- **Auth Scheme:** select **OAuthPKCE**.
- **OAuth Client Id:** Enter the client Id that you were assigned when you registered your application with an OAuth authorization server.### OAuth JWT
      

Google Cloud Storage アカウントで接続するには、次のプロパティを指定します：


      \<ul><li>**Auth Scheme：****OAuthJWT** を選択。</li>
        \<li>**OAuth JWT Cert：**Java web token（JWT）証明書ストアを入力。</li>
        \<li>**OAuth JWT Cert Type：**JWT 証明書を格納するキーストアの種類を入力。デフォルトの種類は**PEMKEY_BLOB** です。</li>
        \<li>**OAuth Client Id：**OAuth 認証サーバーにアプリケーションを登録した際に割り当てられたクライアント識別子（Id）を入力。</li>
        \<li>**OAuth Client Secret：**OAuth 認証サーバーにアプリケーションを登録した際に割り当てられたクライアントシークレットを入力。</li>
        \<li>（オプション）**Scope：**アプリケーションへのアクセス範囲を入力。</li>
        \<li>（オプション）**OAuth Authorization URL：**OAuth サービスのOAuth 認可URL を入力。</li>
        \<li>（オプション）**OAuth Access Token URL：**アクセストークンを取得するURL を入力。</li>
        \<li>（オプション）**OAuth Refresh Token URL：**OAuth トークンを更新するURL を入力。</li>
        \<li>（オプション）**OAuth JWT Cert Password：**OAuth JWT 証明書のパスワードを入力。</li>
        \<li>（オプション）**OAuth JWT Cert Subject：**OAuth JWT 証明書のサブジェクトを入力。</li>
        \<li>（オプション）**OAuth JWT Subject：**アプリケーションが委任されたアクセスを要求するユーザーサブジェクトを入力。</li>
        \<li>（オプション）**OAuth JWT Subject Type：**JWT 認証のサブジェクトの種類（**enterprise** または**user**）を選択。デフォルトの種類は**enterprise** です。</li>
        \<li>（オプション）**OAuth JWT Public Key Id：**JWT のパブリックキーのId を入力。</li></ul>
    ### GCP Instance AccountGCP 仮想マシンでCData Sync を実行すると、Sync は仮想マシンに紐づけられたサービスアカウントを使用して認証できます。そのアカウントを使用するには、**Auth Scheme** で**GCPInstanceAccount** を選択します。追加のプロパティは必要ありません。## 接続を完了するTo complete your connection:1) Specify the following properties:

   **For all file formats:**

   * (Optional) **Project Id**: Enter the identifier (Id) of the project where your Google Cloud Storage instance resides.

     **Note:** This property is **required** for the Avro file format, and it is set in [Authenticate to Google Cloud Storage](#google-cloud-storage-への認証)

   **For the Delta Parquet and CSV file formats:**

   * **FMT:** Enter the format that you want to use to parse all text files. The default format is **CsvDelimited**.
   * **Aggregate Files:** Select whether you want to aggregate all the files that are located in the URI directory and that have the same schema into a single table named AggregatedFiles. By default, the **Enable** checkbox is not selected.
   * **Include Column Headers:** Select whether you want to obtain column headers from the first lines of the specified files. By default, the **Enable** checkbox is already selected.

   **For the Avro and Parquet file formats:**

   * **Data Model:** Select the data model that you want to use to parse documents for your format and to generate the database metadata. The default data model is **Document**.
   * **Aggregate Files:** Select whether you want to aggregate all the files that are located in the URI directory and that have the same schema into a single table named AggregatedFiles. By default, the **Enable** checkbox is not selected.<ol start="2"><li>**Advanced** タブで詳細な接続設定を定義します。（ただし、ほとんどの場合、これらの設定は不要です。）</li>
<li>OAuth or OAuthPKCE で認証する場合は、**Google Cloud Storage への接続**をクリックして Google Cloud Storage アカウントに接続します。</li>
<li>**作成およびテスト**をクリックして接続を作成します。</li></ol>## 詳細について


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.