Fine-tuning Oozie's database connection
Learn how you can configure Oozie to use its database well.
When it comes to configuring database connections, simply providing a hostname, port, username, and password may not be sufficient. In order to optimize Oozie's database connection, you might need to manually construct lengthy connection and configuration strings using safety-valve settings. To simplify this process and enable finer control over Oozie's database connection, you can use several enhancements, as described in this section.
- oozie_database_connection_properties
You can use this property to directly configure the database connection. For example, if you need to pass a trustStore path to the connection, you can add a property named
javax.net.ssl.trustStore
and with a value to your trustStore file. - oozie_datasource_propertiesYou can use this property to configure the datasource object created by OpenJPA. For example, if you would like to finetune how many idle connections the datasource instance should keep, you can set the
maxIdle
property.
oozie.service.JPAService.connection.properties
, and it is
assembled in the following way:- Whatever you specify in
oozie_database_connection_properties
, is concatenated with a semicolon, and available under the ConnectionProperties property in the final configuration. - Whatever you specify in
oozie_datasource_properties
, is directly set in the final configuration.
oozie_database_connection_properties
, because your database
JDBC driver accepts them,javax.net.ssl.trustStore=/path/to/trustStore.jks
ssl.enabled=true
oozie_datasource_properties
:maxIdle=10
defaultQueryTimeout=120
oozie.service.JPAService.connection.properties
will
be:ConnectionProperties="javax.net.ssl.trustStore=/path/to/trustStore.jks;ssl.enabled=true", maxIdle=10, defaultQueryTimeout=120