ARTIFACTORY: Access Microservice License Injection and Failures Due to 3MB Configuration Limit

Products
Frog_Artifactory
Content Type
Use_Case
AuthorFullName__c
Kanishk Sharma
articleNumber
000006810
FirstPublishedDate
2025-12-31T09:26:11Z
lastModifiedDate
2025-12-31

ARTIFACTORY: Access Microservice License Injection and Failures Due to 3MB Configuration Limit

When Artifactory starts, it injects its license into the access microservice by adding the license to the access.config.latest.yml file. This process subsequently updates the internal access configuration.

The following logs show a snippet from a normal access-service.log during a successful startup sequence:
2025-11-17T16:45:32.063Z [jfrt ] [INFO ] [1054179ef45935cc] [o.a.s.a.AccessServiceImpl:692 ] [art-init            ] - Initialized new service id: jfrt@01ka92ytz153hr0trprtg91fm2
2025-11-17T16:45:32.107Z [jfrt ] [INFO ] [1054179ef45935cc] [oryAccessClientConfigStore:531] [art-init            ] - Using Access Server URL: http://localhost:8046/access source: System Config
2025-11-17T16:45:32.730Z [jfrt ] [INFO ] [1054179ef45935cc] [.a.c.AccessClientBootstrap:180] [art-init            ] - Cluster join: Executing join on 'http://localhost:8046/access'
2025-11-17T16:45:32.999Z [jfrt ] [INFO ] [1054179ef45935cc] [.a.c.AccessClientBootstrap:191] [art-init            ] - Cluster join: Successfully joined the cluster
2025-11-17T16:45:33.006Z [jfrt ] [INFO ] [1054179ef45935cc] [.a.u.ListeningPortDetector:114] [art-init            ] - Tomcat connectors: [Catalina:type=Connector,port=8081, Catalina:type=Connector,port=8091,address="127.0.0.1", Catalina:type=Connector,port=8080]
2025-11-17T16:45:33.007Z [jfrt ] [INFO ] [1054179ef45935cc] [.a.u.ListeningPortDetector:116] [art-init            ] - Found Tomcat main connector: Catalina:type=Connector,port=8081
.
.
.
2025-11-17T16:45:35.490Z [jfrt ] [INFO ] [1054179ef45935cc] [o.a.s.a.AccessServiceImpl:621 ] [art-init            ] - Initialized access service successfully with client id 1214430970, closing old client id [null]

The final line, Initialized access service successfully..., indicates a successful boot.
There is a hard limitation on the size of the access.config.latest.yml file, which is 3,145,728 bytes (approximately 3MB).
When the file size exceeds this limit, Artifactory can no longer inject the license payload into the access microservice. During startup, this failure will produce the following ERROR in the access-service.log:
2025-10-07T18:10:35.479Z [jfrt ] [ERROR] [c90f0f6587571088] [o.a.l.v.log:325          ] [art-init            ] - Failed to activate license
org.jfrog.access.client.AccessClientException: Couldn't update access configuration, http response code: 400, body: {
  "errors" : [ {
    "code" : "BAD_REQUEST",
    "message" : "Invalid payload",
    "detail" : "The incoming YAML document exceeds the limit: 3145728 code points."
  } ]
}

This exception, specifically the BAD_REQUEST message, confirms the configuration file has grown too large.

Common cause


This issue commonly occurs when the configuration file becomes bloated with hundreds of unused server names and license entries.
  • Normal Behavior: During a license upgrade on a server with a consistent server name, the old license is simply overwritten in the access.config.latest.yml.
  • Problematic Behavior: If a node ID is not explicitly defined in Artifactory's system.yaml file (under "Node Settings"), the system auto-generates a new ID at each startup.
The access microservice treats each new, auto-generated node ID as a new, distinct server. This causes it to create a new, separate license entry every time Artifactory restarts. This rapid accumulation of entries eventually causes the access.config.latest.yml file to exceed the 3MB limit.

Resolution


To prevent this issue, you can add an automated task called clean-unused-licenses to the access configuration. This task will periodically check for and clean out unused licenses from the configuration file, keeping its size manageable.

For detailed instructions on enabling this task, please refer to the official documentation: Artifactory - Automating and Manual License Key Cleanup in Access Config