You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2021/12/17 17:28:41 UTC

[camel-kamelets] 02/11: Added Google Cloud Functions Sink Kamelet

This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch gcp-functions
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git

commit 0aaa45c4e99459dae1d1b8ea79cb8ed124295dbc
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri Dec 17 18:20:18 2021 +0100

    Added Google Cloud Functions Sink Kamelet
---
 .../kamelets/google-functions-sink.kamelet.yaml    | 74 ++++++++++++++++++++++
 1 file changed, 74 insertions(+)

diff --git a/library/camel-kamelets/src/main/resources/kamelets/google-functions-sink.kamelet.yaml b/library/camel-kamelets/src/main/resources/kamelets/google-functions-sink.kamelet.yaml
new file mode 100644
index 0000000..9de189e
--- /dev/null
+++ b/library/camel-kamelets/src/main/resources/kamelets/google-functions-sink.kamelet.yaml
@@ -0,0 +1,74 @@
+# ---------------------------------------------------------------------------
+# 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-functions-sink
+  annotations:
+    camel.apache.org/kamelet.support.level: "Preview"
+    camel.apache.org/catalog.version: "main-SNAPSHOT"
+    camel.apache.org/kamelet.icon: "data:image/svg+xml;base64,PHN2ZyBoZWlnaHQ9IjI1MDAiIHZpZXdCb3g9Ii0xLjYzMzIzNTQzIDcuMDMyNjA5MzMgMTMxLjI2NTc0NjgyIDExNC40MzkzOTA2NyIgd2lkdGg9IjI1MDAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiPjxsaW5lYXJHcmFkaWVudCBpZD0iYSIgZ3JhZGllbnRVbml0cz0idXNlclNwYWNlT25Vc2UiIHgxPSI2NCIgeDI9IjY0IiB5MT0iNy4wMzQiIHkyPSIxMjAuNzg5Ij48c3RvcCBvZmZzZXQ9IjAiIHN0b3AtY29sb3I9IiM0Mzg3ZmQiLz48c3RvcCBvZmZzZXQ9IjEiIHN0b3 [...]
+    camel.apache.org/provider: "Apache Software Foundation"
+    camel.apache.org/kamelet.group: "Google Functions"
+  labels:
+    camel.apache.org/kamelet.type: "sink"
+spec:
+  definition:
+    title: "Google Functions Sink"
+    description: |-
+      Send messages to Google Functions.
+
+      The serviceAccountKey property needs to be a path to a service account key file.
+    required:
+      - projectId
+      - functionName
+      - location
+      - serviceAccountKey
+    type: object
+    properties:
+      projectId:
+        title: Project Id
+        description: The Google Cloud Functions Project Id
+        type: string
+      region:
+        title: Region 
+        description: The Region where the Google Cloud Functions has been deployed
+        type: string
+      functionName:
+        title: Function Name
+        description: The Function Name
+        type: string
+      serviceAccountKey:
+        title: Service Account Key
+        description: The Service account key that can be used as credentials for the Google Cloud Functions platform
+        type: string
+        x-descriptors:
+        - urn:camel:group:credentials
+  dependencies:
+    - "camel:kamelet"
+    - "camel:google-functions"
+    - "camel:jackson"
+  flow:
+    from:
+      uri: kamelet:source
+      steps:
+      - to:
+          uri: "google-functions://{{functionName}}"
+          parameters:
+            serviceAccountKey: "{{serviceAccountKey}}"
+            project: "{{projectId}}"
+            location: "{{region}}"