- Floodfill rework part 3 of N: Send closest-to-the-key in DSRM replies

This commit is contained in:
zzz
2009-11-18 14:18:16 +00:00
parent 56e0c3e047
commit edd4d4c114

View File

@ -299,4 +299,16 @@ class FloodfillPeerSelector extends PeerSelector {
}
public int size() { return _matches; }
}
/**
* Floodfill peers only. Used only by HandleDatabaseLookupMessageJob to populate the DSRM.
*
* @param key the original key (NOT the routing key)
* @return List of Hash for the peers selected, ordered
*/
@Override
public List<Hash> selectNearest(Hash key, int maxNumRouters, Set<Hash> peersToIgnore, KBucketSet kbuckets) {
Hash rkey = _context.routingKeyGenerator().getRoutingKey(key);
return selectFloodfillParticipants(rkey, maxNumRouters, peersToIgnore, kbuckets);
}
}