203 lines
6.8 KiB
JSON
203 lines
6.8 KiB
JSON
|
|
{
|
||
|
|
"apiVersion": "camel.apache.org/v1",
|
||
|
|
"kind": "Kamelet",
|
||
|
|
"metadata": {
|
||
|
|
"name": "spring-rabbitmq-sink",
|
||
|
|
"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,PHN2ZyB3aWR0aD0iMjcxcHgiIGhlaWdodD0iMjcxcHgiIHZpZXdCb3g9Ii03LjUgMCAyNzEgMjcxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHByZXNlcnZlQXNwZWN0UmF0aW89InhNaWRZTWlkIj48cGF0aCBkPSJNMjQ1LjQ0IDEwOC4zMDhoLTg1LjA5YTcuNzM4IDcuNzM4IDAgMCAxLTcuNzM1LTcuNzM0di04OC42OEMxNTIuNjE1IDUuMzI3IDE0Ny4yOSAwIDE0MC43MjYgMGgtMzAuMzc1Yy02LjU2OCAwLTExLjg5IDUuMzI3LTExLjg5IDExLjg5NHY4OC4xNDNjMCA0LjU3My0zLjY5NyA4LjI5LTguMjcgOC4zMWwtMjcuODg1LjEzM2MtNC42MTIuMDI1LTguMzU5LTMuNzE3LTguMzUtOC4zMjVsLjE3My04OC4yNDFDNTQuMTQ0IDUuMzM3IDQ4LjgxNyAwIDQyLjI0IDBIMTEuODlDNS4zMjEgMCAwIDUuMzI3IDAgMTEuODk0VjI2MC4yMWMwIDUuODM0IDQuNzI2IDEwLjU2IDEwLjU1NSAxMC41NkgyNDUuNDRjNS44MzQgMCAxMC41Ni00LjcyNiAxMC41Ni0xMC41NlYxMTguODY4YzAtNS44MzQtNC43MjYtMTAuNTYtMTAuNTYtMTAuNTZ6bS0zOS45MDIgOTMuMjMzYzAgNy42NDUtNi4xOTggMTMuODQ0LTEzLjg0MyAxMy44NDRIMTY3LjY5Yy03LjY0NiAwLTEzLjg0NC02LjE5OS0xMy44NDQtMTMuODQ0di0yNC4wMDVjMC03LjY0NiA2LjE5OC0xMy44NDQgMTMuODQ0LTEzLjg0NGgyNC4wMDVjNy42NDUgMCAxMy44NDMgNi4xOTggMTMuODQzIDEzLjg0NHYyNC4wMDV6IiBmaWxsPSIjRjYwIi8+PC9zdmc+",
|
||
|
|
"camel.apache.org/provider": "Apache Software Foundation",
|
||
|
|
"camel.apache.org/kamelet.group": "RabbitMQ",
|
||
|
|
"camel.apache.org/kamelet.namespace": "Messaging"
|
||
|
|
},
|
||
|
|
"labels": {
|
||
|
|
"camel.apache.org/kamelet.type": "sink"
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"spec": {
|
||
|
|
"definition": {
|
||
|
|
"title": "RabbitMQ Sink",
|
||
|
|
"description": "Send data to a RabbitMQ Broker.",
|
||
|
|
"required": [
|
||
|
|
"host",
|
||
|
|
"port",
|
||
|
|
"exchangeName"
|
||
|
|
],
|
||
|
|
"type": "object",
|
||
|
|
"properties": {
|
||
|
|
"host": {
|
||
|
|
"title": "Server Address",
|
||
|
|
"description": "RabbitMQ broker address",
|
||
|
|
"type": "string",
|
||
|
|
"example": "localhost"
|
||
|
|
},
|
||
|
|
"port": {
|
||
|
|
"title": "Server Port",
|
||
|
|
"description": "RabbitMQ broker port",
|
||
|
|
"type": "integer",
|
||
|
|
"example": 5672
|
||
|
|
},
|
||
|
|
"routingKey": {
|
||
|
|
"title": "Routing Key",
|
||
|
|
"description": "The routing key to use when binding a consumer queue to the exchange",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"username": {
|
||
|
|
"title": "Username",
|
||
|
|
"description": "The username to access the RabbitMQ server",
|
||
|
|
"type": "string",
|
||
|
|
"x-descriptors": [
|
||
|
|
"urn:camel:group:credentials"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"password": {
|
||
|
|
"title": "Password",
|
||
|
|
"description": "The password to access the RabbitMQ server",
|
||
|
|
"type": "string",
|
||
|
|
"format": "password",
|
||
|
|
"x-descriptors": [
|
||
|
|
"urn:camel:group:credentials"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"exchangeName": {
|
||
|
|
"title": "Exchange name",
|
||
|
|
"description": "The exchange name determines the exchange the queue is bound to.",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"queues": {
|
||
|
|
"title": "Queue name",
|
||
|
|
"description": "The queue to receive messages from",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"autoDeclareProducer": {
|
||
|
|
"title": "Auto Declare Producer",
|
||
|
|
"description": "Specifies whether the producer should auto declare binding between exchange, queue and routing key when starting",
|
||
|
|
"type": "boolean",
|
||
|
|
"default": false
|
||
|
|
},
|
||
|
|
"vhost": {
|
||
|
|
"title": "Virtual Host",
|
||
|
|
"description": "The virtual host",
|
||
|
|
"type": "string",
|
||
|
|
"default": "/"
|
||
|
|
},
|
||
|
|
"protocol": {
|
||
|
|
"title": "Protocol",
|
||
|
|
"description": "The AMQP protocol to use.",
|
||
|
|
"type": "string",
|
||
|
|
"enum": [
|
||
|
|
"amqp",
|
||
|
|
"amqps"
|
||
|
|
],
|
||
|
|
"default": "amqp"
|
||
|
|
}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"dependencies": [
|
||
|
|
"camel:spring-rabbitmq",
|
||
|
|
"camel:kamelet"
|
||
|
|
],
|
||
|
|
"template": {
|
||
|
|
"beans": [
|
||
|
|
{
|
||
|
|
"name": "connectionFactory",
|
||
|
|
"type": "#class:org.springframework.amqp.rabbit.connection.CachingConnectionFactory",
|
||
|
|
"properties": {
|
||
|
|
"username": "{{?username}}",
|
||
|
|
"password": "{{?password}}",
|
||
|
|
"uri": "{{protocol}}://{{host}}:{{port}}",
|
||
|
|
"virtualHost": "{{vhost}}"
|
||
|
|
}
|
||
|
|
}
|
||
|
|
],
|
||
|
|
"from": {
|
||
|
|
"uri": "kamelet:source",
|
||
|
|
"steps": [
|
||
|
|
{
|
||
|
|
"to": {
|
||
|
|
"uri": "spring-rabbitmq://{{exchangeName}}",
|
||
|
|
"parameters": {
|
||
|
|
"connectionFactory": "#bean:{{connectionFactory}}",
|
||
|
|
"routingKey": "{{?routingKey}}",
|
||
|
|
"queues": "{{?queues}}",
|
||
|
|
"autoDeclareProducer": "{{autoDeclareProducer}}"
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"propertiesSchema": {
|
||
|
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
||
|
|
"type": "object",
|
||
|
|
"title": "RabbitMQ Sink",
|
||
|
|
"description": "Send data to a RabbitMQ Broker.",
|
||
|
|
"required": [
|
||
|
|
"host",
|
||
|
|
"port",
|
||
|
|
"exchangeName"
|
||
|
|
],
|
||
|
|
"properties": {
|
||
|
|
"host": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Server Address",
|
||
|
|
"description": "RabbitMQ broker address"
|
||
|
|
},
|
||
|
|
"port": {
|
||
|
|
"type": "integer",
|
||
|
|
"title": "Server Port",
|
||
|
|
"description": "RabbitMQ broker port"
|
||
|
|
},
|
||
|
|
"routingKey": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Routing Key",
|
||
|
|
"description": "The routing key to use when binding a consumer queue to the exchange"
|
||
|
|
},
|
||
|
|
"username": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Username",
|
||
|
|
"description": "The username to access the RabbitMQ server"
|
||
|
|
},
|
||
|
|
"password": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Password",
|
||
|
|
"description": "The password to access the RabbitMQ server",
|
||
|
|
"format": "password"
|
||
|
|
},
|
||
|
|
"exchangeName": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Exchange name",
|
||
|
|
"description": "The exchange name determines the exchange the queue is bound to."
|
||
|
|
},
|
||
|
|
"queues": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Queue name",
|
||
|
|
"description": "The queue to receive messages from"
|
||
|
|
},
|
||
|
|
"autoDeclareProducer": {
|
||
|
|
"type": "boolean",
|
||
|
|
"title": "Auto Declare Producer",
|
||
|
|
"description": "Specifies whether the producer should auto declare binding between exchange, queue and routing key when starting",
|
||
|
|
"default": false
|
||
|
|
},
|
||
|
|
"vhost": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Virtual Host",
|
||
|
|
"description": "The virtual host",
|
||
|
|
"default": "/"
|
||
|
|
},
|
||
|
|
"protocol": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Protocol",
|
||
|
|
"description": "The AMQP protocol to use.",
|
||
|
|
"enum": [
|
||
|
|
"amqp",
|
||
|
|
"amqps"
|
||
|
|
],
|
||
|
|
"default": "amqp"
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|