IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 18247 for trunk/pstamp/src


Ignore:
Timestamp:
Jun 20, 2008, 3:08:02 PM (18 years ago)
Author:
bills
Message:

more tweaks.

Location:
trunk/pstamp/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/pstamp/src/pstampfinish.c

    r18243 r18247  
    2626    psString    dsRoot;
    2727    psString    dsProduct;
     28    psString    dbName;
    2829    int         exitStatus;
    2930} psrfOptions;
     
    7071        return NULL;
    7172    }
     73    psBool status;
     74    options->dbName = psMetadataLookupStr(&status, options->config->complete, "DBNAME");
    7275
    7376    if ((argnum = psArgumentGet(argc, argv, "-mode"))) {
     
    265268    psString command = NULL;
    266269
    267     psStringAppend(&command, "dsreg --add --type PSRESULTS --product %s --fileset %s",
    268             options->dsProduct, fileset_id);
    269 
    270     printf("command is: %s\n", command);
     270    psStringAppend(&command, "dsreg --dbname %s --add --type PSRESULTS --product %s --fileset %s",
     271            options->dbName, options->dsProduct, fileset_id);
     272
     273    if (options->verbose) {
     274        fprintf(stderr, "command is: %s\n", command);
     275    }
    271276
    272277    // open a pipe to dsreg and set up the output fileset
  • trunk/pstamp/src/pstampparse.c

    r18243 r18247  
    6464    }
    6565
     66    // XXX: need to sort out the interactions of this mode option and the JOB_TYPE
     67    // listed in the request file.
    6668    if ((argnum = psArgumentGet(argc, argv, "-mode"))) {
    6769        psArgumentRemove(argnum, &argc, argv);
     
    629631        psStringAppend(&cmd, " -args '%s'", commandArgs);
    630632    }
     633    // XXX We may want to have the data store name be different than the default DB
     634    psBool status;
     635    psString dbName = psMetadataLookupStr(&status, options->config->complete, "DBNAME");
     636    fprintf(stderr, "\n\n   dbName is %s\n", dbName);
     637    if (dbName) {
     638        psStringAppend(&cmd, " -dbname %s", dbName);
     639    }
     640
    631641    psStringAppend(&cmd, " > /dev/null");
    632642
Note: See TracChangeset for help on using the changeset viewer.