Subject: [MMUSIC] Another RTSP Connection close question

From: Aravind Narasimhan <[email-masked]>
Date: Thu, 17 Feb 2005 15:03:35 -0500

Hey folks,

rtsp-bis08, section 9.3 says the following:

> A server SHOULD NOT initiate a close of a connection directly after 
> responding to a TEARDOWN request for the whole session.

Does anybody have a suggestion for what a server SHOULD do?  Should it 
wait for the RTSP session timeout period (60s)?  That doesn't make sense 
to me because the session doesn't exist after the TEARDOWN request is 
complete.  Should it wait for 10s?  It's a random number but has its 
basis in the amount of time a client should wait before it should expect 
the server to not answer (Section 9.4).  Should the server reply back 
somehow with at header which indicates how long the server is willing to 
wait before it closes the connection?  The Session header w/ timeout 
parameter is not going to be useful, because no session would exist.

Two more issues:

    * A client may be using the same connection to control multiple RTSP
      sessions on the server.  So we need to be careful about wording
      that implicitly indicates a one-to-one relationship between
      connections and RTSP sessions where there is none.
    * What happens if a client tries to establish another RTSP session
      through the same connection while the server is about to close the
      connection.  There is a  race condition here that could
      potentially lead to incompatibilities. 

I'm of the opinion that the wording should be the following:

A server SHOULD NOT close a connection immediately after responding to a 
session-level TEARDOWN request for the last RTSP session being 
controlled through the connection.  Instead, it should wait for a 
reasonable amount of time for the client to receive the TEARDOWN 
response, take appropriate action, and initiate the connection closing.  
The server SHOULD wait a default amount of 10s after the TEARDOWN 
response to close the connection.

Alternatively,  I think it's best if the server closes the connection 
after a TEARDOWN when it realizes that the last RTSP session on the 
connection has been destroyed.

Thoughts?

Aravind

_______________________________________________
mmusic mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/mmusic

---

From: Magnus Westerlund <[email-masked]>
Date: Fri, 18 Feb 2005 17:50:00 +0100

> parameter is not going to be useful, because no session would exist.

The reason for this recommendation is to ensure that the client has time 
to setup a new session after having teardown the old one. So this time 
should give the client a decent chance to get his message through. I 
think we can follow our current rules for timing out messages. Thus I 
would say that the server should wait at least 10 seconds.

>       potentially lead to incompatibilities. 

Okay, it might require some clarification, that if the server has 
initiated a close of the TCP connection during the time the client has 
tried to send a request, the client will have to close the connection, 
set up a new one and try again. Which is what one can expect with the 
rule that the server can't close without a serious timeout with an 
outstanding request received.

> response to close the connection.

Seems good, except I would like to change the last sentence to:
"The server SHOULD wait at least 10s after the TEARDOWN response to 
close the connection.

> connection has been destroyed.

As I pointed out, there should be some guard time as proposed in the 
above sentence before the server closes the connection. In most cases, 
the client would initiate the close of the connection after having 
received the response.

Cheers

Magnus Westerlund

Multimedia Technologies, Ericsson Research EAB/TVA/A
----------------------------------------------------------------------
Ericsson AB                | Phone +46 8 4048287
Torshamsgatan 23           | Fax   +46 8 7575550
S-164 80 Stockholm, Sweden | mailto: [email-masked]