Facebook Improves Performance Of Its Android App Thanks To A Field Trip To Africa

Facebook has updated its Android app recently and if you are using the app you might have noticed a few changes in it and most of them are concerned with performance. All these improvements were carried out to ensure that everyone, especially people living in developing and underdeveloped countries get a seamless experience. As you might be aware, Facebook has taken a great interest in developing mobile applications because it shall help the company reach the rest of the five billion people in the world. Since in their offices the developers are habituated with testing apps on high-end smartphones with LTE connectivity they decided to head over to Africa to see how their apps worked. Once they bought a few low-end handsets and tested the efficiency of the app they found that poor mobile data connection coupled with the miserable memory on the phones resulted in a lag ridden crash prone app. Additionally they found that their monthly data plans got exhausted within 40 minutes.

facebook-logo

Once they returned to their offices they set out to improve the app one aspect at a time, starting with performance. They noticed that start times on older Android devices were very high. To reduce the start times in single-core devices where multiple features bogged down the processor they decided to defer some of the initialisations until after startup and in some cases until they are used. To make sure that News Feed loaded faster they fetched stories earlier in the process. With the above changes they were able to reduce start times by up to 50 percent.

Next they proceeded to improve data efficiency of the app and the area of attention was photos. Even though photos are an important aspect of the Facebook experience they tend to consume more data and this is bad in areas where mobile data connection is expensive and slow. Instead of JPG and PNG compression they decided to use WebP which drastically improved data savings without affecting quality. Next they took into account different sizes of displays and loaded images only in those resolutions instead of the previous method where they used maximum resolution everywhere. This helped halving the data consumption.

Considering the inferior quality of mobile networks, Facebook switched to OkHttp networking stack for its Android app that allowed fast retries and involved the SPDY protocol. Failed image loads were eliminated with the help of new image pre-fetching algorithms. Finally, since most budget devices tend to have low internal memory storage, Facebook decided to upload multiple APKs on Google Play for different Android versions and screen resolutions. In the future they hope to include these changes in their Instagram and Messenger apps.

By now you might have realised that we wrote this article in a detailed manner for all mobile developers on CE who can take a clue from Facebook and implement their strategies while developing their mobile apps. For more details you are advised to visit the #-Link-Snipped-# on Facebook’s engineering blog and its coverage on #-Link-Snipped-#.

Replies

  • Rajni Jain
    Rajni Jain
    I am using FB on Android for some time quite regularly, however did not see any noticeable difference.

    May be it's only me.. 😔

You are reading an archived discussion.

Related Posts

The Modi Sarkar in India has raised the railway fare hike by 14.2% and everyone's questioning the government's move. I read up a bit and found out that the Indian...
After Google’s Chromecast managed to earn accolades and sell in millions everyone else is now realising the potential of the streaming devices in the consumer market. Amazon and Roku have...
Here's a draft of the official CrazyEngineers T-Shirt. The art has been created by @eternalthinker and rearranged by yours truly. Note that it's still a draft and everything's still on...
Think about it. We all brag/blame that India is under-Developed. Is it? Railways: Pros: 1. Got some working trains from age old which could probably never be found anywhere else...
As the world gets ready for Google I/O 2014 which starts this week, a leaked image has managed to reveal details about the newest member of the Nexus family. The...