Skip to content

Commit

Permalink
fix: track graphql errors in metrics (#136)
Browse files Browse the repository at this point in the history
  • Loading branch information
StarpTech authored Sep 28, 2023
1 parent 9b2fe7b commit db26994
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions router/core/router.go
Original file line number Diff line number Diff line change
Expand Up @@ -600,12 +600,12 @@ func (r *Router) newServer(ctx context.Context, routerConfig *nodev1.RouterConfi
subChiRouter.Use(traceHandler.Handler)
}

subChiRouter.Use(graphqlPreHandler.Handler)

if metricHandler != nil {
subChiRouter.Use(metricHandler.Handler)
}

subChiRouter.Use(graphqlPreHandler.Handler)

subgraphs := make([]Subgraph, len(routerConfig.Subgraphs))
for _, s := range routerConfig.Subgraphs {
parsedURL, err := url.Parse(s.RoutingUrl)
Expand Down

0 comments on commit db26994

Please sign in to comment.