import "github.com/ethersphere/swarm"
Info represents the current Swarm node's configuration
Info returns the current Swarm configuration
type Swarm struct {
// contains filtered or unexported fields
}
Swarm abstracts the complete Swarm stack
NewSwarm creates a new swarm service instance implements node.Service If mockStore is not nil, it will be used as the storage for chunk data. MockStore should be used only for testing.
APIs returns the RPC API descriptors the Swarm implementation offers implements node.Service
Protocols implements the node.Service interface
func (s *Swarm) RegisterPssProtocol(topic *pssmessage.Topic, spec *protocols.Spec, targetprotocol *p2p.Protocol, options *pss.ProtocolParams) (*pss.Protocol, error)
RegisterPssProtocol adds a devp2p protocol to the swarm node's Pss instance
Start is called when the stack is started * starts the network kademlia hive peer management * (starts netStore level 0 api) * starts DPA level 1 api (chunking -> store/retrieve requests) * (starts level 2 api) * starts http proxy server * registers url scheme handlers for bzz, etc * TODO: start subservices like sword, swear, swarmdns
implements the node.Service interface
Stop stops all component services. Implements the node.Service interface.
Path | Synopsis |
---|---|
api | |
api/client | |
api/http | A simple http server interface to Swarm |
api/http/langos | |
bmt | Package bmt provides a binary merkle tree implementation used for swarm chunk hash |
bmt/testutil | |
bzzeth | |
chunk | |
chunk/testing | |
client | |
contracts/ens | |
contracts/ens/contract | |
contracts/ens/fallback_contract | |
contracts/swap | Package swap wraps the 'swap' Ethereum smart contract. |
file | |
file/bmt | |
file/hasher | |
fuse | |
internal/build | |
internal/cmdtest | |
internal/debug | Package debug interfaces Go runtime debugging facilities. |
internal/flags | |
log | |
metrics | |
metrics/influxdb | |
network | |
network/bitvector | |
network/capability | |
network/priorityqueue | |
network/pubsubchannel | |
network/resourceusestats | |
network/retrieval | |
network/simulation | |
network/simulations | You can run this simulation using |
network/simulations/discovery | |
network/stream | |
network/stream/intervals | |
network/timeouts | |
p2p/protocols | Package protocols is an extension to p2p. |
p2p/testing | |
pot | Package pot see doc.go |
pss | Pss provides devp2p functionality for swarm nodes without the need for a direct tcp connection between them. |
pss/client | simple abstraction for implementing pss functionality |
pss/crypto | |
pss/internal/ticker | |
pss/internal/ttlset | |
pss/message | |
pss/notify | |
pss/outbox | |
pushsync | |
sctx | |
shed | Package shed provides a simple abstraction components to compose more complex operations on storage data organized in fields and indexes. |
simulation | |
spancontext | |
state | |
storage | |
storage/encryption | |
storage/feed | Package feeds defines Swarm Feeds. |
storage/feed/lookup | Package lookup defines feed lookup algorithms and provides tools to place updates so they can be found |
storage/localstore | Package localstore provides disk storage layer for Swarm Chunk persistence. |
storage/mock | Package mock defines types that are used by different implementations of mock storages. |
storage/mock/db | Package db implements a mock store that keeps all chunk data in LevelDB database. |
storage/mock/explorer | |
storage/mock/mem | Package mem implements a mock store that keeps all chunk data in memory. |
storage/mock/rpc | Package rpc implements an RPC client that connect to a centralized mock store. |
storage/mock/test | Package test provides functions that are used for testing GlobalStorer implementations. |
storage/pin | |
swap | |
swap/chain | |
swap/chain/mock | |
swap/int256 | |
testutil | |
tracing | |
version |
Package swarm imports 42 packages (graph) and is imported by 4 packages. Updated 2021-01-15. Refresh now. Tools for package owners.