Optimizing network interaction in mobile applications

Optimizing Performance for the Flash Platform is filled with tips to make faster, more efficient Flash Player and AIR applications for desktop, mobile, and TV devices.

The chapter called Optimizing network interaction has some tips worth reviewing:

  • Use smart seeking.  Smart seeking improves performance when a user seeks to a new destination in a streaming video. Use Netstream.inBufferSeek.  (Adobe Flash Media Server 3.5.3 or greater required)
  • Divide your app into multiple SWF files. Multiple smaller SWF files means your content loads faster, especially on mobile devices with limited access to the network.
  • Provide event handlers and error messages for IO errors. Because network access can be less reliable on a mobile device, be sure to catch every IO error and keep the user informed.
  • Use Flash Remoting and AMF for optimized client-server data communication. As a binary format, Action Message Format (AMF) reduces the size of the data, improving the speed of transmission. Flash Remoting gateways, such as  ZendAMF, FluorineFX, WebORB, and BlazeDS, know how to handle the AMF format on behalf of the server side.
  • Cache assets locally after loading them. Avoid unnecessary loads from the network by saving files to the local file system, by using SharedObjects, or by saving data to a local database.

For more details on these tips, and other topics such as conserving memory and improving rendering performance, visit Optimizing Performance for the Flash Platform.

Jackie Levy, Content and Community Lead