pass peer to storage
This commit is contained in:
parent
778773cb81
commit
4df538d027
1 changed files with 2 additions and 2 deletions
|
@ -48,10 +48,10 @@ type PeerStore interface {
|
||||||
//
|
//
|
||||||
// The returned Peers should strive be:
|
// The returned Peers should strive be:
|
||||||
// - as close to length equal to numWant as possible without going over
|
// - as close to length equal to numWant as possible without going over
|
||||||
// - all IPv4 or all IPv6 depending on the provided ipv6 boolean
|
// - all IPv4 or all IPv6 depending on the provided peer
|
||||||
// - if seeder is true, should ideally return more leechers than seeders
|
// - if seeder is true, should ideally return more leechers than seeders
|
||||||
// - if seeder is false, should ideally return more seeders than leechers
|
// - if seeder is false, should ideally return more seeders than leechers
|
||||||
AnnouncePeers(infoHash bittorrent.InfoHash, seeder bool, numWant int, ipv6 bool) (peers []bittorrent.Peer, err error)
|
AnnouncePeers(infoHash bittorrent.InfoHash, seeder bool, numWant int, p bittorrent.Peer) (peers []bittorrent.Peer, err error)
|
||||||
|
|
||||||
// CollectGarbage deletes all Peers from the PeerStore which are older than
|
// CollectGarbage deletes all Peers from the PeerStore which are older than
|
||||||
// the cutoff time. This function must be able to execute while other methods
|
// the cutoff time. This function must be able to execute while other methods
|
||||||
|
|
Loading…
Reference in a new issue