From c7aa7c4db4259d659e5c866ca3d0a61dd5cc247b Mon Sep 17 00:00:00 2001 From: Jimmy Zelinskie Date: Tue, 9 Feb 2016 13:33:40 -0500 Subject: [PATCH] api: reorder constants and add comments --- api/v1/routes.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/api/v1/routes.go b/api/v1/routes.go index 0b3a383b..f0250b02 100644 --- a/api/v1/routes.go +++ b/api/v1/routes.go @@ -29,10 +29,8 @@ import ( "github.com/coreos/clair/worker" ) -// maxBodySize restricts client requests to 1MiB. const ( - maxBodySize int64 = 1048576 - + // These are the route identifiers for prometheus. postLayerRoute = "v1/postLayer" getLayerRoute = "v1/getLayer" deleteLayerRoute = "v1/deleteLayer" @@ -47,6 +45,9 @@ const ( getNotificationRoute = "v1/getNotification" deleteNotificationRoute = "v1/deleteNotification" getMetricsRoute = "v1/getMetrics" + + // maxBodySize restricts client request bodies to 1MiB. + maxBodySize int64 = 1048576 ) func decodeJSON(r *http.Request, v interface{}) error {