Ecosyste.ms: Packages

An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

Top 1.2% on proxy.golang.org
Top 0.1% dependent packages on proxy.golang.org
Top 0.2% dependent repos on proxy.golang.org
Top 2.3% forks on proxy.golang.org
Top 0.3% docker downloads on proxy.golang.org

proxy.golang.org : github.com/libp2p/go-libp2p-pubsub

The pubsub package provides facilities for the Publish/Subscribe pattern of message propagation, also known as overlay multicast. The implementation provides topic-based pubsub, with pluggable routing algorithms. The main interface to the library is the PubSub object. You can construct this object with the following constructors: - NewFloodSub creates an instance that uses the floodsub routing algorithm. - NewGossipSub creates an instance that uses the gossipsub routing algorithm. - NewRandomSub creates an instance that uses the randomsub routing algorithm. In addition, there is a generic constructor that creates a pubsub instance with a custom PubSubRouter interface. This procedure is currently reserved for internal use within the package. Once you have constructed a PubSub instance, you need to establish some connections to your peers; the implementation relies on ambient peer discovery, leaving bootstrap and active peer discovery up to the client. To publish a message to some topic, use Publish; you don't need to be subscribed to the topic in order to publish. To subscribe to a topic, use Subscribe; this will give you a subscription interface from which new messages can be pumped.

Registry - Source - Documentation - JSON
purl: pkg:golang/github.com/libp2p/go-libp2p-pubsub
License: Apache-2.0,MIT,Apache-2.0,SSPL-1.0
Latest release: 7 months ago
First release: about 5 years ago
Namespace: github.com/libp2p
Dependent packages: 1,172
Dependent repositories: 1,640
Stars: 275 on GitHub
Forks: 140 on GitHub
Docker dependents: 152
Docker downloads: 65,890,331
See more repository details: repos.ecosyste.ms
Last synced: 3 days ago

    Loading...
    Readme
    Loading...