Changes between Version 18 and Version 19 of RemoteJobs


Ignore:
Timestamp:
Jul 26, 2011, 9:23:19 AM (13 years ago)
Author:
davea
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • RemoteJobs

    v18 v19  
    11[[PageOutline]]
    2 = APIs for remote job submission =
    3 
    4 This document describes APIs for remotely submitting jobs to a BOINC server.
     2= API for remote job submission =
     3
     4This document describes an API for remotely submitting jobs to a BOINC server.
    55The APIs support the submission of large '''batches''' of jobs,
    66such as parameter sweeps.
    7 The APIs can be used, for example, to create web interfaces for job submission,
     7The API can be used, for example, to create web interfaces for job submission,
    88such as might be found in a science portal web site:
    99
     
    1414 * All jobs in a batch must use the same application.
    1515 * There can be no dependencies between jobs.
    16 
    17 These restrictions may be removed in the future.
    1816
    1917BOINC provides a PHP library that implements the API.
     
    3028== PHP interface ==
    3129
    32 The following functions are provided in the file
     30The following functions are provided in the PHP file
    3331[/trac/browser/trunk/boinc/html/inc/submit.inc submit.inc],
    3432which is independent of other BOINC code and can be used in the Portal web code.
     
    3634=== boinc_estimate_batch() ===
    3735
    38 This function returns an estimate of the elapsed time
    39 required to complete a given batch.
     36Returns an estimate of the elapsed time required to complete a batch.
    4037
    4138Arguments: a "request object" whose fields include
     
    4643
    4744Return value: a 2-element array containing
    48  * The estimate, in seconds
     45 * The elapsed time estimate, in seconds
    4946 * An error message (null if success)
    5047
     
    6158
    6259for ($i=10; $i<20; $i++) {
    63         $job->rsc_fpops_est = $i*1e9;
    64         $job->command_line = "--t $i";
    65         $req->jobs[] = $job;
     60    $job->rsc_fpops_est = $i*1e9;
     61    $job->command_line = "--t $i";
     62    $req->jobs[] = $job;
    6663}
    6764
    6865list($e, $errmsg) = boinc_estimate_batch($req);
    6966if ($errmsg) {
    70         echo "Error: $errmsg\n";
     67    echo "Error: $errmsg\n";
    7168} else {
    72         echo "The batch will take about $e seconds to complete\n";
     69    echo "The batch will take about $e seconds to complete\n";
    7370}
    7471}}}