You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, some routes in the status endpoint are registered to the http.ServeMux directly, while some are registered to the mux.Router. Since both serves the same purpose and there seems to be no custom handling between routes registered behind ServeMux and Router, it's better to consolidate them so we only register routes on the mux.Router. It's cleaner and makes it easier in the future if we want to add a middleware for all routes.
Enhancement
Currently, some routes in the status endpoint are registered to the
http.ServeMux
directly, while some are registered to themux.Router
. Since both serves the same purpose and there seems to be no custom handling between routes registered behindServeMux
andRouter
, it's better to consolidate them so we only register routes on themux.Router
. It's cleaner and makes it easier in the future if we want to add a middleware for all routes.Sample:
tidb/pkg/server/http_status.go
Line 300 in f4e366e
The text was updated successfully, but these errors were encountered: