RTFS Database Requirements

Set up PostgreSQL for RTFS, including shared versus separate database rules by version, sizing, and partitioning.

RTFS stores federation control-plane data (event queues, member state, binary tasks, file lists, and configuration) in PostgreSQL. RTFS does not support Oracle, MySQL, Microsoft SQL Server, or other database engines for its own datastore.

PostgreSQL for RTFS does not always mean a separate database instance from Artifactory. Shared Artifactory PostgreSQL is a supported path on versions before 7.146.7, and remains supported on 7.146.7 and later when Artifactory already uses PostgreSQL.

Shared Versus Separate PostgreSQL

The following table describes when RTFS can share Artifactory's PostgreSQL and when a separate PostgreSQL is required.

Artifactory versionArtifactory databaseRTFS PostgreSQL
Before 7.146.7PostgreSQLShared. The rtfs.database block is not available. Enabling RTFS with rtfs.enabled: true uses Artifactory's PostgreSQL.
Before 7.146.7Oracle, MySQL, Microsoft SQL Server, or otherNot supported. RTFS cannot run until you migrate Artifactory to PostgreSQL, or upgrade to 7.146.7 or later and configure a separate RTFS PostgreSQL.
7.146.7 and laterPostgreSQLShared is supported. A separate PostgreSQL through rtfs.database is optional and recommended when you want isolation.
7.146.7 and laterOracle, MySQL, Microsoft SQL Server, or otherSeparate PostgreSQL is required. Configure rtfs.database.
❗️

Warning

If you enable RTFS before Artifactory 7.146.7, RTFS stores its schema and control-plane data in the Artifactory PostgreSQL database. There is no product tool or supported procedure to migrate that data from the shared Artifactory database to a separate RTFS PostgreSQL later.

If you plan to isolate RTFS on its own database, enable RTFS for the first time on Artifactory 7.146.7 or later with rtfs.database already configured.

Enable RTFS with a Separate PostgreSQL Database on Artifactory 7.146.7 and Later

Starting with Artifactory 7.146.7, you can run RTFS against a separate PostgreSQL instance while Artifactory continues to use its existing database, for example Oracle. You don't need to migrate your Artifactory installation to PostgreSQL to adopt RTFS.

Why Use a Separate PostgreSQL for RTFS?

Before Artifactory 7.146.7, RTFS could only use Artifactory's PostgreSQL. Teams on Oracle, MySQL, or Microsoft SQL Server couldn't enable RTFS without changing the Artifactory database platform.

From 7.146.7 onward, configure rtfs.database in the Artifactory Helm chart's values.yaml or in system.yaml so RTFS uses its own PostgreSQL while Artifactory keeps your current database configuration. On Helm, leave rtfs.database.type unset to keep sharing Artifactory's PostgreSQL. Set rtfs.database.type to postgresql to point RTFS at a separate database.

Architecture

When you configure rtfs.database, Artifactory and RTFS on a single JPD use independent database connections:

┌──────────────────────────────────────────────┐
│ JFrog Platform Deployment (JPD)              │
│                                              │
│  Artifactory  ◄──►  Artifactory database     │
│       │          (Oracle, MySQL, MSSQL,      │
│       │           or PostgreSQL)             │
│       ▼                                      │
│  RTFS         ◄──►  Separate PostgreSQL      │
│                     (RTFS schema only)       │
└──────────────────────────────────────────────┘

Federation still synchronizes artifacts and metadata between JPDs as usual. Peer JPDs don't need the same Artifactory database engine. They only need reachable Artifactory endpoints and established trust.

Prerequisites

The following table lists the prerequisites for enabling RTFS with a separate PostgreSQL database.

RequirementDetails
ArtifactoryVersion 7.146.7 or later. Introduces the rtfs.database configuration.
Artifactory Helm chartChart version 107.146.7 or later when deploying with Helm.
RTFS PostgreSQLPostgreSQL 13 or later, with an empty database for RTFS. RTFS runs Flyway on first start and creates its own schema.

Provision the RTFS PostgreSQL Database

To provision the RTFS PostgreSQL database:

  • Create an empty database and owner for RTFS:

    CREATE USER rtfs WITH PASSWORD '<RTFS_DB_PASSWORD>';
    CREATE DATABASE rtfs OWNER rtfs;
    GRANT ALL PRIVILEGES ON DATABASE rtfs TO rtfs;

    Where:

    • <RTFS_DB_PASSWORD>: The password to assign to the new rtfs database user

    For example:

    CREATE USER rtfs WITH PASSWORD 'S3cureP@ssw0rd!';
    CREATE DATABASE rtfs OWNER rtfs;
    GRANT ALL PRIVILEGES ON DATABASE rtfs TO rtfs;
❗️

Warning

Use a managed or highly available PostgreSQL deployment with backups for RTFS. RTFS is part of your federation control plane. Treat its database with the same operational rigor as other platform data stores.

Enable RTFS on Helm with a Non-PostgreSQL Artifactory Database

