ipfs / kubo

An IPFS implementation in Go
https://docs.ipfs.tech/how-to/command-line-quick-start/
Other
16.14k stars 3.02k forks source link

corehttp/metrics.go: ERROR with more than one RPC API listener #9397

Open lidel opened 1 year ago

lidel commented 1 year ago

Version

0.17.0-rc1

Config

> ipfs config --json Addresses.API                                                                                                      
[
  "/ip4/127.0.0.1/tcp/5001",
  "/ip6/::1/tcp/5001"
]

Description

Daemon is ready
2022-11-10T22:46:26.286Z    ERROR   core/server corehttp/metrics.go:64  OC default registry ERROR   {"error": "cannot register the collector: duplicate metrics collector registration attempted"}

A potential fix would be to detect that metrics are already registered, and reuse the existing instance.

forgondolin commented 1 year ago

Also happening on 0.18