[Live-devel] how to define that client is died?

Ross Finlayson finlayson at live555.com
Fri Mar 30 14:19:53 PDT 2007


>I have a similar question in the case of server inactivity. What happens
>to the client if it does not receive any RTP stream for sometime from
>the server? Can RTCP info be used to signal the client to behave
>accordingly?

Yes.  Note that RTSP server implementation (e.g, as used in the 
"LIVE555 Media Server") sends send RTCP "BYE" packets when the stream 
ends, but only for media types for which 'seeking' is not supported. 
(For those media types, the server keeps the session open after the 
stream ends, in case the client wants to replay it from an earlier 
time.)

RTSP clients already interpret incoming RTCP "BYE" packets as 
signalling the end of a stream, and handle this accordingly.

However, if you want to watch for a server just 'dying', before 
signalling the end of a stream, then you could also watch for RTCP 
"SR" packets coming from the server (using the 
"RTCPInstance::setSRHandler()" function).  In most cases, though, 
this shouldn't be necessary, because if a server dies, then the RTSP 
TCP connection will also (eventually) get closed, and the client will 
detect this.
-- 

Ross Finlayson
Live Networks, Inc.
http://www.live555.com/


More information about the live-devel mailing list