ARTIFACTORY: Why do I get “there are too many folder download requests currently running. Try again” error

Pranav Hegde
2023-01-22 11:07

Problem statement:

In some scenario, we receive the below error when performing the folder download of the artifacts,{
  "errors" : [ {
    "status" : 400,
    "message" : "{\"error\":\"There are too many folder download requests currently running. Try again later.\"}"
  } ]
}

Cause:

Usually, the above error occurs when the maximum number of concurrent folder downloads allowed reaches the limit.  You should see the below error in the Artifactory logs.

artifactory-service.log:
2022-11-24T06:26:01.960Z [jfrt ] [ERROR] [48387fc44db6b2a5] [wnloadFolderArchiveService:118] [http-nio-8081-exec-4] - Error while executing folder download on path: example-repo-local/ --> There are too many folder download requests currently running. Try again later.

artifactory-request.log:
2022-11-24T06:26:01.962Z|48387fc44db6b2a5|1.2.3.4|admin|GET|/api/artifactactions/downloadfolder|400|-1|0|5|Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:99.0) Gecko/20100101 Firefox/99.0

Solution:

To resolve the issue, you need to increase the Max Parallel Folder Downloads option in the Artifactory General setting page. By default the Max Parallel Folder Downloads allowed in Artifactory is 10, you may increase the number depending on the number of requests you receive to perform the folder download.

User-added image

We can get the number of requests by querying the Artifactory logs like the below:

E.g command:  cat artifactory-request.log | grep “downloadfolder” | wc -l