Changeset 27838 for branches/tap_branches/ippTasks/diff.pro
- Timestamp:
- May 3, 2010, 8:41:49 AM (16 years ago)
- Location:
- branches/tap_branches
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
ippTasks/diff.pro (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/tap_branches
- Property svn:mergeinfo changed
-
branches/tap_branches/ippTasks/diff.pro
r25570 r27838 15 15 $diffSkycell_DB = 0 16 16 $diffAdvance_DB = 0 17 $diff_revert_DB = 0 17 18 #$diffCleanup_DB = 0 18 19 … … 40 41 active true 41 42 end 43 task diff.revert 44 active false 45 end 42 46 end 43 47 … … 53 57 active false 54 58 end 59 task diff.revert 60 active false 61 end 62 end 63 64 macro diff.revert.on 65 task diff.revert 66 active true 67 end 68 end 69 70 macro diff.revert.off 71 task diff.revert 72 active false 73 end 55 74 end 56 75 … … 76 95 ### Load tasks for doing the differences 77 96 ### Tasks are loaded into diffSkyfile. 97 98 78 99 task diff.skycell.load 79 100 host local … … 139 160 140 161 task.exec 162 # if we are unable to run the 'exec', use a long retry time 163 periods -exec $RUNEXEC 164 141 165 book npages diffSkyfile -var N 142 166 if ($N == 0) break 143 167 if ($NETWORK == 0) break 144 168 if ($BURNTOOLING == 1) break 169 145 170 # look for new images in diffSkyfile (pantaskState == INIT) 146 171 book getpage diffSkyfile 0 -var pageName -key pantaskState INIT … … 155 180 book getword diffSkyfile $pageName bothways -var BOTHWAYS 156 181 book getword diffSkyfile $pageName workdir -var WORKDIR_TEMPLATE 182 book getword diffSkyfile $pageName state -var RUN_STATE 157 183 book getword diffSkyfile $pageName dbname -var DBNAME 184 book getword diffSkyfile $pageName reduction -var REDUCTION 185 book getword diffSkyfile $pageName diff_mode -var DIFF_MODE 158 186 159 187 # set the host and workdir based on the skycell hash … … 165 193 # $WORKDIR = $WORKDIR_TEMPLATE 166 194 195 if (($DIFF_MODE == 1)||("$DIFF_MODE" == "NULL")) 196 $DIFF_TAG = "" 197 end 198 if ($DIFF_MODE == 2) 199 $DIFF_TAG = "WS." 200 end 201 if ($DIFF_MODE == 3) 202 $DIFF_TAG = "SW." 203 end 204 if ($DIFF_MODE == 4) 205 $DIFF_TAG = "SS." 206 end 207 167 208 basename $TESS_DIR -var TESS_ID 168 sprintf outroot "%s/%s/%s/%s.%s. dif.%s" $WORKDIR $TESS_ID $SKYCELL_ID $TESS_ID $SKYCELL_ID$DIFF_ID209 sprintf outroot "%s/%s/%s/%s.%s.%sdif.%s" $WORKDIR $TESS_ID $SKYCELL_ID $TESS_ID $SKYCELL_ID $DIFF_TAG $DIFF_ID 169 210 170 211 stdout $LOGDIR/diff.skycell.log 171 212 stderr $LOGDIR/diff.skycell.log 172 213 173 $run = diff_skycell.pl --threads @MAX_THREADS@ --diff_id $DIFF_ID --skycell_id $SKYCELL_ID --diff_skyfile_id $DIFF_SKYFILE_ID --outroot $outroot --redirect-output 214 $run = diff_skycell.pl --threads @MAX_THREADS@ --diff_id $DIFF_ID --skycell_id $SKYCELL_ID --diff_skyfile_id $DIFF_SKYFILE_ID --outroot $outroot --redirect-output --run-state $RUN_STATE 174 215 if ("$BOTHWAYS" == "T") 175 216 $run = $run --inverse 217 end 218 if ("$REDUCTION" != "NULL") 219 $run = $run --reduction $REDUCTION 176 220 end 177 221 add_standard_args run … … 184 228 echo command $run 185 229 end 230 periods -exec 0.05 186 231 command $run 187 232 end … … 375 420 # end 376 421 # end 422 423 task diff.revert 424 host local 425 426 periods -poll 60.0 427 periods -exec 1800.0 428 periods -timeout 120.0 429 npending 1 430 active false 431 432 stdout NULL 433 stderr $LOGDIR/revert.log 434 435 task.exec 436 if ($LABEL:n == 0) break 437 # Only revert failures with fault=2 (SYS_ERROR), which tend to be 438 # temporary filesystem problems. Every other fault type is 439 # interesting and should be kept for debugging (and so it doesn't 440 # continue to occur). 441 $run = difftool -revertdiffskyfile -fault 2 442 if ($DB:n == 0) 443 option DEFAULT 444 else 445 # save the DB name for the exit tasks 446 option $DB:$diff_revert_DB 447 $run = $run -dbname $DB:$diff_revert_DB 448 $diff_revert_DB ++ 449 if ($diff_revert_DB >= $DB:n) set diff_revert_DB = 0 450 end 451 add_poll_labels run 452 command $run 453 end 454 455 # success 456 task.exit 0 457 end 458 459 # locked list 460 task.exit default 461 showcommand failure 462 end 463 464 task.exit crash 465 showcommand crash 466 end 467 468 # operation times out? 469 task.exit timeout 470 showcommand timeout 471 end 472 end
Note:
See TracChangeset
for help on using the changeset viewer.
