April 22, 2014

Geo-location streaming load balancing for Nimble Streamer

Nimble Streamer is typically used for building robust and efficient streaming delivery infrastructure. It's used both as an origin for VOD HLS and live HLS transmission, as well as a light-weight edge re-streaming server. If viewers are distributed across the globe, a streaming provider needs to be able to balance users' requests between various edges.


UPDATEWMSPanel team released an article describing the recommended approach to load balancing for HTTP-based protocols like HLS, DASH, Icecast etc. Please use the technique described there to build your own balancing solution rather than HTTP redirect-based approach shown below.
We've created a reference balancing code for geo-location and put it under our github account. It's a PHP class with an example of its usage. Please try it for your use case.
The text below is considered obsolete.


Any Nimble Streamer instance can work as a geo-location balancer. So when the viewer's player attempts to connect to get the media stream, Nimble may check its geographical location and redirect client to new location close to client to get the content from.

Let's see an example of small streaming network with 2 active streaming servers at separate continents.

Set of servers to work with.

paris.wmspanel.com is a European location in Paris, France.
  • It provides the VOD HLS as origin from local /var/content/ directory via links like http://paris.wmspanel.com:8081/vod/filename.mp4/playlist.m3u8 .
  • Also, it has a live ABR HLS stream available via http://paris.wmspanel.com:8081/live/stream/playlist.m3u8.
Check this screenshot to see VOD setup.
Setting up VOD HLS streaming.


atlanta.wmspanel.com - North American location in Atlanta, U.S.
  • This server makes HLS re-streaming of live stream provided by paris.wmspanel.com. It also uses efficient caching to reduce latency and improve viewing user experience.
  • It also provides the VOD HLS from local /var/media/ directory via links like http://paris.wmspanel.com:8081/media/filename.mp4/playlist.m3u8 . It's a copy of VOD content located in Paris.
Set up VOD for U.S. server.
Set up edge live re-streaming for HLS.

For our example, there are users from France, Spain and Portugal who try to get VOD content from Atlanta. They need to be re-directed to Paris server and get content from there. So we need to create 3 geo redirect routes for atlanta.wmspanel.com as follows. Notice that each geo route allows specifying part of URI which you need to be processed so the other URIs won't be affected.


So after setting up 2 VOD routes, 1 live re-streaming routes and 3 geo routes we have the following picture:
Final routes setup.
Now with described configuration this streaming infrastructure may load balance visitors across two continents according to the type of streaming. You may also use DNS failover scheme which is used in this real life streaming example of our demo page streaming.

If you face any complex streaming scenarios, please contact us so we could help you propose the best usage if Nimble Streamer.

Related documentation


Nimble HTTP StreamerPay-per-view for Nimble StreamerMP4 transmuxing to HLS VOD streamingStreaming VOD with Nimble StreamerMixing multiple MPEG-TS sources into ABR HLSMPEG-TS UDP conversion to HLS with NimbleLoad balancing and failover with Nimble StreamerHDS re-streaming

No comments:

Post a Comment

If you face any specific issue or want to ask some question to our team,
PLEASE USE OUR HELPDESK

This will give much faster and precise response.
Thank you.

Note: Only a member of this blog may post a comment.