Files
scylladb/api/api-doc/gossiper.json
Asias He 0a3a2a82e1 api: Add force_remove_endpoint for gossip
It is used to force remove a node from gossip membership if something
goes wrong.

Note: run the force_remove_endpoint api at the same time on _all_ the
nodes in the cluster in order to prevent the removed nodes come back.
Becasue nodes without running the force_remove_endpoint api cmd can
gossip around the removed node information to other nodes in 2 *
ring_delay (2 * 30 seconds by default) time.

For instance, in a 3 nodes cluster, node 3 is decommissioned, to remove
node 3 from gossip membership prior the auto removal (3 days by
default), run the api cmd on both node 1 and node 2 at the same time.

$ curl -X POST --header "Accept: application/json"
"http://127.0.0.1:10000/gossiper/force_remove_endpoint/127.0.0.3"
$ curl -X POST --header "Accept: application/json"
"http://127.0.0.2:10000/gossiper/force_remove_endpoint/127.0.0.3"

Then run 'nodetool gossipinfo' on all the nodes to check the removed nodes
are not present.

Fixes #2134

Closes #5436
2020-11-29 13:58:46 +02:00

178 lines
5.1 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": "long",
"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": "long",
"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"
}
]
}
]
},
{
"path":"/gossiper/force_remove_endpoint/{addr}",
"operations":[
{
"method":"POST",
"summary":"Force remove an endpoint from gossip",
"type":"void",
"nickname":"force_remove_endpoint",
"produces":[
"application/json"
],
"parameters":[
{
"name":"addr",
"description":"The endpoint address",
"required":true,
"allowMultiple":false,
"type":"string",
"paramType":"path"
}
]
}
]
}
]
}