graphql-mesh
graphql-mesh copied to clipboard
How to run Prometheus with mesh start without giving an error?
🕸️ Mesh - Worker 4 💥 Error: A metric with the name graphql_mesh_fetch_duration has already been registered.
configuração
# ...
serve:
hostname: 0.0.0.0
playground: true
fork: 2
# cors:
# origin: http://localhost:4001
# ...
sources:
- name: API-V1
handler:
graphql:
endpoint: ${API_V1:http://localhost:3004/graphql}
- name: API-V2
handler:
graphql:
endpoint: ${API_V2:http://localhost:3005/graphql}
plugins:
- prometheus:
skipIntrospection: true
requestCount: true
requestSummary: true
parse: true
validate: true
contextBuilding: true
execute: true
errors: true
delegation: true
fetch: true
fetchRequestHeaders: true
fetchResponseHeaders: true
http: gateway
httpRequestHeaders: true
httpResponseHeaders: true
deprecatedFields: true
endpoint: /metrics
I get the same issue. My dependencies are as follows:
"@graphql-mesh/plugin-prometheus":` "^0.98.2",
"prom-client": "^15.1.0"