net.i2p.router.networkdb.kademlia
Class FloodSearchJob
java.lang.Object
net.i2p.router.JobImpl
net.i2p.router.networkdb.kademlia.FloodSearchJob
- All Implemented Interfaces:
- Job
- Direct Known Subclasses:
- FloodOnlySearchJob
class FloodSearchJob
- extends JobImpl
Try sending a search to some floodfill peers, but if we don't get a successful
match within half the allowed lookup time, give up and start querying through
the normal (kademlia) channels. This should cut down on spurious lookups caused
by simple delays in responses from floodfill peers
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
FloodSearchJob
public FloodSearchJob(RouterContext ctx,
FloodfillNetworkDatabaseFacade facade,
Hash key,
Job onFind,
Job onFailed,
int timeoutMs,
boolean isLease)
addDeferred
void addDeferred(Job onFind,
Job onFailed,
long timeoutMs,
boolean isLease)
getExpiration
public long getExpiration()
runJob
public void runJob()
- Description copied from interface:
Job
- Actually perform the task. This call blocks until the Job is complete.
getName
public java.lang.String getName()
- Description copied from interface:
Job
- Descriptive name of the task
getKey
Hash getKey()
decrementRemaining
void decrementRemaining()
getLookupsRemaining
int getLookupsRemaining()
failed
void failed()
success
void success()