...
Provide Http EndPoints for these components:
* Components:
* Root endpoint: List all the available endpoints
* * Config: Do the configuration.
...
/api/v1/<component>/<action>
2. Root endpoint:
/api/v1 |
---|
GET |
Get all the available endpoints |
Response Code | Description |
---|
200 | successful operation | 403 | Don't have permission |
|
3. Config:
/api/v1/config/server_config |
---|
GET |
Get value of all configured values overridden on local server config |
Response Code | Description |
---|
200 | successful operation | 403 | Don't have permission | 404 | Configuration not found |
|
...
/api/v1/config/server_config |
---|
POST |
Update server configuration |
Parameters Name | Type | Required | Description |
---|
configName | String | Yes | Configuration name(key) | configValue | String | Yes | Configuration value(value) |
Body { "configName1": "configValue1", "configName2": "configValue2" } |
---|
Response Code | Description |
---|
204 | successful operation | 403 | Don't have permission | 404 | Configuration not found |
|
43. Ledger:
/api/v1/ledger/delete/?ledger_id=<ledger_id> |
---|
DELETE |
Delete a ledger. |
Parameters Name | Type | Required | Description |
---|
ledger_id | Long | Yes | ledger id of the ledger. |
Response Code | Description |
---|
403 | Don't have permission | 404 | No ledger found |
|
...
/api/v1/ledger/read/?ledger_id=<ledger_id>&start_entry_id=<start_entry_id>&end_entry_id=<end_entry_id> |
---|
GET |
Read a range of entries from ledger |
Parameters Name | Type | Required | Description |
---|
ledger_id | Long | Yes | ledger id of the ledger | start_entry_id | Long | No | start entry id of read range | end_entry_id | Long | No | end entry id of read range |
Response Code | Description |
---|
200 | successful operation. | 403 | Don't have permission | 404 | No ledger found |
|
54. Bookies
/api/v1/bookie/list_bookies/?type=<type>&print_hostnames=<hostnames> |
---|
GET |
Get all the available bookies. |
Parameters Name | Type | Required | Description |
---|
type | String | Yes | value: rw/ro , list read-write/read-only bookies | hostnames | Boolean | No | whether print hostname of bookie |
Response Code | Description |
---|
200 | successful operation | 403 | Don't have permission |
|
...
/api/v1/bookie/expand_storage |
---|
POST |
Expand storage for a bookie. |
Response Code | Description |
---|
204 | successful operation. | 403 | Don't have permission |
|
65. Recover
/api/v1/autorecovery/bookie/ |
---|
POST |
Ledger data recovery for failed bookie |
Parameters Name | Type | Required | Description |
---|
bookie_src | String | Yes | bookie source to recovery | bookie_dest | String | No | bookie data recovery destination | delete_cookie | Boolean | No | Whether delete cookie |
Body { "bookie_src": [ "bookie_src1", "bookie_src2"... ], "bookie_dest": [ "bookie_dest1", "bookie_dest2"... ], "delete_cookie": <bool_value> } |
---|
Response Code | Description |
---|
200 | successful operation. | 403 | Don't have permission | 404 | Not found Bookie |
|
...