all: export querylog docs

This commit is contained in:
Dimitry Kolyshev
2023-05-29 13:29:41 +03:00
parent ea8d634f65
commit f4f2c11eb9
4 changed files with 59 additions and 0 deletions

View File

@@ -62,6 +62,7 @@ func (l *queryLog) initWeb() {
l.conf.HTTPRegister(http.MethodGet, "/control/querylog", l.handleQueryLog)
l.conf.HTTPRegister(http.MethodPost, "/control/querylog_clear", l.handleQueryLogClear)
l.conf.HTTPRegister(http.MethodGet, "/control/querylog/config", l.handleGetQueryLogConfig)
l.conf.HTTPRegister(http.MethodGet, "/control/querylog/export", l.handleQueryLogExport)
l.conf.HTTPRegister(
http.MethodPut,
"/control/querylog/config/update",
@@ -96,6 +97,14 @@ func (l *queryLog) handleQueryLog(w http.ResponseWriter, r *http.Request) {
_ = aghhttp.WriteJSONResponse(w, r, resp)
}
// handleQueryLogExport is the handler for the GET /control/querylog/export
// HTTP API.
//
// TODO(d.kolyshev): !! Implement handleQueryLogExport.
func (l *queryLog) handleQueryLogExport(w http.ResponseWriter, r *http.Request) {
aghhttp.Error(r, w, http.StatusBadRequest, "not implemented")
}
// handleQueryLogClear is the handler for the POST /control/querylog/clear HTTP
// API.
func (l *queryLog) handleQueryLogClear(_ http.ResponseWriter, _ *http.Request) {