Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
JukLee0ira committed Jan 21, 2025
1 parent 6bda333 commit b7516c9
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions p2p/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ var (
)

var (
activePeerGauge *metrics.Gauge = metrics.NewGauge()
// activePeerGauge *metrics.Gauge = metrics.NewGauge()
activePeerGauge = metrics.NewRegisteredGauge("p2p/peers", nil)

// general ingress/egress connection meters
// serveMeter *metrics.Meter = metrics.NewMeter()
Expand Down Expand Up @@ -61,14 +62,14 @@ var (
dialProtoHandshakeError = metrics.NewRegisteredMeter("p2p/dials/error/rlpx/proto", nil)
)

func init() {
if !metrics.Enabled() {
return
}
// func init() {
// if !metrics.Enabled() {
// return
// }

activePeerGauge = metrics.NewRegisteredGauge("p2p/peers", nil)
// activePeerGauge = metrics.NewRegisteredGauge("p2p/peers", nil)

}
// }

// markDialError matches errors that occur while setting up a dial connection
// to the corresponding meter.
Expand Down

0 comments on commit b7516c9

Please sign in to comment.