Guides → Manage Application Databases
This content applies to Incorta Cloud deployments only.
Each application has two separate PostgreSQL databases that Incorta creates and manages for you: one for development and one for production. The application stores everything it saves in these databases, including statuses, notes, approvals, and other user-entered data.
- Each application's databases are isolated from every other application.
- You do not need to provision or configure the databases.
- The development and production databases hold different data. Test data that you enter while you build does not appear in the published application.
| Database | Used by | Created |
|---|---|---|
| Development | The development sandbox and previews | When you create the application |
| Production | The published application only | The first time you publish the application |
View the application databases
- In the Application Editor, select More.
- In the navigation panel, select Database. The Database page lists the Development and Production databases, with the status and storage usage of each.
- To view the details of a database, select the database. To return to the list, select All databases.
Each database has two tabs: Overview and Settings.
Database overview
The Overview tab shows the following information:
| Section | Description |
|---|---|
| Storage | The storage that the database uses, out of its storage limit |
| Tables | The tables in the public schema, with the number of rows and the size of each table |
| Applied schema | Production database only. The schema currently applied to the production database. |
The Applied schema section contains the following details:
| Field | Description |
|---|---|
| Phase | The status of the most recent schema change, for example, complete |
| Applied at | The date and time the schema was applied |
| Version | The application version that the schema belongs to |
| Snapshot | The identifier of the applied schema snapshot |
Database settings
The Settings tab of each database contains the following sections:
| Section | Development | Production |
|---|---|---|
| Connection details | The connection URL of the development database | The connection URL of the production database |
| External access | The development database connection URL to connect from outside Incorta | The production database connection URL to connect from outside Incorta. Production credentials are available only to the hosted published application. |
| Storage | The storage that the database uses, out of its storage limit | The storage that the database uses, out of its storage limit |
| Credentials | Rotate the database password | Rotate the database password |
| Danger zone | Reset the development database | Delete the production database |
Connection details
Hosted runtimes receive the database connection automatically as the DATABASE_URL environment variable, so you do not need to configure the connection in your application.
The Connection URL field shows the connection URL of the development database. The URL is hidden by default. To show the URL, select the eye icon. To copy the URL, select the copy icon.
The connection URL contains the database credentials. If the URL is exposed, rotate the credentials.
External access
External access lets you connect to the development database from outside Incorta, for example, to run the application locally against its development data.
If external database access is not configured on your deployment, the External access section shows Unavailable. Hosted applications are not affected.
The production database never allows external access. Production credentials are available only to the hosted published application.
Rotate the database credentials
All editors of an application receive the same database credential. Removing an editor's access to the application does not revoke a credential that the editor already copied. To revoke access for everyone, rotate the credentials.
Rotate the credentials if a connection string has been exposed.
- Open the Development or Production database, and then select Settings.
- In the Credentials section, select Rotate credentials.
Running environments reconnect to the database automatically with the new credentials.
Reset the development database
Reset the development database when it no longer matches your code. A reset drops the development database and recreates it empty from the schema of the current version. The connection URL stays the same.
A reset permanently deletes all development data. The production database is not affected.
- Open the Development database, and then select Settings.
- In the Danger zone section, enter the application name to confirm.
- Select Reset development database.
Delete the production database
Deleting the production database permanently deletes the database and all of its data. You cannot undo this action.
- Open the Production database, and then select Settings.
- In the Danger zone section, enter the application name to confirm.
- Select Delete production database.
Additional considerations
- Reverting to an earlier version: Reverting syncs the development database to that version's schema, which can drop columns and their data. The production database is not affected.
- Database service unavailable: If the database service is unavailable when you create an application, Incorta still creates the application without a database.
Deleting an application permanently deletes both of its databases and all data in them.