Giter Site home page Giter Site logo

Comments (16)

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
I've a same issue when I stop GTalkSMS and it was running for a long time.
I don't think that is due to mobile data connection but to xmpp protocol.

Can you confirm if the application was running for a long time ? 

Original comment by [email protected] on 28 Dec 2010 at 5:37

  • Changed state: Investigating

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
No, it was not running for a long time. May be few hours max. I checked now: 
after restarting phone and turning mobile data off, it freezed :(

Original comment by [email protected] on 28 Dec 2010 at 6:03

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
Ok, can you do the test after few minutes of uptime ?
I'll investigate on it.

Original comment by [email protected] on 28 Dec 2010 at 10:28

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
FWIW, this hang seems to be an issue with the smack library.  See my note about 
it in http://code.google.com/p/talkmyphone/issues/detail?id=51#c7.  Discussing 
this before with Christophe-Marie, he indicated he thought the best thing to 
try and do was use 'asmack' as the XMPP library, but I failed to get that going 
due to complexities in the asmack build process (it really is just a set of 
patches to smack itself)

Original comment by [email protected] on 28 Dec 2010 at 10:38

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
Here 
http://davanum.wordpress.com/2007/12/31/android-just-use-smack-api-for-xmpp we 
can  find a zip that included smack library with android's patches (I think 
that is asmack version).

Original comment by [email protected] on 28 Dec 2010 at 10:54

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
It seems to me, that explanation is in Issue 12.
When I turn off mobile data and after few minutes turn it on, gtalksms is 
running again. The application is not reacting between these two points. I 
didn't tried this before.

Original comment by [email protected] on 29 Dec 2010 at 8:12

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
Issue 12 should stop the app from hanging - but it may not fix the inability to 
disconnect from the mobile network.  What I expect to see now is that the app 
keeps running, but is unable to auto-reconnect when wifi becomes available.

This problem may also be limited to a device and/or version of android - I've 
seen a number of people report it with TMP on a Desire, which is what I have.

Original comment by [email protected] on 29 Dec 2010 at 11:05

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
Can you try again with v1.4 please? It's available on market

Original comment by [email protected] on 29 Dec 2010 at 11:06

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
I just tried and it is as I predicted - the disconnect never finished, although 
the app remains responsive.  The hang is in XMPPConnection.shutdown(), which is 
called as part of disconnect.  I'll dig a little more for a workaround.

Original comment by [email protected] on 30 Dec 2010 at 12:07

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
FWIW, the smack.jar at http://people.apache.org/~dims/android/ is what we are 
currently using (I just grabbed it - the .jar is identical).  FWIW, I don't 
think that has any relationship to 'asmack', which is a far larger set of 
patches.

Original comment by [email protected] on 30 Dec 2010 at 1:10

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
asmack binaries can be got from http://code.google.com/p/asmack/ - sadly 
though, I did very quick testing with the .jar from there and got the exact 
same results.  It might be worth testing it more thoroughly as it may work 
better in some other ways - but not in this specific case.

So I knocked up a patch that does the disconnect in its own thread - as the 
comments say, it isn't ideal, but probably better than hanging.  In my testing 
I eventually saw the hung thread terminate up to 30 minutes later, so hopefully 
it will not result in lots of hung threads in the process.  Works for me :)

Original comment by [email protected] on 30 Dec 2010 at 7:28

Attachments:

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
if there is now data connection, xmpp never can a clean disconnection.
So XMPPConnection.shutdown() is really necessary ?
This function notify the server that we closing connection but we can't contact 
the server.

Original comment by [email protected] on 30 Dec 2010 at 11:06

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
I guess we might want to clean-up the socket etc - but yeah, that may well work 
too.  I wonder which one sucks least? :)

Original comment by [email protected] on 30 Dec 2010 at 12:14

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024
Actually, a problem with that is that the xmpp stuff keeps at least 3 thread 
alive - a packet reciever, transmitter and a keep-alive watcher - so we would 
probably end up leaking 3 threads instead of one trivial one...

Original comment by [email protected] on 30 Dec 2010 at 12:21

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024

Original comment by [email protected] on 1 Jan 2011 at 9:53

  • Changed state: Fixed

from gtalksms.

GoogleCodeExporter avatar GoogleCodeExporter commented on July 23, 2024

Original comment by [email protected] on 25 Aug 2011 at 7:51

  • Changed state: Deployed

from gtalksms.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.