Skip to content

Commit df45368

Browse files
committed
status: add PUT deny status on exceeding limits
Refs nspcc-dev/neofs-node#3520. Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
1 parent a699f28 commit df45368

File tree

5 files changed

+10
-0
lines changed

5 files changed

+10
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
## [Unreleased]
44

55
### Added
6+
- QUOTA_EXCEEDED status code to SECTION_OBJECT (#343)
67

78
### Changed
89

object/service.proto

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@ service ObjectService {
7373
// - **LOCK_NON_REGULAR_OBJECT** (2051, SECTION_OBJECT): \
7474
// placement of an object of type LOCK that includes at least one object of
7575
// type other than REGULAR is prohibited;
76+
// - **QUOTA_EXCEEDED** (2054, SECTION_OBJECT): \
77+
// size quota set by user was exceeded;
7678
// - **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
7779
// object storage container not found;
7880
// - **TOKEN_NOT_FOUND** (4096, SECTION_SESSION): \

proto-docs/object.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,8 @@ Statuses:
158158
- **LOCK_NON_REGULAR_OBJECT** (2051, SECTION_OBJECT): \
159159
placement of an object of type LOCK that includes at least one object of
160160
type other than REGULAR is prohibited;
161+
- **QUOTA_EXCEEDED** (2054, SECTION_OBJECT): \
162+
size quota set by user was exceeded;
161163
- **CONTAINER_NOT_FOUND** (3072, SECTION_CONTAINER): \
162164
object storage container not found;
163165
- **TOKEN_NOT_FOUND** (4096, SECTION_SESSION): \

proto-docs/status.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ Section of statuses for object-related operations.
118118
| LOCK_NON_REGULAR_OBJECT | 3 | [**2051**] Locking an object with a non-REGULAR type rejected. |
119119
| OBJECT_ALREADY_REMOVED | 4 | [**2052**] Object has been marked deleted. |
120120
| OUT_OF_RANGE | 5 | [**2053**] Invalid range has been requested for an object. |
121+
| QUOTA_EXCEEDED | 6 | [**2054**] Quota was exceeded; no further PUTs will be allowed within current settings. |
121122

122123

123124

status/types.proto

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,10 @@ enum Object {
124124

125125
// [**2053**] Invalid range has been requested for an object.
126126
OUT_OF_RANGE = 5;
127+
128+
// [**2054**] Quota was exceeded; no further PUTs will be allowed within
129+
// current settings.
130+
QUOTA_EXCEEDED = 6;
127131
}
128132

129133
// Section of statuses for container-related operations.

0 commit comments

Comments
 (0)