Page MenuHomePhabricator

Jenkins Job Builder generates obsolete XML for the BuildTimeout plugin
Open, Needs TriagePublic

Description

Found that on https://gerrit.wikimedia.org/r/#/c/operations/debs/trafficserver/+/447074/ . The debian-glue job pass a ${BUILD_TIMEOUT} variable to the Jenkins build timeout plugin (from T143546 ). The variable was not honored and the job failed after the 3 minutes default timeout.

I regenerated the job with JJB which produces:

<buildWrappers>
  <hudson.plugins.build__timeout.BuildTimeoutWrapper>
    <timeoutMinutes>${BUILD_TIMEOUT}</timeoutMinutes>
    <failBuild>true</failBuild>
    <writingDescription>false</writingDescription>
    <timeoutPercentage>0</timeoutPercentage>
    <timeoutMinutesElasticDefault>3</timeoutMinutesElasticDefault>
    <timeoutType>absolute</timeoutType>
  </hudson.plugins.build__timeout.BuildTimeoutWrapper>

Then saving the job, the plugin normalized the config to:

<buildWrappers>
  <hudson.plugins.build__timeout.BuildTimeoutWrapper plugin="build-timeout@1.19">
    <strategy class="hudson.plugins.build_timeout.impl.AbsoluteTimeOutStrategy">
      <timeoutMinutes>${BUILD_TIMEOUT}</timeoutMinutes>
    </strategy>
    <operationList>
      <hudson.plugins.build__timeout.operations.FailOperation/>
    </operationList>
  </hudson.plugins.build__timeout.BuildTimeoutWrapper>

Potential fixes: https://review.openstack.org/#/q/project:openstack-infra/jenkins-job-builder+message:Timeout

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJul 23 2018, 10:56 AM