Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main' into http_instance_ops_1
Browse files Browse the repository at this point in the history
  • Loading branch information
vsian committed Oct 11, 2024
2 parents 447a455 + cfbc37b commit d0d683a
Show file tree
Hide file tree
Showing 2 changed files with 185 additions and 76 deletions.
47 changes: 11 additions & 36 deletions docs/references/http_api_reference.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2784,7 +2784,7 @@ A `500` HTTP status code indicates an error condition. The response includes a J
**POST** `/admin/node/current`
Set a node role.
Sets role for a node.
### Request
Expand All @@ -2805,8 +2805,7 @@ curl --request POST \
'{
"role" : "follower",
"name" : "following",
"address" : "0.0.0.0",
"port" : 23851
"address" : "0.0.0.0:23851"
}'
```
Expand All @@ -2820,7 +2819,6 @@ curl --request POST \
- Parameter settings for setting a node to `follower` or `learner`:
- "name" Required : Name of the node in the cluster.
- "address" Required : Peer server address of the leader in the cluster.
- "port" Required : Peer server port of the leader in the cluster.
### Response
Expand Down Expand Up @@ -2869,7 +2867,7 @@ A `500` HTTP status code indicates an error condition. The response includes a J
**GET** `/admin/variables`
Show all node variables in admin mode.
Shows all node variables in admin mode.
### Request
Expand All @@ -2891,12 +2889,7 @@ None.
### Response
<Tabs
defaultValue="s200"
values={[
{label: 'Status code 200', value: 's200'},
]}>
<TabItem value="s200">
#### Status code 200
The response includes a JSON object like the following:
Expand All @@ -2910,14 +2903,13 @@ The response includes a JSON object like the following:
- `"error_code"`: `integer`
`0`: The operation succeeds.
</Tabs>
---
## Admin show node configs
**GET** `/admin/configs`
Show all node configs in admin mode.
Shows all node configs in admin mode.
### Request
Expand Down Expand Up @@ -2979,8 +2971,6 @@ The response includes a JSON object like the following:
}
```
</Tabs>
---
## Admin show node variable
Expand Down Expand Up @@ -3056,7 +3046,7 @@ The response includes a JSON object like the following:
**GET** `/admin/node/current`
Get information about the currently connected node.
Gets information about the currently connected node.
### Request
Expand All @@ -3077,12 +3067,8 @@ curl --request GET \
None.
### Response
<Tabs
defaultValue="s200"
values={[
{label: 'Status code 200', value: 's200'},
]}>
<TabItem value="s200">
#### Status code 200
The response includes a JSON object like the following:
Expand All @@ -3098,16 +3084,13 @@ The response includes a JSON object like the following:
- `"node_role": string`
The role of querying node.
</TabItem>
</Tabs>
---
## Admin show node
**GET** `/admin/node/{node_name}`
Get information about a node in the cluster.
Gets information about a node in the cluster.
### Request
Expand Down Expand Up @@ -3176,7 +3159,7 @@ A `500` HTTP status code indicates an error condition. The response includes a J
**GET** `/admin/nodes`
List all nodes in the cluster.
Lists all nodes in the cluster.
### Request
Expand All @@ -3198,12 +3181,7 @@ None.
### Response
<Tabs
defaultValue="s200"
values={[
{label: 'Status code 200', value: 's200'},
]}>
<TabItem value="s200">
#### Status code 200
The response includes a JSON object like the following:
Expand All @@ -3223,9 +3201,6 @@ The response includes a JSON object like the following:
- `"nodes" : array` :
Each element is in `[nodename, noderole]` format.
</TabItem>
</Tabs>
---
Loading

0 comments on commit d0d683a

Please sign in to comment.