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

Add setter for currentBuild.duration

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Minor Minor
    • core
    • None

      Please add setter for duration property of Run,

      so that user can override this in case of custom pipelines, parallel stages, etc.

       


      In Run.java, something like:

      /**
       * Sets the {@link #getDuration} of this build.
       * @param d the proposed new duration
       */
       
      public void setDuration(Long d) {

          duration = d;
          LOGGER.log(FINE, this + " in " + getRootDir() + ": Run duration is set to " + d, LOGGER.isLoggable(Level.FINER) ? new Exception() : null);
          }
      }

            Unassigned Unassigned
            dni300 David Nikoloski
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: