Skip to content

Commit

Permalink
Disable MetricsMiddleware (#149)
Browse files Browse the repository at this point in the history
Co-authored-by: James Kwon <[email protected]>
  • Loading branch information
james03160927 and james03160927 authored Jan 22, 2025
1 parent ae9921f commit 0a9d37d
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions server/server.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
package server

import (
monitoring "cloud.google.com/go/monitoring/apiv3/v2"
"context"
"fmt"
"github.com/labstack/echo/v4"
labstack_middleware "github.com/labstack/echo/v4/middleware"
"github.com/newrelic/go-agent/v3/integrations/nrecho-v4"
"github.com/newrelic/go-agent/v3/newrelic"
"github.com/rs/zerolog/log"
"registry-backend/config"
generated "registry-backend/drip"
"registry-backend/ent"
Expand All @@ -16,14 +22,6 @@ import (
"registry-backend/server/middleware"
"registry-backend/server/middleware/authentication"
drip_authorization "registry-backend/server/middleware/authorization"
"registry-backend/server/middleware/metric"

monitoring "cloud.google.com/go/monitoring/apiv3/v2"
"github.com/labstack/echo/v4"
labstack_middleware "github.com/labstack/echo/v4/middleware"
"github.com/newrelic/go-agent/v3/integrations/nrecho-v4"
"github.com/newrelic/go-agent/v3/newrelic"
"github.com/rs/zerolog/log"
)

type ServerDependencies struct {
Expand Down Expand Up @@ -125,7 +123,7 @@ func (s *Server) Start() error {
}))
e.Use(middleware.RequestLoggerMiddleware())
e.Use(middleware.ResponseLoggerMiddleware())
e.Use(metric.MetricsMiddleware(&s.Dependencies.MonitoringClient, s.Config))
//e.Use(metric.MetricsMiddleware(&s.Dependencies.MonitoringClient, s.Config))
e.Use(authentication.FirebaseAuthMiddleware(s.Client))
e.Use(authentication.ServiceAccountAuthMiddleware())
e.Use(authentication.JWTAdminAuthMiddleware(s.Client, s.Config.JWTSecret))
Expand Down

0 comments on commit 0a9d37d

Please sign in to comment.