28 Jul 2011

HTTP Dynamic Streaming – Part 2: Late-Binding Audio Using OSMF

Part 1 of this series discussed HTTP Dynamic Streaming (HDS) at a fairly high level. The next few editions in the series will explore some of the more powerful features that make using this protocol advantageous. Multi-bitrate stream switching and file encryption are two important features that we’ll cover in the very near future, as they’re very big reasons to stream over any protocol. However, in this article I’d like to discuss a brand new feature of the Open Source Media Framework (OSMF) known as “late-binding audio”.

read more
Share this
19 Dec 2008

Video Delivery Solution Analysis

Executive Summary
The manner of delivering a video file to a customer can greatly influence the perceived quality of and experience using a video delivery application. Therefore, the selection of a content delivery network (CDN) partner is among the most important decisions to be made during the application development phase.

This document aggregates the research compiled during CDN analysis for a particular sample project and is based upon research from the companies’ web sites as well as extensive phone conversations. The conclusions reached in terms of a recommended CDN partner are therefore appropriate for the sample project only as bid out in Q4 2008. If another scope of work was evaluated, RealEyes Media’s provider recommendation may be different.

The recommended CDN for the sample project is Level 3. This provider partner is the best value for the customer, including mirrored Origin Storage, 100% uptime guarantee, and a caching option in which video content would never fall out of cache due to viewership levels. In addition, Level 3 owns the most extensive fiber backbone in the United States as well as many of the patents underlying video streaming technology.

Sample Project Overview

  • 5,000 – 10,000 hours of video content in library (10,000 – 20,000 separate video files)
  • Each viewing module would be approximately 30 minutes in length
  • Approximately 5,000 application users, each viewing up to 4 hours of content daily
  • Multi-bitrate delivery strategy will be employed, using three files, averaging 500kbps
  • Users may have low bandwidth constraints, or may be offline at the time of viewing a video. Therefore, a download option is available in addition to a streaming option
  • Digital Rights Management (DRM) protection will be applied to downloaded files. It is assumed in this analysis that the client already has the Adobe Digital Rights Management Server
  • The project may require a desktop delivery option as well as a web-based delivery application.
  • Principally US based viewing audience

Content Delivery Standards
The development paradigm chosen will give use the option to either stream video content or to download this content to their own computers and view independent of an internet connection. Based upon this development direction, content delivery standards and CDN delivery goals have been established for this project. These goals were used when selecting which CDN partners to include as part of this analysis process.

CDN-Specific Delivery Goals

  • Adobe Flash Video Streaming Solution (FVSS) Partner
    – Built-in load balancing and failover to scale video even in the heaviest traffic
    – Video streaming that starts the instant viewers click Play
    – A high-performance network that helps ensure that video isn’t hung up on the Internet
    – Automatic tracking and report generation at the click of a button
    – Flexible bandwidth and storage based on client needs
  • Migration to next generation FMS server (FMS 3.5) By Q2 2009
    – Automatic multi-bitrate streaming delivery
  • Download and streaming options
    – Preferable that these options be at the same rate and plan structure.
    – Supports DRM protection for downloaded files.
  • Origin Storage provider
    – 99.99% + uptime guarantee
    – Content in Origin Storage housed inside CDN’s own network
    – Preferable that Origin Storage be stored in more than one geographic location.
  • Own or lease dedicated network bandwidth
    – First-tier U.S. network, with strong international presence.
  • Content reporting tools

Solution Recommendation
To execute the stated Delivery Goals, RealEyes recommends that a top-tier CDN that specializes in Flash Video Streaming (and gives both download and streaming content options for FVS). Video files will be encoded at three different bitrates (low, medium, and high) with an average bitrate of 500kbps. These files will be protected using Digital Rights Management (DRM).

Content Delivery Network Inclusion Criteria
RealEyes has vetted four industry-leading content delivery networks (CDNs) for the purposes of this analysis: Akamai, Level 3, Limelight, and Streaming Media Hosting. The analysis for each is included below, followed by RealEyes Media’s recommendation for a CDN partner organization for the project outlined.

CDN Qualifications
All four of these companies are leading CDN providers with distinct delivery solution models. Each of them is a high-quality company that would be a good choice for this video delivery project. Additionally, all of these CDNs and share the following qualifications that were essential for inclusion in our analysis group.

Adobe Flash Video Streaming Solution (FVSS) Partner
As an FVSS Partner, these CDNs have a specialization in streaming Flash content. Additionally, their close partnership with Adobe provides them access to the newest software advances and Adobe engineers if needed. All FVSS providers offer the following capabilities to help ensure the best delivery for Flash Player compatible video content: Built-in load balancing and failover to scale video even in the heaviest traffic; Video streaming that starts the instant viewers click Play; A high-performance network that helps ensure that video isn’t hung up on the Internet; Automatic tracking and report generation at the click of a button; Flexible bandwidth and storage based on client needs.

Migration To Next Generation FMS Server Before Application Launch
Video streams over RTMP from intended future releases of Flash Media Server can dynamically change bitrate as network conditions change. Quality of Service metrics, exposed via ActionScript and providing real-time network or CPU information, allow developers to take control of the video playback and adjust the streaming experience accordingly. This feature is part of Flash Player 10 but will only be available with intended future releases of Flash Media Server. Flash Player 10 now supports dynamic switching between media with different audio sampling rates as well. 1,2

Own or Lease Dedicated Network Bandwidth
When a user requests a video file, it is important that it is available right away. Dedicated bandwidth agreements or backbone network ownership ensures that the CDN can bypass general internet traffic to get video content to users as quickly as possible.

Download and Streaming Delivery Options
To meet the requirements for this project, all considered CDN partners must be able to deliver videos via download or streaming methods with equal efficiency. These four CDN partners also do not differentiate between pricing for downloaded vs. streaming video content in their CDN.

Origin Storage Provider
Origin Storage will allow a client to place video content within the CDN’s own network so that it can be accessed by the edge servers more quickly than if it were hosted outside the CDN’s network. All of these CDN providers have a dedicated 10GBps connection out from their Origin Storage (10-100 times faster than from outside the network) to the edge servers. For the purposes of this document, Origin Storage and Net Storage are grouped together as providers use these terms to describe similar solutions.

