Class StoreJob
java.lang.Object
net.i2p.router.JobImpl
net.i2p.router.networkdb.kademlia.StoreJob
- All Implemented Interfaces:
Job
- Direct Known Subclasses:
FloodfillStoreJob
Stores through this always request a reply.
Unused directly - see FloodfillStoreJob
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final Logprotected final StoreStatestatic final StringWas supported in 38, but they're now sigtype 11 which wasn't added until 39static final Stringstatic final String -
Constructor Summary
ConstructorsConstructorDescriptionStoreJob(RouterContext context, KademliaNetworkDatabaseFacade facade, Hash key, DatabaseEntry data, Job onSuccess, Job onFailure, long timeoutMs) Send a data structure to the floodfillsStoreJob(RouterContext context, KademliaNetworkDatabaseFacade facade, Hash key, DatabaseEntry data, Job onSuccess, Job onFailure, long timeoutMs, Set<Hash> toSkip) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidfail()Send totally failedgetName()Descriptive name of the taskprotected intoverridden in FSJprotected intoverridden in FSJvoidrunJob()Actually perform the task.(package private) static booleanIs it new enough?(package private) static booleanIs it new enough?(package private) static booleanIs it new enough?protected voidsucceed()Send was totally successfulMethods inherited from class net.i2p.router.JobImpl
dropped, getAddedBy, getContext, getJobId, getMadeReadyOn, getTiming, madeReady, madeReady, requeue, toString
-
Field Details
-
_log
-
_state
-
MIN_STORE_VERSION
- Since:
- 0.9.28
- See Also:
-
MIN_STORE_LS2_VERSION
- Since:
- 0.9.38
- See Also:
-
MIN_STORE_ENCLS2_VERSION
Was supported in 38, but they're now sigtype 11 which wasn't added until 39- Since:
- 0.9.39
- See Also:
-
-
Constructor Details
-
StoreJob
public StoreJob(RouterContext context, KademliaNetworkDatabaseFacade facade, Hash key, DatabaseEntry data, Job onSuccess, Job onFailure, long timeoutMs) Send a data structure to the floodfills -
StoreJob
public StoreJob(RouterContext context, KademliaNetworkDatabaseFacade facade, Hash key, DatabaseEntry data, Job onSuccess, Job onFailure, long timeoutMs, Set<Hash> toSkip) - Parameters:
toSkip- set of peer hashes of people we dont want to send the data to (e.g. we already know they have it). This can be null.
-
-
Method Details
-
getName
Description copied from interface:JobDescriptive name of the task -
runJob
public void runJob()Description copied from interface:JobActually perform the task. This call blocks until the Job is complete. -
getParallelization
protected int getParallelization()overridden in FSJ -
getRedundancy
protected int getRedundancy()overridden in FSJ -
shouldStoreTo
Is it new enough?- Since:
- 0.9.33
-
shouldStoreLS2To
Is it new enough?- Since:
- 0.9.38
-
shouldStoreEncLS2To
Is it new enough?- Since:
- 0.9.39
-
succeed
protected void succeed()Send was totally successful -
fail
protected void fail()Send totally failed
-