In swagger 1.2 int is defined as int32. We originally used int following the jmx definition, in practice internally we use uint and int64 in many places. While the API format the type correctly, an external system that uses swagger-based code generator can face a type issue problem. This patch replace all use of int in a return type with long that is defined as int64. Changing the return type, have no impact on the system, but it does help external systems that use code generator from swagger. Fixes #5347 Signed-off-by: Amnon Heiman <amnon@scylladb.com>
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": "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"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|