Content Reporting Tools
All of these companies have tools that can determine how video content is being accessed. As we have not established any specialized reporting requirements for this project that would require special investigation from CDN providers and RealEyes does not feel that reporting tools will provide a clear differentiation of service, a full analysis of these tools is not given in this document.

Akamai
Akamai is the largest CDN in the world – in seven visits to the Internet, a user will view at least one asset (graphic, video, or other file) hosted on the Akamai network. This network prowess, coupled with the company’s proprietary software offerings (such as StreamOS), makes Akamai the undisputed industry leader in content delivery.

akami_logoAkamai pioneered the content delivery market a decade ago, and today its services have been adopted by the world’s most recognized brands across diverse industries including:3

  • Large on-line educators Plateau Systems, Learn.com, Rosetta Stone, Outside the Classroom, Englishtown, Columbia Video Network
  • Many of the largest on-line media companies including ESPN.com, MLB.com, MTV, Fox, NBA and Travel Channel
  • 5 of the top 6 online music sites
  • 6 of the top 10 Global 500 companies and six of the top 10 Fortune 500 companies
  • Top 5 internet portals including Google, Yahoo and MSN.
  • More than half of Internet Retailer Top 50 retailers
  • 7 of top 10 global marketers
  • 8 of the world’s top 10 automakers
  • Over 70 of the world’s leading financial institutio
  • All branches of the US military

Serving hundreds of gigabits per second of FLV traffic daily, Akamai is a premier authorized FVSS provider. Akamai’s intelligent routing dynamically transports streams along routes that avoid Internet congestion while proprietary mapping technology identifies an optimal streaming server for each individual viewer or listener. Load balancing ensures that only streaming servers with available resources are chosen to fulfill user requests.4

Network
Akamai Streaming utilizes Akamai’s proprietary streaming technology and the world’s largest fault-tolerant network to deliver both live and on demand streaming media. The service transfers original streams to Akamai’s massive, globally distributed network of servers, resulting in a lossless stream delivered from the edge of the Internet every time.5 Akamai has dedicated usage agreements with backbone network as well as local internet providers to ensure that 90% of Internet users are one “hop” or less from an Akamai Edge server.6 No Full Network Map Available.

Points of Presence (POPs)
The Akamai Platform has over 34,000 servers in 950 networks deployed in 70 countries in their network, makingthem the largest CDN with the most robust presence footprint globally.7 This platform allows Akamai to deliver cached content up to eight times faster than a traditional web server.

Origin Storage
Akamai terms their particular flavor of Origin Storage as “Net Storage.” In this report, the two terms will be used interchangeably when comparing offerings across CDN providers. To Akamai, the Origin Server would be the server from which the customer uploads the video content to the Akamai network.

To use EdgeSuite NetStorage, Akamai customers simply upload their content to a designated directory. As soon as the upload is complete, NetStorage replicates the content to ensure availability, placing additional copies of your files at two of Akamai’s many worldwide storage centers. These delivery services make use of the Akamai Platform, a massive, distributed global network of servers that work together to intelligently place content close to Web users. Then, EdgeSuite Global Traffic Management determines the optimal storage location (storage center or edge server) from which to pull fresh content.8

Uploaded content is replicated across multiple Akamai storage centers in different locations and within different networks. This ensures fault tolerance for both high performance and high reliability. Content is replicated immediately after file upload to ensure consistency across servers. Upon deletion, it is automatically purged from all storage centers.9

origin_storage

Caching & Delivery
Akamai HTTP Downloads helps you deliver large-file downloads quickly and reliably to users anywhere in the world, in real time or through scheduled downloads. Whether the files are multi-gigabyte software files or video images, the Akamai Edge Platform handles your downloads – scaling on demand, optimizing delivery paths, and providing accurate tracking and reporting on completion rates.10

One of the key features of Akamai’s delivery system as it pertains to the sample video delivery project is Akamai’s Large File Download Optimization. Leveraging the distributed global Akamai network, this unique capability significantly enhances download performance for end users who are downloading large multi-gigabyte files. The key technology behind Large File Download Optimization is a system for storing, retrieving, and delivering large files as a cluster of individual file pieces. This enables you to increase file sizes in response to market demand, while in parallel providing a quicker, more seamless download experience for the end-user.11

Akamai has developed SureRoute, technology that would help to route video file delivery to users by employing the most effective (fastest) possible route. SureRoute identifies alternate paths over which an Akamai edge server can communicate with a customer’s origin server and uses these alternatives to either improve the performance of the connection, or to provide for failover in the event that a direct path is congested or otherwise unavailable. When an Akamai edge server contacts the origin server, the “direct” path typically is a route obtained through BGP (Border Gateway Protocol). When SureRoute is used, alternate paths to the origin server are accessed, for example, by sending a request from the Akamai edge server to other Akamai servers, which then issue their own requests to the origin. Based on real-time performance measurements of HTTP download, latency, and loss frequency, SureRoute may use an alternate path to communicate between an edge server and the origin if it can bypass network congestion.12

sure_route

SureRoute is used to optimize communication between edge servers and the origin server. SureRoute chooses the most optimal path to the origin to ensure that a site is continuously accessible and that dynamic content is delivered to end users via the optimal path. SureRoute enables an Akamai edge server to obtain content from a customer origin server through the Akamai network via an optimal Akamai server near the origin. Inside the Akamai network, proprietary techniques are being used to accelerate the content delivery and avoid Internet congestion points and unnecessarily long routes. An optimal path between the origin site and edge server is selected based on real-time data collected by Akamai – based on this data, it may be direct (as recommended by BGP), or indirect through an intermediary Akamai edge server.

StreamOS
This robust management tool helps to control access to and distribution of their video content. As the breadth of this tool is unique in the CMS industry, RealEyes is including it in this analysis.

