- Timestamp:
- Aug 20, 2009, 12:42:13 PM (17 years ago)
- Location:
- branches/czw_branch/cleanup
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
pstamp/scripts/pstamp_finish.pl (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/czw_branch/cleanup
- Property svn:mergeinfo changed
/trunk merged: 25052-25060,25063-25068,25070-25084,25087,25156
- Property svn:mergeinfo changed
-
branches/czw_branch/cleanup/pstamp/scripts/pstamp_finish.pl
r25143 r25158 94 94 if (!mkdir $out_dir) { 95 95 print STDERR "cannot create output directory $out_dir"; 96 stop_request _and_exit($req_id, $PS_EXIT_UNKNOWN_ERROR);96 stop_request($req_id, $PS_EXIT_UNKNOWN_ERROR); 97 97 } 98 98 … … 102 102 # request 103 103 print STDERR "output directory $out_dir exists but is not a directory"; 104 stop_request _and_exit($req_id, $PS_EXIT_UNKNOWN_ERROR);104 stop_request($req_id, $PS_EXIT_UNKNOWN_ERROR); 105 105 } 106 106 107 107 if (! -e $req_file ) { 108 108 print STDERR "request file $req_file is missing\n"; 109 stop_request _and_exit($req_id, $PS_EXIT_CONFIG_ERROR);109 stop_request($req_id, $PS_EXIT_CONFIG_ERROR); 110 110 } 111 111 … … 117 117 # point 118 118 print STDERR "failed to read request_file $req_file" ; 119 stop_request _and_exit($req_id, $PS_EXIT_CONFIG_ERROR);119 stop_request($req_id, $PS_EXIT_CONFIG_ERROR); 120 120 } 121 121 … … 154 154 print STDERR "Request $req_id produced no jobs.\n" 155 155 } 156 # This should not happen. A fake job should be queued 157 stop_request_and_exit($req_id, $PS_EXIT_PROG_ERROR); 156 # No Jobs. 157 # XXXX Ouch. We need results for each rownum (each request specification) in the request file 158 # including those that produced no jobs. 159 # for now add an entry for rownum 1 and a phony error code. 160 # we've included parse_error.txt to the fileset if it exists 161 # 162 my $rownum = 0; 163 my $fault = 42; # get a real error code 164 print $tdf "$rownum|$fault|0|0|"; 165 print $tdf "0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|\n"; 158 166 } else { 159 167 my $metadata = $mdcParser->parse($output) or die("Unable to parse metdata config doc"); … … 174 182 my $exp_id = $job->{exp_id}; 175 183 176 if ($fault eq $PSTAMP_DUP_REQUEST) {177 # this request had a duplicate request name. We can't put the results178 # on the data store since the product name is already used179 # maybe we could be more clever about this and choose a fileset name180 stop_request_and_exit($req_id, $fault);181 }182 183 184 my ($row, $req_info, $project) = get_request_info($rows, $rownum); 184 185 … … 188 189 carp("failed to find imagedb for project: $project"); 189 190 if (!$fault) { 190 stop_request _and_exit($req_id, $PS_EXIT_CONFIG_ERROR);191 stop_request($req_id, $PS_EXIT_CONFIG_ERROR); 191 192 } 192 193 } … … 279 280 } 280 281 281 sub stop_request _and_exit{282 sub stop_request { 282 283 my $req_id = shift; 283 284 my $fault = shift;
Note:
See TracChangeset
for help on using the changeset viewer.
