312 lines
17 KiB
JSON
312 lines
17 KiB
JSON
|
|
{
|
||
|
|
"apiVersion": "camel.apache.org/v1",
|
||
|
|
"kind": "Kamelet",
|
||
|
|
"metadata": {
|
||
|
|
"name": "ibm-cos-source",
|
||
|
|
"annotations": {
|
||
|
|
"camel.apache.org/kamelet.support.level": "Preview",
|
||
|
|
"camel.apache.org/catalog.version": "4.22.1",
|
||
|
|
"camel.apache.org/kamelet.icon": "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjUwMCIgaGVpZ2h0PSIyNTAwIiB2aWV3Qm94PSIwIDAgMjU2IDI1NiIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiBwcmVzZXJ2ZUFzcGVjdFJhdGlvPSJ4TWlkWU1pZCI+PHBhdGggZD0iTTAgMGgyNTZ2MjU2SDB6IiBmaWxsPSIjMDUzMzYyIi8+PHBhdGggZD0iTTE4Ny43MzIgMTI1LjkxOGMtLjAzNi0xLjM1Ny0uMDktMi43MTQtLjE4LTQuMDcyLS4wMzYtLjUyMi0uMDkxLTEuMDQ1LS4xMjgtMS41NjctLjA1NC0uNjEzLS4xMDgtMS4yMjYtLjE4LTEuODM5LS4wNzItLjc3LS4xOC0xLjU0LS4yODgtMi4zMWEzOS43NjYgMzkuNzY2IDAgMCAwLS40MTYtMi4zNjRjLS4xNDQtLjc3LS4zMDYtMS41NC0uNDctMi4yOTJhNDAuODEzIDQwLjgxMyAwIDAgMC0uNjMtMi4zMS40MDkuNDA5IDAgMCAxLS4wNTUtLjEyNiA0MC40OTIgNDAuNDkyIDAgMCAwLS43MjItMi4yMThjLS4yNTItLjcwNC0uNTIyLTEuMzc1LS43OTMtMi4wNjYtLjMwNi0uNzIyLS42My0xLjQyNi0uOTczLTIuMTMtLjMyNS0uNjY3LS42ODYtMS4zMzQtMS4wNDUtMS45ODItLjM2LS42MzEtLjczOS0xLjI2My0xLjExNy0xLjg3Ni0uNDctLjc1OC0uOTU1LTEuNDk4LTEuND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QzNC44MTIuNjQ5LjM0MS4yNzEuNjg1LjU0IDEuMDQ1Ljc5M2E0MC42ODYgNDAuNjg2I
|
||
|
|
"camel.apache.org/provider": "Apache Software Foundation",
|
||
|
|
"camel.apache.org/kamelet.group": "IBM Cloud Object Storage",
|
||
|
|
"camel.apache.org/kamelet.namespace": "IBM"
|
||
|
|
},
|
||
|
|
"labels": {
|
||
|
|
"camel.apache.org/kamelet.type": "source"
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"spec": {
|
||
|
|
"definition": {
|
||
|
|
"title": "IBM Cloud Object Storage Source",
|
||
|
|
"description": "Receive data from an IBM Cloud Object Storage Bucket.",
|
||
|
|
"required": [
|
||
|
|
"bucketName",
|
||
|
|
"apiKey",
|
||
|
|
"serviceInstanceId",
|
||
|
|
"endpointUrl"
|
||
|
|
],
|
||
|
|
"type": "object",
|
||
|
|
"properties": {
|
||
|
|
"bucketName": {
|
||
|
|
"title": "Bucket Name",
|
||
|
|
"description": "The IBM COS Bucket name.",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"apiKey": {
|
||
|
|
"title": "API Key",
|
||
|
|
"description": "IBM Cloud API Key for authentication.",
|
||
|
|
"type": "string",
|
||
|
|
"format": "password",
|
||
|
|
"x-descriptors": [
|
||
|
|
"urn:camel:group:credentials"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"serviceInstanceId": {
|
||
|
|
"title": "Service Instance ID",
|
||
|
|
"description": "IBM COS Service Instance ID (CRN).",
|
||
|
|
"type": "string",
|
||
|
|
"format": "password",
|
||
|
|
"x-descriptors": [
|
||
|
|
"urn:camel:group:credentials"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"endpointUrl": {
|
||
|
|
"title": "Endpoint URL",
|
||
|
|
"description": "IBM COS Endpoint URL (e.g., https://s3.us-south.cloud-object-storage.appdomain.cloud).",
|
||
|
|
"type": "string",
|
||
|
|
"example": "https://s3.us-south.cloud-object-storage.appdomain.cloud"
|
||
|
|
},
|
||
|
|
"location": {
|
||
|
|
"title": "Location",
|
||
|
|
"description": "IBM COS Location/Region (e.g., us-south, eu-gb).",
|
||
|
|
"type": "string",
|
||
|
|
"example": "us-south"
|
||
|
|
},
|
||
|
|
"deleteAfterRead": {
|
||
|
|
"title": "Auto-delete Objects",
|
||
|
|
"description": "Specifies to delete objects after consuming them.",
|
||
|
|
"type": "boolean",
|
||
|
|
"default": true
|
||
|
|
},
|
||
|
|
"moveAfterRead": {
|
||
|
|
"title": "Move Objects After Read",
|
||
|
|
"description": "Move objects from IBM COS bucket to a different bucket after they have been retrieved.",
|
||
|
|
"type": "boolean",
|
||
|
|
"default": false
|
||
|
|
},
|
||
|
|
"destinationBucket": {
|
||
|
|
"title": "Destination Bucket",
|
||
|
|
"description": "Define the destination bucket where an object must be moved when moveAfterRead is set to true.",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"destinationBucketPrefix": {
|
||
|
|
"title": "Destination Bucket Prefix",
|
||
|
|
"description": "Define the destination bucket prefix to use when an object must be moved, and moveAfterRead is set to true.",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"destinationBucketSuffix": {
|
||
|
|
"title": "Destination Bucket Suffix",
|
||
|
|
"description": "Define the destination bucket suffix to use when an object must be moved, and moveAfterRead is set to true.",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"autoCreateBucket": {
|
||
|
|
"title": "Autocreate Bucket",
|
||
|
|
"description": "Specifies to automatically create the IBM COS bucket.",
|
||
|
|
"type": "boolean",
|
||
|
|
"default": false
|
||
|
|
},
|
||
|
|
"prefix": {
|
||
|
|
"title": "Prefix",
|
||
|
|
"description": "The IBM COS bucket prefix to consider while searching.",
|
||
|
|
"type": "string",
|
||
|
|
"example": "folder/"
|
||
|
|
},
|
||
|
|
"delimiter": {
|
||
|
|
"title": "Delimiter",
|
||
|
|
"description": "The delimiter to use for listing objects.",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"includeBody": {
|
||
|
|
"title": "Include Body",
|
||
|
|
"description": "If true, the object body is included in the exchange. If false, only headers are set.",
|
||
|
|
"type": "boolean",
|
||
|
|
"default": true
|
||
|
|
},
|
||
|
|
"includeFolders": {
|
||
|
|
"title": "Include Folders",
|
||
|
|
"description": "Include folders/directories when listing objects.",
|
||
|
|
"type": "boolean",
|
||
|
|
"default": true
|
||
|
|
},
|
||
|
|
"delay": {
|
||
|
|
"title": "Delay",
|
||
|
|
"description": "The number of milliseconds before the next poll of the selected bucket.",
|
||
|
|
"type": "integer",
|
||
|
|
"default": 500
|
||
|
|
},
|
||
|
|
"maxMessagesPerPoll": {
|
||
|
|
"title": "Max Messages Per Poll",
|
||
|
|
"description": "Gets the maximum number of messages as a limit to poll at each polling. The default value is 10. Use 0 or a negative number to set it as unlimited.",
|
||
|
|
"type": "integer",
|
||
|
|
"default": 10
|
||
|
|
}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"dataTypes": {
|
||
|
|
"out": {
|
||
|
|
"default": "binary",
|
||
|
|
"headers": {
|
||
|
|
"CamelIbmCosBucketName": {
|
||
|
|
"title": "IBM COS Bucket Name",
|
||
|
|
"description": "The bucket name which has been used to retrieve objects",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"CamelIbmCosKey": {
|
||
|
|
"title": "IBM COS Key",
|
||
|
|
"description": "The key under which the retrieved object is stored.",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"CamelIbmCosContentType": {
|
||
|
|
"title": "Content Type",
|
||
|
|
"description": "The content type of the retrieved object.",
|
||
|
|
"default": "application/octet-stream",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"CamelIbmCosETag": {
|
||
|
|
"title": "ETag Value",
|
||
|
|
"description": "The hex encoded 128-bit MD5 digest of the associated object according to RFC 1864.",
|
||
|
|
"type": "string"
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"types": {
|
||
|
|
"binary": {
|
||
|
|
"format": "application-octet-stream",
|
||
|
|
"description": "Default binary representation of the IBM COS object retrieved from the bucket.",
|
||
|
|
"mediaType": "application/octet-stream"
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"dependencies": [
|
||
|
|
"camel:core",
|
||
|
|
"camel:ibm-cos",
|
||
|
|
"camel:kamelet"
|
||
|
|
],
|
||
|
|
"template": {
|
||
|
|
"from": {
|
||
|
|
"uri": "ibm-cos:{{bucketName}}",
|
||
|
|
"parameters": {
|
||
|
|
"apiKey": "{{apiKey}}",
|
||
|
|
"serviceInstanceId": "{{serviceInstanceId}}",
|
||
|
|
"endpointUrl": "{{endpointUrl}}",
|
||
|
|
"location": "{{?location}}",
|
||
|
|
"deleteAfterRead": "{{deleteAfterRead}}",
|
||
|
|
"moveAfterRead": "{{moveAfterRead}}",
|
||
|
|
"destinationBucket": "{{?destinationBucket}}",
|
||
|
|
"destinationBucketPrefix": "{{?destinationBucketPrefix}}",
|
||
|
|
"destinationBucketSuffix": "{{?destinationBucketSuffix}}",
|
||
|
|
"autoCreateBucket": "{{autoCreateBucket}}",
|
||
|
|
"prefix": "{{?prefix}}",
|
||
|
|
"delimiter": "{{?delimiter}}",
|
||
|
|
"includeBody": "{{includeBody}}",
|
||
|
|
"includeFolders": "{{includeFolders}}",
|
||
|
|
"delay": "{{delay}}",
|
||
|
|
"maxMessagesPerPoll": "{{maxMessagesPerPoll}}"
|
||
|
|
},
|
||
|
|
"steps": [
|
||
|
|
{
|
||
|
|
"to": "kamelet:sink"
|
||
|
|
}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"propertiesSchema": {
|
||
|
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
||
|
|
"type": "object",
|
||
|
|
"title": "IBM Cloud Object Storage Source",
|
||
|
|
"description": "Receive data from an IBM Cloud Object Storage Bucket.",
|
||
|
|
"required": [
|
||
|
|
"bucketName",
|
||
|
|
"apiKey",
|
||
|
|
"serviceInstanceId",
|
||
|
|
"endpointUrl"
|
||
|
|
],
|
||
|
|
"properties": {
|
||
|
|
"bucketName": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Bucket Name",
|
||
|
|
"description": "The IBM COS Bucket name."
|
||
|
|
},
|
||
|
|
"apiKey": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "API Key",
|
||
|
|
"description": "IBM Cloud API Key for authentication.",
|
||
|
|
"format": "password"
|
||
|
|
},
|
||
|
|
"serviceInstanceId": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Service Instance ID",
|
||
|
|
"description": "IBM COS Service Instance ID (CRN).",
|
||
|
|
"format": "password"
|
||
|
|
},
|
||
|
|
"endpointUrl": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Endpoint URL",
|
||
|
|
"description": "IBM COS Endpoint URL (e.g., https://s3.us-south.cloud-object-storage.appdomain.cloud)."
|
||
|
|
},
|
||
|
|
"location": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Location",
|
||
|
|
"description": "IBM COS Location/Region (e.g., us-south, eu-gb)."
|
||
|
|
},
|
||
|
|
"deleteAfterRead": {
|
||
|
|
"type": "boolean",
|
||
|
|
"title": "Auto-delete Objects",
|
||
|
|
"description": "Specifies to delete objects after consuming them.",
|
||
|
|
"default": true
|
||
|
|
},
|
||
|
|
"moveAfterRead": {
|
||
|
|
"type": "boolean",
|
||
|
|
"title": "Move Objects After Read",
|
||
|
|
"description": "Move objects from IBM COS bucket to a different bucket after they have been retrieved.",
|
||
|
|
"default": false
|
||
|
|
},
|
||
|
|
"destinationBucket": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Destination Bucket",
|
||
|
|
"description": "Define the destination bucket where an object must be moved when moveAfterRead is set to true."
|
||
|
|
},
|
||
|
|
"destinationBucketPrefix": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Destination Bucket Prefix",
|
||
|
|
"description": "Define the destination bucket prefix to use when an object must be moved, and moveAfterRead is set to true."
|
||
|
|
},
|
||
|
|
"destinationBucketSuffix": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Destination Bucket Suffix",
|
||
|
|
"description": "Define the destination bucket suffix to use when an object must be moved, and moveAfterRead is set to true."
|
||
|
|
},
|
||
|
|
"autoCreateBucket": {
|
||
|
|
"type": "boolean",
|
||
|
|
"title": "Autocreate Bucket",
|
||
|
|
"description": "Specifies to automatically create the IBM COS bucket.",
|
||
|
|
"default": false
|
||
|
|
},
|
||
|
|
"prefix": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Prefix",
|
||
|
|
"description": "The IBM COS bucket prefix to consider while searching."
|
||
|
|
},
|
||
|
|
"delimiter": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Delimiter",
|
||
|
|
"description": "The delimiter to use for listing objects."
|
||
|
|
},
|
||
|
|
"includeBody": {
|
||
|
|
"type": "boolean",
|
||
|
|
"title": "Include Body",
|
||
|
|
"description": "If true, the object body is included in the exchange. If false, only headers are set.",
|
||
|
|
"default": true
|
||
|
|
},
|
||
|
|
"includeFolders": {
|
||
|
|
"type": "boolean",
|
||
|
|
"title": "Include Folders",
|
||
|
|
"description": "Include folders/directories when listing objects.",
|
||
|
|
"default": true
|
||
|
|
},
|
||
|
|
"delay": {
|
||
|
|
"type": "integer",
|
||
|
|
"title": "Delay",
|
||
|
|
"description": "The number of milliseconds before the next poll of the selected bucket.",
|
||
|
|
"default": 500
|
||
|
|
},
|
||
|
|
"maxMessagesPerPoll": {
|
||
|
|
"type": "integer",
|
||
|
|
"title": "Max Messages Per Poll",
|
||
|
|
"description": "Gets the maximum number of messages as a limit to poll at each polling. The default value is 10. Use 0 or a negative number to set it as unlimited.",
|
||
|
|
"default": 10
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|