Akamai Stream OS is an enterprise solution that simplifies rich media management and offers flexible tools to control content and enforce business policies. Together with the Akamai Media Delivery solution, Stream OS helps companies aggregate more impressions across the Internet through controlled syndication while lowering the total cost of distribution, and ensuring the highest quality experience for audiences regardless of scale, geography, format, or device.13

  • Content Manager: This easy-to-use drag-and-drop upload and check-in procedure uploads your content and distributes it via the global Akamai network so it’s ready for immediate playback over the best- performing connections and paths on the Internet. Simply cut and paste the URL onto your Web page and your media file is ready to go.14
  • RSS Manager: Capture on-the-go audiences with easy-to-create Podcasts. Simply create content, upload it to Akamai Stream OS, create an RSS feed, and publish it to your Web site or other locations such as iTunes or Yahoo! Podcasts. Akamai Podcasting has the flexibility to support many types of content—downloads, live streaming, or on-demand streaming.15
  • Profile: Control access and target on-demand and live streaming and downloadable content delivered over the Akamai global network. Apply and prioritize business rules to deliver your media online.16
  • Enterprise Manager: Media businesses supporting multiple groups that all need to manage, publish and distribute their own content can reduce operational complexity with Akamai Enterprise Manager. This Web-based application lets you create multiple sub-accounts under one main administrative group and manage all content and processes via a single portal, while providing sub-account administration and reporting to enable autonomy and simplify multi-department billing policies.17

Pricing Overview
Although pricing figures will not be presented for any of the companies included in this analysis document, RealEyes has chosen to indicate how the company’s pricing for the sample project compared with the other companies in this analysis. Based upon the constants discussed in the CDN Price comparison section, Akamai ranked third, meaning that only one company was more expensive than Akamai.

Level 3
Level 3 Communications has integrated Flash Media Servers into its CDN platform. Level 3 Flash Video Streaming provides high-performance solutions for Flash Player compatible on-demand and live video. The service is offered globally and delivered over the Level 3 Internet backbone, one of the world’s largest and most connected IP networks.

Each day, the Level 3 network carries 70% of the United States’ internet traffic.18 The company also has strong network performance and invests in unprecedented network scale. Although Level 3 is seen as a newcomer in the CDN space, it has acquired two of the oldest CDN companies, Savvis and Sand Piper, along with their engineering teams and technology patents.19 This unique combination of assets, engineering innovation, and portfolio allows Level 3 to offer a cost-effective and powerful solution.

Level 3 is the provider of choice to many of the world’s most sophisticated communications customers: 20

  • 19 of the world’s top 20 telecom companies
  • 9 of the 10 largest telecom carriers in Europe
  • 9 of the top 10 U.S. Internet Service Providers (ISPs)
  • Top U.S. cable companies
  • 3 of the top 4 telecom companies in Asia
  • 4 of the top 5 U.S. Wireless Service Providers

Additionally, Level 3 was the CDN selected to stream the 2008 Democratic and Republican Conventions, as well as the Presidential debates as seen on CNN.

Network
One distinct business differentiation for Level 3 is that they own their own fiber network (backbone), other CDN companies such as Limelight and Streaming Media Hosting, rent dedicated transfer on this same network (and others such as AT&T, etc.).21 This means that Level 3 is not marking up the cost of using their network, which is why their rates are so competitive.

l3_network

Points of Presence (POPs)
Additionally, the Level 3 network points of presence (POPs) are an excellent fit for a project with a mainly US- based audience. The Level 3 network continuously monitors internal traffic to determine which POP caching site, or Origin Storage site will provide the fastest response time for a user so streaming can begin immediately.22

l3_pops

Origin Storage
Files uploaded to Level 3 Origin Storage (green dots in the POP map above) are automatically redundantly stored on geographically diverse servers in the United States. This allows for faster file access and optimized network traffic when users want to access your video files. Their Origin Storage super nodes are directly attached to dedicated serving clusters and the Level 3 Network through 10 GigE connections. By the end of 2008, Level 3 will have 1.2PB (1200TB) of dedicated CDN storage and you pay for only what you use.23 Level 3 is one of the few companies who guarantee that your files will be available 100% of the time after they are uploaded.24

Level 3 also offers an API to integrate with any custom file or encoding management program that a customer would use to encode video files – allowing for a more automated process of uploading content to the CDN.25

Caching & Delivery
Based on caching and download delivery models and features, Level 3 supports multiple holistic methods and implementations for content delivery, providing flexibility in designing compatible customer workflows.

When paired with Origin Storage, the basic workflow would be: customer uploads content (via push or pull) to Level 3 Origin Storage servers within the Level 3 CDN. In turn, the CDN feeds the edge delivery network without adversely impacting your infrastructure. This option is particularly useful for customers with a well-defined set of popular content and an interest in outsourcing the origin infrastructure. Content will remain in the edge cache for a few weeks, and fall out if not accessed during this time period.

Another delivery option, and one unique among the CDNs in this analysis is the Level 3 Content Delivery for Extended Libraries.26 In this scenario, a customer uploads a large library of content (via push or pull) to Origin Storage. Then Level 3 applies advanced intelligence to redirect requests to the optimal path from storage to the end user based on the popularity of the object at the time of the request. This option is designed for customers with “long-tail” assets or content with dynamic popularity profiles. With the Extended Library option, a file will never fall out of the cache, perfect for content that rarely changes.

l3_caching_delivery

RealEyes prefers the Level 3 Content Delivery of Extended Libraries (“long-tail”) solution for the sample project as it was noted that the majority of the users will be watching the same video files during a relatively short time period (over a few days or weeks). A smaller number of users will consistently be viewing content that is not part of whatwould be cached by the majority, however. With a traditional caching system, this small (but significant) This “long-tail” solution allows this highly-viewed content to be cached at the very edge of the “cloud” while content that is losing popularity is delivered from locations closer to the Origin Server while still providing end users the quality experience. Intelligent algorithms instantly detect a change in popularity, and populate the edge caches with the relevant files. It’s an automatic service that will substantially increase end user experience.

Pricing Overview
Although pricing figures will not be presented for any of the companies included in this analysis document, RealEyes has chosen to indicate how the company’s pricing for the sample project compared with the other companies in this analysis. Based upon the constants discussed in the CDN Price comparison section, Level 3 ranked first, meaning that it was the least expensive (the CDXL solution was marginally more expensive than Limelight’s basic solution as the overall bandwidth commitment increased).

