Streaming server and ASX

At one my clients occured the problem of all videos being played 3 times 3 times 3 times instead of just one.

After some investigation, it turned out, that for each request coming for a WMV file instead of an ASX file is returned. For example, for a request for http://stream/stream.wmv the following asx was generated:

<asx version="3.0">
    <ref href="http://stream3/stream.wmv" />
    <copyright>(c) 2008 stream</copyright>
    <ref href="http://stream1/stream.wmv" />
    <copyright>(c) 2008 stream</copyright>
    <ref href="http://stream2/stream.wmv" />
    <copyright>(c) 2008 stream</copyright>

If you read the specification for the ASX file format, this should/may be rewritten as:

      <REF HREF="http://stream3/stream.wmv" />
      <REF HREF="http://stream1/stream.wmv" />
      <REF HREF="http://stream2/stream.wmv" />
      <COPYRIGHT>(c) 2008 stream</COPYRIGHT>

This would instead of playing the three items after each other just choose the first one, that responds in a timely fashion from the list. The day is saved, the roundrobin load balancing still works as it should, and nothing plays three times three times three times.

Leave a Reply

Your email address will not be published. Required fields are marked *