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

Conditions are evaluated for each actions

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • None
    • flexible-publish-0.14.1

      Following case:

      Flexible Publish
          Conditional Action
              Run?: String match
                  String1: ${Test1}
                  String2: expected
              Action
                  some action 1
                  some action 2
      

      In this case, string matching is evaluated each for some action 1 and some action 2.
      The condition should be evaluated only one for the configuration as:

      • It can be a problem if there is a condition with side-effects.
      • Users can expect the condition will be evaluated only once as they configured that only once in the configuration page.
      • Users can configure like this if they really want the condition evaluated for each time:
        Flexible Publish
            Conditional Action
                Run?: String match
                    String1: ${Test1}
                    String2: expected
                Action
                    some action 1
            Conditional Action
                Run?: String match
                    String1: ${Test1}
                    String2: expected
                Action
                    some action 2
        

            ikedam ikedam
            ikedam ikedam
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: