public class RequestTag extends UIDTag
accepted, noRecordUnlock, notRoutedOnwards, sourceRestarted, tracker, unlockedHandler
Constructor and Description |
---|
RequestTag(boolean isSSK,
freenet.node.RequestTag.START start,
PeerNode source,
boolean realTimeFlag,
long uid,
Node node) |
Modifier and Type | Method and Description |
---|---|
void |
completedDownstreamTransfers() |
boolean |
currentlyRoutingTo(PeerNode peer) |
int |
expectedTransfersIn(boolean ignoreLocalVsRemote,
int outwardTransfersPerInsert,
boolean forAccept)
Add up the expected transfers in.
|
int |
expectedTransfersOut(boolean ignoreLocalVsRemote,
int outwardTransfersPerInsert,
boolean forAccept)
Add up the expected transfers out.
|
void |
finishedWaitingForOpennet(PeerNode next) |
void |
handlerDisconnected() |
void |
handlerThrew(java.lang.Throwable t)
The handler threw a Throwable, i.e.
|
void |
handlerTransferBegins() |
protected void |
innerUnlock(boolean noRecordUnlock) |
boolean |
isInsert() |
boolean |
isOfferReply() |
boolean |
isSSK() |
void |
logStillPresent(java.lang.Long uid) |
protected boolean |
mustUnlock()
Caller must call innerUnlock(noRecordUnlock) immediately if this returns true.
|
void |
onAbortDownstreamTransfers(int reason,
java.lang.String desc) |
void |
senderTransferBegins(NodeCHK k,
RequestSender requestSender) |
void |
senderTransferEnds(NodeCHK key,
RequestSender requestSender) |
void |
setRejected() |
void |
setRequestSenderFinished(int status) |
void |
setSender(RequestSender rs,
boolean coalesced) |
void |
setServedFromDatastore() |
void |
waitingForOpennet(PeerNode next) |
addRoutedTo, clearWaitingForSlot, countAsSourceRestarted, currentlyFetchingOfferedKeyFrom, getSource, handlingTimeout, hasRoutedTo, hasSourceReallyRestarted, isLocal, isSource, isWaitingForSlot, maybeLogStillPresent, onRestartOrDisconnectSource, postUnlock, reassignToSelf, removeFetchingOfferedKeyFrom, removeRoutingTo, setAccepted, setNotRoutedOnwards, setWaitingForSlot, shouldStop, timedOutToHandlerButContinued, toString, unlockHandler, unlockHandler, wasLocal
public void setRequestSenderFinished(int status)
public void setSender(RequestSender rs, boolean coalesced)
protected boolean mustUnlock()
UIDTag
mustUnlock
in class UIDTag
protected final void innerUnlock(boolean noRecordUnlock)
innerUnlock
in class UIDTag
public void handlerThrew(java.lang.Throwable t)
t
- The Throwable thrown by the RequestHandler.public void setServedFromDatastore()
public void setRejected()
public void logStillPresent(java.lang.Long uid)
logStillPresent
in class UIDTag
public void onAbortDownstreamTransfers(int reason, java.lang.String desc)
public void handlerDisconnected()
public int expectedTransfersIn(boolean ignoreLocalVsRemote, int outwardTransfersPerInsert, boolean forAccept)
UIDTag
expectedTransfersIn
in class UIDTag
ignoreLocalVsRemote
- If true, pretend that the request is remote even if it's local.outwardTransfersPerInsert
- Expected number of outward transfers for an insert.forAccept
- If true, we are deciding whether to accept a request.
If false, we are deciding whether to SEND a request. We need to be more
careful for the latter than the former, to avoid unnecessary rejections
and mandatory backoffs.public int expectedTransfersOut(boolean ignoreLocalVsRemote, int outwardTransfersPerInsert, boolean forAccept)
UIDTag
expectedTransfersOut
in class UIDTag
ignoreLocalVsRemote
- If true, pretend that the request is remote even if it's local.outwardTransfersPerInsert
- Expected number of outward transfers for an insert.forAccept
- If true, we are deciding whether to accept a request.
If false, we are deciding whether to SEND a request. We need to be more
careful for the latter than the former, to avoid unnecessary rejections
and mandatory backoffs.public void completedDownstreamTransfers()
public boolean isOfferReply()
isOfferReply
in class UIDTag
public void waitingForOpennet(PeerNode next)
public void finishedWaitingForOpennet(PeerNode next)
public boolean currentlyRoutingTo(PeerNode peer)
currentlyRoutingTo
in class UIDTag
public void handlerTransferBegins()
public void senderTransferBegins(NodeCHK k, RequestSender requestSender)
public void senderTransferEnds(NodeCHK key, RequestSender requestSender)