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

Ability to decorate Pipeline builds as a global extension

      See JENKINS-30777. Does not currently work from WorkflowRun.

          [JENKINS-45693] Ability to decorate Pipeline builds as a global extension

          Jesse Glick created issue -
          Jesse Glick made changes -
          Link New: This issue depends on JENKINS-30777 [ JENKINS-30777 ]
          Jesse Glick made changes -
          Link New: This issue relates to JENKINS-38381 [ JENKINS-38381 ]

          Jesse Glick added a comment -

          Any patch now would be likely to conflict in a minor way with JENKINS-38381.

          Jesse Glick added a comment - Any patch now would be likely to conflict in a minor way with JENKINS-38381 .
          Oleg Nenashev made changes -
          Link New: This issue relates to SECURITY-739 [ SECURITY-739 ]

          Jesse Glick added a comment -

          Actually ought to be done in LogActionImpl.stream; and then under JENKINS-38381 in AnnotatedLogAction.DecoratedTaskListener. The latter could only support filters which are also Serializable (the same restriction as already exists for ConsoleLogFilter objects applied contextually), so to avoid behavioral changes this restriction should also be enforced in LogActionImpl. That means plugins registering such an extension, in order to be compatible with Pipeline, would need to ensure that it implements Serializable as well as overriding the new overload taking Run.

          Jesse Glick added a comment - Actually ought to be done in LogActionImpl.stream ; and then under JENKINS-38381 in  AnnotatedLogAction.DecoratedTaskListener . The latter could only support filters which are also Serializable (the same restriction as already exists for ConsoleLogFilter objects applied contextually ), so to avoid behavioral changes this restriction should also be enforced in LogActionImpl . That means plugins registering such an extension, in order to be compatible with Pipeline, would need to ensure that it implements Serializable as well as overriding the new overload taking Run .
          Jesse Glick made changes -
          Component/s New: workflow-support-plugin [ 21719 ]
          Component/s Original: workflow-job-plugin [ 21716 ]

          Jesse Glick added a comment -

          (Pipeline code could however print a warning to the log file when encountering a filter which fails to be serializable and/or override the correct overload.)

          Jesse Glick added a comment - (Pipeline code could however print a warning to the log file when encountering a filter which fails to be serializable and/or override the correct overload.)

          Markus Winter added a comment - - edited

          The drawback of doing it in LogActionImpl.stream is that this will not capture the complete output. What is missing is the started and finished messages from the listener and the intermediate output with the prefix. While the prefixed output is probably not that important, having the started by and the finished message when for example using the logstash plugin I would consider important. Not sure if JENKINS-38381 would solve that.

          Markus Winter added a comment - - edited The drawback of doing it in LogActionImpl.stream is that this will not capture the complete output. What is missing is the started and finished messages from the listener and the intermediate output with the prefix. While the prefixed output is probably not that important, having the started by and the finished message when for example using the logstash plugin I would consider important. Not sure if JENKINS-38381 would solve that.
          Markus Winter made changes -
          Remote Link New: This issue links to "Page (Jenkins Wiki)" [ 20408 ]

            jglick Jesse Glick
            jglick Jesse Glick
            Votes:
            8 Vote for this issue
            Watchers:
            19 Start watching this issue

              Created:
              Updated:
              Resolved: