docker build .- APP_URL: request url for ping
- INSTANCE_ID: Id configured for each instance
Method: Post
Request:
{
"ttl": 1, //>=1
"count": 0,// use 0 for manual ping
"initial": {
"id": "string",// whatever you like for initial
"ip": "string"// whatever you like for initial
},
"sender": {
"id": "string",// whatever you like for initial
"ip": "string"// whatever you like for initial
}
}Response:
{
"count": 1,// = initial TTL
"initial": {
"id": "string",
"ip": "string"
},
"lastNode": {
"id": "string",
"ip": "string"
},
"thisNode": {
"id": "default", // id last arrived node
"ip": "172.17.0.2" // last arrived node
}
}Method: Post
Request:
{
"ttl": 0,// TTL for each ping
"batchSize": 0// Number of ping requests to execute
}Response:
{
"stats": {
"[Ip,Id]": {
"count": 0,// Number of response with lastnode=[Ip,Id]
"ratio": 0 // Ratio of response with lastnode=[Ip,Id]
}
},
"details": [
{
"finalNode": { // lastnode from pong
"id": "string",
"ip": "string"
},
"time": 0 // time used, unit: ms
}
]
}