{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-@l10n/ja/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":[]},"type":"markdown"},"seo":{"title":"Google Cloud Storage Import Integration","description":"Google Cloud Storageからデータをインポートし、Treasure AIで分析するための簡単な接続方法を説明します。JSONキーファイルを使用して認証し、*.tsvおよび*.csvファイルを簡単に取り込めます。","siteUrl":"https://docs.treasure.ai","lang":"en-US","jsonLd":{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://www.treasure.ai/","name":"Treasure AI","url":"https://www.treasure.ai/","logo":"https://www.treasure.ai/hubfs/assets/images/logos/primary-logo.svg"},{"@type":"WebSite","@id":"https://docs.treasure.ai/#website","name":"Treasure AI Documentation","url":"https://docs.treasure.ai/","inLanguage":["en","ja"],"publisher":{"@id":"https://www.treasure.ai/"}}]},"llmstxt":{"hide":false,"sections":[{"title":"Table of contents","includeFiles":["**/*"],"excludeFiles":[]}],"excludeFiles":[]}},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"google-cloud-storage-import-integration","__idx":0},"children":["Google Cloud Storage Import Integration"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Google Cloud Storage用のData Connectorは、GCSバケットに保存されている*.tsvおよび*.csvファイルの内容のインポートを可能にします。Export Integrationについては、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/ja/int/google-cloud-storage-export-integration"},"children":["Google Cloud Storage Export Integration"]},"を参照してください。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"前提条件","__idx":1},"children":["前提条件"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Treasure Dataの基本的な知識"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["既存のGoogle Service Account"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Google Developers ConsoleからJSONキーファイルを生成し取得すること。",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://cloud.google.com/storage/docs/authentication#generating-a-private-key"},"children":["Generating a service account credential"]},"を参照してください。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"treasure-data-integration-の静的-ip-アドレス","__idx":2},"children":["Treasure Data Integration の静的 IP アドレス"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["セキュリティポリシーで IP ホワイトリストが必要な場合は、接続を成功させるために Treasure Data の IP アドレスを許可リストに追加する必要があります。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["リージョンごとに整理された静的 IP アドレスの完全なリストは、次のリンクにあります:"," ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/apis/endpoints/ip-addresses-integrations-result-workers"},"children":["IP Addresses for Integrations"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"treasure-コンソールを使用したgoogle-cloud-storageからのインポート","__idx":3},"children":["Treasure コンソールを使用したGoogle Cloud Storageからのインポート"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"新しい接続の作成","__idx":4},"children":["新しい接続の作成"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データ接続を設定する際、インテグレーションにアクセスするための認証情報を提供します。Treasure Dataでは、認証を設定してからソース情報を指定します。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure コンソールを開きます。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Integrations Hub > Catalogに移動します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Google Cloud Storageを検索して選択します。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image-20191206-003009.5434e471c33eac02c339db73bbed82434413cc8071dba89ed7deb8ddd0aadf75.276f5576.png","alt":""},"children":[]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["次のダイアログが開きます。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image-20191015-135359.53e904e28e902844ebd25df2bb8175971839b949f891dfca43c844b31eddb9a3.276f5576.png","alt":""},"children":[]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["新しいGoogle Cloud Storage Connectorを作成します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["以下のパラメータを設定します:"]}]}]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"パラメータ"},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["パラメータ"]}]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"説明"},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["説明"]}]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Authentication mode"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["JSON keyfileを選択します。この方法では、Google Developers Consoleから生成されたJSONキーファイルを使用します。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["JSON Keyfile"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Google Developers Consoleから生成されたJSONキーファイルの内容をこのフィールドにコピー&ペーストします。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Application Name"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"em","attributes":{},"children":["Treasure Data GCS Output"]},"がデフォルト値です。これはAPIリクエストに関連付けられる任意のクライアント名であるため、デフォルト値(Treasure Data GCS Output)のままにすることができます。"]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"接続に名前を付ける","__idx":5},"children":["接続に名前を付ける"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["接続の名前を入力します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Done"]},"を選択します。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"google-cloud-storageアカウントデータをtreasure-dataに転送","__idx":6},"children":["Google Cloud StorageアカウントデータをTreasure Dataに転送"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["認証済み接続を作成すると、自動的にAuthenticationsに移動します。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["作成した接続を検索します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["New Source"]},"を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Data Transferフィールドで",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Source"]},"の名前を入力します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Next"]},"をクリックします。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image-20200812-232831.affaea454b73d8f5b11d439a2861c2bebbc1ec0f2064f926499cb200aca2c3fd.276f5576.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"source-table","__idx":7},"children":["Source Table"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Next"]},"を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Source Tableダイアログが開きます。以下のパラメータを編集します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image-20200812-233240.257493d38be492509c623f3cd8c55696fe1c29868b4ece21d6a07df9da44204f.276f5576.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"パラメータ"},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["パラメータ"]}]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"説明"},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["説明"]}]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Bucket"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["Google Cloud Storageバケット名(例: ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["your_bucket_name"]},")"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Path Prefix"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["ターゲットキーのプレフィックス。(例: ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["logs/data_"]},")"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Path Regex"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["ファイルパスに一致させるための正規表現。ファイルパスがこのパターンに一致しない場合、そのファイルはスキップされます。(例: ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":[".csv$"]}," # この場合、パスがこのパターンに一致しないファイルはスキップされます。)"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Start after path"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"em","attributes":{},"children":["last_path"]},"パラメータを挿入して、最初の実行時にこのパスより前のファイルをスキップします。(例: ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["logs/data_20170101.csv"]},")"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Incremental"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["インクリメンタルローディングを有効にします。インクリメンタルローディングが有効な場合、次回実行の設定差分には",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["last_path"]},"パラメータが含まれるため、次回実行時にそのパスより前のファイルがスキップされます。それ以外の場合、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["last_path"]},"は含まれません。"]}]}]}]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["例: CloudFront Log"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Amazon CloudFrontは、静的および動的Webコンテンツの配信を高速化するWebサービスです。CloudFrontを設定して、CloudFrontが受信するすべてのユーザーリクエストに関する詳細情報を含むログファイルを作成できます。ロギングを有効にすると、次のようにCloudFrontログファイルを保存できます:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"[your_bucket] - [logging] - [E231A697YXWD39.2017-04-23-15.a103fd5a.gz]\n[your_bucket] - [logging] - [E231A697YXWD39.2017-04-23-15.b2aede4a.gz]\n[your_bucket] - [logging] - [E231A697YXWD39.2017-04-23-16.594fa8e6.gz]\n[your_bucket] - [logging] - [E231A697YXWD39.2017-04-23-16.d12f42f9.gz]\n"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["この場合、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Source Table"]},"の設定は次のようになります:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Bucket"]},": your_bucket"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Path Prefix"]},": logging/"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Path Regex"]},": ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":[".gz$"]}," (必須ではありません)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Start after path"]},": logging/E231A697YXWD39.2017-04-23-15.b2aede4a.gz (2017-04-23-16からログファイルをインポートしたい場合を想定)"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Incremental"]},": true (このジョブをスケジュールしたい場合)"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"data-settings","__idx":8},"children":["Data Settings"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Next"]},"を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Data Settings"]},"ページが開きます。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["オプションで、データ設定を編集するか、ダイアログのこのページをスキップします。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/image-20200812-233941.d8cb1d6af994f3003283498c0e8f4fdd0616979d4c642b7f1d77133672b71b99.276f5576.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"img","attributes":{"src":"/assets/google-cloud-storage-import-integration-2025-02-24-1.50f24e1fb8d74b8ce877136a26f616367cb488af0944ab631593ae069465fa36.276f5576.png","alt":""},"children":[]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"parser","__idx":9},"children":["Parser"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"パラメータ"},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["パラメータ"]}]},{"$$mdtype":"Tag","name":"th","attributes":{"data-label":"説明"},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["説明"]}]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Type"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["以下のタイプがサポートされています:   - Avro - CSV - json - Query String"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Default timezone"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["値自体にタイムゾーンが含まれていない場合、タイムスタンプカラムのタイムゾーンを変更します。"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Total file count limit"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["読み取るファイルの最大数。(オプション)"]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Schema Settings"]}]},{"$$mdtype":"Tag","name":"td","attributes":{},"children":["カラムに名前を付けてデータ型を設定できます。TDは指定されたデータ型として値を解析します。その後、Treasure Dataスキーマに変換して保存します。   - ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["boolean"]}," - ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["long"]}," - ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["timestamp"]},": Treasure DataではString型としてインポートされます(例: 2017-04-01 00:00:00.000) - ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["double"]}," - ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["string"]}," - ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["json"]}]}]}]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"data-preview","__idx":10},"children":["Data Preview"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["インポートを実行する前に、Generate Preview を選択してデータの",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/products/customer-data-platform/integration-hub/batch/import/previewing-your-source-data"},"children":["プレビュー"]},"を表示できます。Data preview はオプションであり、選択した場合はダイアログの次のページに安全にスキップできます。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Next"]}," を選択します。Data Preview ページが開きます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["データをプレビューする場合は、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Generate Preview"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["データを確認します。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"data-placement","__idx":11},"children":["Data Placement"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データの配置について、データを配置したいターゲット database と table を選択し、インポートを実行する頻度を指定します。"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Next"]}," を選択します。Storage の下で、インポートされたデータを配置する新しい database を作成するか、既存の database を選択し、新しい table を作成するか、既存の table を選択します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Database"]}," を選択 > ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Select an existing"]}," または ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Create New Database"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["オプションで、database 名を入力します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Table"]}," を選択 > ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Select an existing"]}," または ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Create New Table"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["オプションで、table 名を入力します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データをインポートする方法を選択します。"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Append"]}," (デフォルト) - データインポートの結果は table に追加されます。"," ","table が存在しない場合は作成されます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Always Replace"]}," - 既存の table の全体の内容をクエリの結果出力で置き換えます。table が存在しない場合は、新しい table が作成されます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Replace on New Data"]}," - 新しいデータがある場合のみ、既存の table の全体の内容をクエリの結果出力で置き換えます。"]}]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Timestamp-based Partition Key"]}," 列を選択します。"," ","デフォルトキーとは異なるパーティションキーシードを設定したい場合は、long または timestamp 列をパーティショニング時刻として指定できます。デフォルトの時刻列として、add_time フィルターで upload_time を使用します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データストレージの ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Timezone"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Schedule"]}," の下で、このクエリを実行するタイミングと頻度を選択できます。"]}]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"一度だけ実行","__idx":12},"children":["一度だけ実行"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Off"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Scheduling Timezone"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Create & Run Now"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":4,"id":"定期的に繰り返す","__idx":13},"children":["定期的に繰り返す"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["On"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Schedule"]}," を選択します。UI では、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["@hourly"]},"、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["@daily"]},"、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["@monthly"]},"、またはカスタム ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["cron"]}," の 4 つのオプションが提供されます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Delay Transfer"]}," を選択して、実行時間の遅延を追加することもできます。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Scheduling Timezone"]}," を選択します。"]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":[{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Create & Run Now"]}," を選択します。"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["転送が実行された後、",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Data Workbench"]}," > ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":["Databases"]}," で転送の結果を確認できます。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"workflowを使用したgoogle-cloud-storageからのインポート","__idx":14},"children":["Workflowを使用したGoogle Cloud Storageからのインポート"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["GCSからデータをインポートするサンプルワークフローについては、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://github.com/treasure-data/treasure-boxes/tree/master/td_load/gcs"},"children":["Treasure Boxes"]},"を参照してください。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"clitoolbelt経由でのgoogle-cloud-storageからのインポート","__idx":15},"children":["CLI(Toolbelt)経由でのGoogle Cloud Storageからのインポート"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["コネクタを設定する前に、最新のTD Toolbeltをインストールしてください。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Data Connectorは、\"boolean\"、\"long\"、\"double\"、\"string\"、\"timestamp\"タイプの解析をサポートしています。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"seed-config-file-seedymlの作成","__idx":16},"children":["Seed Config File (seed.yml)の作成"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["JSONキーファイルを使用して",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["seed.yml"]},"を準備します。また、バケット名とターゲットファイル名(または複数ファイルのプレフィックス)を指定する必要があります。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"yaml","header":{"controls":{"copy":{}}},"source":"in:\n  type: gcs\n  bucket: sample_bucket\n  path_prefix: path/to/sample_file  # path the the *.csv or *.tsv file on your GCS bucket\n  auth_method: json_key\n  json_keyfile:\n    content: |\n      {\n        \"private_key_id\": \"1234567890\",\n        \"private_key\": \"-----BEGIN PRIVATE KEY-----\\nABCDEF\",\n        \"client_id\": \"...\",\n        \"client_email\": \"...\",\n        \"type\": \"service_account\"\n      }\nout:\n  mode: append\n","lang":"yaml"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Data Connector for Google Cloud Storageは、指定されたプレフィックスに一致するすべてのファイルをインポートします。（例: path_prefix: ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_"]}," –> ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_201501.csv.gz"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_201502.csv.gz"]},", …, ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_201505.csv.gz"]},"）"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"フィールドの推測loadymlの生成","__idx":17},"children":["フィールドの推測（load.ymlの生成）"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"em","attributes":{},"children":["connector:guess"]},"を使用します。このコマンドは、対象ファイルを自動的に読み取り、ファイル形式をインテリジェントに推測します。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"td connector:guess seed.yml -o load.yml\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"em","attributes":{},"children":["load.yml"]},"を開くと、ファイル形式、エンコーディング、カラム名、型など、推測されたファイル形式定義が表示されます。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"yaml","header":{"controls":{"copy":{}}},"source":"in:\n  type: gcs\n  bucket: sample_bucket\n  path_prefix: path/to/sample_file\n  auth_method: json_key\n  json_keyfile:\n    content: |\n      {\n        \"private_key_id\": \"1234567890\",\n        \"private_key\": \"-----BEGIN PRIVATE KEY-----\\nABCDEF\",\n        \"client_id\": \"...\",\n        \"client_email\": \"...\",\n        \"type\": \"service_account\"\n      }\n  decoders:\n  - {type: gzip}\n  parser:\n    charset: UTF-8\n    newline: CRLF\n    type: csv\n    delimiter: ','\n    quote: '\"'\n    escape: ''\n    skip_header_lines: 1\n    columns:\n    - name: id\n      type: long\n    - name: company\n      type: string\n    - name: customer\n      type: string\n    - name: created_at\n      type: timestamp\n      format: '%Y-%m-%d %H:%M:%S'\nout:\n  mode: append\n","lang":"yaml"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"em","attributes":{},"children":["preview"]},"コマンドを使用すると、システムがファイルをどのように解析するかをプレビューできます。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"td connector:preview load.yml\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["guessコマンドは、ソースデータファイルに3行以上、2列以上必要です。これは、ソースデータのサンプル行を使用してカラム定義を推測するためです。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["システムがカラム名やカラム型を予期せず検出した場合は、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["load.yml"]},"を直接修正して再度プレビューしてください。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["previewコマンドは、指定されたバケットから1つのファイルをダウンロードし、そのファイルからの結果を表示します。そのため、previewコマンドとissueコマンドの結果に違いが生じる場合があります。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"ロードジョブの実行","__idx":18},"children":["ロードジョブの実行"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["ロードジョブを送信します。データのサイズによっては、数時間かかる場合があります。ユーザーは、データが保存されるデータベースとテーブルを指定する必要があります。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure Dataのストレージは時間によってパーティション分割されているため、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["--time-column"]},"オプションを指定することをお勧めします。オプションが指定されていない場合、Data Connectorは最初の",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["long"]},"または",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["timestamp"]},"カラムをパーティション分割時間として選択します。",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["--time-column"]},"で指定するカラムの型は、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["long"]},"または",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["timestamp"]},"型のいずれかである必要があります。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["データに時間カラムがない場合は、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["add_time"]},"フィルターオプションを使用して追加できます。詳細については、",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"https://docs.treasuredata.com/smart/project-product-documentation/add_time-filter-function"},"children":["add_timeフィルタープラグイン"]},"を参照してください。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"td connector:issue load.yml --database td_sample_db --table td_sample_table   --time-column created_at\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["前述のコマンドは、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["database(td_sample_db)",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["と"]},"table(td_sample_table)",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["がすでに作成されていることを前提としています。データベースまたはテーブルがTDに存在しない場合、このコマンドは成功しないため、データベースとテーブルを手動で作成するか、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["td connector:issue"]},"コマンドで"]},"--auto-create-table"]},"オプションを使用してデータベースとテーブルを自動作成してください。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"td connector:issue load.yml --database td_sample_db --table td_sample_table --time-column created_at --auto-create-table\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Data Connectorはサーバー側でレコードをソートしません。時間ベースのパーティション分割を効果的に使用するには、ファイル内のレコードを事前にソートしてください。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"em","attributes":{},"children":["time"]},"というフィールドがある場合は、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["--time-column"]},"オプションを指定する必要はありません。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"td connector:issue load.yml --database td_sample_db --table td_sample_table\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"スケジュール実行","__idx":19},"children":["スケジュール実行"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["増分Google Cloud Storageファイルインポートのために、定期的なData Connector実行をスケジュールできます。TDはスケジューラーを慎重に管理して、高可用性を確保します。この機能を使用することで、ローカルデータセンターで",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["cron"]},"デーモンを使用する必要がなくなります。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["スケジュールインポートの場合、Data Connector for Google Cloud Storageは、最初に指定されたプレフィックスに一致するすべてのファイルをインポートし（例: path_prefix: ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_"]}," –> ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_201501.csv.gz"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_201502.csv.gz"]},", …, ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_201505.csv.gz"]},"）、次回の実行のために最後のパス（",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_201505.csv.gz"]},"）を記憶します。"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["2回目以降の実行では、アルファベット順（辞書順）で最後のパスの後に来るファイルのみをインポートします。（",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["path/to/sample_201506.csv.gz"]},", …）"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"スケジュールの作成","__idx":20},"children":["スケジュールの作成"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["新しいスケジュールは、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["td connector:create"]},"コマンドを使用して作成できます。スケジュールの名前、cron形式のスケジュール、データが保存されるデータベースとテーブル、およびData Connector設定ファイルが必要です。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"td connector:create daily_import \"10 0 * * *\" td_sample_db td_sample_table load.yml\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Treasure Dataのストレージは時間によってパーティション分割されているため、",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["--time-column"]},"オプションを指定することもお勧めします。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"bash","header":{"controls":{"copy":{}}},"source":"td connector:create daily_import \"10 0 * * *\" td_sample_db td_sample_table load.yml --time-column created_at\n","lang":"bash"},"children":[]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["cron"]},"パラメータは、3つの特別なオプションも受け入れます：",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["@hourly"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["@daily"]},"、",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["@monthly"]},"。デフォルトでは、スケジュールはUTCタイムゾーンで設定されます。-tまたは--timezoneオプションを使用して、タイムゾーンでスケジュールを設定できます。",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["--timezone"]},"オプションは、'Asia/Tokyo'、'America/Los_Angeles'などの拡張タイムゾーン形式のみをサポートしています。PST、CSTなどのタイムゾーン略語は*サポートされておらず*、予期しないスケジュールになる可能性があります。"]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":3,"id":"スケジュールの一覧表示","__idx":21},"children":["スケジュールの一覧表示"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"em","attributes":{},"children":["td connector:list"]},"コマンドを実行すると、現在スケジュールされているエントリのリストを確認できます。"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"$ td connector:list\n"},"children":[]}]},"headings":[{"value":"Google Cloud Storage Import Integration","id":"google-cloud-storage-import-integration","depth":1},{"value":"前提条件","id":"前提条件","depth":2},{"value":"Treasure Data Integration の静的 IP アドレス","id":"treasure-data-integration-の静的-ip-アドレス","depth":2},{"value":"Treasure コンソールを使用したGoogle Cloud Storageからのインポート","id":"treasure-コンソールを使用したgoogle-cloud-storageからのインポート","depth":2},{"value":"新しい接続の作成","id":"新しい接続の作成","depth":3},{"value":"接続に名前を付ける","id":"接続に名前を付ける","depth":3},{"value":"Google Cloud StorageアカウントデータをTreasure Dataに転送","id":"google-cloud-storageアカウントデータをtreasure-dataに転送","depth":3},{"value":"Source Table","id":"source-table","depth":3},{"value":"Data Settings","id":"data-settings","depth":3},{"value":"Parser","id":"parser","depth":3},{"value":"Data Preview","id":"data-preview","depth":3},{"value":"Data Placement","id":"data-placement","depth":3},{"value":"一度だけ実行","id":"一度だけ実行","depth":4},{"value":"定期的に繰り返す","id":"定期的に繰り返す","depth":4},{"value":"Workflowを使用したGoogle Cloud Storageからのインポート","id":"workflowを使用したgoogle-cloud-storageからのインポート","depth":2},{"value":"CLI(Toolbelt)経由でのGoogle Cloud Storageからのインポート","id":"clitoolbelt経由でのgoogle-cloud-storageからのインポート","depth":2},{"value":"Seed Config File (seed.yml)の作成","id":"seed-config-file-seedymlの作成","depth":3},{"value":"フィールドの推測（load.ymlの生成）","id":"フィールドの推測loadymlの生成","depth":3},{"value":"ロードジョブの実行","id":"ロードジョブの実行","depth":3},{"value":"スケジュール実行","id":"スケジュール実行","depth":3},{"value":"スケジュールの作成","id":"スケジュールの作成","depth":3},{"value":"スケジュールの一覧表示","id":"スケジュールの一覧表示","depth":3}],"frontmatter":{"seo":{"title":"Google Cloud Storage Import Integration","description":"Google Cloud Storageからデータをインポートし、Treasure AIで分析するための簡単な接続方法を説明します。JSONキーファイルを使用して認証し、*.tsvおよび*.csvファイルを簡単に取り込めます。"}},"lastModified":"2026-06-17T07:22:53.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/ja/int/google-cloud-storage-import-integration","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}