You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A relational database is used to store stream and task definitions as well as the state of executed tasks.
4
+
Spring Cloud Data Flow provides schemas for *MariaDB*, *MySQL*, *Oracle*, *PostgreSQL*, *Db2*, *SQL Server*, and *H2*. The schema is automatically created when the server starts.
5
+
6
+
NOTE: The JDBC drivers for *MariaDB*, *MySQL* (via the _MariaDB_ driver), *PostgreSQL*, *SQL Server* are available without additional configuration. To use any other database you need to put the corresponding JDBC driver jar on the classpath of the server as described <<#add-custom-driver,here>>.
7
+
8
+
To configure a database the following properties must be set:
9
+
10
+
* `spring.datasource.url`
11
+
* `spring.datasource.username`
12
+
* `spring.datasource.password`
13
+
* `spring.datasource.driver-class-name`
14
+
15
+
The `username` and `password` are the same regardless of the database. However, the `url` and `driver-class-name` vary per database as follows.
|[.small]#jdbc:mariadb://${db-hostname}:${db-port}/${db-name}?allowPublicKeyRetrieval=true&useSSL=false&autoReconnect=true&permitMysqlScheme#{empty}footnote:[SSL is disabled in this example, adjust accordingly for your environment and requirements]
Copy file name to clipboardExpand all lines: spring-cloud-dataflow-docs/src/main/asciidoc/configuration-kubernetes.adoc
+5-10Lines changed: 5 additions & 10 deletions
Original file line number
Diff line number
Diff line change
@@ -421,14 +421,13 @@ data:
421
421
The password is a base64-encoded value.
422
422
423
423
[[configuration-kubernetes-rdbms]]
424
-
=== Database Configuration
424
+
=== Database
425
425
426
-
Spring Cloud Data Flow provides schemas for H2, MariaDB, Oracle, PostgreSQL, DB2, and SQL Server. The appropriate schema is automatically created when the server starts, provided the right database driver and appropriate credentials are in the classpath.
426
+
include::configuration-database.adoc[]
427
427
428
-
The JDBC drivers for MariaDB, PostgreSQL, SQL Server, and embedded H2 are available out of the box.
429
-
If you use any other database, you need to put the corresponding JDBC driver jar on the classpath of the server.
428
+
==== Database configuration
430
429
431
-
For instance, if you use MariaDB in addition to a password in the secrets file, you could provide the following properties in the ConfigMap:
430
+
When running in Kubernetes, the database properties are typically set in the ConfigMap. For instance, if you use MariaDB in addition to a password in the secrets file, you could provide the following properties in the ConfigMap:
Copy file name to clipboardExpand all lines: spring-cloud-dataflow-docs/src/main/asciidoc/configuration-local.adoc
+13-73Lines changed: 13 additions & 73 deletions
Original file line number
Diff line number
Diff line change
@@ -29,91 +29,31 @@ The REST `/about` endpoint provides information on the features that have been e
29
29
[[configuration-local-rdbms]]
30
30
=== Database
31
31
32
-
A relational database is used to store stream and task definitions as well as the state of executed tasks.
33
-
Spring Cloud Data Flow provides schemas for *H2*, *MariaDB*, *Oracle*, *PostgreSQL*, *Db2*, and *SQL Server*. The schema is automatically created when the server starts.
32
+
include::configuration-database.adoc[]
34
33
35
-
By default, Spring Cloud Data Flow offers an embedded instance of the *H2* database (if the H2 JDBC driver jar is found on the classpath).
36
-
The *H2* database is good for development purposes but is not recommended for production use.
37
-
38
-
NOTE: *H2* database is not supported as an external mode.
39
-
40
-
The JDBC drivers for *MariaDB*, *PostgreSQL*, *SQL Server* are available without additional configuration.
41
-
42
-
If you are using the embedded *H2* or any other database, then you need to put the corresponding JDBC driver jar on the classpath of the server.
43
-
44
-
The database properties can be passed as environment variables or command-line arguments to the Data Flow Server.
45
-
46
-
==== MariaDB
47
-
48
-
The following example shows how to define a MariaDB database connection with command Line arguments
34
+
==== Database configuration
49
35
36
+
When running locally, the database properties can be passed as environment variables or command-line arguments to the Data Flow Server. For example, to start the server with MariaDB using command line arguments execute the following command:
NOTE: Due to licensing restrictions we're unable to bundle Oracle driver. You need to add it to
115
-
server's classpath yourself.
116
-
56
+
[#add-custom-driver]
117
57
==== Adding a Custom JDBC Driver
118
58
To add a custom driver for the database (for example, Oracle), you should rebuild the Data Flow Server and add the dependency to the Maven `pom.xml` file.
119
59
You need to modify the maven `pom.xml` of `spring-cloud-dataflow-server` module.
@@ -124,7 +64,7 @@ To add a custom JDBC driver dependency for the Spring Cloud Data Flow server:
124
64
. Select the tag that corresponds to the version of the server you want to rebuild and clone the github repository.
125
65
. Edit the spring-cloud-dataflow-server/pom.xml and, in the `dependencies` section, add the dependency for the database driver required. In the following example , an Oracle driver has been chosen:
0 commit comments