Revert "Does not retransmit StunClientTransaction-s over TCP." because

1. The particular implementation causes us to timeout client
transactions after 200ms.
2. We can't be certain that all legs of the connection use a reliable
transport (i.e. we may be connected via TCP to a TURN server, which
talks to the other side over UDP), so we should retransmit anyway.

This reverts commit 8a7f8c1eeaa22c475ec43d9468891afbead11413.
This commit is contained in:
Boris Grozev 2015-09-30 16:55:30 -05:00
parent afd095e67a
commit 5c4ad56614

View File

@ -283,8 +283,6 @@ class ConnectivityCheckClient
tran.setApplicationData(candidatePair);
if (isReliableTransport(candidatePair))
maxRetransmissions = 0;
logger.fine(
"start check for " + candidatePair.toShortString() + " tid "
+ tran);
@ -740,20 +738,6 @@ class ConnectivityCheckClient
evt.getRemoteAddress());
}
/**
* Checks whether the transport protocol used by <tt>pair</tt> is to be
* considered reliable for the purposes of <tt>ConnectivityCheckClient</tt>,
* that is, if client transactions need to be retransmitted or not.
* @param pair the pair to check.
* @return <tt>true</tt> iff the transport protocol of <tt>pair</tt> is
* to be considered reliable and retransmissions should be disabled for
* a client transaction for <tt>pair</tt>.
*/
private boolean isReliableTransport(CandidatePair pair)
{
return pair.getLocalCandidate().getTransport() == Transport.TCP;
}
/**
* In case of a role conflict, changes the state of the agent and
* reschedules the check, in all other cases sets the corresponding peer