Debian Codegraph @

gavo/resources/inputs/__system__/uws.rd

raw
1 <resource schema="uws" resdir="__system">
2 <meta name="creationDate">2009-12-04T09:00:00</meta>
3 <meta name="subject">virtual-observatories</meta>
4 <meta name="description">Helpers for the support of
5 universal worker services.</meta>
6 <!-- the uwsfields STREAM contains what's necessary for
7 protocols.uws.BaseUWSJob; in particular, don't mess with the table
8 attributes given at the top. -->
9
10 <STREAM id="uwsfields">
11 <onDisk>True</onDisk>
12 <primary>jobId</primary>
13 <allProfiles>feed,trustedquery</allProfiles>
14 <dupePolicy>overwrite</dupePolicy>
15 <!-- the entire UWS shares a single directory for the job directories. -->
16 <column name="jobId" type="text"
17 description="Internal id of the job. At the same time,
18 uwsDir-relative name of the job directory."/>
19 <column name="phase" type="text"
20 description="The state of the job.">
21 <values>
22 <option>PENDING</option>
23 <option>QUEUED</option>
24 <option>EXECUTING</option>
25 <option>COMPLETED</option>
26 <option>ERROR</option>
27 <option>ABORTED</option>
28 <option>UNKNOWN</option>
29 </values>
30 </column>
31 <column name="executionDuration" type="integer"
32 unit="s"
33 description="Job time limit">
34 <values nullLiteral="-1"/>
35 </column>
36 <column name="destructionTime" type="timestamp"
37 description="Time at which the job, including ancillary
38 data, will be deleted"/>
39 <column name="owner" type="text"
40 description="Submitter of the job, if verified"/>
41 <column name="parameters" type="text"
42 description="Pickled representation of the parameters (except uploads)"/>
43 <column name="runId" type="text"
44 description="User-chosen run Id"/>
45 <column name="startTime" type="timestamp"
46 description="UTC job execution started"/>
47 <column name="endTime" type="timestamp"
48 description="UTC job execution finished"/>
49 <column name="error" type="text"
50 description="some suitable representation an error that has
51 occurred while executing the job (null means no error information
52 has been logged)"/>
53 <column name="creationTime" type="timestamp"
54 description="UTC job was created"/>
55 </STREAM>
56
57 <!-- have an empty data so gavo imp does not complain -->
58 <data id="empty"/>
59
60 <data id="upgrade_0.6.3_0.7" auto="false">
61 <!-- remove old uws tables; this needs a special script because
62 the drop functionality was broken for system tables before 0.7 -->
63 <sources items="0"/>
64 <nullGrammar/>
65 <make>
66 <table onDisk="True" temporary="True" id="tmp"/>
67 <script lang="AC_SQL" name="drop old UWS tables" type="newSource">
68 drop table uws.jobs;
69 drop table uws.uwsresults;
70 delete from dc.tablemeta where tablename='uws.jobs';
71 delete from dc.tablemeta where tablename='uws.uwsresults';
72 delete from dc.columnmeta where tablename='uws.jobs';
73 delete from dc.columnmeta where tablename='uws.uwsresults';
74 </script>
75 </make>
76 </data>
77
78
79 <table id="userjobs" onDisk="True" system="True">
80 <meta name="description">The jobs table for user-defined UWS
81 jobs. As the jobs can come from all kinds of services, this
82 must encode the jobClass (as the id of the originating service).
83 </meta>
84
85 <FEED source="uwsfields"/>
86 <column name="pid" type="integer"
87 description="A unix pid to kill to make the job stop">
88 <values nullLiteral="-1"/>
89 </column>
90 <column name="jobClass" type="text"
91 description="Key for the job class to use here. This is,
92 as an implementation detail, simply the cross-id of the service
93 processing this."/>
94 </table>
95
96 <data id="enable_useruws" auto="False">
97 <make table="userjobs"/>
98 </data>
99
100 </resource>