This is an automated email from the ASF dual-hosted git repository.
oscerd pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git
The following commit(s) were added to refs/heads/main by this push:
new 1cb510c20 chore: the PostgreSQL, MySQL and MariaDB Kamelets take JDBC
connection properties (#3170) (#3176)
1cb510c20 is described below
commit 1cb510c20ad6c026de58f7d7639bd6121a06ad8d
Author: Claus Ibsen <[email protected]>
AuthorDate: Wed Nov 18 09:56:50 2026 +0100
chore: the PostgreSQL, MySQL and MariaDB Kamelets take JDBC connection
properties (#3170) (#3176)
The postgresql-*, mysql-* and mariadb-* Kamelets get an optional
connectionProperties option, passed to the connectionProperties of the
commons-dbcp2 BasicDataSource as name=value pairs separated by ';'. It lets
people require TLS (sslmode=require, sslMode=REQUIRED, sslMode=trust) and
set
any other driver setting. When it is not set, the data source gets no
properties, as before.
Checked with Camel JBang against PostgreSQL 17 with hostssl only, and MySQL
8.4
and MariaDB 11.8 with require_secure_transport=ON.
Co-authored-by: Claude Opus 5.5 <[email protected]>
---
.../modules/ROOT/partials/mariadb-sink-description.adoc | 14 +++++++++++++-
.../ROOT/partials/mariadb-source-description.adoc | 13 +++++++++++++
docs/modules/ROOT/partials/mysql-sink-description.adoc | 13 ++++++++++++-
.../modules/ROOT/partials/mysql-source-description.adoc | 14 +++++++++++++-
.../ROOT/partials/postgresql-sink-description.adoc | 16 +++++++++++++++-
.../ROOT/partials/postgresql-source-description.adoc | 17 ++++++++++++++++-
kamelets/mariadb-sink.kamelet.yaml | 8 +++++++-
kamelets/mariadb-source.kamelet.yaml | 8 +++++++-
kamelets/mysql-sink.kamelet.yaml | 8 +++++++-
kamelets/mysql-source.kamelet.yaml | 8 +++++++-
kamelets/postgresql-sink.kamelet.yaml | 8 +++++++-
kamelets/postgresql-source.kamelet.yaml | 8 +++++++-
.../src/main/resources/META-INF/kamelets-index.json | 12 ++++++------
.../main/resources/kamelets/mariadb-sink.kamelet.yaml | 8 +++++++-
.../main/resources/kamelets/mariadb-source.kamelet.yaml | 8 +++++++-
.../src/main/resources/kamelets/mysql-sink.kamelet.yaml | 8 +++++++-
.../main/resources/kamelets/mysql-source.kamelet.yaml | 8 +++++++-
.../resources/kamelets/postgresql-sink.kamelet.yaml | 8 +++++++-
.../resources/kamelets/postgresql-source.kamelet.yaml | 8 +++++++-
19 files changed, 172 insertions(+), 23 deletions(-)
diff --git a/docs/modules/ROOT/partials/mariadb-sink-description.adoc
b/docs/modules/ROOT/partials/mariadb-sink-description.adoc
index 469d58ff4..286281ce1 100644
--- a/docs/modules/ROOT/partials/mariadb-sink-description.adoc
+++ b/docs/modules/ROOT/partials/mariadb-sink-description.adoc
@@ -18,4 +18,16 @@ The Kamelet uses Apache Commons DBCP2 for connection
pooling, providing efficien
=== Authentication
-Requires username and password authentication for secure database access.
These credentials should be properly managed and secured.
\ No newline at end of file
+Requires username and password authentication for secure database access.
These credentials should be properly managed and secured.
+
+=== Connecting with TLS
+
+Set `connectionProperties` to pass settings to the MariaDB JDBC driver
(MariaDB Connector/J), as `name=value` pairs
+separated by `;`. Without it, the default of the driver applies, and it
depends on its version: Connector/J 3 connects
+without TLS, Connector/J 4 with TLS. Set `sslMode=trust` to always use TLS,
without checking the certificate of the
+server.
+
+[source,yaml,subs='+attributes,macros']
+----
+connectionProperties: "sslMode=trust"
+----
diff --git a/docs/modules/ROOT/partials/mariadb-source-description.adoc
b/docs/modules/ROOT/partials/mariadb-source-description.adoc
index c64885dd0..c9350fd4c 100644
--- a/docs/modules/ROOT/partials/mariadb-source-description.adoc
+++ b/docs/modules/ROOT/partials/mariadb-source-description.adoc
@@ -17,6 +17,7 @@ The Kamelet requires database connection parameters:
- `username` and `password`: the database user to log in as
- `query`: the SQL query to run, such as `SELECT * FROM accounts WHERE
processed = false`
- `consumedQuery` (optional): an SQL statement run for each row once it is
sent, to mark the row as read or delete it, such as `UPDATE accounts SET
processed = true WHERE id = :#id`
+- `connectionProperties` (optional): extra settings for the MariaDB JDBC
driver, such as `sslMode=trust` to always use TLS
=== Usage example
@@ -38,3 +39,15 @@ The route below logs each account that is not processed yet,
and marks it as pro
- to:
uri: "kamelet:log-sink"
----
+
+=== Connecting with TLS
+
+Set `connectionProperties` to pass settings to the MariaDB JDBC driver
(MariaDB Connector/J), as `name=value` pairs
+separated by `;`. Without it, the default of the driver applies, and it
depends on its version: Connector/J 3 connects
+without TLS, Connector/J 4 with TLS. Set `sslMode=trust` to always use TLS,
without checking the certificate of the
+server.
+
+[source,yaml,subs='+attributes,macros']
+----
+connectionProperties: "sslMode=trust"
+----
diff --git a/docs/modules/ROOT/partials/mysql-sink-description.adoc
b/docs/modules/ROOT/partials/mysql-sink-description.adoc
index 397cff193..d2d844069 100644
--- a/docs/modules/ROOT/partials/mysql-sink-description.adoc
+++ b/docs/modules/ROOT/partials/mysql-sink-description.adoc
@@ -18,4 +18,15 @@ Uses Apache Commons DBCP2 for efficient database connection
pooling. This provid
=== Authentication and Security
-Requires username and password authentication for database access.
\ No newline at end of file
+Requires username and password authentication for database access.
+
+=== Connecting with TLS
+
+Set `connectionProperties` to pass settings to the MySQL JDBC driver
(Connector/J), as `name=value` pairs separated by
+`;`. Without it, the driver uses TLS only when the server offers it, and does
not check the certificate of the server.
+Set `sslMode=REQUIRED` to always use TLS.
+
+[source,yaml,subs='+attributes,macros']
+----
+connectionProperties: "sslMode=REQUIRED"
+----
diff --git a/docs/modules/ROOT/partials/mysql-source-description.adoc
b/docs/modules/ROOT/partials/mysql-source-description.adoc
index 3de47df87..04c087de3 100644
--- a/docs/modules/ROOT/partials/mysql-source-description.adoc
+++ b/docs/modules/ROOT/partials/mysql-source-description.adoc
@@ -16,6 +16,7 @@ The MySQL Source Kamelet supports the following
configurations:
- **Server Port**: Port number for the MySQL server (default: 3306)
- **Delay**: How long to wait after one run of the query before the next, in
milliseconds (default: 500)
- **Consumed Query**: An SQL statement run for each row once it is sent, to
mark the row as read or delete it, so that it is not read again
+- **Connection Properties**: Extra settings for the MySQL JDBC driver, such as
`sslMode=REQUIRED` to always use TLS
=== Output Format
@@ -81,4 +82,15 @@ The Kamelet sends one message per row of the query result.
Each row is a JSON ob
=== Connection Management
-The kamelet manages database connections automatically, including connection
pooling and reconnection on failures. Query execution is scheduled at the
specified interval.
\ No newline at end of file
+The kamelet manages database connections automatically, including connection
pooling and reconnection on failures. Query execution is scheduled at the
specified interval.
+
+=== Connecting with TLS
+
+Set `connectionProperties` to pass settings to the MySQL JDBC driver
(Connector/J), as `name=value` pairs separated by
+`;`. Without it, the driver uses TLS only when the server offers it, and does
not check the certificate of the server.
+Set `sslMode=REQUIRED` to always use TLS.
+
+[source,yaml,subs='+attributes,macros']
+----
+connectionProperties: "sslMode=REQUIRED"
+----
diff --git a/docs/modules/ROOT/partials/postgresql-sink-description.adoc
b/docs/modules/ROOT/partials/postgresql-sink-description.adoc
index cbe9ecff1..967aeca9d 100644
--- a/docs/modules/ROOT/partials/postgresql-sink-description.adoc
+++ b/docs/modules/ROOT/partials/postgresql-sink-description.adoc
@@ -22,4 +22,18 @@ Here is example input for the example query:
=== Authentication
-The Kamelet requires username and password authentication to connect to the
PostgreSQL database.
\ No newline at end of file
+The Kamelet requires username and password authentication to connect to the
PostgreSQL database.
+
+=== Connecting with TLS
+
+Set `connectionProperties` to pass settings to the PostgreSQL JDBC driver, as
`name=value` pairs separated by `;`.
+Without it, the driver uses TLS only when the server offers it, and does not
check the certificate of the server.
+
+* `sslmode=require`: always use TLS, and fail when the server does not offer
it.
+* `sslmode=verify-full;sslrootcert=/etc/certs/root.crt`: also check the
certificate of the server against the CA
+ certificate in that file.
+
+[source,yaml,subs='+attributes,macros']
+----
+connectionProperties: "sslmode=require"
+----
diff --git a/docs/modules/ROOT/partials/postgresql-source-description.adoc
b/docs/modules/ROOT/partials/postgresql-source-description.adoc
index 00267a74f..97f13b84f 100644
--- a/docs/modules/ROOT/partials/postgresql-source-description.adoc
+++ b/docs/modules/ROOT/partials/postgresql-source-description.adoc
@@ -16,6 +16,7 @@ The PostgreSQL Source Kamelet supports the following
configurations:
- **Server Port**: Port number for the PostgreSQL server (default: 5432)
- **Delay**: How long to wait after one run of the query before the next, in
milliseconds (default: 500)
- **Consumed Query**: An SQL statement run for each row once it is sent, to
mark the row as read or delete it, so that it is not read again
+- **Connection Properties**: Extra settings for the PostgreSQL JDBC driver,
such as `sslmode=require` to always use TLS
=== Output Format
@@ -61,4 +62,18 @@ The Kamelet sends one message per row of the query result.
Each row is a JSON ob
=== Connection Management
-The kamelet manages PostgreSQL connections automatically, including connection
pooling and reconnection on failures. Query execution is scheduled at the
specified interval with robust error handling.
\ No newline at end of file
+The kamelet manages PostgreSQL connections automatically, including connection
pooling and reconnection on failures. Query execution is scheduled at the
specified interval with robust error handling.
+
+=== Connecting with TLS
+
+Set `connectionProperties` to pass settings to the PostgreSQL JDBC driver, as
`name=value` pairs separated by `;`.
+Without it, the driver uses TLS only when the server offers it, and does not
check the certificate of the server.
+
+* `sslmode=require`: always use TLS, and fail when the server does not offer
it.
+* `sslmode=verify-full;sslrootcert=/etc/certs/root.crt`: also check the
certificate of the server against the CA
+ certificate in that file.
+
+[source,yaml,subs='+attributes,macros']
+----
+connectionProperties: "sslmode=require"
+----
diff --git a/kamelets/mariadb-sink.kamelet.yaml
b/kamelets/mariadb-sink.kamelet.yaml
index 9a591c334..2085c010c 100644
--- a/kamelets/mariadb-sink.kamelet.yaml
+++ b/kamelets/mariadb-sink.kamelet.yaml
@@ -39,7 +39,7 @@ spec:
Output: the body afterwards is the JSON object as a Map, and the
`CamelSqlUpdateCount` header holds the number of rows the statement changed.
When `query` is a SELECT, the body is instead a List of the rows found, each a
Map, and the `CamelSqlRowCount` header holds their number.
- Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. The JDBC driver
of MariaDB is not included: add `mvn:org.mariadb.jdbc:mariadb-java-client` to
the dependencies of the [...]
+ Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. The JDBC driver
of MariaDB is not included: add `mvn:org.mariadb.jdbc:mariadb-java-client` to
the dependencies of the [...]
required:
- serverName
- username
@@ -81,6 +81,11 @@ spec:
description: The name of the database to connect to on the MariaDB
server.
type: string
example: shop
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the MariaDB JDBC driver (MariaDB
Connector/J), as `name=value` pairs separated by `;`, such as
`sslMode=trust;connectTimeout=10000`. Use it for TLS: `sslMode=trust` makes the
connection use TLS without checking the certificate of the server, and
`sslMode=disable` turns TLS off. When it is not set, the default of the driver
applies, and it depends on its version: Connector/J 3 connects without TLS,
Connector/J 4 with TLS. The value is not hidden li [...]
+ type: string
+ example: sslMode=trust
types:
in:
mediaType: application/json
@@ -113,6 +118,7 @@ spec:
password: "{{password}}"
url: "jdbc:mariadb://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: org.mariadb.jdbc.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri: kamelet:source
steps:
diff --git a/kamelets/mariadb-source.kamelet.yaml
b/kamelets/mariadb-source.kamelet.yaml
index e11d7045d..3158c116a 100644
--- a/kamelets/mariadb-source.kamelet.yaml
+++ b/kamelets/mariadb-source.kamelet.yaml
@@ -37,7 +37,7 @@ spec:
Output: the body is one row as JSON text, an object with the column
names as keys, such as `{"id":1,"username":"oscerd","city":"Rome"}`. The
`Content-Type` header is `application/json`.
- Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
+ Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
required:
- serverName
- username
@@ -89,6 +89,11 @@ spec:
description: How long to wait after one run of `query` before the
next, in milliseconds.
type: integer
default: 500
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the MariaDB JDBC driver (MariaDB
Connector/J), as `name=value` pairs separated by `;`, such as
`sslMode=trust;connectTimeout=10000`. Use it for TLS: `sslMode=trust` makes the
connection use TLS without checking the certificate of the server, and
`sslMode=disable` turns TLS off. When it is not set, the default of the driver
applies, and it depends on its version: Connector/J 3 connects without TLS,
Connector/J 4 with TLS. The value is not hidden li [...]
+ type: string
+ example: sslMode=trust
types:
out:
mediaType: application/json
@@ -117,6 +122,7 @@ spec:
password: "{{password}}"
url: "jdbc:mariadb://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: org.mariadb.jdbc.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri:
"{{local-sql-mariadb-source}}:{{query}}?dataSource=#bean:{{dsBean}}&onConsume=RAW({{?consumedQuery}})&delay={{delay}}"
steps:
diff --git a/kamelets/mysql-sink.kamelet.yaml b/kamelets/mysql-sink.kamelet.yaml
index f0c4c2b39..f948d184e 100644
--- a/kamelets/mysql-sink.kamelet.yaml
+++ b/kamelets/mysql-sink.kamelet.yaml
@@ -39,7 +39,7 @@ spec:
Output: the body afterwards is the JSON object as a Map, and the
`CamelSqlUpdateCount` header holds the number of rows the statement changed.
When `query` is a SELECT, the body is instead a List of the rows found, each a
Map, and the `CamelSqlRowCount` header holds their number.
- Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. The JDBC driver
of MySQL is not included: add `mvn:com.mysql:mysql-connector-j` to the
dependencies of the integratio [...]
+ Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. The JDBC driver
of MySQL is not included: add `mvn:com.mysql:mysql-connector-j` to the
dependencies of the integratio [...]
required:
- serverName
- username
@@ -81,6 +81,11 @@ spec:
description: The name of the database to connect to on the MySQL
server.
type: string
example: shop
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the MySQL JDBC driver (Connector/J),
as `name=value` pairs separated by `;`, such as
`sslMode=REQUIRED;connectTimeout=10000`. Use it for TLS: `sslMode=REQUIRED`
makes the connection use TLS, and `sslMode=DISABLED` turns TLS off. When it is
not set, the driver uses TLS when the server offers it, without checking the
certificate. The value is not hidden like a password, and it can show in the
log when the integration starts, so do not put a password [...]
+ type: string
+ example: sslMode=REQUIRED
types:
in:
mediaType: application/json
@@ -113,6 +118,7 @@ spec:
password: "{{password}}"
url: "jdbc:mysql://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: com.mysql.cj.jdbc.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri: kamelet:source
steps:
diff --git a/kamelets/mysql-source.kamelet.yaml
b/kamelets/mysql-source.kamelet.yaml
index caa81b146..1bc84d1c5 100644
--- a/kamelets/mysql-source.kamelet.yaml
+++ b/kamelets/mysql-source.kamelet.yaml
@@ -37,7 +37,7 @@ spec:
Output: the body is one row as JSON text, an object with the column
names as keys, such as `{"id":1,"username":"oscerd","city":"Rome"}`. The
`Content-Type` header is `application/json`.
- Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
+ Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
required:
- serverName
- username
@@ -89,6 +89,11 @@ spec:
description: How long to wait after one run of `query` before the
next, in milliseconds.
type: integer
default: 500
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the MySQL JDBC driver (Connector/J),
as `name=value` pairs separated by `;`, such as
`sslMode=REQUIRED;connectTimeout=10000`. Use it for TLS: `sslMode=REQUIRED`
makes the connection use TLS, and `sslMode=DISABLED` turns TLS off. When it is
not set, the driver uses TLS when the server offers it, without checking the
certificate. The value is not hidden like a password, and it can show in the
log when the integration starts, so do not put a password [...]
+ type: string
+ example: sslMode=REQUIRED
types:
out:
mediaType: application/json
@@ -117,6 +122,7 @@ spec:
password: "{{password}}"
url: "jdbc:mysql://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: com.mysql.cj.jdbc.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri:
"{{local-sql-mysql-source}}:{{query}}?dataSource=#bean:{{dsBean}}&onConsume=RAW({{?consumedQuery}})&delay={{delay}}"
steps:
diff --git a/kamelets/postgresql-sink.kamelet.yaml
b/kamelets/postgresql-sink.kamelet.yaml
index 4c230f0ba..05f543bc7 100644
--- a/kamelets/postgresql-sink.kamelet.yaml
+++ b/kamelets/postgresql-sink.kamelet.yaml
@@ -39,7 +39,7 @@ spec:
Output: the body afterwards is the JSON object as a Map, and the
`CamelSqlUpdateCount` header holds the number of rows the statement changed.
When `query` is a SELECT, the body is instead a List of the rows found, each a
Map, and the `CamelSqlRowCount` header holds their number.
- Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start.
+ Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. Without
`connectionProperties`, the connection uses TLS only when the server offers it,
and the certificate of the se [...]
required:
- serverName
- username
@@ -81,6 +81,11 @@ spec:
description: The name of the database to connect to on the PostgreSQL
server.
type: string
example: shop
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the PostgreSQL JDBC driver, as
`name=value` pairs separated by `;`, such as
`sslmode=require;connectTimeout=10`. Use it for TLS: `sslmode=require` refuses
a server that does not offer TLS, and `sslmode=verify-full` also checks the
certificate of the server against the CA certificate in the file named by
`sslrootcert`. When it is not set, the driver uses TLS when the server offers
it, without checking the certificate. The value is not hidden like a [...]
+ type: string
+ example: sslmode=require
types:
in:
mediaType: application/json
@@ -114,6 +119,7 @@ spec:
password: "{{password}}"
url:
"jdbc:postgresql://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: org.postgresql.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri: kamelet:source
steps:
diff --git a/kamelets/postgresql-source.kamelet.yaml
b/kamelets/postgresql-source.kamelet.yaml
index c389cd115..95305ddcf 100644
--- a/kamelets/postgresql-source.kamelet.yaml
+++ b/kamelets/postgresql-source.kamelet.yaml
@@ -37,7 +37,7 @@ spec:
Output: the body is one row as JSON text, an object with the column
names as keys, such as `{"id":1,"username":"oscerd","city":"Rome"}`. The
`Content-Type` header is `application/json`.
- Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
+ Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
required:
- serverName
- username
@@ -89,6 +89,11 @@ spec:
description: How long to wait after one run of `query` before the
next, in milliseconds.
type: integer
default: 500
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the PostgreSQL JDBC driver, as
`name=value` pairs separated by `;`, such as
`sslmode=require;connectTimeout=10`. Use it for TLS: `sslmode=require` refuses
a server that does not offer TLS, and `sslmode=verify-full` also checks the
certificate of the server against the CA certificate in the file named by
`sslrootcert`. When it is not set, the driver uses TLS when the server offers
it, without checking the certificate. The value is not hidden like a [...]
+ type: string
+ example: sslmode=require
types:
out:
mediaType: application/json
@@ -118,6 +123,7 @@ spec:
password: "{{password}}"
url:
"jdbc:postgresql://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: org.postgresql.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri:
"{{local-sql-postgres-source}}:{{query}}?dataSource=#bean:{{dsBean}}&onConsume=RAW({{?consumedQuery}})&delay={{delay}}"
steps:
diff --git
a/library/camel-kamelets/src/main/resources/META-INF/kamelets-index.json
b/library/camel-kamelets/src/main/resources/META-INF/kamelets-index.json
index c80728efd..9747e2ab3 100644
--- a/library/camel-kamelets/src/main/resources/META-INF/kamelets-index.json
+++ b/library/camel-kamelets/src/main/resources/META-INF/kamelets-index.json
@@ -1525,7 +1525,7 @@
"supportLevel" : "Stable",
"title" : "MariaDB Sink",
"summary" : "Runs an SQL statement, such as an INSERT, in a MariaDB
database for each message, with values taken from the fields of the JSON object
in the body.",
- "description" : "Runs an SQL statement, such as an INSERT, in a MariaDB
database for each message, with values taken from the fields of the JSON object
in the body.\n\nUse it to store records from another system as rows of a table,
such as each order that arrives on a Kafka topic, or to update or delete rows.
To read rows, use `mariadb-source`.\n\nInput: the body is one JSON object, as
text, such as `{\"username\":\"oscerd\",\"city\":\"Rome\"}`. In `query`, write
`:#username` where t [...]
+ "description" : "Runs an SQL statement, such as an INSERT, in a MariaDB
database for each message, with values taken from the fields of the JSON object
in the body.\n\nUse it to store records from another system as rows of a table,
such as each order that arrives on a Kafka topic, or to update or delete rows.
To read rows, use `mariadb-source`.\n\nInput: the body is one JSON object, as
text, such as `{\"username\":\"oscerd\",\"city\":\"Rome\"}`. In `query`, write
`:#username` where t [...]
"group" : "SQL",
"namespace" : "Database",
"provider" : "Apache Software Foundation"
@@ -1535,7 +1535,7 @@
"supportLevel" : "Stable",
"title" : "MariaDB Source",
"summary" : "Runs an SQL query in a MariaDB database again and again, and
sends each row it returns as a message, as a JSON object.",
- "description" : "Runs an SQL query in a MariaDB database again and again,
and sends each row it returns as a message, as a JSON object.\n\nUse it to pick
up the rows that another application adds to a table, such as new orders or
events, and pass them on to another system. To write rows, use
`mariadb-sink`.\n\nOutput: the body is one row as JSON text, an object with the
column names as keys, such as
`{\"id\":1,\"username\":\"oscerd\",\"city\":\"Rome\"}`. The `Content-Type`
header is [...]
+ "description" : "Runs an SQL query in a MariaDB database again and again,
and sends each row it returns as a message, as a JSON object.\n\nUse it to pick
up the rows that another application adds to a table, such as new orders or
events, and pass them on to another system. To write rows, use
`mariadb-sink`.\n\nOutput: the body is one row as JSON text, an object with the
column names as keys, such as
`{\"id\":1,\"username\":\"oscerd\",\"city\":\"Rome\"}`. The `Content-Type`
header is [...]
"group" : "SQL",
"namespace" : "Database",
"provider" : "Apache Software Foundation"
@@ -1685,7 +1685,7 @@
"supportLevel" : "Stable",
"title" : "MySQL Sink",
"summary" : "Runs an SQL statement, such as an INSERT, in a MySQL database
for each message, with values taken from the fields of the JSON object in the
body.",
- "description" : "Runs an SQL statement, such as an INSERT, in a MySQL
database for each message, with values taken from the fields of the JSON object
in the body.\n\nUse it to store records from another system as rows of a table,
such as each order that arrives on a Kafka topic, or to update or delete rows.
To read rows, use `mysql-source`.\n\nInput: the body is one JSON object, as
text, such as `{\"username\":\"oscerd\",\"city\":\"Rome\"}`. In `query`, write
`:#username` where the v [...]
+ "description" : "Runs an SQL statement, such as an INSERT, in a MySQL
database for each message, with values taken from the fields of the JSON object
in the body.\n\nUse it to store records from another system as rows of a table,
such as each order that arrives on a Kafka topic, or to update or delete rows.
To read rows, use `mysql-source`.\n\nInput: the body is one JSON object, as
text, such as `{\"username\":\"oscerd\",\"city\":\"Rome\"}`. In `query`, write
`:#username` where the v [...]
"group" : "SQL",
"namespace" : "Database",
"provider" : "Apache Software Foundation"
@@ -1695,7 +1695,7 @@
"supportLevel" : "Stable",
"title" : "MySQL Source",
"summary" : "Runs an SQL query in a MySQL database again and again, and
sends each row it returns as a message, as a JSON object.",
- "description" : "Runs an SQL query in a MySQL database again and again,
and sends each row it returns as a message, as a JSON object.\n\nUse it to pick
up the rows that another application adds to a table, such as new orders or
events, and pass them on to another system. To write rows, use
`mysql-sink`.\n\nOutput: the body is one row as JSON text, an object with the
column names as keys, such as
`{\"id\":1,\"username\":\"oscerd\",\"city\":\"Rome\"}`. The `Content-Type`
header is `app [...]
+ "description" : "Runs an SQL query in a MySQL database again and again,
and sends each row it returns as a message, as a JSON object.\n\nUse it to pick
up the rows that another application adds to a table, such as new orders or
events, and pass them on to another system. To write rows, use
`mysql-sink`.\n\nOutput: the body is one row as JSON text, an object with the
column names as keys, such as
`{\"id\":1,\"username\":\"oscerd\",\"city\":\"Rome\"}`. The `Content-Type`
header is `app [...]
"group" : "SQL",
"namespace" : "Database",
"provider" : "Apache Software Foundation"
@@ -1785,7 +1785,7 @@
"supportLevel" : "Stable",
"title" : "PostgreSQL Sink",
"summary" : "Runs an SQL statement, such as an INSERT, in a PostgreSQL
database for each message, with values taken from the fields of the JSON object
in the body.",
- "description" : "Runs an SQL statement, such as an INSERT, in a PostgreSQL
database for each message, with values taken from the fields of the JSON object
in the body.\n\nUse it to store records from another system as rows of a table,
such as each order that arrives on a Kafka topic, or to update or delete rows.
To read rows, use `postgresql-source`.\n\nInput: the body is one JSON object,
as text, such as `{\"username\":\"oscerd\",\"city\":\"Rome\"}`. In `query`,
write `:#username` w [...]
+ "description" : "Runs an SQL statement, such as an INSERT, in a PostgreSQL
database for each message, with values taken from the fields of the JSON object
in the body.\n\nUse it to store records from another system as rows of a table,
such as each order that arrives on a Kafka topic, or to update or delete rows.
To read rows, use `postgresql-source`.\n\nInput: the body is one JSON object,
as text, such as `{\"username\":\"oscerd\",\"city\":\"Rome\"}`. In `query`,
write `:#username` w [...]
"group" : "SQL",
"namespace" : "Database",
"provider" : "Apache Software Foundation"
@@ -1795,7 +1795,7 @@
"supportLevel" : "Stable",
"title" : "PostgreSQL Source",
"summary" : "Runs an SQL query in a PostgreSQL database again and again,
and sends each row it returns as a message, as a JSON object.",
- "description" : "Runs an SQL query in a PostgreSQL database again and
again, and sends each row it returns as a message, as a JSON object.\n\nUse it
to pick up the rows that another application adds to a table, such as new
orders or events, and pass them on to another system. To write rows, use
`postgresql-sink`.\n\nOutput: the body is one row as JSON text, an object with
the column names as keys, such as
`{\"id\":1,\"username\":\"oscerd\",\"city\":\"Rome\"}`. The `Content-Type` head
[...]
+ "description" : "Runs an SQL query in a PostgreSQL database again and
again, and sends each row it returns as a message, as a JSON object.\n\nUse it
to pick up the rows that another application adds to a table, such as new
orders or events, and pass them on to another system. To write rows, use
`postgresql-sink`.\n\nOutput: the body is one row as JSON text, an object with
the column names as keys, such as
`{\"id\":1,\"username\":\"oscerd\",\"city\":\"Rome\"}`. The `Content-Type` head
[...]
"group" : "SQL",
"namespace" : "Database",
"provider" : "Apache Software Foundation"
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/mariadb-sink.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/mariadb-sink.kamelet.yaml
index 9a591c334..2085c010c 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/mariadb-sink.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/mariadb-sink.kamelet.yaml
@@ -39,7 +39,7 @@ spec:
Output: the body afterwards is the JSON object as a Map, and the
`CamelSqlUpdateCount` header holds the number of rows the statement changed.
When `query` is a SELECT, the body is instead a List of the rows found, each a
Map, and the `CamelSqlRowCount` header holds their number.
- Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. The JDBC driver
of MariaDB is not included: add `mvn:org.mariadb.jdbc:mariadb-java-client` to
the dependencies of the [...]
+ Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. The JDBC driver
of MariaDB is not included: add `mvn:org.mariadb.jdbc:mariadb-java-client` to
the dependencies of the [...]
required:
- serverName
- username
@@ -81,6 +81,11 @@ spec:
description: The name of the database to connect to on the MariaDB
server.
type: string
example: shop
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the MariaDB JDBC driver (MariaDB
Connector/J), as `name=value` pairs separated by `;`, such as
`sslMode=trust;connectTimeout=10000`. Use it for TLS: `sslMode=trust` makes the
connection use TLS without checking the certificate of the server, and
`sslMode=disable` turns TLS off. When it is not set, the default of the driver
applies, and it depends on its version: Connector/J 3 connects without TLS,
Connector/J 4 with TLS. The value is not hidden li [...]
+ type: string
+ example: sslMode=trust
types:
in:
mediaType: application/json
@@ -113,6 +118,7 @@ spec:
password: "{{password}}"
url: "jdbc:mariadb://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: org.mariadb.jdbc.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri: kamelet:source
steps:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/mariadb-source.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/mariadb-source.kamelet.yaml
index e11d7045d..3158c116a 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/mariadb-source.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/mariadb-source.kamelet.yaml
@@ -37,7 +37,7 @@ spec:
Output: the body is one row as JSON text, an object with the column
names as keys, such as `{"id":1,"username":"oscerd","city":"Rome"}`. The
`Content-Type` header is `application/json`.
- Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
+ Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
required:
- serverName
- username
@@ -89,6 +89,11 @@ spec:
description: How long to wait after one run of `query` before the
next, in milliseconds.
type: integer
default: 500
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the MariaDB JDBC driver (MariaDB
Connector/J), as `name=value` pairs separated by `;`, such as
`sslMode=trust;connectTimeout=10000`. Use it for TLS: `sslMode=trust` makes the
connection use TLS without checking the certificate of the server, and
`sslMode=disable` turns TLS off. When it is not set, the default of the driver
applies, and it depends on its version: Connector/J 3 connects without TLS,
Connector/J 4 with TLS. The value is not hidden li [...]
+ type: string
+ example: sslMode=trust
types:
out:
mediaType: application/json
@@ -117,6 +122,7 @@ spec:
password: "{{password}}"
url: "jdbc:mariadb://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: org.mariadb.jdbc.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri:
"{{local-sql-mariadb-source}}:{{query}}?dataSource=#bean:{{dsBean}}&onConsume=RAW({{?consumedQuery}})&delay={{delay}}"
steps:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/mysql-sink.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/mysql-sink.kamelet.yaml
index f0c4c2b39..f948d184e 100644
--- a/library/camel-kamelets/src/main/resources/kamelets/mysql-sink.kamelet.yaml
+++ b/library/camel-kamelets/src/main/resources/kamelets/mysql-sink.kamelet.yaml
@@ -39,7 +39,7 @@ spec:
Output: the body afterwards is the JSON object as a Map, and the
`CamelSqlUpdateCount` header holds the number of rows the statement changed.
When `query` is a SELECT, the body is instead a List of the rows found, each a
Map, and the `CamelSqlRowCount` header holds their number.
- Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. The JDBC driver
of MySQL is not included: add `mvn:com.mysql:mysql-connector-j` to the
dependencies of the integratio [...]
+ Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. The JDBC driver
of MySQL is not included: add `mvn:com.mysql:mysql-connector-j` to the
dependencies of the integratio [...]
required:
- serverName
- username
@@ -81,6 +81,11 @@ spec:
description: The name of the database to connect to on the MySQL
server.
type: string
example: shop
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the MySQL JDBC driver (Connector/J),
as `name=value` pairs separated by `;`, such as
`sslMode=REQUIRED;connectTimeout=10000`. Use it for TLS: `sslMode=REQUIRED`
makes the connection use TLS, and `sslMode=DISABLED` turns TLS off. When it is
not set, the driver uses TLS when the server offers it, without checking the
certificate. The value is not hidden like a password, and it can show in the
log when the integration starts, so do not put a password [...]
+ type: string
+ example: sslMode=REQUIRED
types:
in:
mediaType: application/json
@@ -113,6 +118,7 @@ spec:
password: "{{password}}"
url: "jdbc:mysql://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: com.mysql.cj.jdbc.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri: kamelet:source
steps:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/mysql-source.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/mysql-source.kamelet.yaml
index caa81b146..1bc84d1c5 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/mysql-source.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/mysql-source.kamelet.yaml
@@ -37,7 +37,7 @@ spec:
Output: the body is one row as JSON text, an object with the column
names as keys, such as `{"id":1,"username":"oscerd","city":"Rome"}`. The
`Content-Type` header is `application/json`.
- Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
+ Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
required:
- serverName
- username
@@ -89,6 +89,11 @@ spec:
description: How long to wait after one run of `query` before the
next, in milliseconds.
type: integer
default: 500
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the MySQL JDBC driver (Connector/J),
as `name=value` pairs separated by `;`, such as
`sslMode=REQUIRED;connectTimeout=10000`. Use it for TLS: `sslMode=REQUIRED`
makes the connection use TLS, and `sslMode=DISABLED` turns TLS off. When it is
not set, the driver uses TLS when the server offers it, without checking the
certificate. The value is not hidden like a password, and it can show in the
log when the integration starts, so do not put a password [...]
+ type: string
+ example: sslMode=REQUIRED
types:
out:
mediaType: application/json
@@ -117,6 +122,7 @@ spec:
password: "{{password}}"
url: "jdbc:mysql://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: com.mysql.cj.jdbc.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri:
"{{local-sql-mysql-source}}:{{query}}?dataSource=#bean:{{dsBean}}&onConsume=RAW({{?consumedQuery}})&delay={{delay}}"
steps:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/postgresql-sink.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/postgresql-sink.kamelet.yaml
index 4c230f0ba..05f543bc7 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/postgresql-sink.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/postgresql-sink.kamelet.yaml
@@ -39,7 +39,7 @@ spec:
Output: the body afterwards is the JSON object as a Map, and the
`CamelSqlUpdateCount` header holds the number of rows the statement changed.
When `query` is a SELECT, the body is instead a List of the rows found, each a
Map, and the `CamelSqlRowCount` header holds their number.
- Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start.
+ Good to know: a message fails when its body is not a JSON object (a JSON
array or plain text, for example), or when it has no value for a parameter of
`query`. The values are sent to the database apart from the SQL text, so the
content of a message cannot change the statement. Do not write `?` in `query`,
not even in a quoted string: the Kamelet then fails to start. Without
`connectionProperties`, the connection uses TLS only when the server offers it,
and the certificate of the se [...]
required:
- serverName
- username
@@ -81,6 +81,11 @@ spec:
description: The name of the database to connect to on the PostgreSQL
server.
type: string
example: shop
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the PostgreSQL JDBC driver, as
`name=value` pairs separated by `;`, such as
`sslmode=require;connectTimeout=10`. Use it for TLS: `sslmode=require` refuses
a server that does not offer TLS, and `sslmode=verify-full` also checks the
certificate of the server against the CA certificate in the file named by
`sslrootcert`. When it is not set, the driver uses TLS when the server offers
it, without checking the certificate. The value is not hidden like a [...]
+ type: string
+ example: sslmode=require
types:
in:
mediaType: application/json
@@ -114,6 +119,7 @@ spec:
password: "{{password}}"
url:
"jdbc:postgresql://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: org.postgresql.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri: kamelet:source
steps:
diff --git
a/library/camel-kamelets/src/main/resources/kamelets/postgresql-source.kamelet.yaml
b/library/camel-kamelets/src/main/resources/kamelets/postgresql-source.kamelet.yaml
index c389cd115..95305ddcf 100644
---
a/library/camel-kamelets/src/main/resources/kamelets/postgresql-source.kamelet.yaml
+++
b/library/camel-kamelets/src/main/resources/kamelets/postgresql-source.kamelet.yaml
@@ -37,7 +37,7 @@ spec:
Output: the body is one row as JSON text, an object with the column
names as keys, such as `{"id":1,"username":"oscerd","city":"Rome"}`. The
`Content-Type` header is `application/json`.
- Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
+ Good to know: the query runs again `delay` milliseconds after the
previous run, so the same rows are sent again and again, unless `consumedQuery`
marks or deletes each row once it is sent and `query` leaves such rows out: for
example `SELECT * FROM accounts WHERE processed = false` with `UPDATE accounts
SET processed = true WHERE id = :#id`. When the next step fails for a row,
`consumedQuery` is not run for it, and the row is read again. A query that
finds no rows sends nothing. `q [...]
required:
- serverName
- username
@@ -89,6 +89,11 @@ spec:
description: How long to wait after one run of `query` before the
next, in milliseconds.
type: integer
default: 500
+ connectionProperties:
+ title: Connection Properties
+ description: "Extra settings for the PostgreSQL JDBC driver, as
`name=value` pairs separated by `;`, such as
`sslmode=require;connectTimeout=10`. Use it for TLS: `sslmode=require` refuses
a server that does not offer TLS, and `sslmode=verify-full` also checks the
certificate of the server against the CA certificate in the file named by
`sslrootcert`. When it is not set, the driver uses TLS when the server offers
it, without checking the certificate. The value is not hidden like a [...]
+ type: string
+ example: sslmode=require
types:
out:
mediaType: application/json
@@ -118,6 +123,7 @@ spec:
password: "{{password}}"
url:
"jdbc:postgresql://{{serverName}}:{{serverPort}}/{{databaseName}}"
driverClassName: org.postgresql.Driver
+ connectionProperties: "{{?connectionProperties}}"
from:
uri:
"{{local-sql-postgres-source}}:{{query}}?dataSource=#bean:{{dsBean}}&onConsume=RAW({{?consumedQuery}})&delay={{delay}}"
steps: