Skip to content

Commit 71a75c7

Browse files
author
Leonard Lyubich
committed
[#194] Generate docs with recent protocol changes
Signed-off-by: Leonard Lyubich <[email protected]>
1 parent 9d7e61c commit 71a75c7

File tree

6 files changed

+279
-138
lines changed

6 files changed

+279
-138
lines changed

container/service.proto

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ service ContainerService {
2121
// is added into smart contract storage.
2222
//
2323
// Statuses:
24-
// - **OK** (0, SECTION_SUCCESS):
25-
// request to save the container has been sent to the sidechain;
24+
// - **OK** (0, SECTION_SUCCESS): \
25+
// request to save the container has been sent to the sidechain;
2626
// - Common failures (SECTION_FAILURE_COMMON).
2727
rpc Put(PutRequest) returns (PutResponse);
2828

@@ -32,26 +32,26 @@ service ContainerService {
3232
// is added into smart contract storage.
3333
//
3434
// Statuses:
35-
// - **OK** (0, SECTION_SUCCESS):
36-
// request to remove the container has been sent to the sidechain;
35+
// - **OK** (0, SECTION_SUCCESS): \
36+
// request to remove the container has been sent to the sidechain;
3737
// - Common failures (SECTION_FAILURE_COMMON).
3838
rpc Delete(DeleteRequest) returns (DeleteResponse);
3939

4040
// Returns container structure from `Container` smart contract storage.
4141
//
4242
// Statuses:
43-
// - **OK** (0, SECTION_SUCCESS):
44-
// container has been successfully read;
43+
// - **OK** (0, SECTION_SUCCESS): \
44+
// container has been successfully read;
4545
// - Common failures (SECTION_FAILURE_COMMON);
46-
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER):
47-
// requested container not found.
46+
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
47+
// requested container not found.
4848
rpc Get(GetRequest) returns (GetResponse);
4949

5050
// Returns all owner's containers from 'Container` smart contract' storage.
5151
//
5252
// Statuses:
53-
// - **OK** (0, SECTION_SUCCESS):
54-
// container list has been successfully read;
53+
// - **OK** (0, SECTION_SUCCESS): \
54+
// container list has been successfully read;
5555
// - Common failures (SECTION_FAILURE_COMMON).
5656
rpc List(ListRequest) returns (ListResponse);
5757

@@ -60,27 +60,27 @@ service ContainerService {
6060
// added into smart contract storage.
6161
//
6262
// Statuses:
63-
// - **OK** (0, SECTION_SUCCESS):
64-
// request to save container eACL has been sent to the sidechain;
63+
// - **OK** (0, SECTION_SUCCESS): \
64+
// request to save container eACL has been sent to the sidechain;
6565
// - Common failures (SECTION_FAILURE_COMMON).
6666
rpc SetExtendedACL(SetExtendedACLRequest) returns (SetExtendedACLResponse);
6767

6868
// Returns Extended ACL table and signature from `Container` smart contract
6969
// storage.
7070
//
7171
// Statuses:
72-
// - **OK** (0, SECTION_SUCCESS):
73-
// container eACL has been successfully read;
72+
// - **OK** (0, SECTION_SUCCESS): \
73+
// container eACL has been successfully read;
7474
// - Common failures (SECTION_FAILURE_COMMON);
75-
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER):
76-
// container not found.
75+
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
76+
// container not found.
7777
rpc GetExtendedACL(GetExtendedACLRequest) returns (GetExtendedACLResponse);
7878

7979
// Announce container used space values for P2P synchronization.
8080
//
8181
// Statuses:
82-
// - **OK** (0, SECTION_SUCCESS):
83-
// estimation of used space has been successfully announced;
82+
// - **OK** (0, SECTION_SUCCESS): \
83+
// estimation of used space has been successfully announced;
8484
// - Common failures (SECTION_FAILURE_COMMON).
8585
rpc AnnounceUsedSpace(AnnounceUsedSpaceRequest) returns (AnnounceUsedSpaceResponse);
8686
}

object/service.proto

Lines changed: 80 additions & 80 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,19 @@ service ObjectService {
2020
// keeping receiving order.
2121
//
2222
// Statuses:
23-
// - **OK** (0, SECTION_SUCCESS):
24-
// object has been successfully read;
23+
// - **OK** (0, SECTION_SUCCESS): \
24+
// object has been successfully read;
2525
// - Common failures (SECTION_FAILURE_COMMON);
26-
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER):
27-
// object container not found;
28-
// - **ACCESS_DENIED** (2048, SECTION_OBJECT):
29-
// read access to the object is denied;
30-
// - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT):
31-
// object not found in container;
32-
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION):
33-
// provided session token has expired;
34-
// - **OBJECT_ALREADY_REMOVED** (2052, SECTION_OBJECT):
35-
// the requested object has been marked as deleted.
26+
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
27+
// object container not found;
28+
// - **ACCESS_DENIED** (2048, SECTION_OBJECT): \
29+
// read access to the object is denied;
30+
// - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT): \
31+
// object not found in container;
32+
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \
33+
// provided session token has expired;
34+
// - **OBJECT_ALREADY_REMOVED** (2052, SECTION_OBJECT): \
35+
// the requested object has been marked as deleted.
3636
rpc Get(GetRequest) returns (stream GetResponse);
3737