The following example shows Artifactory on Oracle with RTFS on a separate PostgreSQL instance. The Artifactory database block is unchanged when you enable RTFS. Only the rtfs section is added or updated.

Artifactory on Oracle:

postgresql:
  enabled: false

database:
  allowNonPostgresql: true
  type: oracle
  driver: oracle.jdbc.OracleDriver
  url: "jdbc:oracle:thin:@<ORACLE_HOST>:1521/FREEPDB1"
  user: "artifactory"
  password: "<ARTIFACTORY_DB_PASSWORD>"

The Oracle JDBC driver isn't bundled with Artifactory. Ship ojdbc11.jar in a custom image or mount it into Tomcat's lib directory rather than downloading it on every pod start.

Enable RTFS with a separate PostgreSQL:

rtfs:
  enabled: true
  database:
    type: postgresql
    driver: org.postgresql.Driver
    url: "jdbc:postgresql://<POSTGRES_HOST>:5432/rtfs"
    user: "rtfs"
    password: "<RTFS_DB_PASSWORD>"
❗️

Warning

Do not store database passwords in plain text in chart values. Reference existing Kubernetes Secrets:

rtfs:
  enabled: true
  database:
    secrets:
      url:
        name: my-rtfs-db-secret
        key: db-url
      user:
        name: my-rtfs-db-secret
        key: db-user
      password:
        name: my-rtfs-db-secret
        key: db-password

Run helm upgrade with your values file, then confirm RTFS health as described in Verify RTFS Is Running.

Enable RTFS in system.yaml for Non-Helm Installations

For RPM/Debian, archive/tarball, Docker Compose, or VM deployments, edit $JFROG_HOME/artifactory/var/etc/system.yaml.

Example for Oracle-backed Artifactory with RTFS on a separate PostgreSQL:

shared:
  database:
    allowNonPostgresql: true
    type: oracle
    driver: oracle.jdbc.OracleDriver
    url: "jdbc:oracle:thin:@<ORACLE_HOST>:1521/FREEPDB1"
    username: "artifactory"
    password: "<ARTIFACTORY_DB_PASSWORD>"

rtfs:
  enabled: true
  database:
    type: postgresql
    driver: org.postgresql.Driver
    url: "jdbc:postgresql://<POSTGRES_HOST>:5432/rtfs"
    username: "<RTFS_DB_USER>"
    password: "<RTFS_DB_PASSWORD>"
📘

Note

Helm chart values use user under rtfs.database. In system.yaml, use username for the RTFS database user.

Your existing shared.database configuration doesn't change. You only add the rtfs block. Restart Artifactory so the platform picks up the change and starts RTFS.

Verify RTFS Is Running

Check the RTFS liveness endpoint (Artifactory 7.117.5+ or 7.111.12+):

curl -s -o /dev/null -w "%{http_code}\n" \
  https://<JFROG_PLATFORM_URL>/rtfs/api/v1/system/liveness

A response of 200 indicates RTFS is up and connected to PostgreSQL.

On Kubernetes, RTFS pod logs should show JDBC connectivity and Flyway migrations on first start:

kubectl -n <NAMESPACE> logs <RTFS_POD> | grep -iE "postgres|jdbc:postgres|flyway"

Existing trust and federation configurations continue to work when you enable RTFS on an already federated environment. If you run legacy in-Artifactory federation today, enable RTFS first, then migrate configuration and state. For more information, see Migrate to the Artifactory Federation Service.

After RTFS is healthy, configure federated repositories and trust between JPDs as described in Setup Prerequisites for Federated Repositories and Create a Federated Repository or Create Your First Federation.

Production Considerations for RTFS Database

  • Use rtfs.database.secrets (and existingSecret for Artifactory credentials) instead of inline passwords.
  • Run managed or HA PostgreSQL for RTFS with backup and recovery procedures.
  • Set appropriate resource requests, limits, HPA, and PodDisruptionBudgets per the Helm chart documentation.
  • Establish JPD trust through the Platform UI or supported automation rather than ad-hoc API calls where possible.

Database Requirements

RTFS has the following database requirements.

RequirementValue
Database enginePostgreSQL
JDBC driverorg.postgresql.Driver
Helm configurationFor a separate RTFS database, set rtfs.database.type to postgresql and provide URL and credentials. Leave rtfs.database.type unset to share Artifactory's PostgreSQL.

RTFS doesn't support MySQL, MariaDB, Oracle, or other databases for its own datastore. PostgreSQL is required for both SaaS and self-managed deployments.

Key Tables and Data Types

RTFS stores the following categories of data in its database.

Data CategoryPurposeGrowth Pattern
Event queuePersistent storage for artifact and repository events waiting to be propagated.Grows with event volume. Cleaned by EventsCleanupJob after rtfs.events.cleanup.retention.time.Days (default: 3 days).
Message blobsSerialized event payloads for batch propagation.Grows with event volume. Partitioned automatically.
Member stateCurrent state, heartbeat timestamps, and configuration for each Federation member.Stable size. One record per member per repository.
Binary tasksTracking records for asynchronous binary transfers between members.Grows with binary transfer volume. Completed tasks are cleaned up.
File list tasksTracking records for Full Sync file list preparation and processing.Transient. Entries are removed after Full Sync completes.
Stream metadataWorker stream positions and lag tracking.Stable size. One record per stream.