limelightLimelight
Limelight Networks’ Content Delivery Network is built to support global distributed delivery of rich media to audiences of any size. Limelight is an efficient high-performance delivery provider for large libraries, large files and large audiences. The infrastructure is designed to deliver media and entertainment content to a complete range of IP-enabled devices, like cell phones, music players, game consoles and other devices.

The design the Limelight network is massively scalable. With over 1 terabit per second raw egress available, and dedicated network usage rights, Limelight can bypass the public internet traffic to deliver lessons with minimal wait and at the fastest download speed the customer’s machine will accept.27

More than 1300 companies rely on Limelight Networks including28:

  • Microsoft
  • MSNBC
  • Amazon
  • DreamWorks
  • EA Games

Network
The innovative Limelight CDN starts with thousands of servers deployed around the world, interconnected via a dedicated high-speed fiber-optic network. Limelight connects to more than 900 access networks throughout the world, often with dedicated bandwidth agreements.29 No full network map is available.

Points of Presence (POPs)
Limelight’s CDN spans the globe with a dedicated high-speed fiber-optic backbone, and regional content delivery centers use a multi-tiered cache architecture to store content for immediate access. Large-scale data centers at each POP ensure that requested content delivery is reliable and quick.30

limelight_pops

Origin Storage
Limelight Networks would provide a dedicated server for Origin Storage requiring 1TB plus of storage, as would be the case in the sample project. As this server will be within the Limelight network, when files need to be pulled from Origin Storage to the edge cache, it will be done quickly and efficiently. Limelight provides various options for placing content on this server including HTTP, FTP, sFTP, and Aspera, depending on your security and performance requirements.31

Caching & Delivery
Limelight Content Delivery uses a local caching scheme with several specialized rules to provide the optimal balance between content freshness and network usage. The rules are as follows: 1. Freshness checks are performed through “Last-Modified” HTTP request calls to determine if the file is 20% older than it was when last checked. 2. If the content has been in cache for more than 3 days, the cache will check for freshness. Because the Limelight Network cache is so large, files can stay cached in the system for days or weeks, instead of minutes or hours as is common with other CDN providers. Limelight Content Delivery also honors content expiration headers specified by the origin server.32

The workflow for delivering content via the Limelight CDN: Using an FTP account and a special customer URL prepend variable, the customer would upload video files to the Limelight Networks HTTP Origin Server. The uploaded content would then be placed in the cache the first time it is requested by a user and released from the cache using the caching rules stated above.

Limelight Networks also offers a security option that protects your content from unauthorized access. With MediaVault a protected URL is associated with each user and/or each request as part of the download URL. This helps to prevent abuse from spiders, bots, and deep linking. Additional MediaVault controls include settings for start and stop dates/times, perfect for time-sensitive content. While this type of protection is an asset, another way to secure content similarly is to prohibit video files from being viewed outside of a custom video player. This is the model that was chosen for the sample project.

Pricing Overview
Although pricing figures will not be presented for any of the companies included in this analysis document, RealEyes has chosen to indicate how the company’s pricing for the sample project compared with the other companies in this analysis. Based upon the constants discussed in the CDN Price comparison section, Limelight ranked second, meaning that only one company was less expensive.

streaming_media_hostingStreaming Media Hosting
Streaming Media Hosting provides content delivery services for thousands of businesses and consumers worldwide. Streaming Media Hosting’s proprietary technologies provide customers with advanced capabilities to manage, deliver and monitor audio, video, and multimedia content over the Internet.

Streaming Media Hosting’s particular marketplace advantage is superior customer service for small to medium sized businesses. Their company is small enough to be able to react to each customer’s business needs with individual attention, creating custom solutions that are not always possible with larger providers. They pride themselves on being quick and nimble, providing excellent quality media hosting, with the utmost in integrity and customer service.33

Of particular note is that Streaming Media Hosting does business with many faith-based organizations around the world including The Lutheran Hour Ministries, Christian International, The Louisiana & Oklahoma Baptist Conventions, and The Arch Diocese.34 As part of their commitment to faith-based communities, Streaming Media Hosting does not house any adult content on its servers, nor does it stream any such content via its CDN.35

Streaming Media Hosting’s clients range from Fortune 500 to small businesses including:36

  • The Tennis Channel
  • McGraw/Hill
  • ASPCA
  • The Lutheran Hour Ministries
  • Harrah’s Entertainment

Network
With direct access to the backbones of the world’s leading carriers, Streaming Media Hosting has agreements with tier-one network providers including Level 3 and Global Crossing.37 Through these relationships, Streaming Media Hosting consistently delivers the quality of service required by the most performance sensitive applications. Streaming Media Hosting’s Origin Storage and primary data center is located in Anaheim, California.38 No full network map is available.

Points of Presence (POPs)
Streaming Media Hosting has two “Super POPs: a highly-sophisticated $50M Data Center in California (15 network data providers funnel in to this one location, each with a 10GBps pipeline); and a presence in Ashburn, Virginia. Using these two POPs, Streaming Media Hosting is able to minimize hops from their Data Centers to the internet backbone.39 No map showing POP locations is available.

Origin Storage
Streaming Media Hosting provides origin storage at their Data Centers.40

Caching & Delivery
The workflow for delivering content via the Streaming Media Hosting CDN: Using an FTP account, the customer would upload video files to the Streaming Media Hosting HTTP Origin Server. The content would then be placed in the cache the first time it is requested by a user and eventually released from the cache.

Pricing Overview
Although pricing figures will not be presented for any of the companies included in this analysis document, RealEyes has chosen to indicate how the company’s pricing for the sample project compared with the other companies in this analysis. Based upon the constants discussed in the CDN Price comparison section, Streaming Media Hosting ranked fourth, meaning that this was the most expensive option.

  • Videos average 30 minutes in length
  • Total of 140,000 video views per month
  • Videos average a bitrate of 500kbps
  • Total transfer / month = 156,000 GB
  • Total video storage needs = 1TB

Price Comparison Listing
The following pricing matrix includes relative costs as communicated to RealEyes Media in our conversations with the CDN providers related for the project outlined in the Pricing Constraints section.

  1. Level 3 – Least Expensive
  2. Limelight
  3. Akamai
  4. Streaming Media Hosting – Most Expensive

Content Delivery Network Recommendation
RealEyes Media recommended the Extended Library option from Level 3 for the example video delivery project. This service offering is not only of the highest quality, it is the best match for the client’s needs for this project and comes at a very reasonable price point. In short, it is the best value for the expenditure.

Company Match
Level 3 built one of the world’s largest and most connected IP network backbones. Each day, the Level 3 network carries 70% of the United States’ internet traffic. The company also has strong network performance and invests in unprecedented network scale.

Although Level 3 is seen as a newcomer in the CDN space, it has acquired two of the oldest CDN companies, Savvis and Sand Piper, along with their engineering teams and technology patents. This unique combination of assets, engineering innovation, and portfolio allows Level 3 to offer a cost-effective and powerful solution.

Level 3 is poised to become a market-leading CDN, alongside Akamai. In RealEyes’ estimation, this is a great time to establish a relationship with Level 3 to lock in favorable rates.

Product Offering Match
The Extended Library Option from Level 3 ensures that once a video file is within the Level 3 cache that it will not fall out of cache without explicit intervention (administratively, or updating the file with a newer version). This option is typically only available with CDN providers that are twice as expensive. Having the file within the cache gives the fastest, best file access experience to all users.

Additionally, Level 3 offers superior origin storage options – only Akamai’s are more robust. Files that are placed in Level 3 Origin Storage are automatically placed on two, geographically separate servers (east and west coasts US). This mirroring backs up Level 3’s guarantee of 100% uptime and allows for efficiencies when a file does need to be pulled from Origin Storage.

What Level 3 does not include in its pricing is as important as what is – you are not paying for management tools that are CDN-specific (meaning that moving to a different CDN in the future would be more difficult) and contain features geared for advertising and live events – situations that are not within the example application’s intended use cases. Level 3 provides programmatic access to the tools that it does offer, allowing a client to easily integrate custom administrative services.

Network Match
Level 3 owns the network on which many of the other CDN providers included in this analysis lease space. Not only is this cost savings passed through to Level 3 customers, Level 3 can provide the best, most optimized path through the backbone for their CDN customers.

Alternate Recommendation: Akamai
Akamai is the undisputed leader in the CDN space, and would certainly be an excellent choice for a CDN partner for any client and this project. RealEyes chose not to place our primary recommendation with Akamai as the large difference in cost does not justify the additional administrative services, which may not provide much incremental value to this project in particular.

Citations:

  1. Adobe Edge Newsletter, August 2008 http://www.adobe.com/newsletters/edge/august2008/articles/article2/index.html?trackingid=DLFXH
  2. Where available, citations have been given to support the research presented herein; however, many of the statistics and descriptions provided
  3. arethe result of many hours of telephone meetings with each of the networks included in this analysis and are not cited.
  4. Akamai email; however, a public client listing is available at http://www.akamai.com/html/customers/index.html
  5. Akamai Media Delivery Streaming, http://www.akamai.com/dl/feature_sheets/Akamai_media_streaming.pdf
  6. Akamai Media Delivery Streaming, http://www.akamai.com/dl/feature_sheets/Akamai_media_streaming.pdf
  7. Akamai phone conversation.
  8. Akamai Facts and Figures, http://www.akamai.com/html/about/facts_figures.html
  9. Akamai EdgeSuite® Net Storage, http://www.akamai.com/dl/feature_sheets/FS_NetStorage.pdf
  10. Akamai Net Storage, http://www.akamai.com/html/technology/products/netstorage.html
  11. Akamai HTTP Downloads, http://www.akamai.com/html/technology/products/http_downloads.html
  12. Akamai HTTP Downloads, http://www.akamai.com/html/technology/products/http_downloads.html 12
  13. Transform the Internet into a Business-Ready Application Delivery Platform for Enterprise SOA based SAP Deployments,
  14. https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/406cc24a-cf60-2a10-58ab-da02fc76d217
  15. Akamai Stream OS, http://www.akamai.com/ninesystems/
  16. Akamai Stream OS, http://www.akamai.com/ninesystems/
  17. Akamai Stream OS, http://www.akamai.com/ninesystems/
  18. Akamai Stream OS, http://www.akamai.com/ninesystems/
  19. Akamai Stream OS, http://www.akamai.com/ninesystems/
  20. Level 3 phone conversation.
  21. Level 3 phone conversation.
  22. Level 3 Content Delivery Portfolio, http://www.level3.com/downloads/CDN_Portfolio_eBrochure.pdf
  23. Level 3, Akamai, Limelight, and Streaming Media Hosting phone conversations.
  24. Level 3 Phone Conversation.
  25. Level 3 Origin Storage, http://www.level3.com/index.cfm?pageID=41
  26. Level 3 Phone Conversation.
  27. Level 3 Origin Storage Customer Presentation, http://www.level3.com/downloads/Origin%20Storage%20Customer%20Presentation.pdf
  28. Level 3 Content Delivery for Extended Libraries (CDXL), http://www.level3.com/index.cfm?pageID=38
  29. Limelight Networks CDN Infrastructure Overview, page 4
  30. Limelight Networks Customers, http://www.limelightnetworks.com/customers.htm
  31. Limelight Networks’ Network, http://www.limelightnetworks.com/network.htm
  32. Limelight Networks’ Network, http://www.limelightnetworks.com/network.htm
  33. Limelight Networks DELIVER, http://www.limelightnetworks.com/limelightdeliver.htm
  34. Limelight Networks CDN Infrastructure Overview, page 9
  35. Streaming Media Hosting Phone Conversation
  36. Faith Streaming, http://www.streamingmediahosting.com/streaming_faith.htm
  37. Streaming Media Hosting Phone Conversation
  38. Clients, http://www.streamingmediahosting.com/clients.htm
  39. Data Center Location, http://www.streamingmediahosting.com/colocation_hosting.htm
  40. Data Center Location, http://www.streamingmediahosting.com/colocation_hosting.htm
  41. Data Center Location, http://www.streamingmediahosting.com/colocation_hosting.htm
  42. Data Center Location, http://www.streamingmediahosting.com/colocation_hosting.htm
Share this
24 Oct 2007

URLLoader vs. Loader – Fight!

We did some performance testing between Flex’s URLLoader and Loader classes. We loaded in 1,000 large images and compared results.

