Posts Tagged ‘streaming’

AWS CloudFront Now Does True-Streaming

Friday, December 18th, 2009 by Francois

AWS_LOGO_RGB_300pxAmazon Web Services (AWS) recently announced that CloudFront now supports Flash streaming (RTMP) in addition to progressive downloads (HTTP). Live streaming is also expected to be rolled out at some point in 2010.

This is all being made possible by Amazon’s decision to deploy Flash Media Servers (FMS) at its 14 edge locations. The decision to go with FMS over Wowza Media Server is somewhat surprising given the fact we’ve been streaming off AWS for quite some time using Wowza Media Server for EC2 .

Even though we were really happy with the quality of service we eventually got out of this, setting it up was not a pleasant experience.

Given what I’ve just said why did we go down this route when there are plenty of content delivery networks (CDN’s) we could have used for this?

Bottom line, pricing and flexibility.

Put simply, using a CDN for true streaming (RTMP) more often that not is out of reach for low-volume publishers due to cost, long-term contracts and minimum commitments.

Hence, our decision to stream off of AWS using Wowza.

Now that CloudFront has deployed FMS we will certainly be reassessing our current set-up.

Using Amazon CloudFront for true-streaming offers low-volume publishers like us the following benefits:

  • high performance
  • reliable delivery
  • global coverage
  • ability to leverage other streaming protocols such as RTMPT, RTMPE, RTMPTE
  • no up-front commitments
  • no additional platform or licensing fees
  • no long-term contracts

We will definitely be testing CloudFront for streaming and will report back on our findings in the New Year.

Using Amazon Web Services To Deliver Online Video

Saturday, April 25th, 2009 by Francois

AWS_LOGO_RGB_300pxAfter much research and testing we have settled on two approaches for delivering video content from Amazon Web Services (AWS).

Each approach uses a different delivery protocol.

By progressive download (HTTP) using CloudFront or S3

HTTP delivery sends the entire video file upon request meaning the video arrives with the same quality at which it was encoded. However, the user will receive it only as fast as their network connection will allow.

You can get around this to a certain extent with PHP-streaming or pseudo-streaming but this still relies on a traditional web server rather than a streaming server.

By steaming (RTMP) using Wowza Media Server for EC2

When a file is streamed via a media server such as Wowza Media Server a measured stream of data is delivered to users as the video plays. Priority is given to timely delivery over aesthetic quality ensuring that the data stream continues uninterrupted, even if it means reducing quality.

Excellent or poor performance can be achieved with either delivery protocol. And in most cases, the user cannot tell whether the video they’re watching is downloading or streaming.

Why set up both on AWS?

HTTP:

  • is what S3 and CloudFront are all about
  • is suitable for videos of a short duration
  • is suitable for delivering high-bit rate encodings
  • is suitable if end-users need/are allowed to keep a copy of the video on their own computers

RTMP:

  • we had the in-house technical resources to configure and set this up
  • we needed a suitable delivery protocol for longer form content
  • we wanted to enable interactive functionaliy between the playback client and media server
  • we wanted greater statistical granularity
  • we wanted greater control over access rights to videos

We would never stick out our neck out and say that one delivery protocol was better than the other.

But we will say that they each have their own pro’s and con’s and having the option to choose between the two was critical for us.

There is no doubt that HTTP is a doddle to set-up.

Wowza for EC2 is amazingly well supported via the Wowza forums but it is still a bit of a challenge.

So our advice would be if your looking for the best of both worlds definitely look into the approaches outlined above but if you’re looking for a quick and easy way to offload your video delivery (or any other heavy assets) stick to S3/CloudFront you won’t be disappointed.

JW Player, S3, Wowza and “Stream not found” error for files that have spaces in filename

Monday, February 23rd, 2009 by The BCM Team

When working on an application that streams videos from S3 I noticed that whenever an s3 object has a space in its name it fails to stream.

However, when streaming objects without spaces in the name it works fine.

The solution is as follows:

I am using PHP and JW Player 4.3. The problem is due to JW player not encoding url when rtmp:// protocol is used (specifically in RTMPTModel.as file). So to fix the problem with playing files that have spaces you need to either:

  • Replace spaces with “+” and urlencode() the whole url after that. For example:
    
    urlencode("mp4:amazons3//file+name+with+spaces.m4v");
    
  • Double urlencode() the whole url. For example:
    
    urlencode(urlencode("mp4:amazons3//file name with spaces.m4v"));