admin api: add CleanupIncompleteUploads spec
This commit is contained in:
parent
bb5e0c210f
commit
3018dfd663
2 changed files with 62 additions and 0 deletions
|
@ -826,6 +826,46 @@ paths:
|
|||
schema:
|
||||
$ref: '#/components/schemas/BucketInfo'
|
||||
|
||||
/CleanupIncompleteUploads:
|
||||
post:
|
||||
tags:
|
||||
- Bucket
|
||||
operationId: "CleanupIncompleteUploads"
|
||||
summary: "Cleanup incomplete uploads in a bucket"
|
||||
description: |
|
||||
Cleanup all incomplete uploads in a bucket that are older than a specified number of seconds
|
||||
requestBody:
|
||||
description: |
|
||||
Bucket id and minimum age of uploads to delete (in seconds)
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
required: [bucketId, olderThanSecs]
|
||||
properties:
|
||||
bucketId:
|
||||
type: string
|
||||
example: "e6a14cd6a27f48684579ec6b381c078ab11697e6bc8513b72b2f5307e25fff9b"
|
||||
olderThanSecs:
|
||||
type: integer
|
||||
example: "3600"
|
||||
responses:
|
||||
'500':
|
||||
description: "The server can not handle your request. Check your connectivity with the rest of the cluster."
|
||||
'400':
|
||||
description: "The payload is not formatted correctly"
|
||||
'200':
|
||||
description: "The bucket was cleaned up successfully"
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
uploadsDeleted:
|
||||
type: integer
|
||||
example: 12
|
||||
|
||||
/AllowBucketKey:
|
||||
post:
|
||||
tags:
|
||||
|
|
|
@ -702,6 +702,28 @@ Deletes a storage bucket. A bucket cannot be deleted if it is not empty.
|
|||
|
||||
Warning: this will delete all aliases associated with the bucket!
|
||||
|
||||
#### CleanupIncompleteUploads `POST /v2/CleanupIncompleteUploads`
|
||||
|
||||
Cleanup all incomplete uploads in a bucket that are older than a specified number
|
||||
of seconds.
|
||||
|
||||
Request body format:
|
||||
|
||||
```json
|
||||
{
|
||||
"bucketId": "e6a14cd6a27f48684579ec6b381c078ab11697e6bc8513b72b2f5307e25fff9b",
|
||||
"olderThanSecs": 3600
|
||||
}
|
||||
```
|
||||
|
||||
Response format
|
||||
|
||||
```json
|
||||
{
|
||||
"uploadsDeleted": 12
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
### Operations on permissions for keys on buckets
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue