Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions doc/sphinx-guides/source/installation/config.rst
Original file line number Diff line number Diff line change
Expand Up @@ -957,7 +957,28 @@ Logging & Slow Performance
- When set to true, all JDBC calls will be logged allowing tracing of all JDBC interactions including SQL.
- ``false``

Database Configuration Tips
+++++++++++++++++++++++++++

In this section you can find some example scenarios of advanced configuration for the database connection that can improve service performance and availability.

Database Connection Recovery
^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Consider the following scenario: if there is no advanced configuration for the database connection and the Dataverse server loses that connection, for example if the database host is down, the server will be "dead" even after the database server is back to normal.
The only solution to recover Dataverse would be to restart the service. To avoid this situation, the following settings can be used to configure validation of the database connection.
This way, the database connection can be automatically recovered after a failure, improving the server availability. For a Docker installation, it is suggested to create an init.d script so that if the container needs to be recreated, these settings will always be configured.

.. code-block:: bash

# Enable database connection validation
asadmin create-jvm-options "-Ddataverse.db.is-connection-validation-required=true"
# Configure to use a database table as the validation method
asadmin create-jvm-options "-Ddataverse.db.connection-validation-method=table"
# Configure the "setting" table to be used for connection validation, but any tables can be used
asadmin create-jvm-options "-Ddataverse.db.validation-table-name=setting"
# Configure a validation period of 60 seconds, but different values may be used
asadmin create-jvm-options "-Ddataverse.db.validate-atmost-once-period-in-seconds=60"

.. _file-storage:

Expand Down