none
The I/O operation has been aborted because of either a thread exit or an application request RRS feed

  • Question

  • Hi,

    we have a wcf service which is hosted in windows service and we have attached a DebugDiag to this service. AFter some time The DebubDiag has created one dump file. The dump file saying that,

    "The I/O operation has been aborted because of either a thread exit or an application request".

    Will this exception crash the Service? and Why this exception is occurred?

    Any suggestion or help would be appreciated?

    Monday, May 4, 2015 2:28 PM

Answers

  • Hi NareshReddy Bomireddy,

    >>"The I/O operation has been aborted because of either a thread exit or an application request".

    After meeting the above exception, please try to enter your wcf service address in the broswer (if your service is http service) to see if it works, if it does not work, it means that this exception will crash the wcf service. If so, please try to enable the WCF Trace to find some detailed error information or you can try to host the WCF in the IIS/Console application to see if it works.

    The following configuration taken from this MSDN article can be applied to enable tracing on your WCF Services.

    <configuration>
      <system.diagnostics>
        <sources>
          <source name="System.ServiceModel"
                  switchValue="Information, ActivityTracing"
                  propagateActivity="true" >
            <listeners>
                 <add name="xml"/>
            </listeners>
          </source>
          <source name="System.ServiceModel.MessageLogging">
            <listeners>
                <add name="xml"/>
            </listeners>
          </source>
          <source name="myUserTraceSource"
                  switchValue="Information, ActivityTracing">
            <listeners>
                <add name="xml"/>
            </listeners>
          </source>
        </sources>
        <sharedListeners>
            <add name="xml"
                 type="System.Diagnostics.XmlWriterTraceListener"
                 initializeData="Error.svclog" />
        </sharedListeners>
      </system.diagnostics>
    </configuration>

    Best Regards,
    Amy Peng



    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.



    Tuesday, May 5, 2015 4:52 AM
    Moderator
  • Most likely, the service is running out of time to complete the process.
    Wednesday, May 13, 2015 1:31 PM
  • Hi NareshReddy Bomireddy,

    Based on your description, I know that your servie is running though the exception is raised, then as @DA924 said the service may run out of time to complete the process, so please try to increase the timeout in your service and client side to see if it works:

    <basicHttpBinding> <binding name="MyBasicHttpBinding" closeTimeout="00:20:00" openTimeout="00:20:00" receiveTimeout="00:20:00" sendTimeout="00:20:00"
    ...... </basicHttpBinding>

    Besides, please do not forget to apply the above binding configuration to the endpoint as following:

    <endpoint address="" binding="basicHttpBinding" 
    bindingConfiguration="MyBasicHttpBinding" contract="XXX">

    Best Regrads,
    Amy Peng





    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Monday, May 25, 2015 1:42 AM
    Moderator

All replies

  • Hi NareshReddy Bomireddy,

    >>"The I/O operation has been aborted because of either a thread exit or an application request".

    After meeting the above exception, please try to enter your wcf service address in the broswer (if your service is http service) to see if it works, if it does not work, it means that this exception will crash the wcf service. If so, please try to enable the WCF Trace to find some detailed error information or you can try to host the WCF in the IIS/Console application to see if it works.

    The following configuration taken from this MSDN article can be applied to enable tracing on your WCF Services.

    <configuration>
      <system.diagnostics>
        <sources>
          <source name="System.ServiceModel"
                  switchValue="Information, ActivityTracing"
                  propagateActivity="true" >
            <listeners>
                 <add name="xml"/>
            </listeners>
          </source>
          <source name="System.ServiceModel.MessageLogging">
            <listeners>
                <add name="xml"/>
            </listeners>
          </source>
          <source name="myUserTraceSource"
                  switchValue="Information, ActivityTracing">
            <listeners>
                <add name="xml"/>
            </listeners>
          </source>
        </sources>
        <sharedListeners>
            <add name="xml"
                 type="System.Diagnostics.XmlWriterTraceListener"
                 initializeData="Error.svclog" />
        </sharedListeners>
      </system.diagnostics>
    </configuration>

    Best Regards,
    Amy Peng



    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.



    Tuesday, May 5, 2015 4:52 AM
    Moderator
  • Thanks Amy. The Service running though the exception is raised.
    Wednesday, May 13, 2015 12:11 PM
  • Most likely, the service is running out of time to complete the process.
    Wednesday, May 13, 2015 1:31 PM
  • Hi NareshReddy Bomireddy,

    Based on your description, I know that your servie is running though the exception is raised, then as @DA924 said the service may run out of time to complete the process, so please try to increase the timeout in your service and client side to see if it works:

    <basicHttpBinding> <binding name="MyBasicHttpBinding" closeTimeout="00:20:00" openTimeout="00:20:00" receiveTimeout="00:20:00" sendTimeout="00:20:00"
    ...... </basicHttpBinding>

    Besides, please do not forget to apply the above binding configuration to the endpoint as following:

    <endpoint address="" binding="basicHttpBinding" 
    bindingConfiguration="MyBasicHttpBinding" contract="XXX">

    Best Regrads,
    Amy Peng





    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Monday, May 25, 2015 1:42 AM
    Moderator
  • I had similar errors coming from the depths of my http bindings in WCF.

    client -> The underlying connection was closed: An unexpected error occurred on a receive.

    client -> Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host.

    server -> The I/O operation has been aborted because of either a thread exit or an application request

    Eventually after many hours I came upon the HTTP.sys logging (in C:\WINDOWS\System32\LogFiles\HTTPERR ) and I discovered that the WCF self-hosted service connections were being forcibly dropped (on purpose) because of an obscure configuration issue (minimum send rate bytes per second). Unfortunately it took another few hours to reconfigure that (you cannot do it via "netsh http add timeout" so you have to do it within the app or within IIS when not self-hosted).


    David Beavon

    Thursday, September 10, 2015 12:41 PM