Database Partitioning

RTFS automatically manages database table partitioning for event and message blob tables. Partitioning keeps query performance stable as event volume grows by distributing data across manageable segments.

How Partitioning Works

  1. The PartitionMakerJob runs on a schedule (default: every 30 minutes) and evaluates whether new partitions are needed.
  2. New partitions are created when the current partition's primary key count reaches a configurable threshold percentage of the partition size.
  3. The SubPartitionPrimaryKeyMonitoringJob monitors sub-partition primary key counts and reports metrics.

Partitioning Properties

The following properties control partitioning behavior.

PropertyDefaultDescription
rtfs.partition.job.interval.cron0 0/30 * ? * *Cron schedule for the partition management job.
rtfs.sub.partition.pk.monitoring.cron0 0 0 ? * * *Cron schedule for sub-partition primary key monitoring (daily at midnight).
rtfs.chunk.of.sub.partition.size7000000Maximum number of records per sub-partition chunk.
rtfs.threshold.percentage.partition.creation.size50Percentage of partition capacity that triggers creation of a new partition.

Partitioning Metrics

The following metrics track partition growth.

MetricDescription
jfrtfs_sub_partition_total_countTotal number of sub-partitions for a tenant and table.
jfrtfs_sub_partition_pk_countNumber of sub-partitions with primary keys for a tenant and table.
jfrtfs_repo_management_message_blob_duration_between_partition_creationsTime between message blob partition creations (milliseconds).
jfrtfs_repo_management_events_duration_between_partition_creationsTime between events partition creations (milliseconds).

Sizing Recommendations

The following table provides sizing guidelines based on deployment scale.

Deployment ScaleFederated ReposEstimated DB Size (steady state)Recommended Resources
Small< 10< 5 GB2 vCPU, 4 GB RAM
Medium10 - 1005 - 50 GB4 vCPU, 8 GB RAM
Large100+50+ GB8+ vCPU, 16+ GB RAM

These are rough guidelines. Actual database size depends on event volume, binary task count, event retention period, and Full Sync frequency. For thread pool and replica sizing guidance based on deployment scale, see the Scaling and Sizing Guide.

Connection Pool Configuration

The following property configures the database connection pool.

PropertyDefaultDescription
rtfs.db.lock.native.pool.size3Database lock pool size for coordinating concurrent operations.

Maintenance

  • Event cleanup: The EventsCleanupJob removes processed events older than rtfs.events.cleanup.retention.time.Days (default: 3 days).
  • Orphan cleanup: The MaintenanceCleanupJob removes orphaned records (default: daily at 2:00 AM).
  • Partition monitoring: Monitor jfrtfs_sub_partition_total_count and jfrtfs_sub_partition_pk_count metrics to track partition growth.
  • Vacuuming: Standard PostgreSQL maintenance (VACUUM, ANALYZE) applies. Configure autovacuum appropriately for high-event-volume deployments.

Frequently Asked Questions

This section provides answers to frequently asked questions.

plusFAQs
Q: Which Artifactory version supports a separate PostgreSQL database for RTFS?

A: Starting with Artifactory 7.146.7, you can configure rtfs.database so RTFS uses a separate PostgreSQL instance while Artifactory continues to use its existing database.

Q: Can RTFS share Artifactory's PostgreSQL?

A: Yes. Before 7.146.7, shared PostgreSQL is the only supported path. From 7.146.7, shared PostgreSQL remains supported when Artifactory already uses PostgreSQL. A separate RTFS database is optional in that case, and required when Artifactory uses a non-PostgreSQL engine.

Q: Can I migrate RTFS data from the shared Artifactory database to a separate PostgreSQL?

A: No. There is no product tool or supported procedure to migrate existing RTFS data from a shared Artifactory PostgreSQL database to a separate RTFS PostgreSQL. Enable a separate PostgreSQL at first RTFS enablement on 7.146.7 or later if you need isolation.

Q: Can RTFS use the same database engine as Artifactory, such as Oracle or MySQL?

A: No. RTFS only supports PostgreSQL for its own datastore. From 7.146.7, Artifactory can keep Oracle, MySQL, or Microsoft SQL Server while RTFS uses a separate PostgreSQL.

Q: How does RTFS manage database partitioning?

A: The PartitionMakerJob runs on a schedule and creates new partitions automatically once the current partition's primary key count reaches a configurable threshold. See Database Partitioning for the properties that control this.

Q: How long are processed events retained before cleanup?

A: By default, the EventsCleanupJob removes processed events after 3 days, controlled by rtfs.events.cleanup.retention.time.Days.

Related Topics


Did this page help you?