|
|
@ -53,12 +53,14 @@ func registerAdminRouter(router *mux.Router) { |
|
|
|
// Info operations
|
|
|
|
// Info operations
|
|
|
|
adminV1Router.Methods(http.MethodGet).Path("/info").HandlerFunc(httpTraceAll(adminAPI.ServerInfoHandler)) |
|
|
|
adminV1Router.Methods(http.MethodGet).Path("/info").HandlerFunc(httpTraceAll(adminAPI.ServerInfoHandler)) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if globalIsDistXL || globalIsXL { |
|
|
|
/// Heal operations
|
|
|
|
/// Heal operations
|
|
|
|
|
|
|
|
|
|
|
|
// Heal processing endpoint.
|
|
|
|
// Heal processing endpoint.
|
|
|
|
adminV1Router.Methods(http.MethodPost).Path("/heal/").HandlerFunc(httpTraceAll(adminAPI.HealHandler)) |
|
|
|
adminV1Router.Methods(http.MethodPost).Path("/heal/").HandlerFunc(httpTraceAll(adminAPI.HealHandler)) |
|
|
|
adminV1Router.Methods(http.MethodPost).Path("/heal/{bucket}").HandlerFunc(httpTraceAll(adminAPI.HealHandler)) |
|
|
|
adminV1Router.Methods(http.MethodPost).Path("/heal/{bucket}").HandlerFunc(httpTraceAll(adminAPI.HealHandler)) |
|
|
|
adminV1Router.Methods(http.MethodPost).Path("/heal/{bucket}/{prefix:.*}").HandlerFunc(httpTraceAll(adminAPI.HealHandler)) |
|
|
|
adminV1Router.Methods(http.MethodPost).Path("/heal/{bucket}/{prefix:.*}").HandlerFunc(httpTraceAll(adminAPI.HealHandler)) |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// Profiling operations
|
|
|
|
// Profiling operations
|
|
|
|
adminV1Router.Methods(http.MethodPost).Path("/profiling/start").HandlerFunc(httpTraceAll(adminAPI.StartProfilingHandler)). |
|
|
|
adminV1Router.Methods(http.MethodPost).Path("/profiling/start").HandlerFunc(httpTraceAll(adminAPI.StartProfilingHandler)). |
|
|
@ -102,4 +104,7 @@ func registerAdminRouter(router *mux.Router) { |
|
|
|
|
|
|
|
|
|
|
|
// List policies
|
|
|
|
// List policies
|
|
|
|
adminV1Router.Methods(http.MethodGet).Path("/list-canned-policies").HandlerFunc(httpTraceHdrs(adminAPI.ListCannedPolicies)) |
|
|
|
adminV1Router.Methods(http.MethodGet).Path("/list-canned-policies").HandlerFunc(httpTraceHdrs(adminAPI.ListCannedPolicies)) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// If none of the routes match.
|
|
|
|
|
|
|
|
adminV1Router.NotFoundHandler = http.HandlerFunc(httpTraceHdrs(notFoundHandler)) |
|
|
|
} |
|
|
|
} |
|
|
|