Scaling and Sizing Guide
Size RTFS deployments with tier-based guidance on thread pools, batches, and autoscaling.
This guide provides sizing recommendations for RTFS deployments based on the number of Federated repositories, event volume, and member count.
Deployment Tiers
Small: Fewer Than 10 Federated Repositories
Suitable for teams getting started with Federation or running a limited number of synchronized repositories.
| Resource | Recommended Value |
|---|---|
| RTFS replicas | 1 |
| CPU requests and limits | 2 and 4 |
| Memory requests and limits | 4Gi and 8Gi |
| Database | 2 vCPU, 4 GB RAM |
| Thread pool overrides | None (use defaults) |
Medium: 10 to 100 Federated Repositories
Suitable for organizations with multiple teams and moderate artifact volume.
| Resource | Recommended Value |
|---|---|
| RTFS replicas | 1 - 2 |
| CPU requests and limits | 4 and 6 |
| Memory requests and limits | 8Gi and 12Gi |
| Database | 4 vCPU, 8 GB RAM |
| Thread pool overrides | Consider increasing rtfs.jobs.thread.pool.size and rtfs.tenant.thread.pool.size |
Large: More Than 100 Federated Repositories
Suitable for large enterprises with high artifact volume and many Federation members.
| Resource | Recommended Value |
|---|---|
| RTFS replicas | 2+ (with autoscaling) |
| CPU requests and limits | 4 and 6 (per replica) |
| Memory requests and limits | 8Gi and 12Gi (per replica) |
| Database | 8+ vCPU, 16+ GB RAM |
| Thread pool overrides | Increase thread pools proportionally (see the following section) |
Thread Pool Sizing
Scale thread pools based on the number of Federated repositories and members.
| Property | Default | When to Increase | Guideline |
|---|---|---|---|
rtfs.jobs.thread.pool.size | 100 | > 100 repos or high Full Sync frequency | Set to 1.5x the number of federated repos |
rtfs.tenant.thread.pool.size | 100 | Multi-tenant SaaS deployments | Scale with tenant count |
rtfs.heartbeat.thread.pool.size | 100 | > 100 repos with many members each | Scale with total member count across all repos |
rtfs.tenant.heartbeat.thread.pool.size | 200 | Multi-tenant deployments | Scale with tenant count |
rtfs.full.sync.thread.pool.size | 30 | Frequent Full Syncs or large repos | Increase to handle concurrent Full Syncs |
rtfs.request.tunneling.thread.pool.size | 30 | Heavy use of cross-member operations | Scale with tunneling request volume |
Worker and Batch Sizing
The following properties control worker and batch sizing.
| Property | Default | Impact of Increasing | Impact of Decreasing |
|---|---|---|---|
rtfs.worker.batch.size | 100 | Higher throughput per worker cycle, more memory usage | Lower throughput, faster per-event response |
rtfs.worker.max.events.processed.in.batch | 200 | More events per cycle for STANDARD priority repos | Limits maximum batch size |
rtfs.worker.max.events.processed.in.batch.for.high.priority | 400 | More events per cycle for HIGH or URGENT repos | Limits maximum batch size for prioritized repos |
rtfs.stream.allocation.size | 50 | More events loaded per stream read | More memory per stream |
Priority Repository Limits
RTFS enforces limits on the number of repositories that can be set to HIGH or URGENT priority to prevent priority inflation.
| Property | Default | Description |
|---|---|---|
rtfs.max.high.priority.repos.per.member | 10 | Maximum number of HIGH priority repos per member. |
rtfs.max.high.priority.repos.percentage | 0.2 (20%) | Maximum percentage of total repos that can be HIGH priority. |
The effective limit is the lower of the two values.
Connection Pool Sizing
The following properties control connection pool sizing.
| Property | Default | When to Increase |
|---|---|---|
rtfs.reactive.http.client.max.connections | 50 | High concurrency across many members |
federated.repo.max.total.http.connections | 50 | Many concurrent federation operations on Artifactory side |
Binary Task Handler Sizing
The following properties control binary task handler sizing.
| Property | Default | When to Increase |
|---|---|---|
rtfs.binary.tasks.handler.tenants.thread.pool.size | 100 | High volume of binary transfers |
rtfs.binary.tasks.handler.fetch.limit.per.tenant | 500 | Large backlog of pending binary tasks |
rtfs.binary.tasks.inbound.insert.batch.size | 500 | Burst of new binary tasks during Full Sync |
Kubernetes Autoscaling
RTFS supports Horizontal Pod Autoscaling when deployed via Helm:
autoscaling:
enabled: true
minReplicas: 1
maxReplicas: 5
targetCPU: "70"
targetMemory: "80"Monitoring for Sizing Decisions
Use these metrics to determine if scaling is needed.
| Metric | What It Tells You | Action If High |
|---|---|---|
jfrtfs_worker_lag | Event processing is falling behind | Increase worker batch size or add replicas |
jfrtfs_binary_tasks_counter (status=AVAILABLE) | Binary tasks are queuing up | Increase binary task handler thread pool |
jfrtfs_http_client_connections_pending | HTTP connections are exhausted | Increase max connections |
jfrtfs_http_client_connections_available | Low availability indicates saturation | Increase max connections or add replicas |
Related Topics
Updated about 7 hours ago
