blob: 869e8bce85b2ed26d963644fb3d7a5ee3dcda969 [file] [log] [blame]
# ---------------------------------------------------------------------------
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# ---------------------------------------------------------------------------
apiVersion: camel.apache.org/v1alpha1
kind: Kamelet
metadata:
name: google-bigquery-sink
annotations:
camel.apache.org/kamelet.support.level: "Preview"
camel.apache.org/catalog.version: "0.8.1"
camel.apache.org/kamelet.icon: "data:image/svg+xml;base64,PHN2ZyBoZWlnaHQ9IjI1MDAiIHdpZHRoPSIyNTAwIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9Ii0xLjYzMzIzNTQzMzMyODI1NiA3LjAzMjYwOTMzMDMxNTY1NjUgMTMxLjI2NTc0NjgyNDE2ODc2IDExNC42MzQzOTA2Njk2ODQzNSI+PGxpbmVhckdyYWRpZW50IGlkPSJhIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjY0IiB4Mj0iNjQiIHkxPSI3LjAzNCIgeTI9IjEyMC43ODkiPjxzdG9wIG9mZnNldD0iMCIgc3RvcC1jb2xvcj0iIzQzODdmZCIvPjxzdG9wIG9mZnNldD0iMSIgc3RvcC1jb2xvcj0iIzQ2ODNlYSIvPjwvbGluZWFyR3JhZGllbnQ+PHBhdGggZD0iTTI3Ljc5IDExNS4yMTdMMS41NCA2OS43NDlhMTEuNDk5IDExLjQ5OSAwIDAgMSAwLTExLjQ5OWwyNi4yNS00NS40NjdhMTEuNSAxMS41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g2MXpNODAuNjkxIDc4LjI4N2wtMi40MDMgMi40MDVhMS4wODggMS4wODggMCAwIDAgMCAxLjUzN2w5LjExNSA5LjExMmExLjA4OCAxLjA4OCAwIDAgMCAxLjUzNyAwbDIuNDAzLTIuNDAyYTEuMDkyIDEuMDkyIDAgMCAwIDAtMS41MzZsLTkuMTE2LTkuMTE2YTEuMDkgMS4wOSAwIDAgMC0xLjUzNiAwIi8+PC9nPjwvc3ZnPg=="
camel.apache.org/provider: "Apache Software Foundation"
camel.apache.org/kamelet.group: "Google Big Query"
labels:
camel.apache.org/kamelet.type: "sink"
spec:
definition:
title: "Google Big Query Sink"
description: |-
Send data to a Google Big Query table.
It is expected the body is in Json format representing an object or an array of objects.
The credentialsFileLocation property needs to be a path to a service account key file.
required:
- projectId
- dataset
- table
- credentialsFileLocation
type: object
properties:
projectId:
title: Google Cloud Project Id
description: Google Cloud Project id
type: string
dataset:
title: Big Query Dataset Id
description: The Big Query Dataset Id
type: string
table:
title: Big Query Table Id
description: The Big Query Table Id
type: string
credentialsFileLocation:
title: Google Cloud Platform Credential File
description: The credential to access Google Cloud Platform api services
type: string
x-descriptors:
- urn:camel:group:credentials
types:
in:
mediaType: application/json
dependencies:
- "camel:core"
- "camel:kamelet"
- "camel:google-bigquery"
- "camel:jackson"
template:
beans:
- name: connectionFactoryBean
type: "#class:org.apache.camel.component.google.bigquery.GoogleBigQueryConnectionFactory"
property:
- key: credentialsFileLocation
value: '{{credentialsFileLocation}}'
from:
uri: "kamelet:source"
steps:
- unmarshal:
json:
library: Jackson
- to:
uri: "google-bigquery:{{projectId}}:{{dataset}}:{{table}}"
parameters:
connectionFactory: "#bean:{{connectionFactoryBean}}"