curl -X GET "http://127.0.0.1:10000/gossiper/heart_beat_version/127.0.0.2" This is useful to check if the gossip code is still running when debugging. Now we can get both the generation version and heart beat version of a node. curl -X GET "http://127.0.0.1:10000/gossiper/generation_number/127.0.0.2"
154 lines
4.4 KiB
JSON
154 lines
4.4 KiB
JSON
{
|
|
"apiVersion":"0.0.1",
|
|
"swaggerVersion":"1.2",
|
|
"basePath":"{{Protocol}}://{{Host}}",
|
|
"resourcePath":"/gossiper",
|
|
"produces":[
|
|
"application/json"
|
|
],
|
|
"apis":[
|
|
{
|
|
"path":"/gossiper/endpoint/down/",
|
|
"operations":[
|
|
{
|
|
"method":"GET",
|
|
"summary":"Get the addreses of the down endpoints",
|
|
"type":"array",
|
|
"items":{
|
|
"type":"string"
|
|
},
|
|
"nickname":"get_down_endpoint",
|
|
"produces":[
|
|
"application/json"
|
|
],
|
|
"parameters":[
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"path":"/gossiper/endpoint/live/",
|
|
"operations":[
|
|
{
|
|
"method":"GET",
|
|
"summary":"Get the addreses of live endpoints",
|
|
"type":"array",
|
|
"items":{
|
|
"type":"string"
|
|
},
|
|
"nickname":"get_live_endpoint",
|
|
"produces":[
|
|
"application/json"
|
|
],
|
|
"parameters":[
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"path":"/gossiper/downtime/{addr}",
|
|
"operations":[
|
|
{
|
|
"method":"GET",
|
|
"summary":"Get the downtime of an end point",
|
|
"type":"long",
|
|
"nickname":"get_endpoint_downtime",
|
|
"produces":[
|
|
"application/json"
|
|
],
|
|
"parameters":[
|
|
{
|
|
"name":"addr",
|
|
"description":"The endpoint address",
|
|
"required":true,
|
|
"allowMultiple":false,
|
|
"type":"string",
|
|
"paramType":"path"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"path":"/gossiper/generation_number/{addr}",
|
|
"operations":[
|
|
{
|
|
"method":"GET",
|
|
"summary":"Returns files which are pending for archival attempt. Does NOT include failed archive attempts",
|
|
"type":"int",
|
|
"nickname":"get_current_generation_number",
|
|
"produces":[
|
|
"application/json"
|
|
],
|
|
"parameters":[
|
|
{
|
|
"name":"addr",
|
|
"description":"The endpoint address",
|
|
"required":true,
|
|
"allowMultiple":false,
|
|
"type":"string",
|
|
"paramType":"path"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"path":"/gossiper/heart_beat_version/{addr}",
|
|
"operations":[
|
|
{
|
|
"method":"GET",
|
|
"summary":"Get heart beat version for a node",
|
|
"type":"int",
|
|
"nickname":"get_current_heart_beat_version",
|
|
"produces":[
|
|
"application/json"
|
|
],
|
|
"parameters":[
|
|
{
|
|
"name":"addr",
|
|
"description":"The endpoint address",
|
|
"required":true,
|
|
"allowMultiple":false,
|
|
"type":"string",
|
|
"paramType":"path"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"path":"/gossiper/assassinate/{addr}",
|
|
"operations":[
|
|
{
|
|
"method":"POST",
|
|
"summary":"Assassinate an end point",
|
|
"type":"void",
|
|
"nickname":"assassinate_endpoint",
|
|
"produces":[
|
|
"application/json"
|
|
],
|
|
"parameters":[
|
|
{
|
|
"name":"addr",
|
|
"description":"The endpoint address",
|
|
"required":true,
|
|
"allowMultiple":false,
|
|
"type":"string",
|
|
"paramType":"path"
|
|
},
|
|
{
|
|
"name":"unsafe",
|
|
"description":"Set to True to perform an unsafe assassination",
|
|
"required":false,
|
|
"allowMultiple":false,
|
|
"type":"boolean",
|
|
"paramType":"query"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|