3838
// Put the object into container. Request uses gRPC stream. First message
@@ -43,77 +43,77 @@ service ObjectService {
4343
// Chunk messages SHOULD be sent in direct order of fragmentation.
4444
//
4545
// Statuses:
46-
// - **OK** (0, SECTION_SUCCESS):
47-
// object has been successfully saved in the container;
46+
// - **OK** (0, SECTION_SUCCESS): \
47+
// object has been successfully saved in the container;
4848
// - Common failures (SECTION_FAILURE_COMMON);
49-
// - **LOCKED** (2050, SECTION_OBJECT):
50-
// placement of an object of type TOMBSTONE that includes at least one locked
51-
// object is prohibited;
52-
// - **LOCK_NON_REGULAR_OBJECT** (2051, SECTION_OBJECT):
53-
// placement of an object of type LOCK that includes at least one object of
54-
// type other than REGULAR is prohibited;
55-
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER):
56-
// object storage container not found;
57-
// - **ACCESS_DENIED** (2048, SECTION_OBJECT):
58-
// write access to the container is denied;
59-
// - **TOKEN_NOT_FOUND** (4096, SECTION_SESSION):
60-
// (for trusted object preparation) session private key does not exist or has
49+
// - **LOCKED** (2050, SECTION_OBJECT): \
50+
// placement of an object of type TOMBSTONE that includes at least one locked
51+
// object is prohibited;
52+
// - **LOCK_NON_REGULAR_OBJECT** (2051, SECTION_OBJECT): \
53+
// placement of an object of type LOCK that includes at least one object of
54+
// type other than REGULAR is prohibited;
55+
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
56+
// object storage container not found;
57+
// - **ACCESS_DENIED** (2048, SECTION_OBJECT): \
58+
// write access to the container is denied;
59+
// - **TOKEN_NOT_FOUND** (4096, SECTION_SESSION): \
60+
// (for trusted object preparation) session private key does not exist or has
6161
// been deleted;
62-
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION):
63-
// provided session token has expired.
62+
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \
63+
// provided session token has expired.
6464
rpc Put(stream PutRequest) returns (PutResponse);
6565

6666
// Delete the object from a container. There is no immediate removal
6767
// guarantee. Object will be marked for removal and deleted eventually.
6868
//
6969
// Statuses:
70-
// - **OK** (0, SECTION_SUCCESS):
71-
// object has been successfully marked to be removed from the container;
70+
// - **OK** (0, SECTION_SUCCESS): \
71+
// object has been successfully marked to be removed from the container;
7272
// - Common failures (SECTION_FAILURE_COMMON);
73-
// - **LOCKED** (2050, SECTION_OBJECT):
74-
// deleting a locked object is prohibited;
75-
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER):
76-
// object container not found;
77-
// - **ACCESS_DENIED** (2048, SECTION_OBJECT):
78-
// delete access to the object is denied;
79-
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION):
80-
// provided session token has expired.
73+
// - **LOCKED** (2050, SECTION_OBJECT): \
74+
// deleting a locked object is prohibited;
75+
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
76+
// object container not found;
77+
// - **ACCESS_DENIED** (2048, SECTION_OBJECT): \
78+
// delete access to the object is denied;
79+
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \
80+
// provided session token has expired.
8181
rpc Delete(DeleteRequest) returns (DeleteResponse);
8282

