Should have been:

sleep time: 1, unit: 'HOURS'



On Wednesday, 15 March 2017 23:25:44 UTC, Bill Dennis wrote:
>
> Hi -
>
> You can do it with a declarative pipeline job to orchestrate running your 
> test and log collection jobs.
>
> Something like this using 'agent none' so you don't tie up executors when 
> waiting at any point:
>
> pipeline {
>     agent none
>     
>     stages {
>         stage('Build') {
>             steps {
>                 echo 'Triggering test cases..'
>                 build job: 'TestIt', wait: false
>             }
>         }
>         
>         stage('Waiting for something') {
>             steps {
>                 echo 'Waiting to collect logs'
>                 sleep time: 1, unit: 'MINUTES'
>             }
>         }
>         
>         stage('Collect Logs') {
>             steps {
>                 echo 'Collecting the logs'
>                 build 'CollectLogs'
>             }
>         }
>     }
>     
>     post {
>         success {
>             echo "All done"
>         }
>         
>         failure {
>             echo "Something failed"
>         }
>     }
> }
>
> But how will you know the 1 hour wait is enough? If you trigger the test 
> cases job but elect to wait for that job to complete, will the logs be 
> ready to collect? Like this which defaults to waiting:
>
> build 'TestIt'
>
> --Bill
>
> On Tuesday, 14 March 2017 09:20:41 UTC, Hemanth Reddy wrote:
>>
>> Hi All,
>>
>> I have a requirement some thing like, my first job will run test cases on 
>> the machine.
>>
>> I need to configure another job in such a way that after 1 hour of first 
>> job triggered, my second job should run to collect the logs.
>>
>> Regards,
>> Hemanth
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/b80654ba-75d3-4519-ab72-89f673ebad51%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to