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

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

commit 1b2997640c58600c172a171b3549216cfad8de93
Author: Andrea Cosentino <[email protected]>
AuthorDate: Fri Jun 25 11:38:19 2021 +0200

    Added MongoDB Source Kamelet
---
 mongodb-source.kamelet.yaml | 68 +++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 68 insertions(+)

diff --git a/mongodb-source.kamelet.yaml b/mongodb-source.kamelet.yaml
new file mode 100644
index 0000000..83e8501
--- /dev/null
+++ b/mongodb-source.kamelet.yaml
@@ -0,0 +1,68 @@
+apiVersion: camel.apache.org/v1alpha1
+kind: Kamelet
+metadata:
+  name: mongodb-source
+  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,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB2aWV3Qm94PSIwIDAgMzEgNjciIGZpbGw9IiNmZmYiIGZpbGwtcnVsZT0iZXZlbm9kZCIgc3Ryb2tlPSIjMDAwIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjx1c2UgeGxpbms6aHJlZj0iI0EiIHg9IjEiIHk9IjEiLz48c3ltYm9sIGlkPSJBIiBvdmVyZmxvdz0idmlzaWJsZSI+PGcgc3Ryb2tlPSJub25lIiBmaWxsLXJ1bGU9Im5vbnplcm8iPjxwYXRoIGQ9Ik0xNC4xNzQuMTc1bD
 [...]
+    camel.apache.org/provider: "Apache Software Foundation"
+    camel.apache.org/kamelet.group: "MongoDB"
+  labels:
+    camel.apache.org/kamelet.type: "source"
+spec:
+  definition:
+    title: "MongoDB Source"
+    description: |-
+      Consume documents from MongoDB
+    required:
+      - hosts
+      - collection
+      - password
+      - username
+      - database
+    type: object
+    properties:
+      hosts:
+        title: MongoDB Hosts
+        description: Comma separated list of MongoDB Host Addresses in 
host:port format.
+        type: string
+      collection:
+        title: MongoDB Collection
+        description: Sets the name of the MongoDB collection to bind to this 
endpoint.
+        type: string
+      password:
+        title: MongoDB Password
+        description: User password for accessing MongoDB.
+        type: string
+        format: password
+        x-descriptors:
+          - urn:alm:descriptor:com.tectonic.ui:password
+      username:
+        title: MongoDB Username
+        description: Username for accessing MongoDB.
+        type: string
+      database:
+        title: MongoDB Database
+        description: Sets the name of the MongoDB database to target.
+        type: string
+  dependencies:
+    - "camel:kamelet"
+    - "camel:mongodb"
+    - "camel:jackson"
+  flow:
+    beans:
+      - name: local-mongodb
+        type: "#class:org.apache.camel.component.mongodb.MongoDbComponent"
+    from:
+      uri: "{{local-mongodb}}:test"
+      parameters:
+        hosts: "{{hosts}}"
+        collection: "{{collection}}"
+        password: "{{password}}"
+        username: "{{username}}"
+        database: "{{database}}"
+      steps:
+      - marshal:
+          json: {}
+      - to: kamelet:sink

Reply via email to