| 1 |
[meta] |
| 2 |
title = "Try out scenarios for intelligent host selection." |
| 3 |
description = """ |
| 4 |
Runs two long running tasks on a known good platform and on a |
| 5 |
platform with some unreachable hosts. |
| 6 |
|
| 7 |
Once each has started trigger a task which kills each to test the |
| 8 |
execution polling. |
| 9 |
""" |
| 10 |
|
| 11 |
[scheduling] |
| 12 |
cycling mode = integer |
| 13 |
initial cycle point = 1 |
| 14 |
[[graph]] |
| 15 |
R1 = """ |
| 16 |
goodhosttask:start => stop_g |
| 17 |
mixedhosttask:start => stop_m |
| 18 |
goodhosttask:fail & mixedhosttask:fail |
| 19 |
""" |
| 20 |
|
| 21 |
[runtime] |
| 22 |
[[goodhosttask]] |
| 23 |
# Sleep for a long time, expect to be killed by stop_g |
| 24 |
script=sleep 120 & echo $! >file; wait |
| 25 |
platform = goodhostplatform |
| 26 |
|
| 27 |
[[mixedhosttask]] |
| 28 |
# Sleep for a long time, expect to be killed by stop_m |
| 29 |
script=sleep 120 & echo $! >file; wait |
| 30 |
platform = mixedhostplatform |
| 31 |
|
| 32 |
[[stop_g]] |
| 33 |
# Kill goodhosttask when polling confirms it's started. |
| 34 |
script=""" |
| 35 |
sleep 5 # Give the badhosts list time to empty |
| 36 |
cylc kill "$CYLC_WORKFLOW_ID//1/goodhosttask" || true |
| 37 |
""" |
| 38 |
|
| 39 |
[[stop_m]] |
| 40 |
# Kill mixedhosttask when polling confirms it's started. |
| 41 |
script=""" |
| 42 |
sleep 5 # Give the badhosts list time to empty |
| 43 |
cylc kill "$CYLC_WORKFLOW_ID//1/mixedhosttask" || true |
| 44 |
""" |