8383
// Returns the object Headers without data payload. By default full header is
8484
// returned. If `main_only` request field is set, the short header with only
8585
// the very minimal information would be returned instead.
8686
//
8787
// Statuses:
88-
// - **OK** (0, SECTION_SUCCESS):
89-
// object header has been successfully read;
88+
// - **OK** (0, SECTION_SUCCESS): \
89+
// object header has been successfully read;
9090
// - Common failures (SECTION_FAILURE_COMMON);
91-
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER):
92-
// object container not found;
93-
// - **ACCESS_DENIED** (2048, SECTION_OBJECT):
94-
// access to operation HEAD of the object is denied;
95-
// - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT):
96-
// object not found in container;
97-
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION):
98-
// provided session token has expired;
99-
// - **OBJECT_ALREADY_REMOVED** (2052, SECTION_OBJECT):
100-
// the requested object has been marked as deleted.
91+
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
92+
// object container not found;
93+
// - **ACCESS_DENIED** (2048, SECTION_OBJECT): \
94+
// access to operation HEAD of the object is denied;
95+
// - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT): \
96+
// object not found in container;
97+
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \
98+
// provided session token has expired;
99+
// - **OBJECT_ALREADY_REMOVED** (2052, SECTION_OBJECT): \
100+
// the requested object has been marked as deleted.
101101
rpc Head(HeadRequest) returns (HeadResponse);
102102

103103
// Search objects in container. Search query allows to match by Object
104104
// Header's filed values. Please see the corresponding NeoFS Technical
105105
// Specification section for more details.
106106
//
107107
// Statuses:
108-
// - **OK** (0, SECTION_SUCCESS):
109-
// objects have been successfully selected;
108+
// - **OK** (0, SECTION_SUCCESS): \
109+
// objects have been successfully selected;
110110
// - Common failures (SECTION_FAILURE_COMMON);
111-
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER):
112-
// search container not found;
113-
// - **ACCESS_DENIED** (2048, SECTION_OBJECT):
114-
// access to operation SEARCH of the object is denied;
115-
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION):
116-
// provided session token has expired.
111+
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
112+
// search container not found;
113+
// - **ACCESS_DENIED** (2048, SECTION_OBJECT): \
114+
// access to operation SEARCH of the object is denied;
115+
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \
116+
// provided session token has expired.
117117
rpc Search(SearchRequest) returns (stream SearchResponse);
118118

119119
// Get byte range of data payload. Range is set as an (offset, length) tuple.
@@ -122,19 +122,19 @@ service ObjectService {
122122
// order.
123123
//
124124
// Statuses:
125-
// - **OK** (0, SECTION_SUCCESS):
126-
// data range of the object payload has been successfully read;
125+
// - **OK** (0, SECTION_SUCCESS): \
126+
// data range of the object payload has been successfully read;
127127
// - Common failures (SECTION_FAILURE_COMMON);
128-
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER):
129-
// object container not found;
130-
// - **ACCESS_DENIED** (2048, SECTION_OBJECT):
131-
// access to operation RANGE of the object is denied;
132-
// - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT):
133-
// object not found in container;
134-
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION):
135-
// provided session token has expired;
136-
// - **OBJECT_ALREADY_REMOVED** (2052, SECTION_OBJECT):
137-
// the requested object has been marked as deleted.
128+
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
129+
// object container not found;
130+
// - **ACCESS_DENIED** (2048, SECTION_OBJECT): \
131+
// access to operation RANGE of the object is denied;
132+
// - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT): \
133+
// object not found in container;
134+
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \
135+
// provided session token has expired;
136+
// - **OBJECT_ALREADY_REMOVED** (2052, SECTION_OBJECT): \
137+
// the requested object has been marked as deleted.
138138
rpc GetRange(GetRangeRequest) returns (stream GetRangeResponse);
139139

140140
// Returns homomorphic or regular hash of object's payload range after
@@ -143,17 +143,17 @@ service ObjectService {
143143
// request. Note that hash is calculated for XORed data.
144144
//
145145
// Statuses:
146-
// - **OK** (0, SECTION_SUCCESS):
147-
// data range of the object payload has been successfully hashed;
146+
// - **OK** (0, SECTION_SUCCESS): \
147+
// data range of the object payload has been successfully hashed;
148148
// - Common failures (SECTION_FAILURE_COMMON);
149-
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER):
150-
// object container not found;
151-
// - **ACCESS_DENIED** (2048, SECTION_OBJECT):
152-
// access to operation RANGEHASH of the object is denied;
153-
// - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT):
154-
// object not found in container;
155-
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION):
156-
// provided session token has expired.
149+
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
150+
// object container not found;
151+
// - **ACCESS_DENIED** (2048, SECTION_OBJECT): \
152+
// access to operation RANGEHASH of the object is denied;
153+
// - **OBJECT_NOT_FOUND** (2049, SECTION_OBJECT): \
154+
// object not found in container;
155+
// - **TOKEN_EXPIRED** (4097, SECTION_SESSION): \
156+
// provided session token has expired.
157157
rpc GetRangeHash(GetRangeHashRequest) returns (GetRangeHashResponse);
158158
}
159159

