In reply to post ID 9372
Quote by Alex:try a lower interval, because what your logs showed is that the disconnect appeared at exactly 2 minutes or a bit below. I would try 60 seconds for a test.
The BOSH logs fro the very beginning of your session would be also very helpful. There we can see some of the BOSH configuration of your server, like inactive value setting.
I'll update the client to ping every 60 seconds and log the bosh payloads. Once that test is completed I'll post the results.
Quote by Alex:layer?
- Your stacktrace also mentions the SslStream class. Have you made some tests without HTTPS to exclude problems on the SSL
I've thought of that myself, I'm currently running a test with just http to see if the error still arises.
Quote by Alex:
- Do you have HTTP proxies between the client and the servers?
I don't know about any proxies however, I don't manager the server so it's hard for me to know for sure. It'll probably take me a little time to find out.
Quote by Alex:
- Is there a firewall? Have you tried to disable it? Many firewalls hook into sockets and SSL and can cause strange behavior.
There's a firewall however, we have an firewall rule to open up the port which the chat server uses for https. Also the client is connecting locally, so it wouldn't have the usual troubles of a remote connection.
On another note my most recent test has retrieved a different error from previous tests which you'll see in the attachment.
For this test I used (System.Threading.Timer) to trigger the ping instead of (System.Timers.Timer) so it wouldn't worry about making itself synchronous for other threads. And from the test it seemed to have worked as I didn't see the timer stop for six minutes like it has in previous tests. However, it did receive a different error dirrectly from the chat server which I've noted below.
- 12/23/2015 12:55:20 PM - RECV: <stream:error xmlns:stream="http://etherx.jabber.org/streams">
- <conflict xmlns="urn:ietf:params:xml:ns:xmpp-streams" />
Do you know what this would mean? I can see that MatriX is calling the closed event afterwards, and that my client isn't the one calling for the Chat connection to be closed. As of now I would assume it would apply to the following below shown in the OnError event.
- 12/23/2015 12:55:20 PM - Matrix.OnError(object sender, ExceptionEventArgs error)
- 12/23/2015 12:55:20 PM - error.Exception.GetType(): Matrix.Net.BoshException
- 12/23/2015 12:55:20 PM - error.Exception.Message: BoshException
- 12/23/2015 12:55:20 PM - error.Exception.GetBaseException().GetType(): System.Net.WebException
- 12/23/2015 12:55:20 PM - error.Exception.GetBaseException().Message: The remote server returned an error: (404) Not Found.
This error strikes me as odd, since the only thing the client is doing is pinging the chat server, so it's not like it's requesting something out of the ordinary unless the chat server lost the connection for some reason.
Finally, I added the stack trace to MatriX's OnClose event. I'm not sure if this would help with anything, but I though it might help show if the call is coming from some odd location.
Thanks for your Assistance.
The author has attached one file to this post:

You have no permission to open this file.