modulepackage
0.4.0
Repository: https://github.com/libp2p/go-libp2p-connmgr.git
Documentation: pkg.go.dev
# README
DEPRECATION NOTICE
This package has moved into go-libp2p as a sub-package, github.com/libp2p/go-libp2p/p2p/net/connmgr
.
go-libp2p-connmgr
==================
A package to help manage connections in go-libp2p.
Table of Contents
Install
go get github.com/libp2p/go-libp2p-connmgr
Contribute
PRs are welcome!
Small note: If editing the Readme, please conform to the standard-readme specification.
License
MIT © Whyrusleeping
The last gx published version of this module was: 0.3.34: QmSTKY2v62v9RjcfTMCFKMVAWvVjWGixkYWEi68iG7e1TT
# Functions
DecayerConfig applies a configuration for the decayer.
NewConnManager creates a new BasicConnMgr with the provided params: lo and hi are watermarks governing the number of connections that'll be maintained.
NewDecayer creates a new decaying tag registry.
WithEmergencyTrim is an option to enable trimming connections on memory emergency.
WithGracePeriod sets the grace period.
WithSilencePeriod sets the silence period.
# Type aliases
BasicConnMgr is a ConnManager that trims connections whenever the count exceeds the high watermark.
DecayerCfg is the configuration object for the Decayer.
Option represents an option for the basic connection manager.