diff --git a/checkin_notes b/checkin_notes index 8524c58a40..6656659d0b 100755 --- a/checkin_notes +++ b/checkin_notes @@ -4961,3 +4961,15 @@ David 23 May 2006 client/ client_state.C + +Bruce 23 May 2006 + - Make backend more robust, to prevent 'stuck' workunits. Now + transitioner will not sent the transition_time to INT_MAX + UNLESS a canonical result has been found. Otherwise it is + set to MAX(ten days, 1.5*delay_bound) in the future. This + ensures that the transition will 'see' the workunit again + if no canonical result has been found. + + sched/ + transitioner.C + diff --git a/sched/transitioner.C b/sched/transitioner.C index 40cfd815d4..18d1b91a58 100644 --- a/sched/transitioner.C +++ b/sched/transitioner.C @@ -475,7 +475,18 @@ int handle_wu( // compute next transition time = minimum timeout of in-progress results // - wu_item.transition_time = INT_MAX; + if (wu_item.canonical_resultid) { + wu_item.transition_time = INT_MAX; + } else { + // If there is no canonical result, make sure that the transitioner will 'see' + // this WU again. In principle this is NOT needed, but it is one way to make + // the BOINC back-end more robust. + // + const int ten_days = 10*86400; + int long_delay = 1.5*wu_item.delay_bound; + wu_item.transition_time = (long_delay > ten_days) ? long_delay : ten_days; + wu_item.transition_time += time(0); + } for (i=0; i