IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 36042


Ignore:
Timestamp:
Aug 27, 2013, 2:34:33 PM (13 years ago)
Author:
bills
Message:

if release information is supplied use releasetool to look up the stack summaries

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/PS-IPP-PStamp/lib/PS/IPP/PStamp/Job.pm

    r36018 r36042  
    247247
    248248    if ($stage eq 'stack_summary') {
    249         # stack_summary jobs are so different from others that we lookup in a unique function
     249        # stack_summary jobs are so different from others that we lookup in a specialized function
    250250        return lookup_stack_summary($ipprc, $row, $imagedb, $tess_id, $component, $filter, $data_group, $option_mask, $mjd_min, $mjd_max, $verbose);
    251251    }
     
    746746    $row->{error_code} = $PSTAMP_NO_IMAGE_MATCH;
    747747
     748    $component = '' if $component eq 'all';
     749
    748750    my $req_type = $row->{REQ_TYPE};
    749751    my $results;
     
    753755        $results = runToolAndParse($command, $verbose);
    754756    } else {
     757        my ($release_name, $survey, $default_tess_id) = get_release_info($row);
     758        if (!$tess_id and $default_tess_id) {
     759            $tess_id = $default_tess_id;
     760        }
     761
    755762        my $skycells;
    756763        if ($req_type eq 'bycoord') {
     
    774781        }
    775782
    776 
    777783        if ($skycells) {
    778784            # We have a list of skycells. Find matching projection cells.
    779 
    780             #list of projection_cells that we've included
     785            # and then matching rows in stackSummary
     786
    781787            my %projection_cells_found;
    782788            foreach my $skycell (@$skycells) {
     
    793799                # print "$tess_id $skycell_id $projection_cell\n";
    794800
    795                 my $command = "$stacktool -dbname $imagedb -summary -tess_id $tess_id";
     801                my $command;
     802                if ($release_name or $survey) {
     803                    $command = "$releasetool -dbname $imagedb";
     804                    if ($release_name) {
     805                        $command .= " -release_name $release_name";
     806                    } else {
     807                        $command .= " -priority_order";
     808                    }
     809                    $command .= " -surveyName $survey";
     810                } else {
     811                    $command = "$stacktool -dbname $imagedb";
     812                }
     813                $command .= " -summary -tess_id $tess_id";
    796814                $command .= " -projection_cell $projection_cell";
    797815
     
    836854    return $results;
    837855}
     856
    838857sub lookup_diff {
    839858    my $ipprc    = shift;
Note: See TracChangeset for help on using the changeset viewer.