Skip to content

Commit b73f9e2

Browse files
committed
DOC-4035 RS: Add DB stop_traffic & resume_traffic REST API request references
1 parent c77a10a commit b73f9e2

File tree

3 files changed

+122
-0
lines changed

3 files changed

+122
-0
lines changed

content/operate/rs/references/rest-api/requests/bdbs/actions/_index.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,3 +44,13 @@ weight: $weight
4444
|--------|------|-------------|
4545
| [GET]({{<relref "/operate/rs/references/rest-api/requests/bdbs/actions/recover#get-bdbs-actions-recover">}}) | `/v1/bdbs/{uid}/actions/recover` | Get database recovery plan |
4646
| [POST]({{<relref "/operate/rs/references/rest-api/requests/bdbs/actions/recover#post-bdbs-actions-recover">}}) | `/v1/bdbs/{uid}/actions/recover` | Recover database |
47+
48+
## Resume traffic
49+
| Method | Path | Description |
50+
|--------|------|-------------|
51+
| [POST]({{<relref "/operate/rs/references/rest-api/requests/bdbs/actions/resume_traffic#post-bdbs-actions-resume-traffic">}}) | `/v1/bdbs/{uid}/actions/resume_traffic` | Resume database traffic |
52+
53+
## Stop traffic
54+
| Method | Path | Description |
55+
|--------|------|-------------|
56+
| [POST]({{<relref "/operate/rs/references/rest-api/requests/bdbs/actions/stop_traffic#post-bdbs-actions-stop-traffic">}}) | `/v1/bdbs/{uid}/actions/stop_traffic` | Stop database traffic |
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
---
2+
Title: Resume database traffic requests
3+
alwaysopen: false
4+
categories:
5+
- docs
6+
- operate
7+
- rs
8+
description: REST API requests to resume traffic for a database
9+
headerRange: '[1-2]'
10+
linkTitle: resume_traffic
11+
weight: $weight
12+
---
13+
14+
| Method | Path | Description |
15+
|--------|------|-------------|
16+
| [POST](#post-bdbs-actions-resume-traffic) | `/v1/bdbs/{uid}/actions/resume_traffic` | Resume database traffic |
17+
18+
## Resume database traffic {#post-bdbs-actions-resume-traffic}
19+
20+
```sh
21+
POST /v1/bdbs/{int: uid}/actions/resume_traffic
22+
```
23+
24+
Resume traffic handling for the database.
25+
26+
#### Required permissions
27+
28+
| Permission name | Roles |
29+
|-----------------|-------|
30+
| [update_bdb_with_action]({{< relref "/operate/rs/references/rest-api/permissions#update_bdb_with_action" >}}) | admin<br />cluster_member<br />db_member |
31+
32+
### Request {#post-request}
33+
34+
#### Example HTTP request
35+
36+
```sh
37+
POST /bdbs/1/actions/resume_traffic
38+
```
39+
40+
#### URL parameters
41+
42+
| Field | Type | Description |
43+
|-------|------|-------------|
44+
| uid | integer | The unique ID of the database. |
45+
46+
### Response {#post-response}
47+
48+
Returns a JSON object with an `action_uid`. You can track the action's progress with a [`GET /v1/actions/<action_uid>`]({{<relref "/operate/rs/references/rest-api/requests/actions#get-action">}}) request.
49+
50+
#### Status codes {#post-status-codes}
51+
52+
| Code | Description |
53+
|------|-------------|
54+
| [200 OK](https://www.rfc-editor.org/rfc/rfc9110.html#name-200-ok) | The request is accepted and is being processed. The database state will be `active-change-pending` until the request has been fully processed. |
55+
| [404 Not Found](https://www.rfc-editor.org/rfc/rfc9110.html#name-404-not-found) | Attempting to perform an action on a nonexistent database. |
56+
| [409 Conflict](https://www.rfc-editor.org/rfc/rfc9110.html#name-409-conflict) | Attempting to change a database while it is busy with another configuration change. This is a temporary condition, and the request should be reattempted later. |
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
---
2+
Title: Stop database traffic requests
3+
alwaysopen: false
4+
categories:
5+
- docs
6+
- operate
7+
- rs
8+
description: REST API requests to stop traffic for a database
9+
headerRange: '[1-2]'
10+
linkTitle: stop_traffic
11+
weight: $weight
12+
---
13+
14+
| Method | Path | Description |
15+
|--------|------|-------------|
16+
| [POST](#post-bdbs-actions-stop-traffic) | `/v1/bdbs/{uid}/actions/stop_traffic` | Stop database traffic |
17+
18+
## Stop database traffic {#post-bdbs-actions-stop-traffic}
19+
20+
```sh
21+
POST /v1/bdbs/{int: uid}/actions/stop_traffic
22+
```
23+
24+
Stop handling traffic for the database.
25+
26+
#### Required permissions
27+
28+
| Permission name | Roles |
29+
|-----------------|-------|
30+
| [update_bdb_with_action]({{< relref "/operate/rs/references/rest-api/permissions#update_bdb_with_action" >}}) | admin<br />cluster_member<br />db_member |
31+
32+
### Request {#post-request}
33+
34+
#### Example HTTP request
35+
36+
```sh
37+
POST /bdbs/1/actions/stop_traffic
38+
```
39+
40+
#### URL parameters
41+
42+
| Field | Type | Description |
43+
|-------|------|-------------|
44+
| uid | integer | The unique ID of the database. |
45+
46+
### Response {#post-response}
47+
48+
Returns a JSON object with an `action_uid`. You can track the action's progress with a [`GET /v1/actions/<action_uid>`]({{<relref "/operate/rs/references/rest-api/requests/actions#get-action">}}) request.
49+
50+
#### Status codes {#post-status-codes}
51+
52+
| Code | Description |
53+
|------|-------------|
54+
| [200 OK](https://www.rfc-editor.org/rfc/rfc9110.html#name-200-ok) | The request is accepted and is being processed. The database state will be `active-change-pending` until the request has been fully processed. |
55+
| [404 Not Found](https://www.rfc-editor.org/rfc/rfc9110.html#name-404-not-found) | Attempting to perform an action on a nonexistent database. |
56+
| [409 Conflict](https://www.rfc-editor.org/rfc/rfc9110.html#name-409-conflict) | Attempting to change a database while it is busy with another configuration change. This is a temporary condition, and the request should be reattempted later. |

0 commit comments

Comments
 (0)