Database Overview

Database setup

Follow the instructions for the type of database you'll be connecting to the application:

Note that PostgreSQL and MSSQL are the recommended database options. While we do support the use of Oracle, it is the least used option, and we may remove support for it in the future if usage decreases.

For a list of supported versions, see Infrastructure Requirements (Production).

Database notifications configuration (optional)

Workers notify each other using a database provided notification mechanism. With big clusters, this can put unnecessary high load on the database.

To replace the notification mechanism with polling, add:

JOBQUEUE_POLLING_SEC=8

A positive value means the number of seconds to sleep between polls. A value of 0 means notifications through the database.

Recommended values:

  1. For clusters up to 2 machines: 0

  2. For clusters of 3 or more machines: the number of machines.

Pooling database connections (optional)

In v28.3.3+ and v30.0.5 and later, you can pool database connections by adding the FORMS_DB_CONN_MAX_AGE variable to your ".env" file. The variable's value is the maximum number of seconds that database connections are kept and reused.

In the example below, database connections are retained and reused for up to 10 hours:

FORMS_DB_CONN_MAX_AGE=36000