Changeset 28755
- Timestamp:
- Jul 28, 2010, 4:19:30 PM (16 years ago)
- File:
-
- 1 edited
-
trunk/ippToPsps/perl/ippToPsps_run.pl (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippToPsps/perl/ippToPsps_run.pl
r28699 r28755 15 15 use ippToPsps::IppToPspsDb; 16 16 17 18 17 # globals 19 my ($verbose, $save_temps, $no_op, $no_update, $camera, $batchType, $output, $dvodb, $datastoreProduct, $survey, $singleExpId, $force, $initBatch, $help); 20 21 # default values for certain globals 22 $verbose = undef; 23 $save_temps = undef; 24 $no_update = undef; 25 $camera = 'GPC1'; 26 $output = undef; 27 $singleExpId = undef; 28 $datastoreProduct = undef; 29 $force = undef; 30 $initBatch = 0; 18 my $camera = 'GPC1'; 19 my $batchType = undef; 20 my $survey = undef; 21 my $dvodb = undef; 22 my $verbose = undef; 23 my $save_temps = undef; 24 my $no_update = undef; 25 my $output = undef; 26 my $singleExpId = undef; 27 my $datastoreProduct = undef; 28 my $force = undef; 29 my $initBatch = undef; 30 my $dontTarNZip = undef; 31 31 32 32 # get user args … … 42 42 'no-update|u' => \$no_update, 43 43 'force|f' => \$force, 44 'tarnzip|z' => \$dontTarNZip, 44 45 ); 45 46 … … 68 69 if (!defined $force) { 69 70 print "* OPTIONAL: force if already processed : -f\n"; $force = 0;} 71 if (!defined $dontTarNZip) { 72 print "* OPTIONAL: don't tar and zip output : -z\n"; $dontTarNZip = 0;} 70 73 print "*\n*******************************************************************************\n"; 71 74 72 75 if ($quit) { exit; } 73 76 74 my $gpc1Db = new ippToPsps::Gpc1Db("gpc1", "ippdb01", "ippuser", "ippuser", $verbose );75 my $ippToPspsDb = new ippToPsps::IppToPspsDb("ippToPsps", "ippdb01", "ipp", "ipp", $verbose );77 my $gpc1Db = new ippToPsps::Gpc1Db("gpc1", "ippdb01", "ippuser", "ippuser", $verbose, $save_temps); 78 my $ippToPspsDb = new ippToPsps::IppToPspsDb("ippToPsps", "ippdb01", "ipp", "ipp", $verbose, $save_temps); 76 79 77 80 # check we can run programs and get camera config … … 81 84 82 85 if ($batchType eq "init") {$initBatch = 1;} 86 else {$initBatch = 0;} 83 87 process(); 84 88 … … 146 150 if (!$surveyType) {next;} 147 151 148 $batchId = $ippToPspsDb->getNewBatchId($expId, $surveyType );152 $batchId = $ippToPspsDb->getNewBatchId($expId, $surveyType, $batchType); 149 153 150 154 # TODO quit here if no sensible batch ID … … 167 171 if (writeBatchManifest($batchDir, $batch, $batchType, $surveyType, $filename, $minObjId, $maxObjId)) { 168 172 169 my $tarball = tarAndZipBatch($output, $batch); 170 if ($tarball && $datastoreProduct && publishToDatastore($batch, $output, $tarball)) {$published = 1;} 173 if (!$dontTarNZip) { 174 my $tarball = tarAndZipBatch($output, $batch); 175 if ($tarball && $datastoreProduct && publishToDatastore($batch, $output, $tarball)) {$published = 1;} 176 } 171 177 } 172 178
Note:
See TracChangeset
for help on using the changeset viewer.
