Not logged in. · Lost password · Register
Forum: MatriX RSS
On IQ failure Matrix Through Control to OnError Event and Disconnect the connection , can we handle it so it dnt disconnects
Avatar
RajuOms #1
Member since May 2016 · 5 posts
Group memberships: Members
Show profile · Link to this post
Subject: Handle On Error Event
Hi ,
 Every time when ever there is an Error with IQ matrix close the connection and take the Execution to On Error , Can I handle it with any event prior to on error , so it does not disconnect the clients with server?

Thanks
Avatar
Alex #2
Member since Feb 2003 · 4327 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
I would help if you post exactly which kind of error is happening.
Do you have a Xml log? If an IQ raises the OnError event and closes the connection then it looks like there is something wrong in your codes.

Alex
Avatar
RajuOms #3
Member since May 2016 · 5 posts
Group memberships: Members
Show profile · Link to this post
Hi, Alex

Please find the attachment.
I am providing you log file in an attachment. there is three log files of On Send Event, On Receive Event and On Error Event.
Please help how can i handle it in our end.
The author has attached one file to this post:
LogFiles.zip 51.7 kBytes
You have no permission to open this file.
Avatar
Alex #4
Member since Feb 2003 · 4327 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Splitting your log in 3 files is not very useful. We need send, receive and error in the exact sequence they occur.
In your error log it tells you that the connection was closed by the remote host, which is your server.
If the server closes the socket for some reason there is nothing MatriX an do. You get an OnClose and then have to reconnect.

From your log it also looks like you use a old version of MatriX. Try first updating to the latest MatriX version.

Alex
Avatar
RajuOms #5
Member since May 2016 · 5 posts
Group memberships: Members
Show profile · Link to this post
In reply to post #2
when ever OnError event raises then we are getting this kind of error in mostly cases.
 ERROR 2016/05/04 19:06:31,035 >> Matrix.XmppStreamException: Unable to send data. The XMPP Stream is inactive.
Avatar
Alex #6
Member since Feb 2003 · 4327 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
as I suggested, please update to the latest MatriX version.
Or Destroy the old XmppClient and create a new one.

Regards,
Aöex
Avatar
RajuOms #7
Member since May 2016 · 5 posts
Group memberships: Members
Show profile · Link to this post
Ok Alex, as for your suggestion we have to update latest MatriX version but please first you see our new log file. it is in sequence of event raises which is mentioned on log file.

Please find the attachment.
The author has attached one file to this post:
Logfile.zip 67 kBytes
You have no permission to open this file.
Avatar
Alex #8
Member since Feb 2003 · 4327 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
The log still shows the same error:

System.IO.IOException: Unable to write data to the transport connection: An existing connection was forcibly closed by the remote host.

Usually this means that the server close the connection for some reason. Or you lost the network connection. And you still try to send packages, so you get this exception multiple times.

  • Have you looked at the logs of your server?
  • Have you tried it without Stream Management?
  • Can you provide us a simpel test case so that we can try to cause this in our labs?

Alex
Avatar
RajuOms #9
Member since May 2016 · 5 posts
Group memberships: Members
Show profile · Link to this post
as per our previous conversation, we have updated latest matrix version(2.0.0.17) but i think issue is same.
we have executed that an application two time and get two different type of log file at the prior on onerror event raised.
please see the log file again.
The author has attached one file to this post:
LogFile.zip 151.6 kBytes
You have no permission to open this file.
Avatar
Alex #10
Member since Feb 2003 · 4327 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
I told you before that its the same issue, and that the server is closing the connection.
I also asked you several questions which you never replied to. You latest logs are the still the same and don't help to solve the problem.

Alex
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Forum: MatriX RSS