proto-docs/container.md

Lines changed: 20 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,8 @@ verified by Inner Ring nodes. After one more block in sidechain, container
8585
is added into smart contract storage.
8686

8787
Statuses:
88-
- **OK** (0, SECTION_SUCCESS):
89-
request to save the container has been sent to the sidechain;
88+
- **OK** (0, SECTION_SUCCESS): \
89+
request to save the container has been sent to the sidechain;
9090
- Common failures (SECTION_FAILURE_COMMON).
9191

9292
| Name | Input | Output |
@@ -100,8 +100,8 @@ verified by Inner Ring nodes. After one more block in sidechain, container
100100
is added into smart contract storage.
101101

102102
Statuses:
103-
- **OK** (0, SECTION_SUCCESS):
104-
request to remove the container has been sent to the sidechain;
103+
- **OK** (0, SECTION_SUCCESS): \
104+
request to remove the container has been sent to the sidechain;
105105
- Common failures (SECTION_FAILURE_COMMON).
106106

107107
| Name | Input | Output |
@@ -112,9 +112,11 @@ request to remove the container has been sent to the sidechain;
112112
Returns container structure from `Container` smart contract storage.
113113

114114
Statuses:
115-
- **OK** (0, SECTION_SUCCESS):
116-
container has been successfully read;
117-
- Common failures (SECTION_FAILURE_COMMON).
115+
- **OK** (0, SECTION_SUCCESS): \
116+
container has been successfully read;
117+
- Common failures (SECTION_FAILURE_COMMON);
118+
- **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
119+
requested container not found.
118120

119121
| Name | Input | Output |
120122
| ---- | ----- | ------ |
@@ -124,8 +126,8 @@ container has been successfully read;
124126
Returns all owner's containers from 'Container` smart contract' storage.
125127

126128
Statuses:
127-
- **OK** (0, SECTION_SUCCESS):
128-
container list has been successfully read;
129+
- **OK** (0, SECTION_SUCCESS): \
130+
container list has been successfully read;
129131
- Common failures (SECTION_FAILURE_COMMON).
130132

131133
| Name | Input | Output |
@@ -138,8 +140,8 @@ immediately. After one more block in sidechain, Extended ACL changes are
138140
added into smart contract storage.
139141

140142
Statuses:
141-
- **OK** (0, SECTION_SUCCESS):
142-
request to save container eACL has been sent to the sidechain;
143+
- **OK** (0, SECTION_SUCCESS): \
144+
request to save container eACL has been sent to the sidechain;
143145
- Common failures (SECTION_FAILURE_COMMON).
144146

145147
| Name | Input | Output |
@@ -151,9 +153,11 @@ Returns Extended ACL table and signature from `Container` smart contract
151153
storage.
152154

153155
Statuses:
154-
- **OK** (0, SECTION_SUCCESS):
155-
container eACL has been successfully read;
156-
- Common failures (SECTION_FAILURE_COMMON).
156+
- **OK** (0, SECTION_SUCCESS): \
157+
container eACL has been successfully read;
158+
- Common failures (SECTION_FAILURE_COMMON);
159+
- **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
160+
container not found.
157161

158162
| Name | Input | Output |
159163
| ---- | ----- | ------ |
@@ -163,8 +167,8 @@ container eACL has been successfully read;
163167
Announce container used space values for P2P synchronization.
164168

165169
Statuses:
166-
- **OK** (0, SECTION_SUCCESS):
167-
estimation of used space has been successfully announced;
170+
- **OK** (0, SECTION_SUCCESS): \
171+
estimation of used space has been successfully announced;
168172
- Common failures (SECTION_FAILURE_COMMON).
169173

170174
| Name | Input | Output |

0 commit comments

Comments
 (0)