Uploaded image for project: 'Jenkins Artifactory Plug-in'
  1. Jenkins Artifactory Plug-in
  2. HAP-1000

Deployment via spec isn't working if too many files/folders exist

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: 2.13.0
    • Fix Version/s: 2.16.0
    • Component/s: Common
    • Labels:
    • Environment:

      Jenkins 2.84

      Description

      I try to deploy one specific file using spec:

      {
          "files": [
              {
                  "pattern": "${WORKSPACE}/build_info.txt",
                  "target": "test_repo/${BUILD_ID}/",
                  "props": "test_prop1=1;test_prop2=2"
              }	
          ]
      }
      

      Result is:

      Jenkins Artifactory Plugin version: 2.13.0
      ERROR: Too many candidate files found.
      java.lang.IllegalStateException: Too many candidate files found.
      	at org.jfrog.build.extractor.clientConfiguration.util.FileCollectionUtil.isPassedLimit(FileCollectionUtil.java:94)
      	at org.jfrog.build.extractor.clientConfiguration.util.FileCollectionUtil.collectFiles(FileCollectionUtil.java:77)
      	at org.jfrog.build.extractor.clientConfiguration.util.FileCollectionUtil.collectFiles(FileCollectionUtil.java:35)
      	at org.jfrog.build.extractor.clientConfiguration.util.spec.UploadSpecHelper.collectMatchedFilesByWildcard(UploadSpecHelper.java:92)
      	at org.jfrog.build.extractor.clientConfiguration.util.spec.UploadSpecHelper.buildPublishingData(UploadSpecHelper.java:68)
      	at org.jfrog.build.extractor.clientConfiguration.util.spec.SpecsHelper.buildTargetPathToFiles(SpecsHelper.java:242)
      	at org.jfrog.build.extractor.clientConfiguration.util.spec.SpecsHelper.getDeployDetails(SpecsHelper.java:133)
      	at org.jfrog.build.extractor.clientConfiguration.util.spec.SpecsHelper.uploadArtifactsBySpec(SpecsHelper.java:64)
      	at org.jfrog.hudson.generic.GenericArtifactsDeployer$FilesDeployerCallable.invoke(GenericArtifactsDeployer.java:189)
      	at org.jfrog.hudson.generic.GenericArtifactsDeployer$FilesDeployerCallable.invoke(GenericArtifactsDeployer.java:130)
      	at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2761)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:205)
      	at hudson.remoting.UserRequest.perform(UserRequest.java:52)
      	at hudson.remoting.Request$2.run(Request.java:356)
      	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      	at java.lang.Thread.run(Thread.java:748)
      	Suppressed: hudson.remoting.Channel$CallSiteStackTrace: Remote call to CentOS7_slave
      		at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1655)
      		at hudson.remoting.UserResponse.retrieve(UserRequest.java:308)
      		at hudson.remoting.Channel.call(Channel.java:904)
      		at hudson.FilePath.act(FilePath.java:987)
      		at hudson.FilePath.act(FilePath.java:976)
      		at org.jfrog.hudson.generic.GenericArtifactsDeployer.deploy(GenericArtifactsDeployer.java:76)
      		at org.jfrog.hudson.generic.ArtifactoryGenericConfigurator$1.tearDown(ArtifactoryGenericConfigurator.java:401)
      		at hudson.model.Build$BuildExecution.doRun(Build.java:174)
      		at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:496)
      		at hudson.model.Run.execute(Run.java:1724)
      		at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      		at hudson.model.ResourceController.execute(ResourceController.java:97)
      		at hudson.model.Executor.run(Executor.java:421)
      

      This error only occurs if the file to deploy is located in a folder containing many(>400000) sub folders and files. However with legacy patterns it is working.

        Attachments

          Activity

            People

            • Assignee:
              barb Bar Belity
              Reporter:
              shildwein Samuel Hildwein
            • Votes:
              2 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: