Open gammazero opened 1 year ago
Any reason you are using this package ? We don't want people importing parts of kubo anymore, would be nice to steer boxo into what peoples need.
Also the DHT already have bootstrap code I would use the bootstrap option on the dht directly, there are multiple implementations of bootstrap inside kubo for historic reasons I want to remove this.
Any reason you are using this package ?
This is being used to bootstrap IPNI indexers with known gateway nodes that relay pubsub messages from Filecoin storage providers announcing that new index data is available. It is necessary to maintain connections with at least some gateways in order to maintain the gossip mesh over which the messages are communicated. Seemed better to use an existing tested package that was part of go-ipfs (now kubo) that to write one that is nearly identical. The peering package is also used similarly. Both imported here: https://github.com/ipni/storetheindex/blob/main/command/daemon.go#L19-L20
Also the DHT already have bootstrap code I would use the bootstrap option on the dht directly
I am not currently using DHT in my project, and I am bootstrapping against a known set of gateway nodes that can authenticate Filecoin storage providers and relay gossip pubsub. It seems like using DHT and its bootstrapping is not what I want.
there are multiple implementations of bootstrap inside kubo for historic reasons I want to remove this.
Can I expect one to be available in boxo soon? It seems that the basic bootstrapping service should be in boxo, with the specific implementation of the Load/SaveBackupBootstrapPeers functions being provided by kubo.
Should I fork the bootstrap and the peering services and not use what is provided by kubo? Should I create a PR that moves the non-kubo-specific portions of those services into boxo?
I did not thought about the fact you would bootstrap something else than a DHT. There are no plans to move this into boxo yet, I've created https://github.com/ipfs/boxo/issues/419.
I'll look at your pull request thx.
Checklist
Installation method
built from source
Version
Config
N/A
Description
I am using the bootstrap package to establish libp2p connections to a set of hosts that I need to exchange gossip pubsub messages with. I am creating the bootstrap config using
BootstrapConfigWithPeers
. When starting the bootstrapper, with:A panic occurs when the first bootstrap round runs because these functions are not assigned in the configuration:
LoadBackupBootstrapPeers
SaveBackupBootstrapPeers
If these functions are expected to be defined, then an error should be returned from
Boosstrap
. If these functions can benil
, then they should not be called.I have created a PR to suggest a possible fix: #10029
Related discussion and issue
Issue #9876 Kubo, invalid memory address or nil pointer dereference from IpfsNode.Bootstrap