Changes between Version 2 and Version 3 of RemoteOverview


Ignore:
Timestamp:
Feb 15, 2013, 2:18:10 PM (12 years ago)
Author:
davea
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • RemoteOverview

    v2 v3  
     1[[PageOutline]]
    12= Remote job submission - overview =
    23
    34In early versions of BOINC, scientists submitted jobs to
    45a BOINC server by logging in to the server and running programs or scripts.
    5 More recently, BOINC has been used to build systems in which scientists can submit
    6 jobs without logging in to the BOINC server.
    7 These systems can be structured in various ways
    8 (several examples are shown below);
    9 we collectively call them '''remote job submission''' systems.
     6More recently, BOINC has been used to build systems,
     7collectively called '''remote job submission''' systems,
     8in which scientists can submit jobs without logging in to the BOINC server.
    109
    1110In all these systems, job submitters are identified using accounts on the BOINC project
     
    1615Users have '''quotas''' how resources are allocated to their jobs.
    1716
     17The structure and details of remote job submission systems
     18vary widely.
     19BOINC doesn't include a pre-packaged remote job submission system,
     20but it provides a number of components that can be used to build such systems.
     21We'll list some example systems, then describe the components.
     22
    1823== Example: single-server portal ==
     24
     25Users submit jobs using forms on the project web site:
    1926
    2027[[Image(submit2.png)]]
    2128
    22 Users submit jobs using forms on the project web site.
    2329These forms are application-specific; you must develop them yourself.
    2430Two examples are included in the BOINC distribution:
     
    2935provide a minimal/generic example.
    3036
    31 The job-submission scripts use [foo local PHP interfaces] to
     37The job-submission scripts use [RemoteOverview#LocalPHPinterfaces local PHP interfaces] to
    3238authenticate users and to create jobs and batches.
    3339
     
    6773== Components supplied by BOINC ==
    6874
    69 BOINC doesn't include a pre-packaged remote job submission system,
    70 but it provides a number of components that can be used to build such systems.
    71 
    7275=== Job submission control panel ===
    7376
     
    8992=== Local PHP interfaces ===
    9093
     94Job-submission scripts to be run on the BOINC server
     95are best implemented in PHP.
     96BOINC provides a large set of PHP APIs for accessing the BOINC database,
     97staging files, and so on.
     98
     99For example, you can authorize a job submission request with code like
     100{{{
     101$user = get_logged_in_user();
     102$user_submit = BoincUserSubmit::lookup_userid($user->id);
     103if (!$user_submit) error_page("no submit access");
     104$app = BoincApp::lookup("name='lammps'");
     105if (!$app) error_page("no lammps app");
     106if (!$user_submit->submit_all) {
     107    $usa = BoincUserSubmitApp::lookup("user_id=$user->id and app_id=$app->id");
     108    if (!$usa) {
     109        error_page("no submit access");
     110    }
     111}
     112}}}
     113
     114You can create a batch as follows:
     115{{{
     116$batch_id = BoincBatch::insert(
     117    "(user_id, create_time, njobs, name, app_id, state)
     118    values ($user->id, $now, $njobs, '$batch_name', $app->id, ".BATCH_STATE_IN_PROGRESS.")"
     119);
     120}}}
     121
     122'''TODO: document these interfaces, or provide simpler examples.'''
     123
    91124=== Web RPCs for input file management ===
    92125
     126BOINC provides [RemoteInputFiles#Content-basedfilemanagement Web RPCs for remotely managing input files],
     127and a C++ binding of this API.
     128
    93129=== Web RPCs for job submission ===
     130
     131BOINC provides [RemoteJobs Web RPCs for creating and managing jobs].
     132
     133=== Per-user file sandbox ===
     134
     135BOINC provides [RemoteInputFiles#Per-userfilesandbox a web-based system allowing users to remotely manage input files].