Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-50130

Artifacts are not archived when the build fails using parallel executions.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • workflow-cps-plugin
    • None
    • Jenkins 2.89.4

      I am calling these functions

      zip(zipFile: "it-surefire-its-${stageKey}.zip", dir: 'surefire-its/target', archive: true)

      archiveArtifacts(artifacts: '*.zip', allowEmptyArchive: true, onlyIfSuccessful: false)

      When the build fails, the artifacts are not available for downloads.

      If is succeeds, they are available.

      This is the script https://github.com/apache/maven-surefire/blob/master/Jenkinsfile

      And you can try out this job for instance:

      https://builds.apache.org/job/maven-wip/job/maven-surefire/job/SUREFIRE-1495/

      I use function parallel() as well. Could it be the case?

      If I use similar script in my company without parallel(), the artifacts can be always downloaded.

            Unassigned Unassigned
            tibor17 Tibor Digana
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: