2002-08-20 23:54:17 +00:00
|
|
|
<title>Workunits</title>
|
|
|
|
<body bgcolor=ffffff>
|
|
|
|
<h2>Workunits</h2>
|
2002-04-30 22:22:54 +00:00
|
|
|
<p>
|
2002-08-20 23:54:17 +00:00
|
|
|
A <b>workunit</b> describes a computation to be performed.
|
|
|
|
Workunits are maintained in the <b>workunit</b> table in the BOINC DB.
|
2002-08-19 18:43:10 +00:00
|
|
|
The attributes of a workunit include:
|
2002-07-29 19:01:38 +00:00
|
|
|
</p>
|
2002-04-30 22:22:54 +00:00
|
|
|
<ul>
|
2002-08-19 18:43:10 +00:00
|
|
|
<li> Its name (unique across all workunits in the project).
|
2002-11-07 19:31:34 +00:00
|
|
|
<li> Its application.
|
2002-08-19 18:43:10 +00:00
|
|
|
<li> An XML document describing its input files and other parameters
|
2002-05-17 22:33:57 +00:00
|
|
|
(see below).
|
2002-08-19 18:43:10 +00:00
|
|
|
<li> The estimated resource requirements of the work unit
|
2002-11-07 19:31:34 +00:00
|
|
|
(computation, memory, disk space).
|
2002-12-05 19:13:06 +00:00
|
|
|
<li> The maximum processing
|
|
|
|
(measured in <a href=credit.html>Cobblestones</a>)
|
|
|
|
and maximum disk space to be used for the computation.
|
|
|
|
An instance of the computation that exceeds either of these bounds
|
|
|
|
will be aborted.
|
|
|
|
This mechanism is used to prevent an infinite-loop bug from
|
|
|
|
indefinitely incapacitating a host.
|
|
|
|
<li> A <b>delay bound</b>: upper bound on how long (in real time)
|
2002-11-29 20:13:44 +00:00
|
|
|
a result associated with this work unit should take to complete.
|
|
|
|
This determines which hosts the workunit can be sent to,
|
2002-11-07 19:31:34 +00:00
|
|
|
and it's used to assign result deadlines and
|
|
|
|
times for retrying results.
|
2002-05-17 22:33:57 +00:00
|
|
|
</ul>
|
|
|
|
<p>
|
2002-12-05 19:13:06 +00:00
|
|
|
Some parameters of a workunit are described by an XML document of the form
|
2002-05-17 22:33:57 +00:00
|
|
|
<pre>
|
2002-11-29 20:13:44 +00:00
|
|
|
[ <file_info>...</file_info> ]
|
2002-05-17 22:33:57 +00:00
|
|
|
[ ... ]
|
2002-11-29 20:13:44 +00:00
|
|
|
<workunit>
|
|
|
|
[ <command_line>-flags xyz</command_line> ]
|
|
|
|
[ <env_vars>name=val&name=val</env_vars> ]
|
2002-12-05 19:13:06 +00:00
|
|
|
[ <max_processing>...</max_processing> ]
|
|
|
|
[ <max_disk>...</max_disk> ]
|
2002-11-29 20:13:44 +00:00
|
|
|
[ <file_ref>...</file_ref> ]
|
2002-05-17 22:33:57 +00:00
|
|
|
[ ... ]
|
2002-11-29 20:13:44 +00:00
|
|
|
</workunit>
|
2002-08-19 18:43:10 +00:00
|
|
|
</pre>
|
|
|
|
The components are:
|
2002-12-05 19:13:06 +00:00
|
|
|
<table border=1 cellpadding=6>
|
|
|
|
<tr><td><command_line></td>
|
|
|
|
<td>The command-line arguments to be passed to the main program.
|
|
|
|
</td></tr>
|
|
|
|
<tr><td><env_vars></td>
|
|
|
|
<td>A list of environment variables in the form
|
|
|
|
name=value&name=value&name=value.
|
|
|
|
</td></tr>
|
|
|
|
<tr><td><max_processing></td>
|
|
|
|
<td>Maximum processing (in Cobblestones).
|
|
|
|
The default is determined by the client; typically it is 1.
|
|
|
|
</td></tr>
|
|
|
|
<tr><td><max_disk></td>
|
|
|
|
<td>Maximum disk usage (in bytes).
|
|
|
|
The default is determined by the client; typically it is 1,000,000.
|
|
|
|
</td></tr>
|
|
|
|
<tr><td><file_ref></td>
|
|
|
|
<td> describes a <a
|
2002-07-29 19:01:38 +00:00
|
|
|
href="files.html">reference</a> to an input file, each of which is
|
2002-11-29 20:13:44 +00:00
|
|
|
described by a <b><file_info></b> element.
|
2002-12-05 19:13:06 +00:00
|
|
|
</td></tr></table>
|
2002-04-30 22:22:54 +00:00
|
|
|
<p>
|
2002-08-19 18:43:10 +00:00
|
|
|
A workunit is associated with an application, not with a particular
|
2002-11-07 19:31:34 +00:00
|
|
|
version or range of versions.
|
2002-08-19 18:43:10 +00:00
|
|
|
If the format of your input data changes in
|
2002-08-20 23:54:17 +00:00
|
|
|
a way that is incompatible with older versions,
|
|
|
|
you must create a new application.
|
2002-08-19 18:43:10 +00:00
|
|
|
This can often be avoided by using XML data format.
|
2002-04-30 22:22:54 +00:00
|
|
|
<p>
|
2002-08-21 23:49:33 +00:00
|
|
|
The <a href="tools_work.html">create_work</a> utility program provides a
|
2002-07-29 19:01:38 +00:00
|
|
|
simplified interface for creating workunits.
|