org.apache.cxf.ws.rm.soap
Class RetransmissionQueueImpl
java.lang.Object
org.apache.cxf.ws.rm.soap.RetransmissionQueueImpl
- All Implemented Interfaces:
- RetransmissionQueue
public class RetransmissionQueueImpl
- extends Object
- implements RetransmissionQueue
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RetransmissionQueueImpl
public RetransmissionQueueImpl(RMManager m)
getManager
public RMManager getManager()
setManager
public void setManager(RMManager m)
addUnacknowledged
public void addUnacknowledged(Message message)
- Description copied from interface:
RetransmissionQueue
- Accepts a new context for posible future retransmission.
- Specified by:
addUnacknowledged
in interface RetransmissionQueue
countUnacknowledged
public int countUnacknowledged(SourceSequence seq)
- Specified by:
countUnacknowledged
in interface RetransmissionQueue
- Parameters:
seq
- the sequence under consideration
- Returns:
- the number of unacknowledged messages for that sequence
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interface RetransmissionQueue
- Returns:
- true if there are no unacknowledged messages in the queue
purgeAcknowledged
public void purgeAcknowledged(SourceSequence seq)
- Purge all candidates for the given sequence that have been acknowledged.
- Specified by:
purgeAcknowledged
in interface RetransmissionQueue
- Parameters:
seq
- the sequence object.
start
public void start()
- Initiate resends.
- Specified by:
start
in interface RetransmissionQueue
stop
public void stop(SourceSequence seq)
- Stops resending messages for the specified source sequence.
- Specified by:
stop
in interface RetransmissionQueue
getExponentialBackoff
protected int getExponentialBackoff()
- Returns:
- the exponential backoff
createResendCandidate
protected RetransmissionQueueImpl.ResendCandidate createResendCandidate(Message message)
- Parameters:
message
- the message context
- Returns:
- a ResendCandidate
cacheUnacknowledged
protected RetransmissionQueueImpl.ResendCandidate cacheUnacknowledged(Message message)
- Accepts a new resend candidate.
- Parameters:
ctx
- the message context.
- Returns:
- ResendCandidate
getUnacknowledged
protected Map<String,List<RetransmissionQueueImpl.ResendCandidate>> getUnacknowledged()
- Returns:
- a map relating sequence ID to a lists of un-acknowledged messages
for that sequence
getSequenceCandidates
protected List<RetransmissionQueueImpl.ResendCandidate> getSequenceCandidates(SourceSequence seq)
- Parameters:
seq
- the sequence under consideration
- Returns:
- the list of resend candidates for that sequence
getSequenceCandidates
protected List<RetransmissionQueueImpl.ResendCandidate> getSequenceCandidates(String key)
- Parameters:
key
- the sequence identifier under consideration
- Returns:
- the list of resend candidates for that sequence
getDefaultResender
protected final RetransmissionQueueImpl.Resender getDefaultResender()
- Create default Resender logic.
- Returns:
- default Resender
replaceResender
protected void replaceResender(RetransmissionQueueImpl.Resender replacement)
- Plug in replacement resend logic (facilitates unit testing).
- Parameters:
replacement
- resend logic
getAssertion
protected JaxbAssertion<RMAssertion> getAssertion(AssertionInfo ai)
Apache CXF