diff --git a/procima/internal/app/http/v1/const.go b/procima/internal/app/http/v1/const.go index 1181f72..e25d9cd 100644 --- a/procima/internal/app/http/v1/const.go +++ b/procima/internal/app/http/v1/const.go @@ -1,9 +1,9 @@ package v1 const ( - MetricsURL = "/metrics" BaseURL = "/api/v1" ImageURL = "/images" + MetricsURL = "/metrics" ImageUploadURL = ImageURL + UPLOAD UPLOAD = ":upload" diff --git a/procima/internal/app/http/v1/metrics/routes.go b/procima/internal/app/http/v1/metrics/routes.go index d9a13e5..c1be8b3 100644 --- a/procima/internal/app/http/v1/metrics/routes.go +++ b/procima/internal/app/http/v1/metrics/routes.go @@ -6,5 +6,5 @@ import ( ) func (mc *metricsController) RegisterRoutes(router *gin.RouterGroup) { - router.POST(v1.ImageUploadURL, mc.PrometheusHandler) + router.POST(v1.MetricsURL, mc.PrometheusHandler) } diff --git a/procima/internal/bootstrap/registry/web_server.go b/procima/internal/bootstrap/registry/web_server.go index e7ff98d..1a3fb54 100644 --- a/procima/internal/bootstrap/registry/web_server.go +++ b/procima/internal/bootstrap/registry/web_server.go @@ -15,7 +15,8 @@ import ( "net/http" ) -func InitWebServer(logger loggerPkg.Logger, configPath string, metr metrics.Metrics, imgService services.ImageService) (*endpoint.WebServer, error) { +func InitWebServer(logger loggerPkg.Logger, configPath string, metr metrics.Metrics, + imgService services.ImageService) (*endpoint.WebServer, error) { cfg, err := config.LoadServerConfig(configPath) if err != nil { return nil, errors.New("failed to load server config: " + err.Error())