-
-
Notifications
You must be signed in to change notification settings - Fork 815
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Short keepalive drains battery #227
Comments
Actually we plan to make it configurable. |
There is a chance for implementation of this feature in next build? It shouldn't be hard to do, but will be very useful. |
Seems to be a duplicate of #152. |
a-iv said "Note that large keep alive interval will increase chance to loss messages over bad GPRS connection." That's what TCP-retransmissions are for. --- Slightly off-topic because it's not directly Xabber related --- TL;DR and summary: |
TCP keepalive is for detecting a broken connection quickly, and thus, reconnect cleanly. During the dead-time during which the connection is unknowingly broken, messages will be sent into the void. TCP keepalives are not used, to my knowledge, to have quicker re-sending. The proper long-term fix to losing messages during unknown dead-time of the connection is to use xmpp stream management, for which issue #67 is already opened. Nevertheless, a configurable keepalive time would be desirable for saving battery live, especially once stream management is implemented. |
@horazont stream management has some flaws in design. Better than nothing, but not too good for proper message delivery control. Anyway, current Xabber battery usage is very modest, so I close this issue |
Hello,
In my experience xabber heavily drains my phone battery. A bit of investigation suggests that a big culprit here is a very short keepalive timeout (30s) for xmpp connections. Another side effect of this is a big data consumption (about 2MB / day with 3 jabber accounts, not used at all).
Im currently testing increasing values of keepAliveInterval and keepAliveResponse in res/raw/smack_config.xml to 1800s. So far, my battery drain seems to be normal again.
Would you mind increasing those values or make them configurable?
The text was updated successfully, but these errors were encountered: