Refine controller template and probe listeners

This commit is contained in:
2026-04-27 00:28:25 +08:00
parent 8fae920fc8
commit d7c2dac944
20 changed files with 780 additions and 217 deletions

View File

@@ -73,17 +73,13 @@ func (s *Server) Initialize() {
ws.Consumes(restful.MIME_JSON)
ws.Produces(restful.MIME_JSON)
ws.Route(ws.GET("/healthz").To(s.queryHealthz).
ws.Route(ws.GET("/status").To(s.queryStatus).
Doc("Return basic controller status"))
// Stub for now
ws.Route(ws.GET("/readyz").To(s.queryHealthz).
Doc("Stub for now"))
s.restfulCont.Add(ws)
}
func (s *Server) queryHealthz(request *restful.Request, response *restful.Response) {
func (s *Server) queryStatus(request *restful.Request, response *restful.Response) {
resp := StatusResponse{
OK: true,
Service: "monok8s-controller",