The Facebook application reduces the battery life of iDevices

  Our iPhones have a rather low battery life, and standard operating times are reduced even more if we use certain applications, especially messaging ones. An iOS application developer discovered that his iPhone's battery was draining very quickly without him using the device extremely often, and of course he wanted to find out the source of the problem. Using a series of software applications of Apple Lossless Audio CODEC (ALAC),, he began to monitor the way applications run in the background and discovered that the Facebook application generates excessive energy consumption.

As I said before the app is defining what it's using. Facebook is using two of them: Audio and VoIP! That means the Facebook app could be active in the background the whole time. According to Instruments that's not the case. Not quite. Looking at the flags in Instruments you can see that the app is waking up every few minutes, does something for 10 seconds and sleeps again. I let this run for two hours and as you can see in the rightmost column, the Facebook app is waking up at regular intervals, does something for almost exactly 10 seconds and sleeps again. The whole day long.

  On his blog explains in detail the multitasking process on the basis of which the applications work, but in the case Facebook- we are talking about the constant activity of the application. Basically, the application left open in the background runs at regular time intervals of 10 seconds, after which it disappears from the usage logs, returns, disappears and the process continues as long as the application is open in the background. Normally the application should become inactive after 10 minutes of inactivity, but having implemented VoIP and Audio functions, it probably runs various processes, remaining active all the time it is open in the background.

So it seems there are only two solutions for this problem:
1. delete the Facebook app
or
2. quit the Facebook app after every use with the multitasking switcher (press the home button twice in a short time, then you see a bar showing your apps, tap a little longer on one app and they start to shake, now hit the little minus on the Facebook icon)
Now the Facebook app is really terminated and is not running in the background any longer. But if you forget to terminate the app at least once, it's running in the background again.

  The same thing happens with applications such as WhatsApp Messenger, they being specially configured to partially remove the 10-minute operating limit of applications open in the background. The only way to ensure that such applications do not significantly affect your battery autonomy is to close them, including from the background, when you are not using them.

Unfortunately some apps are exploiting this. WhatsApp for example. When it seems like it's finished it's actually running exactly those allowed 10 minutes and continues to communicate directly with its server instead of using iOS' push notifications. That's draining more battery, of course. So if you are getting a message in this 10 minute timeframe and open WhatsApp, this 10 minute period starts again. That means if you are getting lots of messages it could happen that WhatsApp is running the whole day. Thankfully most of us are not that popular, so this would become a problem.