Fabio Forno a écrit :
On Mon, Aug 31, 2009 at 10:33 PM, Vincent BARAT<[email protected]> wrote:Additional information regarding battery consuption (in favor of XMPP): according to our tests (using an ammeter), keeping a TCP/IP socket open DOES NOT CONSUME MORE POWER than having none open at all, as long as there is no activity on the socket.With which phones did you test it and which type of network?
Phone: HTC G1 & HTC Magic OS: Android 1.5 ejabberd: 2.0.4The test was to send only 1 log by minute (a small stanza) on a permanent XMPP connection, and to compare to the same done using a non permanent HTTP connection.
Mesures were performed during 1 hour, using the 2G and 3G network. Results (median consumption) 2G: XMPP: 21,8 mA, BOSH: 24,45 mA, HTTP: 26,16 mA 3G: XMPP: 25,34 mA, BOSH: 29,09 mA, HTTP: 27,44 mA Our BOSH client uses a HTTP connection with keep alive. I'm
asking because we don't don't have the same experience, in particular with 3G phones. Our tests show that TCP with a keepalive is much better than UDP sockets, but there is still a noticeable reduction of battery life (for example with no traffic we are still waiting for symbian phone able to stay connected for more than 36h over edge, utms is worse; in comparison when idle battery lasts a week). We believe this depends on many factors, density of cells, firmware version of phone and cells too, since we noticed a considerable improvement in the last 2years (for example a nokia n95 went from just 12h of battery life to more than a day with a simple firmware upgrade).
<<attachment: vincent_barat.vcf>>
