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

Influx build_result is not set correct if written in post section

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Major Major
    • influxdb-plugin
    • None

      I never get a 'SUCCESS' in the `build_result` field if data is reported to Influx in a pipeline `post` section.
      I would expect that at this time, the outcome is of the pipeline run is set.

      pipeline{
        stages {
          stage('A') {
            steps {
              echo "build result: ${currentBuild.result}"
              echo "current build result: ${currentBuild.currentResult}"
            }
          }
        }
        post{
          always{
            script {
              node {
                step([$class: 'InfluxDbPublisher', selectedTarget: 'myInflux'])
              }
            }
          }
        }
      }
      

            aleksisimell Aleksi Simell
            ennef Christopher Fenner
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: