I am building HTML5 applications at Sencha. It is a great platform, take a look...

 

  Ted Patrick - Developer Relations @ Sencha


   Note: This is the personal blog of Ted Patrick. The opinions and statements voiced here are my own.



Speeding multiple image loading in Flash Player

DIGG IT!     Published Wednesday, April 18, 2007 at 3:18 PM .

Flash Player adheres to the HTTP 1.1 spec allowing only 2 connections per domain. Given this technical limitation there are a few very handy workarounds. One comes by using CNAME feature of DNS. It seems that is you add DNS CNAMES to a single domain, the browser and Flash Player allow 2 connections per listed subdomain even though they are technically the same HTTP server. In this case by simply adding several subdomains, the Flash Player can load multiple images and data in parallel over HTTP/HTTPS.

So instead of loading the following images:

http://mt3.google.com/mt?n=404&v=w2.43&x=0&y=1&zoom=15
http://mt3.google.com/mt?n=404&v=w2.43&x=0&y=2&zoom=15
http://mt3.google.com/mt?n=404&v=w2.43&x=0&y=3&zoom=15
http://mt3.google.com/mt?n=404&v=w2.43&x=2&y=4&zoom=15

These will load 2 at a time!

One might load these URLS:

http://mt0.google.com/mt?n=404&v=w2.43&x=0&y=1&zoom=15
http://mt1.google.com/mt?n=404&v=w2.43&x=0&y=2&zoom=15
http://mt2.google.com/mt?n=404&v=w2.43&x=0&y=3&zoom=15
http://mt3.google.com/mt?n=404&v=w2.43&x=2&y=4&zoom=15

These will load 4 at a time! A 2X performance improvement.

I am adding CNAMES to onflex.org to test this out.

More to come...

Ted :)


Where to find me:

Ted on Twitter - @__ted__
Ted on Adobe Groups
Ted on LinkedIn
Ted on Facebook
Ted at Adobe

Latest

Lists

Links

Jobs

city, state, zip

Archives