]> mj.ucw.cz Git - moe.git/blob - submit/PROTOCOL
Combining local and remote operations.
[moe.git] / submit / PROTOCOL
1 Protocol spoken by the submit server
2 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3
4 (1) Server sends "+OK\n" or "+TLS\n"
5
6 (2) TLS is started if requested
7
8 (3) Client sends hello, server replies
9
10 (4) Loop: client sends command, server replies
11
12 Except for the initial "+xxx" message, all requests and replies are simple objects
13 as handled by the Sherlock library. Each line starts with a single-character
14 attribute name followed by the value of the attribute, the object is terminated
15 by an empty line. Parentheses can delimit nested blocks.
16
17 Every reply contains either a "+" or "-" attribute denoting status (OK/failed).
18 The value of the attribute is a message for the user, which should not be
19 interpreted in any way.
20
21 Hello request:
22
23         Uusername
24
25 Hello reply:
26
27         (only status)
28
29 Submit request:
30
31         !SUBMIT
32         Ttask
33         Ppart                   <-- optional part ID
34         Ssize
35         Xextension
36         (after the request is ACK-ed, the client sends raw data and then server sends a 2nd reply)
37
38 Submit reply:
39
40         (only status)
41
42 Submit reply after data:
43
44         (only status)
45
46 Status request:
47
48         !STATUS
49
50 Status reply:
51
52         task status objects defined below with the following added:
53         (T
54                 Aallowed_extension
55         )
56
57
58 Task status objects
59 ~~~~~~~~~~~~~~~~~~~
60 (T                              <-- task
61         Tname
62         (P                      <-- task part
63                 Pname
64                 Vid             <-- which version is current
65                 (V              <-- submitted version
66                         Vid
67                         Tsubmit_time
68                         Sstatus
69                         Lfilesize
70                         Hhash
71                         Xextension
72                 )
73         )
74 )