63 lines
1.4 KiB
JSON
63 lines
1.4 KiB
JSON
{
|
|
"components": {
|
|
"schemas": {
|
|
"HealthResponse": {
|
|
"additionalProperties": false,
|
|
"properties": {
|
|
"service": {
|
|
"const": "platform",
|
|
"title": "Service",
|
|
"type": "string"
|
|
},
|
|
"status": {
|
|
"const": "ok",
|
|
"title": "Status",
|
|
"type": "string"
|
|
},
|
|
"version": {
|
|
"title": "Version",
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"status",
|
|
"service",
|
|
"version"
|
|
],
|
|
"title": "HealthResponse",
|
|
"type": "object"
|
|
}
|
|
}
|
|
},
|
|
"info": {
|
|
"description": "工程骨架。当前只提供进程存活检查,业务接口逐项实现。",
|
|
"title": "KF-OnlineJudge Platform API",
|
|
"version": "0.0.1"
|
|
},
|
|
"openapi": "3.1.0",
|
|
"paths": {
|
|
"/api/v1/health/live": {
|
|
"get": {
|
|
"description": "Check process liveness only; does not attest DB, queue or judge readiness.",
|
|
"operationId": "liveness",
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/HealthResponse"
|
|
}
|
|
}
|
|
},
|
|
"description": "Successful Response"
|
|
}
|
|
},
|
|
"summary": "Liveness",
|
|
"tags": [
|
|
"health"
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|