pipeline timer not taking precedent on dependent pipelines

Follow

Comments

7 comments

  • Avatar
    Yogi Kulkarni
    The timer trigger does not implicitly mark the first stage of the pipeline to be manual. We've kept the concept of "trigger" separate from that of "approval".
    The timer trigger behaves just like a person waking up at the configured time and clicking the trigger button on the pipeline dashboard.
    So if you want to prevent upstream pipelines from triggering the Test pipeline, you would have to mark it's first stage to be manual.
    -Yogi
  • Avatar
    LeeBenhart

    Thank you, perjaps I mistated my intent.  I do not want to have to approve this stage, I want it to go automatically.  However, I only want it to go at a specified time of the day.  I do not want it to go with every success of its upstream pipeline.

  • Avatar
    Pavan K S

    Hello,


    By default, the pipeline is auto triggered along with the Timer. That means the pipeline gets triggered automatically on every checkin or upstream modification AND also gets triggered by a timer. In order to achieve what you have suggested, you need to make the pipeline a manually triggered one so that it does not automatically get triggered by changes. However, it will still be triggered by the timer.


    Hence, you would do something like:


    <pipeline..>


    <timer...>


    <stage>


    <approval type="manual"/>


    </stage>


    </pipeline>


    Does that make sense?


    Cheers,


    Pavan

  • Avatar
    SS

    Hi I have the following pipeline config... the pipeline didn't trigger at 2pm today... any guesses at to why?

    <pipeline name="mypipeline" isLocked="true">
          <params>
            <param name="active_pipeline" />
          </params>
          <timer>0 0 14 ? * MON-FRI</timer>
           <stage name="defaultStage">
            <approval type="manual" />
            <jobs>
              <job name="defaultJob">
                <tasks>
                  <rake buildfile="rakefile.rb" target="createartifacts">
                    <runif status="passed" />
                  </rake>
                </tasks>
                <resources>
                  <resource>build</resource>
                </resources>
                <artifacts>
                  <artifact src="buildOutput/Package/*.*" dest="Packages" />
                </artifacts>
              </job>
            </jobs>
          </stage>
    </pipeline>

     

    Yesterday this same pipeline (with config below) triggered at 2pm but it also triggered when someone checked-in a change in TFS:
    So to stop check-ins from triggering the pipeline I made the first stage as a manual approval (shown above) but it stopped the timer from triggering the pipeline.

     

    <pipeline name="mypipeline" isLocked="false">
          <params>
            <param name="active_pipeline" />
          </params>
          <timer>0 0 14 ? * MON-FRI</timer>
          <stage name="defaultStage">
            <jobs>
              <job name="defaultJob">
                <tasks>
                  <rake buildfile="rakefile.rb" target="createartifacts">
                    <runif status="passed" />
                  </rake>
                </tasks>
                <resources>
                  <resource>build</resource>
                </resources>
                <artifacts>
                  <artifact src="buildOutput/Package/*.*" dest="Packages" />
                </artifacts>
              </job>
            </jobs>
          </stage>
    </pipeline>

  • Avatar
    Srikanth Seshadri

    It should not be the case. Can you send us the go-server logs. 

  • Avatar
    SS

    Where can I find the logs?

  • Avatar
    SS

    The timer triggered the pipeline today as expected... not sure what happened yesterday

Please sign in to leave a comment.