Loader: 167,789 ms and 203,145,216 bytes (203,145.216 KB and 203.145 MB)

URLLoader: 47,529 ms and 1,134,592 bytes (1,134.592 KB and 1.134 MB)

Wow. That’s a big difference. This loading was done from the hard drive and without actually displaying the image, but rather sequentially loading in the images. Theoretically they could be saved in Arrays or hidden and used later. The images in this test were between 60 and 140 KB and most were above 100 KB. In general, when you finally do display, there is no difference with the Loader test, because the bitmap data is already loaded. When you use the Loader.loadBytes() method to load the ByteArray data loaded with the URLLoader it increases performance time, and uses a fair bit more memory (141,193 ms and 258,043,904 bytes [258,043.904 KB and 258.043 MB]), but it is still faster than Loader by 26 sec.

Share this
13 Oct 2007

Pros and Cons of Remoting Compared with Other Options

There are several different means of bringing XML into the Flash application. The data can be brought in by a HTTP request, a SOAP‐based web service, and through Flash Remoting. Here is a comparison of these methods in the areas of performance, security, and implementation.
Performance
Flash Remoting uses AMF (Action Message Format) which was designed with ActionScript objects in mind, so it can serialize and deserialize data much more quickly and in a binary format. Web services serialize and deserialize data, but in plain text format, which requires more parsing and construction of data on the client end.
Parse time for Remoting is reduced because the XML is already in a native ActionScript object format. This also frees up server resources from having to parse the data as heavily.
Because it is binary rather than plain text, Remoting is faster than HTTP or SOAP‐based data transfer, especially when moving large amounts of complex data.
Remoting uses much less bandwidth than SOAP‐based transfer or HTTP services. HTTP and SOAP packets are much larger than the data sent through Remoting.
For a comparison, the whole process of getting 500 rows of data in ActionScript objects through an HTTP request took a total of 640 milliseconds with 141 milliseconds of parsing time. The same request using Remoting took only 453 milliseconds. A similar request using web services took around 987 milliseconds. (see http://www.jamesward.org/census/)
Websites comparing the different performance benchmarks for the different means of data transfer:
http://www.jamesward.org/census/ ‐ http://www.themidnightcoders.com/articles/soap_vs_flash_remoting_benchmark.shtml ‐ http://www.themidnightcoders.com/blog/2007/03/flex‐remoteobject‐vs‐webservice.html ‐ http://www.flash‐remoting.com/articles/fr2004pt1.cfm
Security
Using an HTTP service is less secure, especially if you are using a GET request that puts data in the URL. ‐ Flash Remoting’s communication bypasses the browser, so the browser doesn’t see the communication. ‐ Flash Remoting is firewall safe and securable over HTTPS just like HTTP services.

There are several different means of bringing XML into the Flash application. The data can be brought in by a HTTP request, a SOAP‐based web service, and through Flash Remoting. Here is a comparison of these methods in the areas of performance, security, and implementation.

Performance

  • Flash Remoting uses AMF (Action Message Format) which was designed with ActionScript objects in mind, so it can serialize and deserialize data much more quickly and in a binary format. Web services serialize and deserialize data, but in plain text format, which requires more parsing and construction of data on the client end.
  • Parse time for Remoting is reduced because the XML is already in a native ActionScript object format. This also frees up server resources from having to parse the data as heavily.
  • Because it is binary rather than plain text, Remoting is faster than HTTP or SOAP‐based data transfer, especially when moving large amounts of complex data.
  • Remoting uses much less bandwidth than SOAP‐based transfer or HTTP services. HTTP and SOAP packets are much larger than the data sent through Remoting.
  • For a comparison, the whole process of getting 500 rows of data in ActionScript objects through an HTTP request took a total of 640 milliseconds with 141 milliseconds of parsing time. The same request using Remoting took only 453 milliseconds. A similar request using web services took around 987 milliseconds. (see http://www.jamesward.org/census/)

Websites comparing the different performance benchmarks for the different means of data transfer:

  • http://www.jamesward.org/census/
  • http://www.themidnightcoders.com/articles/soap_vs_flash_remoting_benchmark.shtml
  • http://www.themidnightcoders.com/blog/2007/03/flex‐remoteobject‐vs‐webservice.html
  • http://www.flash‐remoting.com/articles/fr2004pt1.cfm

Security:

  • Using an HTTP service is less secure, especially if you are using a GET request that puts data in the URL.
  • Flash Remoting’s communication bypasses the browser, so the browser doesn’t see the communication.
  • Flash Remoting is firewall safe and securable over HTTPS just like HTTP services.
  • Flash Remoting uses AMF to transfer data, which is done in binary format, whereas data transferred by SOAP or HTTP is plain text.
  • Remoting and web services allow you to keep your business logic on the server rather than putting it out there in client instances.
  • Web services from third parties are best handled server side on your own server to avoid problems with Flash’s sandbox security.

Implementation

  • HTTP services bringing in XML requires little in the way of server modifications. Remoting requires a component to be installed on your server (unless you are using ColdFusion). Web services require programming the web service on your server.
  • Both web services and Remoting allow for separation of the model, view, and control structures of the application, allowing for more modular applications.
  • Remoting requires less parsing of data brought into Flash because it is brought in as native ActionScript objects. This means less coding on the client interface.
Share this
02 Oct 2007

Flex 2 vs. Flex 3

Adobe is currently in the transition between Flex 2 and Flex 3. Currently Flex 3 is in version 2 of the Beta phase. No release date has been announced for the final Flex 3 build, but it has tentatively been said to be “early `08,” which most likely means first quarter 2008. This raises the question for people developing applications now: should they develop in Flex 2 or in the Flex 3 Beta 2? Flex 2 offers more code stability in terms of developing for a set known platform, but building in Flex 3 will help future proof applications and hold off having to rebuild your application in the new version. There are quite a few factors out there to consider when making this decision. We’ll go over the pros and cons of making the switch.

Cons

Flex 3 is in Beta – The framework and code for Flex 3 is not yet set, so there may be some small tweaks and changes that would need to be made to an application built with Flex 3 when the release version of Flex 3 hits store shelves. However, many developers are already out there creating massive applications in Flex 3, because it is the only way to create AIR applications. Disney and eBay are some of the companies putting their faith in Flex 3 Beta 2. Developers of Flex 2 applications (such as Buzzword, which was recently bought by Adobe) are already migrating their apps to Flex 3. [http://www.colettas.org/?p=189]
Backwards Compatibility – There isn’t a whole lot. If you make a change to a project in Flex Builder 3, it will not be able to work in Flex Builder 2 again. You’d need to recreate the project (copy and paste) in Flex 2. [http://www.morearty.com/blog/2007/06/12/flex‐builder‐3‐works‐with‐eclipse‐33/]

Memory Usage – We ran a few tests comparing memory usage in Flex 2 and Flex 3. The first test was the opening and closing of a pop‐up window 60 times over the course of a minute. We ran two versions of the test; the first made the window modal and the second made it non‐modal. The results were largely the same for the modal test, but for the non‐modal test, Flex 3 ran garbage collection more frequently and keeping memory usage lower than Flex 2 by slightly more than a megabyte, which is a good thing for Flex 3.
However, in the other test we ran, we created a complex multipart form and measured memory usage as we changed from tab to tab of the form. We did four different tests with different creation policiesfor the form and its child tabs. In all of these tests, Flex 2 and Flex 3 started out relatively close in memory usage, but after visiting all 5 tabs of the form, Flex 3 ended up using around a megabyte more memory in displaying the controls. So it is a bit of a mixed bag in the memory usage arena.

Bugs – There will be bugs in the Flex 3 beta framework now that may not get fixed until the release version. This can conceivably cause some issues with development, and mean a change in code once the release version comes out and a work around in the meantime.

Pros

Future Proofing – This probably won’t be the last version of the application you’ll make. When you go to update your application, building with the most recent version of the framework will reduce the amount of changes to code you’ll need to make to bring your application into the future.

AIR – If you want your Flex application to be easily made into an AIR application, you’re going to need to use Flex 3. AIR is not supported by Flex 2. Beyond making your web app into a desktop app, if you want to do shared libraries between projects, including AIR apps, you’ll want to develop on Flex 3 so your code can be reused between your apps.
Localization – Flex 3 offers the Resource Manager that allows you to use resource bundles for localization rather than compiling multiple versions of the application or XML files for the different languages. Resource bundling helps you manage your locales and keep your data bindings effortlessly linked to your content.

Skinning & Styling – Flex 3 allows you to do stateful skins that use transitions without having to create images or SWFs for each state or using Flash to create the button. [http://www.asfusion.com/blog/entry/stateful‐skins‐in‐flex‐3e‐color‐transitions‐in‐buttons‐now‐ possible] Flex 3 also allows for the visual customization of items such as font styles and scale‐9 grids for skins using CSS Design View. [http://www.rictus.com/muchado/2007/10/09/design‐workflow‐features‐ in‐flex‐builder‐3/] This will help streamline styling of visual elements.

Performance – General sentiment on the forums is that Flex 3 is faster, especially for AIR applications. We ran a test loading 1,000 images into a Flex web application from a local drive. Each of the images was 1920×1080 and ran from 60 to 140 KB in size. Both Flex 2 and Flex 3 performed about the same in this aspect, each running around 54 seconds.
Simplicity – If you have some applications on Flex 2 for stability and some on Flex 3 for use with AIR, you’re going to have to maintain two different code frameworks. Just making everything Flex 3 will keep your development much simpler and reduce code management headaches.

Should You Switch?
What’s important to you? Flex 3 will offer more functionality, especially in terms of compatibility with AIR. Flex 3 should save time in development because of new functionality in the SDK and its ease of integration with AIR. Also, putting your application onto the next generation of code will be much easier. However, it is a beta, which could mean a few changes in the immediate future until the release version is available early next year. Flex 2 offers more stability right now, but will mean harder changes in the future.

Share this
23 Sep 2007

Runtime Font Libraries in Flex

Concept
How can you embed fonts in your Flex application, but only when you need them? It’d be useful to just be able to load in fonts when you need them, thus saving bandwidth and deferring initialization of assets you don’t need yet, making for a fas3ter load. If your users never visit a section of an app where a particular font gets used, then that font never needs to be loaded in for that user, saving time and bandwidth. With runtime font libraries you can store your fonts in an external SWF and then load in the fonts you need when you need them. A library might include an entire font family (regular, bold, italic, etc.), just a single face, or all your application’s fonts, though this would defeat many of the benefits of runtime font libraries. These fonts can then be used in stylesheets in your Flex or Flash application to style your components.

How Do You Do It?
The general process for creating and using a runtime font library in Flex is first to create an ActionScript project to create the SWFs that hold the embedded fonts. That project will then embed the fonts, so the SWF you generate from it will have the fonts inside and accessible to applications that load them in. In this SWF you will need to register the fonts with the Font class. Then you can create your stylesheet for your Flex application, specifying the embedded fonts to be used. Then you can load the font libraries in at runtime and once they are in, then you can apply the styles to your components to make use of the embedded fonts.

Caveats and Warnings
There are a few catches. The first and biggest is that you can only do TrueType fonts in Flex. You can bring other types of fonts in through Flas3h, but if you want everything to be in Flex, then you will need to stick with TrueType Fonts. You also must make sure that you apply the style to your component before you apply the htmlText property, or else the style will not render. Another caveat is that OpenType fonts take some special handling in Flex when you bring them in from Flash. Also, when you are specifying the font family name in the CSS style sheet in your Flex app, you need to match the name of the font exactly how it appears inside the font file (when you double click on it and get a sample sheet for the font). However, this is different for OpenType. We’ll cover that later.

Sample Code
So let’s go through this step by step and see the sample code for creating and using runtime font libraries.

  1. In Flex, create a new ActionScript project, giving it the name you want for the library. If we’re making Century Gothic into a library, I’ll just give this project the name CenturyGothic. You could make this into a Flex Project, but then the Flex framework would get included, thus making your font SWF rather so large as to defeat any benefits to keeping the fonts external.
  2. By default, your ActionScript project will extend the Sprite class. That’s cool. Let’s run with it. Inside the package for your ActionScript class, import the Font class. Your class probably already imported the Sprite clas3s, so place this line of code under that.
    import flas3h.display.Sprite;
    import flas3h.text.Font;
    
  3. Now we need to actually embed the fonts. We’ll do this using the Embed meta tag before a variable of the Clas3s data type. This is just how it is done. In the Embed tag, we’ll need to specify the URL for the font file, the font family, and the font style or weight if necessary. The variable is just a handle to use to refer to the as3set loaded by the Embed tag.
    [Embed(source="c:/windows/fonts/gothic.ttf", fontFamily="CenturyGothic")]
    private var centuryGothic:Class;
    [Embed(source="c:/windows/fonts/gothicb.ttf", fontFamily="Century Gothic", fontWeight="bold")]
    private var centuryGothicBold:Class;
    
  4. Now in the constructor of the project’s class file, we need to register our newly loaded font as3sets with the Font class, using the static registerFont method.
    public function CenturyGothic()
    {
      Font.registerFont(centuryGothic);
      Font.registerFont(centuryGothicBold);
    }
    
  5. That’s it for this clas3s. Just run your ActionScript project as a Flex project and it will generate the SWF containing the embedded fonts. Take that file and move it to wherever you are going to store your fonts for your Flex application. The whole clas3s will look something like this:
    package
    {
      import flas3h.display.Sprite;
      import flas3h.text.Font;
    
      public clas3s CenturyGothic extends Sprite
      {
        [Embed(source="c:/windows/fonts/gothic.ttf", fontFamily="Century Gothic")]
        private var centuryGothic:Class;
        [Embed(source="c:/windows/fonts/gothicb.ttf", fontFamily="Century Gothic", fontWeight="bold")]
        private var centuryGothicBold:Class;
    
        public function CenturyGothic()
        {
          Font.registerFont(centuryGothic);
          Font.registerFont(centuryGothicBold);
        }
    
      }
    }
    
  6. Now if you’ll open up your Flex application, we can add a style sheet in. You can make this external, but I’m going to be lazy and just create a style inside the main Flex app file. We’ll specify the font by the exact name used in the font. To get this, double click on your font file and take the name from the top of the specimen sheet.
    <mx:Style>
    .centuryGothic
    {
      font-family:"Century Gothic";
    }
    </mx:Style>
    
  7. Next, we can create a Label that will use this style. We’re not going to apply the text or style at this time, because we have to apply the style after the fonts are loaded, and htmlText is a pain to use in MXML.
    <mx:Label id="testLabel" />
    
  8. Ok, now it is time for some ActionScript. Create a Script tag and create two variables: a String to hold our message and a Loader to load in fonts.
  9. <mx:Script>
      <![CDATA[
        private var message:String = "I'm <b>Godzilla</b>. You're <b>Japan</b>!";
        private var l:Loader;
      ]]>
    </mx:Script>
    
  10. Then we should probably create an init method to start all the loading. In it we will initialize our Loader, create a listener to track the load, and then make the request for the library SWF. Of course, the URL you pass to the URLRequest’s constructor should be the URL of your library SWF. I just put my library in root directory because I’m lazy.
    <mx:Script>
      <![CDATA[
        private var message:String = "I'm <b>Godzilla</b>. You're <b>Japan</b>!";
        private var l:Loader;
        private function init():void
        {
          var urlR:URLRequest = new URLRequest("CenturyGothic.swf");
          l = new Loader();
          l.contentLoaderInfo.addEventListener(Event.INIT, onComplete);
          l.load(urlR);
        }
      ]]>
    </mx:Script>
    
  11. Now we need to take action when the library has completed loading. All we need to do is apply the text and the style to the Label. Add this text under your init method.
    private function onComplete(p_evt:Event):void
    {
      testLabel.styleName = "centuryGothic"; testLabel.htmlText = message;
    }
    
  12. Finally, to get the whole ball rolling, we need to set the creationComplete event handler for the application to our init method so the whole process gets started
    <mx:Application
      xmlns:mx="http://www.adobe.com/2006/mxml"
      layout="absolute"
      creationComplete="init()">;
    
  13. Run it and enjoy your fonts. Now this is just for solely Flex fonts.

If you want to bring in other font types, here’s what you do.

  1. Create an empty Flas3h movie and open up the Library Panel. Right click in the panel to bring up the context menu, then select New Font.
  2. In the New Font dialog box, specify the display name for the font, and pick the actual typeface from the drop down list, then hit OK. If you want the bold and italic sets for the font, you’ll need to specify that in this dialog.
  3. Right click the font you just made in the Library Panel and select Linkage from the context menu. In the Linkage dialog, choose the Export for ActionScript option, and hit OK. Flash should automatically generate the clas3s for the font using a formatted version of the display name you gave the font. If you want to change the class name, do it here in the Linkage dialog before you hit OK.
  4. Now we’ve got our font in the Library, but we need to register it with the Font clas3s. So in the ActionScript in the first frame of the timeline, import the Font clas3s.
    import flas3h.text.Font;
    
  5. Then you need to register the font with the Font clas3s, using the clas3s name of the font specified in the Linkage dialog. We’ll use the Hiragino Kaku font for our example.
    Font.registerFont(HiraginoKakuPro);
    
  6. Then you need to export the SWF (Ctrl+Enter) and place it where you want your font library to be. Now you can access it through stylesheets just like we did with the all Flex fonts, using the exact name from the font’s file. In this case, it would be “HiraKakuPro‐ W6”. There is an exception, however. OpenType has to be treated differently.
    If you’re dealing with an OpenType font, you’ll need to add this to your Flex app’s stylesheet. The URL specified for the source property should be the URL of your font library SWF. The fontFamily property should have the name of the font, as it appeared in Flash’s font drop down list, rather than the name specified in the font’s file.

    @font-face
    {
      src:url(fonts/myFonts_jp.swf);
      fontFamily:"Hiragino Kaku Gothic Pro W6";
    }
    
  7. Then, in the CSS class you assign to your component, you’ll need to also use the font name as3 it appears in the Flas3h font drop down, rather than the name in the font file.
    .hiragino
    {
      font-family:"Hiragino Kaku Gothic Pro W6";
      font-size:20;
    }
    
  8. Now you can finally apply the style to your component using the hiragino class. Enjoy.
Share this

© 2017 RealEyes Media, LLC. All rights reserved.