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

Pipeline parallel map not supporting curried closures

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Component/s: workflow-cps-plugin
    • Labels:
      None
    • Similar Issues:

      Description

      When executing a curried closure in parallel the output appears to be cached (see the output for the spam branch below).

      Example pipeline:

      def example_c = { input -> node { echo "$input" } }
      def map = [:]
      map['spam'] = example_c.curry('spam')
      map['eggs'] = example_c.curry('eggs')
      parallel map
      

      Output:

      [Pipeline] parallel
      [Pipeline] [spam] { (Branch: spam)
      [Pipeline] [eggs] { (Branch: eggs)
      [Pipeline] [spam] node
      [spam] Running on java8-jenkins-ec2-slave (i-a541b5be) 
      [Pipeline] [eggs] node
      [Pipeline] [spam] {
      [eggs] Running on java8-jenkins-ec2-slave (i-a541b5be) 
      [Pipeline] [spam] echo
      [spam] eggs
      [Pipeline] }
      [Pipeline] [eggs] {
      [Pipeline] // node
      [Pipeline] }
      [Pipeline] [eggs] echo
      [eggs] eggs
      [Pipeline] }
      [Pipeline] // node
      [Pipeline] }
      [Pipeline] // parallel
      [Pipeline] End of Pipeline
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                abayer Andrew Bayer
                Reporter:
                fortuna Ben Fortuna
              • Votes:
                6 Vote for this issue
                Watchers:
                9 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: