2.2.2.8 SelectStream (Request and Response)
The purpose of the SelectStream request is to request that the server turn on or off specified streams in the content (or current playlist entry if server-side playlists are used).
The SelectStream request, when sent via pipelined mode, is defined as an HTTP GET request that satisfies the ABNF syntax for WMS-SelectStrm-Request [RFC4234] and satisfies all of the following conditions:
The GET request uses either the HTTP 1.0 protocol, as specified in [RFC1945], or the HTTP 1.1 protocol, as specified in [RFC2616].
The GET request includes a Pragma header with the stream-switch-entry (section 2.2.1.4.27) token.
The GET request does not include the pipeline-request (section 2.2.1.4.16) token on a Pragma header.
The GET request does not include the xKeepAliveInPause (section 2.2.1.4.34) token on a Pragma header.
The GET request does not include the xPlayNextEntry (section 2.2.1.4.35) token on a Pragma header.
The GET request does not include the xPlayStrm (section 2.2.1.4.36) token on a Pragma header.
The GET request does not include the xStopStrm (section 2.2.1.4.38) token on a Pragma header.
The SelectStream request, when sent via non-pipelined mode, is defined as an HTTP POST request that satisfies the ABNF syntax for WMS-SelectStrm-Request [RFC4234] and satisfies all of the following conditions:
The POST request uses either the HTTP 1.0 protocol, as specified in [RFC1945], or the HTTP 1.1 protocol, as specified in [RFC2616].
The POST request includes a Pragma header with the stream-switch-entry (section 2.2.1.4.27) token.
The message body of the POST request is of zero length.
The POST request does not include the Content-Type header.
The POST request does not include the pipeline-request (section 2.2.1.4.16) token on a Pragma header.
The POST request does not include the xKeepAliveInPause (section 2.2.1.4.34) token on a Pragma header.
The POST request does not include the xPlayNextEntry (section 2.2.1.4.35) token on a Pragma header.
The POST request does not include the xPlayStrm (section 2.2.1.4.36) token on a Pragma header.
The POST request does not include the xStopStrm (section 2.2.1.4.38) token on a Pragma header.
The syntax of the SelectStream request is defined as WMS-SelectStrm with the additional constraint that when in pipelined mode the response will either use Chunked Transfer Coding, as specified in [RFC2616] section 3.6.1, or contain a zero length message body.
The syntax of the WMS-SelectStrm-Request:
-
WMS-SelectStrm-Request= WMS-SelectStrm-Req-Line WMS-StrmSelReq-Headers CRLF WMS-SelectStrm-Req-Line= ( "GET" / "POST" ) SP Request-URI SP HTTP-Version CRLF WMS-SelStrmReq-Headers= *( SelStrmReq-Header-REQ / SelStrmReq-Header-OPT / SelStrmReq-Pragma / HTTP-Header-Types ) SelStrmReq-Header-REQ = User-Agent ; section 2.2.1.8 SelStrmReq-Header-OPT = Cookie ; section 2.2.1.3 / Supported ; section 2.2.1.7 / X-Accept-Authentication; section 2.2.1.9 / X-Proxy-Client-Verb ; section 2.2.1.11 SelStrmReq-Pragma = "Pragma: " #SelStrmReq-Pragma-Types CRLF SelStrmReq-Pragma-Types= SelStrmReq-Token-REQ / SelStrmReq-Token-OPT / SelStrmReq-Token-OPT11 SelStrmReq-Token-REQ = client-id ; section 2.2.1.4.5 / no-cache ; section 2.2.1.4.12 / stream-switch-count ; section 2.2.1.4.26 / stream-switch-entry ; section 2.2.1.4.27 SelStrmReq-Token-OPT = client-lag ; section 2.2.1.4.6 / proxy-client-agent ; section 2.2.1.4.21 / request-context ; section 2.2.1.4.23 / xClientGuid ; section 2.2.1.4.33 SelStrmReq-Token-OPT11= version11-enabled ; section 2.2.1.4.30
The syntax of the WMS-SelectStrm-Response:
-
WMS-SelectStrm-Response= Status-Line WMS-SelStrmResp-Headers CRLF WMS-SelStrmResp-Body WMS-SelStrmResp-Headers = *( SelStrmResp-Header-REQ / SelStrmResp-Header-OPT / SelStrmResp-Pragma / HTTP-Header-Types ) SelStrmResp-Header-REQ = Cache-Control ; section 2.2.1.1 / Server ; section 2.2.1.5 SelStrmResp-Header-OPT = Set-Cookie ; section 2.2.1.6 / Supported ; section 2.2.1.7 SelStrmResp-Pragma = "Pragma: " #SelStrmResp-Pragma-Types CRLF SelStrmResp-Pragma-Types = SelStrmResp-Token-REQ / SelStrmResp-Token-OPT SelStrmResp-Token-REQ = no-cache ; section 2.2.1.4.12 SelStrmResp-Token-OPT = AccelBW ; section 2.2.1.4.1 / AccelDuration ; section 2.2.1.4.2 / BurstBW ; section 2.2.1.4.3 / BurstDuration ; section 2.2.1.4.4 / client-id ; section 2.2.1.4.5 / speed ; section 2.2.1.4.24 / timeout ; section 2.2.1.4.29 WMS-SelStrmResp-Body = *( <$D Data packet type> ); section 2.2.3.3
The following example shows a SelectStream request.
-
Accept: */* User-Agent: NSPlayer/12.0.7680.0 Host: SampleServer X-Accept-Authentication: Negotiate, NTLM, Digest, Basic Pragma: version11-enabled=11 Pragma: no-cache,rate=1.000,stream-time=0,stream-offset=4294967295:4294967295,packet-num=4294967295,max-duration=0 Pragma: xPlayStrm=1 Pragma: client-id=297067864 Pragma: LinkBW=2147483647, AccelBW=2147483647, AccelDuration=18000, Speed=869219.563 Supported: com.microsoft.wm.srvppair, com.microsoft.wm.sswitch, com.microsoft.wm.startupprofile Pragma: playlist-seek-id=44 Pragma: xClientGUID={52CB2BDB-6925-4E19-8D1D-62D10E9E2705} Pragma: stream-switch-count=1 Pragma: stream-switch-entry=ffff:1:0 Accept-Language: en-us, *;q=0.1
The following example shows a SelectStream response.
-
HTTP/1.1 200 OK Content-Type: application/x-mms-framed Server: Cougar/9.5.6001.18281 Date: Thu, 25 Feb 2010 15:06:06 GMT Pragma: no-cache, client-id=297067864, features="seekable", timeout=60000, AccelBW=3500000, AccelDuration=18000, Speed=5.000 Cache-Control: no-cache, x-wms-content-size=3923, max-age=86399, user-public, must-revalidate, proxy-public, proxy-revalidate Last-Modified: Fri, 05 Jan 2001 18:09:30 GMT Etag: "3923" Transfer-Encoding: chunked X-StartupProfile: Rate=10,12,15,20,30;MaxBytes=23,23,23,23,23;Time=0,0,0,0,0;StartTime=235;LastTime=14062;MaxDiffTime=0;MaxDiffSndTime=0;ByteRate=330,330,330,330,330; Supported: com.microsoft.wm.srvppair, com.microsoft.wm.sswitch, com.microsoft.wm.predstrm, com.microsoft.wm.fastcache, com.microsoft.wm.startupprofile