Federation over JFrog Bridge
Synchronize Federated repositories between SaaS and self-managed JPDs through JFrog Bridge.
JFrog Bridge enables secure, encrypted communication between JFrog Platforms without complex networking requirements. Platform services communicate with services running on another site over a private channel. Bridge doesn't require inbound network access, public exposure, or complex VPN configurations.
Bridges let you configure a Repository Federation with any number of SaaS and self-managed Artifactory sites.
This procedure was updated to include new functionality provided from Artifactory version 7.173.21 and JFrog Bridge version 1.689. If you previously implemented Federation over JFrog Bridge, We recommend that you install the latest versions and implement this method.
Prerequisites
-
You must have Admin access to all SaaS and Self-managed sites you want to federate.
-
Self-managed sites must run Artifactory version 7.173.21 or higher. On each site:
- Enable the following Bridge feature flags. Set these flags to Boolean
true:artifactory.rtfs.bridge.url.enabledin Artifactorysystem.yamlrtfs.bridge.url.enabledin RTFSsystem.yaml
- Install Bridge Client Service version 1.689 or higher and whitelist outbound traffic to the Bridge Server.
- Enable the following Bridge feature flags. Set these flags to Boolean
Setup Overview
- Step 1: Configure Bridges to Create a Federated Mesh
- Step 2: Configure Trust Between Federated Sites
- Step 3: Create the Federated Repository
Step 1: Configure Bridges to Create a Federated Mesh
Add Bridges between Self-managed and SaaS sites to build the many-to-many structure of the federation. On each Self-managed site, define bridges to every SaaS site in the federation. In each Bridge:
- The Self-managed site is the Bridge Client, and the SaaS site is the Bridge Server.
- Configure the Bridge Base URL to match the Custom Base URL of the Self-managed site, or the Federated Base URL if one is defined.
Step 2: Configure Trust Between Federated Sites
Exchange pairing tokens scoped to the Repository Federation use case to establish trust between the SaaS and Self-managed sites that you linked with Bridges.
In the code samples that follow in this procedure:
<user>:<password>are your JFrog Platform admin credentials.<saas_site_url>is the hostname of a SaaS site in the federation.<self_managed_url>is the hostname of a Self-managed site in the federation.<access-token>is the pairing token returned by the previous command
To configure trust between federated sites:
- On a SaaS site of the repository federation, generate a pairing token for the Repository Federation use case, as in the following example:
curl -u <user>:<password> --location --request POST \ 'https://<saas_site_url>/artifactory/api/v1/service_trust/pairing/federated-repo/*' \ --data ''Import this pairing token on a Self-managed site of the federation, for example:
curl -u <user>:<password> --location --request PUT \ 'https://<self_managed_url>/artifactory/api/v1/service_trust/pairing/federated-repo/*' \ --header 'Content-Type: application/json' \ --data '{ "pairing_token": "<access_token>"
}'- On the self-managed site, generate a pairing token for the Repository Federation use case, for example:
curl -u <user>:<password> --location --request POST \ 'https://<self_managed_url>/artifactory/api/v1/service_trust/pairing/federated-repo/*' \ --data ''Import this pairing token on the SaaS site of Step 1. For example:
curl -u <user>:<password> --location --request PUT \ 'https://<saas_site_url>/artifactory/api/v1/service_trust/pairing/federated-repo/*' \ --header 'Content-Type: application/json' \ --data '{
"pairing_token": "<access_token>"
}'- Repeat Steps 1 and 2 to establish trust between every Self-managed site and every SaaS site.
Step 3: Create the Federated Repository
Confirm that Federation over Bridge is working by creating a test repository and syncing an artifact between environments.
To create the federated repository:
-
Log in to a SaaS site that you want to include in the federated repository, and Create a Federated Repository. In the Federation tab, click Add Repository. The Add Federated Repositories dialog appears.
-
Add the mesh of sites you defined in previous steps. To add Self-managed sites, click URL. Add Self-managed members using the following format:
http://<self_managed_url>/artifactory/<repo_name>Where
repo-nameis the name of the federated repository you created in step 1. -
To test the federated repository, upload an artifact to the repository, and verify that it appears on SaaS and Self-managed member sites.
Verification
Success Indicators
- Bridge endpoint responds to ping.
- Pairing completes without errors.
- Artifacts sync between environments.
- No 400 or 404 errors on federation operations.
Health Check Commands
Check Bridge status (SaaS):
curl https://<saas-url>/bridge-<Bridge_ID>/access/api/v1/system/pingCheck Federation status and repository sync (SaaS):
curl -u admin:password https://<saas-url>/artifactory/api/federation/status
curl -u admin:password https://<saas-url>/artifactory/api/repositories/<repo-name>Troubleshooting
Common Issues
The following table lists common issues, their causes, and their solutions.
| Issue | Symptoms | Cause | Solution |
|---|---|---|---|
| "Adding members from same host is not allowed" | Error appears when adding members from the same host | Bridge feature flags aren't enabled | Enable artifactory.rtfs.bridge.url.enabled (Artifactory) and rtfs.bridge.url.enabled (RTFS), then retry. |
| "Federated service is not fully operational yet" | 400 error when accessing Bridge endpoint | RTFS still initializing | Wait 5–10 minutes, then retry. |
| 404 on Bridge endpoint | Bridge endpoint returns 404 Not Found | Feature flags not enabled or incorrect URL format | Verify feature flags are enabled on both Artifactory and RTFS, and check the URL format includes /bridge-<Bridge_ID>/. |
| Pairing fails with token exception | Token validation error during pairing | Known issue with RTFS-to-RTFS pairing | Follow the pairing process in Step 2 above and verify both directions are completed. |
| Artifacts not syncing | Files uploaded to one side don't appear on the other | Federation not properly configured or connection issues | Verify pairing completed successfully, check the federation member URL uses the correct Bridge prefix, review logs for connection errors, and verify base URLs are configured correctly. |
Debug Checklist
Run through this checklist if you're experiencing issues.
- Feature flags enabled on SaaS (
artifactory.rtfs.bridge.url.enabled) - RTFS enabled on self-managed (
rtfs.enabled: true) - Base URLs configured correctly on both sides
- Federation base URL includes Bridge prefix
- Pairing tokens generated and imported successfully
- Network connectivity exists (port 443)
- Pods are running and healthy
Verify Configuration Format in system.yaml
A common mistake is setting the feature flag value as a quoted string instead of a boolean.
Incorrect:
rtfs:
bridge:
url:
enabled: 'true'Correct:
rtfs:
bridge:
url:
enabled: trueAfter restart, confirm the parameter appears as a boolean in startup logs:
rtfs.bridge.url.enabled = trueA quoted 'true' may not be interpreted as a boolean, leaving the feature effectively disabled.
Enable TRACE Logging
If federation using Bridge URLs is failing, enable TRACE logging to see how URLs are detected and processed.
RTFS: Edit logback.xml (/opt/jfrog/federation/var/etc/rtfs/logback.xml), adding before </configuration>:
<logger name="org.jfrog.rtfs.common.utils.BridgeUrlProcessor" level="TRACE"/>
<logger name="org.jfrog.rtfs.common.utils.HttpUtils" level="TRACE"/>Artifactory: Edit logback.xml:
<logger name="org.artifactory.addon.federated.utils.BridgeUrlProcessor" level="TRACE"/>
<logger name="org.artifactory.addon.federated" level="DEBUG"/>After enabling TRACE, reproduce the issue and search logs:
grep -E "(BridgeUrlProcessor|Detected bridge URL|processed)" /opt/jfrog/federation/var/log/artifactory-federation-service.logExpected RTFS output:
TRACE BridgeUrlProcessor - Detected bridge URL pattern, Input remoteUrl: http://localhost:8046/bridge-xyz/artifactory/my-repo
TRACE BridgeUrlProcessor - Bridge URL with /artifactory processed - returning: http://localhost:8046/bridge-xyz/artifactoryExpected Artifactory output:
TRACE BridgeUrlProcessor - Detected bridge URL pattern, Input remoteUrl: http://localhost:8046/bridge-xyz/artifactory/my-repo
TRACE BridgeUrlProcessor - Bridge URL with /artifactory processed - removed /artifactory, returning: http://localhost:8046/bridge-xyzCollect Information for Support
When opening a support ticket, include:
rtfs.bridge.url.enabledvalue from startup logs (Artifactory and RTFS)- Relevant
system.yamlsections - RTFS and Artifactory logs with TRACE enabled (filtered for
BridgeUrlProcessor) - Repository name, Bridge URL being used, and full error message
Performance Considerations
Federation over Bridge introduces additional network hops compared to direct federation. Expect higher latency and lower throughput, particularly for large-scale artifact synchronization or high-frequency metadata operations. The degree of impact depends on the network distance between environments and artifact sizes.
If you experience slow federation or timeouts:
- Check connection pool size: Verify the Bridge client has sufficient connections.
- Monitor network latency: High latency between environments directly impacts sync times.
- Review artifact sizes: Very large artifacts may require timeout adjustments.
- Check resource allocation: Ensure pods have adequate CPU and memory.
- Test with your workload: Validate performance against your expected usage patterns before production rollout.
API Reference
Pairing Endpoints
Create pairing token:
POST /artifactory/api/v1/service_trust/pairing/federated-repo/*
Authorization: Bearer <token>Register pairing token:
PUT /artifactory/api/v1/service_trust/pairing/federated-repo/*
Content-Type: application/json
Authorization: Bearer <token>
{
"pairing_token": "<pairing-token>"
}Federation Status
Check Federation status:
GET /artifactory/api/federation/status
Authorization: Bearer <token>List Federation members:
GET /artifactory/api/repositories/<repo-name>
Authorization: Bearer <token>Configuration Reference
Base URL Format
Self-managed Federation Base URL:
http://localhost:8046/bridge-<Bridge_ID>/artifactorySaaS Base URL:
https://<your-instance>.jfrogdev.org/artifactoryBridge URL Format
For SaaS to self-managed communication:
http://localhost:8046/bridge-<Bridge_ID>/artifactory/<repo-name>Frequently Asked Questions
This section provides answers to frequently asked questions.
FAQs
Q: Do I need to configure anything on my firewall?
A: For firewall and network requirements, see Manage JFrog Bridges.
Q: What's the performance impact of using Bridge?
A: Federation over Bridge adds network overhead compared to direct federation, with higher latency for large artifacts or high-frequency sync operations. See Performance Considerations for tuning steps if you experience slow federation or timeouts.
Q: What happens if the Bridge connection drops?
A: Federation operations fail until the connection is restored. For details on Bridge reconnection behavior, see Manage JFrog Bridges.
For general Bridge questions (architecture, installation, VPN comparison), see Manage JFrog Bridges.
Related Topics
Updated 9 days ago
