Open GoogleCodeExporter opened 8 years ago
flush() and write in general are broken on many many phones. Motorola Milestone
is
one of the best examples of a phone that can go into flight mode without
throwing an
exception.
Did you try this via wifi or via gsm?
You should try to detected stalled methods on your own, e.g. with xmpp ping (you
*will* get a reply, error or success). This is usually more stable than a naive
solution, especially as your GSM may lie.
Original comment by rtreffer@gmail.com
on 14 May 2010 at 6:11
I have done the next test:
- start openfire
- start client
- shutdown and start openfire
- send packet from client
And I get:
connectionClosedOnError
java.io.IOException: Write error: I/O error during system call, Broken pipe
at org.apache.harmony.xnet.provider.jsse.OpenSSLSocketImpl.nativewrite(Native
Method)
at
org.apache.harmony.xnet.provider.jsse.OpenSSLSocketImpl.access$600(OpenSSLSocket
Impl.java:54)
at
org.apache.harmony.xnet.provider.jsse.OpenSSLSocketImpl$SSLOutputStream.write(Op
enSSLSocketImpl.java:568)
at java.io.OutputStreamWriter.flush(OutputStreamWriter.java:183)
at java.io.OutputStreamWriter.convert(OutputStreamWriter.java:263)
at java.io.OutputStreamWriter.write(OutputStreamWriter.java:252)
at java.io.BufferedWriter.flush(BufferedWriter.java:145)
at org.jivesoftware.smack.util.ObservableWriter.flush(ObservableWriter.java:48)
at org.jivesoftware.smack.PacketWriter.writePackets(PacketWriter.java:195)
at org.jivesoftware.smack.PacketWriter.access$000(PacketWriter.java:42)
at org.jivesoftware.smack.PacketWriter$1.run(PacketWriter.java:78)
So, at this moment asmack knows that the connection is broken and it is still
not
reconnecting. I think that in this error the asmack could recover from crash
starting
the reconnecting.
Im sorry if I haven't understood well but I hope this will help.
I have used asmack-2010.05.07.jar
Original comment by cver...@gmail.com
on 1 Jun 2010 at 3:16
I see a related issue on nexus one 2.1
Migrate from wifi to edge, you get a connection closed on error, then reconnect
the existing xmpp connection. All looks fine, but when you send a packet it is
never sent, without any error
Original comment by carl.dha...@gmail.com
on 28 Jun 2010 at 12:00
I have the same problem on Android 2.2.1 on Motorola Droid. Strangely enough, I
do not have the problem on my Nexus One, only on the Motorola Droid.
Original comment by SSZer...@gmail.com
on 4 Jan 2011 at 3:14
Treatment of different mobile phone networks in different ways, cell phone
manufacturers are custom android
Original comment by leadr...@gmail.com
on 17 Jan 2011 at 9:51
I have a same-problem.
On htc wildfire, xmpp don't generate an exception when close network.
This problem doesn't happen on other phones.
How to recognize exception when network lost.
Thanks!
Original comment by hnbang1...@gmail.com
on 11 Jul 2011 at 4:18
We are heavy users of asmack in http://rogerthatmessenger.com
Whenever we get an XMPP connection closed on error, we create a new
XMPPConnection object. That seems the only way to avoid unusable connections
Original comment by c...@mobicage.com
on 3 Nov 2011 at 2:11
Hi I am using asmack for developing android IM.I am facing problem on message
receiving after reconnect network connection.
I am using a broadcast receiver with action as
android.net.conn.CONNECTIVITY_CHANGE > to know is the internet reconnection
(wifi or 3g)I have a service for listen incoming packets. When my device
reconnect with internet from above broadcast active and hear a internet
available that time I reconnect my application with Tigase Server and then I
re-login on server that is fine. Same time I also again attaching listeners of
my service so they can listen incoming packets. But When I send message it
going to user B but User B sending me messages on my side its not receiving. on
user B side it showing that user A Connected with new connection and also
showing presence.Like to hear where I am doing wrong. .
Original comment by tonasiri...@gmail.com
on 30 Jun 2012 at 10:54
Original issue reported on code.google.com by
alfred.o...@gmail.com
on 14 May 2010 at 5:31