monika0691 / emite

Automatically exported from code.google.com/p/emite
0 stars 0 forks source link

possibly bug in XmppBoshConnection on connection failure #350

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
If emite is not able to connect to the backend it will do 8 retries with an 
increasing delay (see RetryControl) as long as the error count does not get 
reset. Each time emite handles a resonse in XmppBoshConnection it will reset 
the error count and so RetryControl will not do it's purpose.

What steps will reproduce the problem?
1. you need a unresponsive jabber server behind responsive reverse proxy
2. try to connect to jabber server
3. reverse proxy will responde with status 502

What is the expected output? What do you see instead?

emite should try to connect 8 times with more delay on each retry. But instead 
it retries forever with a delay of 500ms.

If clearErrors(); will be done just on a successful response the onError 
handler will pass a proper error-count to RetryControl.

Original issue reported on code.google.com by bernd.roessl on 24 May 2011 at 1:21

GoogleCodeExporter commented 9 years ago
Hi, 

I've worked a bit on this and made a patch. Please find it attached. (worked on 
the master)

Original comment by Fabrice....@gmail.com on 19 Aug 2011 at 9:53

Attachments:

GoogleCodeExporter commented 9 years ago
what is the reason for changing SessionStates.ready to SessionStates.loggedIn? 
if a connection get resumed we will not get 'loggedIn' but 'ready'.

Original comment by roe...@lovelysystems.com on 19 Aug 2011 at 10:14

GoogleCodeExporter commented 9 years ago
but if the connection is not resumed but re-established (as it happens in this 
scenario) you will not get 'ready' 

Original comment by Fabrice....@gmail.com on 30 Aug 2011 at 8:50

GoogleCodeExporter commented 9 years ago
By the way I'm a bit confused about where to have this discussion: should we 
discuss on google code or GitHub ?

Original comment by Fabrice....@gmail.com on 30 Aug 2011 at 8:51

GoogleCodeExporter commented 9 years ago
Sorry Fabrice... we are a little bit stalled... I'm currently on holidays... we 
are moving to github and I hope we can look at this issue soon...

Meanwhile, any patch is welcomed ;)

Bests, dani

Original comment by danigb on 30 Aug 2011 at 5:03