mirror of https://github.com/BOINC/boinc.git
76 lines
2.6 KiB
HTML
76 lines
2.6 KiB
HTML
<body bgcolor=ffffff>
|
|
<h2>Compute model: workunits and results</h2>
|
|
|
|
<p>
|
|
A <b>workunit</b> describes a computation to be performed.
|
|
The attributes of a workunit include:
|
|
<ul>
|
|
<li> The application it's associated with.
|
|
<li> Its name (unique across all workunits in the project).
|
|
<li> A list of its input files.
|
|
Each has an <b>input file association</b>
|
|
that specifies the filename or file descriptor number
|
|
by which the application will refer to the file.
|
|
<li> The command-line arguments to be passed to the application.
|
|
<li> The environment variables to be set for the application.
|
|
<li> The estimated resource requirements of the work unit
|
|
(computation, memory, disk space, network traffic).
|
|
</ul>
|
|
|
|
<p>
|
|
A workunit is associated with an application,
|
|
not with a particular version or set of versions.
|
|
If the format of your input data changes in a way that
|
|
is incompatible with older versions,
|
|
you must create a new application.
|
|
This can often be avoided by using XML-like data representations.
|
|
<p>
|
|
|
|
A <b>result</b> describes a particular instance of a computation,
|
|
either to be performed or already performed.
|
|
The attributes of a result include:
|
|
<ul>
|
|
<li> The workunit it's associated with.
|
|
<li> Its name (unique across all results in the project).
|
|
<li> A list of its output files.
|
|
Each has an <b>output file association</b>
|
|
that specifies the filename or file descriptor number
|
|
by which the application will refer to the file.
|
|
<li> Its <b>state</b>. Values include:
|
|
<ul>
|
|
<li> Inactive (not ready to dispatch)
|
|
<li> Unsent (ready to dispatch, but not dispatched)
|
|
<li> In progress (dispatched, not done)
|
|
<li> Done successfully
|
|
<li> Timed out
|
|
<li> Done with error
|
|
</ul>
|
|
</ul>
|
|
<p>
|
|
Several results may be associated with a single workunit.
|
|
Results may be generated in either of two ways
|
|
(selected as part of the application):
|
|
<ul>
|
|
<li> <b>Advance generation</b> of results.
|
|
One or more result records are stored in the database
|
|
when the workunit is produced.
|
|
The scheduling server dispatches each result to a single participant host.
|
|
When all result records have been dispatched,
|
|
participants hosts are "turned away".
|
|
<li> <b>On-demand generation</b> of results.
|
|
The application specifies a "result template",
|
|
which has place-holder tokens for the output filenames.
|
|
The scheduling server, in response to a host request,
|
|
generates a new result record and sends the result template.
|
|
The host generates unique output filenames,
|
|
and returns them along when it the computation is done.
|
|
</ul>
|
|
<p>
|
|
|
|
<hr>
|
|
The following diagram illustrates the relationship between
|
|
workunits, results, files, and I/O assocations.
|
|
<p>
|
|
|
|
<img src=work.gif>
|