After using the MM7 client (based on the sample code) to submit to a NowSMS MMSC, we got below exception randomly.
The MMS still got sent through, but we can't get the SubmitResponse because of the exception.
Exception:
"The server committed a protocol violation. Section=ResponseStatusLine"
According to our research, this seems to be an issue with httpwebrequest's "KeepAlive" or "useUnsafeHeaderParsing"
https://social.msdn.microsoft.com/Forum ... arpgeneral
Exception when submitting MM7 request
Moderator: alt
Re: Exception when submitting MM7 request
Hi,
To add on
The desktop demo project does not get the error when connecting to the same MMSC server
However, when using the library as a MM7 client in a web application, the response sometimes ok, but most of the time we get below exception
02:36:39: ERROR: 68: (MM7Client) Message sending failed., Exception: System.Net.WebException: The server committed a protocol violation. Section=ResponseStatusLine
at System.Net.HttpWebRequest.GetResponse()
at Inetlab.MMS.MM7Client.fChbNhseILb9GZnK2bG(Object )
at Inetlab.MMS.MM7Client.JL8zyhSHe(MediaMessage )
To add on
The desktop demo project does not get the error when connecting to the same MMSC server
However, when using the library as a MM7 client in a web application, the response sometimes ok, but most of the time we get below exception
02:36:39: ERROR: 68: (MM7Client) Message sending failed., Exception: System.Net.WebException: The server committed a protocol violation. Section=ResponseStatusLine
at System.Net.HttpWebRequest.GetResponse()
at Inetlab.MMS.MM7Client.fChbNhseILb9GZnK2bG(Object )
at Inetlab.MMS.MM7Client.JL8zyhSHe(MediaMessage )
Re: Exception when submitting MM7 request
Hi javabeanz,
I have made some changes in the version 0.10.0.
You can create subclass from MM7Client class and override method GetWebRequest to customize web request before sending.
I have made some changes in the version 0.10.0.
You can create subclass from MM7Client class and override method GetWebRequest to customize web request before sending.