Hi Flow, i always wanted to thank you for your efforts on Android port of smack, so THANKS!!!
Your welcome. I appreciate that.
The only change is that in the past i was registering providers manually (no SmackAndroid.init(Context))
and later i used SmackAndroid.init(Context) …
In both cases i use a Ping Provider copied/pasted from here for both sending & receiving xmpp Ping packets
That seems unecessary work and error prone. First, (a)Smack comes with XMPP Ping support, there is no need to add an extra PingProvider.
I am still confused about your actual problem. Is it the server that sends the ping requests so often, you mentioned 15 seconds, or the client? Both shouldn’t do it and IIRC neither openfire nor (a)smack are configured to do so. How did you discover that behavior?
You are right, as (a)Smack comes with Ping support, i have to “renew” my code. Is it also supports Pong support ?? (answer packet to Ping packet).
Each 5 minutes my client sends a ping to server & this works OK as expected.
I try to develop the other way, each X minutes the server sends a Ping to client & the client responds.
With the following client/server configuration, openfire sends a Ping to client every **150 **secs. (I check the time intervals from smack Logs in client’s Logs)
Server settings:
Send an XMPP Ping request to idle clients.
Client: asmack 0.8.9 / SmackAndroid.init(Context) / Ping provider mentioned before
The question is how to manually change the Ping time interval from the openfire side
(e.g. is it possible to the Ping interval at 250 secs , at Openfire side ? )
as far as the 15 seconds interval at my first message, lets assume that i did something terribly wrong, and i suppose that using SmackAndroid.init(Context) is a must-do in android dev with asmack) which i didn’t do as i had to.