266 lines
14 KiB
JSON
266 lines
14 KiB
JSON
|
|
{
|
||
|
|
"apiVersion": "camel.apache.org/v1",
|
||
|
|
"kind": "Kamelet",
|
||
|
|
"metadata": {
|
||
|
|
"name": "cassandra-source",
|
||
|
|
"annotations": {
|
||
|
|
"camel.apache.org/kamelet.support.level": "Stable",
|
||
|
|
"camel.apache.org/catalog.version": "4.22.1",
|
||
|
|
"camel.apache.org/kamelet.icon": "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDIyLjEuMCwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHZlcnNpb249IjEuMSIgaWQ9IkxheWVyXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IgoJIHZpZXdCb3g9IjAgMCAzMiAzMiIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgMzIgMzI7IiB4bWw6c3BhY2U9InByZXNlcnZlIj4KPHRpdGxlPmNhc3NhbmRyYTwvdGl0bGU+CjxwYXRoIGQ9Ik0yMy4zLDguN2MwLDAtMC4zLDAuMy0wLjUsMC41Yy0wLjUsMC41LTEuMiwxLjMtMS43LDEuNWgwYy0wLjEsMC0wLjEsMC0wLjItMC4xbDAuOS0xLjlsMCwwYzAsMC4xLTEsMS45LTIuMiwxLjZsMCwwCgljMCwwLDAsMC0wLjEsMGMwLjYtMC44LDAuOC0xLjUsMC44LTEuNXMtMSwxLjYtMi4zLDEuMmMwLDAtMC4xLDAtMC4xLTAuMWMwLDAsMC0wLjEsMC0wLjFjMC0wLjEsMC4xLTAuMSwwLjEtMC4yCglj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y0wLjMsMC43LTAuMywxYzAsMi4yLDEuMyw0LDMuM
|
||
|
|
"camel.apache.org/provider": "Apache Software Foundation",
|
||
|
|
"camel.apache.org/kamelet.group": "Cassandra",
|
||
|
|
"camel.apache.org/kamelet.namespace": "Nosql"
|
||
|
|
},
|
||
|
|
"labels": {
|
||
|
|
"camel.apache.org/kamelet.type": "source"
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"spec": {
|
||
|
|
"definition": {
|
||
|
|
"title": "Cassandra Source",
|
||
|
|
"description": "Send a query to an Apache Cassandra cluster table.",
|
||
|
|
"required": [
|
||
|
|
"connectionHost",
|
||
|
|
"connectionPort",
|
||
|
|
"keyspace",
|
||
|
|
"query"
|
||
|
|
],
|
||
|
|
"type": "object",
|
||
|
|
"properties": {
|
||
|
|
"connectionHost": {
|
||
|
|
"title": "Connection Host",
|
||
|
|
"description": "The hostname(s) for the Cassandra server(s). Use a comma to separate multiple hostnames.",
|
||
|
|
"type": "string",
|
||
|
|
"example": "localhost"
|
||
|
|
},
|
||
|
|
"connectionPort": {
|
||
|
|
"title": "Connection Port",
|
||
|
|
"description": "The port number(s) of the cassandra server(s). Use a comma to separate multiple port numbers.",
|
||
|
|
"type": "string",
|
||
|
|
"example": 9042
|
||
|
|
},
|
||
|
|
"keyspace": {
|
||
|
|
"title": "Keyspace",
|
||
|
|
"description": "The keyspace to use.",
|
||
|
|
"type": "string",
|
||
|
|
"example": "customers"
|
||
|
|
},
|
||
|
|
"username": {
|
||
|
|
"title": "Username",
|
||
|
|
"description": "The username for accessing a secured Cassandra cluster.",
|
||
|
|
"type": "string",
|
||
|
|
"x-descriptors": [
|
||
|
|
"urn:camel:group:credentials"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"password": {
|
||
|
|
"title": "Password",
|
||
|
|
"description": "The password for accessing a secured Cassandra cluster.",
|
||
|
|
"type": "string",
|
||
|
|
"format": "password",
|
||
|
|
"x-descriptors": [
|
||
|
|
"urn:camel:group:credentials"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"resultStrategy": {
|
||
|
|
"title": "Result Strategy",
|
||
|
|
"description": "The strategy to convert the result set of the query.",
|
||
|
|
"type": "string",
|
||
|
|
"default": "ALL",
|
||
|
|
"enum": [
|
||
|
|
"ALL",
|
||
|
|
"ONE",
|
||
|
|
"LIMIT_10",
|
||
|
|
"LIMIT_100"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"consistencyLevel": {
|
||
|
|
"title": "Consistency Level",
|
||
|
|
"description": "The consistency level to use.",
|
||
|
|
"type": "string",
|
||
|
|
"default": "QUORUM",
|
||
|
|
"enum": [
|
||
|
|
"ONE",
|
||
|
|
"TWO",
|
||
|
|
"THREE",
|
||
|
|
"QUORUM",
|
||
|
|
"ALL",
|
||
|
|
"LOCAL_QUORUM",
|
||
|
|
"EACH_QUORUM",
|
||
|
|
"SERIAL",
|
||
|
|
"LOCAL_SERIAL",
|
||
|
|
"LOCAL_ONE"
|
||
|
|
]
|
||
|
|
},
|
||
|
|
"query": {
|
||
|
|
"title": "Query",
|
||
|
|
"description": "The query to execute against the Cassandra cluster table.",
|
||
|
|
"type": "string"
|
||
|
|
},
|
||
|
|
"extraTypeCodecs": {
|
||
|
|
"title": "Extra Type Codecs",
|
||
|
|
"description": "To use a specific comma separated list of Extra Type codecs.",
|
||
|
|
"type": "string",
|
||
|
|
"enum": [
|
||
|
|
"BLOB_TO_ARRAY",
|
||
|
|
"BOOLEAN_LIST_TO_ARRAY",
|
||
|
|
"BYTE_LIST_TO_ARRAY",
|
||
|
|
"SHORT_LIST_TO_ARRAY",
|
||
|
|
"INT_LIST_TO_ARRAY",
|
||
|
|
"LONG_LIST_TO_ARRAY",
|
||
|
|
"FLOAT_LIST_TO_ARRAY",
|
||
|
|
"DOUBLE_LIST_TO_ARRAY",
|
||
|
|
"TIMESTAMP_UTC",
|
||
|
|
"TIMESTAMP_MILLIS_SYSTEM",
|
||
|
|
"TIMESTAMP_MILLIS_UTC",
|
||
|
|
"ZONED_TIMESTAMP_SYSTEM",
|
||
|
|
"ZONED_TIMESTAMP_UTC",
|
||
|
|
"ZONED_TIMESTAMP_PERSISTED",
|
||
|
|
"LOCAL_TIMESTAMP_SYSTEM",
|
||
|
|
"LOCAL_TIMESTAMP_UTC"
|
||
|
|
]
|
||
|
|
}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"types": {
|
||
|
|
"out": {
|
||
|
|
"mediaType": "application/json"
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"dependencies": [
|
||
|
|
"camel:jackson",
|
||
|
|
"camel:kamelet",
|
||
|
|
"camel:cassandraql"
|
||
|
|
],
|
||
|
|
"template": {
|
||
|
|
"beans": [
|
||
|
|
{
|
||
|
|
"name": "local-sql-cassandraql-source",
|
||
|
|
"type": "#class:org.apache.camel.component.cassandra.CassandraComponent",
|
||
|
|
"properties": {
|
||
|
|
"autowiredEnabled": "false"
|
||
|
|
}
|
||
|
|
}
|
||
|
|
],
|
||
|
|
"from": {
|
||
|
|
"uri": "{{local-sql-cassandraql-source}}://{{connectionHost}}:{{connectionPort}}/{{keyspace}}",
|
||
|
|
"parameters": {
|
||
|
|
"username": "{{?username}}",
|
||
|
|
"password": "{{?password}}",
|
||
|
|
"cql": "{{query}}",
|
||
|
|
"consistencyLevel": "{{consistencyLevel}}",
|
||
|
|
"resultSetConversionStrategy": "{{resultStrategy}}",
|
||
|
|
"extraTypeCodecs": "{{?extraTypeCodecs}}"
|
||
|
|
},
|
||
|
|
"steps": [
|
||
|
|
{
|
||
|
|
"marshal": {
|
||
|
|
"json": {}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
{
|
||
|
|
"to": "kamelet:sink"
|
||
|
|
}
|
||
|
|
]
|
||
|
|
}
|
||
|
|
}
|
||
|
|
},
|
||
|
|
"propertiesSchema": {
|
||
|
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
||
|
|
"type": "object",
|
||
|
|
"title": "Cassandra Source",
|
||
|
|
"description": "Send a query to an Apache Cassandra cluster table.",
|
||
|
|
"required": [
|
||
|
|
"connectionHost",
|
||
|
|
"connectionPort",
|
||
|
|
"keyspace",
|
||
|
|
"query"
|
||
|
|
],
|
||
|
|
"properties": {
|
||
|
|
"connectionHost": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Connection Host",
|
||
|
|
"description": "The hostname(s) for the Cassandra server(s). Use a comma to separate multiple hostnames."
|
||
|
|
},
|
||
|
|
"connectionPort": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Connection Port",
|
||
|
|
"description": "The port number(s) of the cassandra server(s). Use a comma to separate multiple port numbers."
|
||
|
|
},
|
||
|
|
"keyspace": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Keyspace",
|
||
|
|
"description": "The keyspace to use."
|
||
|
|
},
|
||
|
|
"username": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Username",
|
||
|
|
"description": "The username for accessing a secured Cassandra cluster."
|
||
|
|
},
|
||
|
|
"password": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Password",
|
||
|
|
"description": "The password for accessing a secured Cassandra cluster.",
|
||
|
|
"format": "password"
|
||
|
|
},
|
||
|
|
"resultStrategy": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Result Strategy",
|
||
|
|
"description": "The strategy to convert the result set of the query.",
|
||
|
|
"enum": [
|
||
|
|
"ALL",
|
||
|
|
"ONE",
|
||
|
|
"LIMIT_10",
|
||
|
|
"LIMIT_100"
|
||
|
|
],
|
||
|
|
"default": "ALL"
|
||
|
|
},
|
||
|
|
"consistencyLevel": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Consistency Level",
|
||
|
|
"description": "The consistency level to use.",
|
||
|
|
"enum": [
|
||
|
|
"ONE",
|
||
|
|
"TWO",
|
||
|
|
"THREE",
|
||
|
|
"QUORUM",
|
||
|
|
"ALL",
|
||
|
|
"LOCAL_QUORUM",
|
||
|
|
"EACH_QUORUM",
|
||
|
|
"SERIAL",
|
||
|
|
"LOCAL_SERIAL",
|
||
|
|
"LOCAL_ONE"
|
||
|
|
],
|
||
|
|
"default": "QUORUM"
|
||
|
|
},
|
||
|
|
"query": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Query",
|
||
|
|
"description": "The query to execute against the Cassandra cluster table."
|
||
|
|
},
|
||
|
|
"extraTypeCodecs": {
|
||
|
|
"type": "string",
|
||
|
|
"title": "Extra Type Codecs",
|
||
|
|
"description": "To use a specific comma separated list of Extra Type codecs.",
|
||
|
|
"enum": [
|
||
|
|
"BLOB_TO_ARRAY",
|
||
|
|
"BOOLEAN_LIST_TO_ARRAY",
|
||
|
|
"BYTE_LIST_TO_ARRAY",
|
||
|
|
"SHORT_LIST_TO_ARRAY",
|
||
|
|
"INT_LIST_TO_ARRAY",
|
||
|
|
"LONG_LIST_TO_ARRAY",
|
||
|
|
"FLOAT_LIST_TO_ARRAY",
|
||
|
|
"DOUBLE_LIST_TO_ARRAY",
|
||
|
|
"TIMESTAMP_UTC",
|
||
|
|
"TIMESTAMP_MILLIS_SYSTEM",
|
||
|
|
"TIMESTAMP_MILLIS_UTC",
|
||
|
|
"ZONED_TIMESTAMP_SYSTEM",
|
||
|
|
"ZONED_TIMESTAMP_UTC",
|
||
|
|
"ZONED_TIMESTAMP_PERSISTED",
|
||
|
|
"LOCAL_TIMESTAMP_SYSTEM",
|
||
|
|
"LOCAL_TIMESTAMP_UTC"
|
||
|
|
]
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|