ASP.Net timeouts

Discussion in 'ASP .Net' started by Mark, Aug 11, 2009.

  1. Mark

    Mark Guest

    Hi...

    We've got a page that's throwing HttpException "Request timed out" error
    messages and for the life of us we can't figure out why. One of the problems
    is that there is no stack trace with that exception so it's harder to figure
    out what it's doing when the clock runs out. Attaching a debugger obviously
    changes things.

    I've found a number of posts online where people say there are 2 event log
    messages for both the HttpException and the underlying ThreadAbortException.
    In the screen caps I've found the event log message for the
    ThreadAbortException includes the stack trace of the thread getting whacked.

    But on our systems, I only see one event log message for the HttpException.
    By default our application does have an error handler. I've tried changing
    it to do a Server.ClearError() and not, still no ThreadAbortException trace.

    I deleted the web config to get the handler out of the way; this changed the
    text of the HttpException message in the event log but still no
    ThreadAbortException and no trace.

    How does one get a stack trace of where the page was at the time of timeout?

    We're still using 2.0.50727.3082
    Mark, Aug 11, 2009
    #1
    1. Advertising

  2. Mark

    sloan Guest

    Its hard to give specific advice:

    http://support.microsoft.com/kb/911816

    Wire up the UnhandledExceptionModule, that'll usually expose the underlying
    issue.




    And/or wire up ELMAH
    http://www.hanselman.com/blog/ELMAHErrorLoggingModulesAndHandlersForASPNETAndMVCToo.aspx




    "Mark" <> wrote in message
    news:...
    > Hi...
    >
    > We've got a page that's throwing HttpException "Request timed out" error
    > messages and for the life of us we can't figure out why. One of the
    > problems
    > is that there is no stack trace with that exception so it's harder to
    > figure
    > out what it's doing when the clock runs out. Attaching a debugger
    > obviously
    > changes things.
    >
    > I've found a number of posts online where people say there are 2 event log
    > messages for both the HttpException and the underlying
    > ThreadAbortException.
    > In the screen caps I've found the event log message for the
    > ThreadAbortException includes the stack trace of the thread getting
    > whacked.
    >
    > But on our systems, I only see one event log message for the
    > HttpException.
    > By default our application does have an error handler. I've tried
    > changing
    > it to do a Server.ClearError() and not, still no ThreadAbortException
    > trace.
    >
    > I deleted the web config to get the handler out of the way; this changed
    > the
    > text of the HttpException message in the event log but still no
    > ThreadAbortException and no trace.
    >
    > How does one get a stack trace of where the page was at the time of
    > timeout?
    >
    > We're still using 2.0.50727.3082
    sloan, Aug 11, 2009
    #2
    1. Advertising

  3. Hi,

    >We've got a page that's throwing HttpException "Request timed out" error
    >messages and for the life of us we can't figure out why. One of the

    problems
    >is that there is no stack trace with that exception so it's harder to

    figure
    >out what it's doing when the clock runs out. Attaching a debugger

    obviously
    >changes things.


    >I've found a number of posts online where people say there are 2 event log
    >messages for both the HttpException and the underlying

    ThreadAbortException.
    >In the screen caps I've found the event log message for the
    >ThreadAbortException includes the stack trace of the thread getting

    whacked.

    From your description, the innerexception of this HttpException is null.
    There's no managed call stack on the thread that throws this exception.

    This behavior, based on my experience, is typically caused by
    executionTimeout is smaller than the real execution time. You can not get
    any managed call stack of the thread that throws this excetpion because
    there's no one. And it even doesn't make sense to get it because the tasks
    that potentially cause this issue are run by other threads.

    You can reproduce it if you set the executionTimeout to a small value and
    do a lot of time consuming taks in the processing request phase:
    <system.web>
    <httpRuntime executionTimeout="3" .../>
    ...
    </system.web>

    Please check out the following documentation for more details about this
    element:
    http://msdn.microsoft.com/en-us/library/e1f13641.aspx

    So, first, please let me know the approximate process time of the web
    request that causes this exception. You can do unit test to get the time.
    If it's longer than two minutes, most likely this is the culprit, if you're
    using the default setting of httpRuntime element.

    You can also add some trace at the begining/end of any time conusuming
    tasks. This will give you a clear picture of which task is done before this
    exception.

    If you use WinDbg to debug, please use the following command to list all
    call stack of managed threads:
    ~* e!clrstack
    In this way you can know what all managed threads are doing at that moment.

    Download Debugging Tools for Windows:
    http://www.microsoft.com/whdc/devtools/debugging/default.mspx

    Please keep me updated if you find anything. If you have further questions
    please feel free to ask. I'll do my best to follow up.

    Regards,
    Allen Chen
    Microsoft Online Support

    Delighting our customers is our #1 priority. We welcome your comments and
    suggestions about how we can improve the support we provide to you. Please
    feel free to let my manager know what you think of the level of service
    provided. You can send feedback directly to my manager at:
    .

    ==================================================
    Get notification to my posts through email? Please refer to
    http://msdn.microsoft.com/en-us/subscriptions/aa948868.aspx#notifications.

    Note: MSDN Managed Newsgroup support offering is for non-urgent issues
    where an initial response from the community or a Microsoft Support
    Engineer within 2 business day is acceptable. Please note that each follow
    up response may take approximately 2 business days as the support
    professional working with you may need further investigation to reach the
    most efficient resolution. The offering is not appropriate for situations
    that require urgent, real-time or phone-based interactions. Issues of this
    nature are best handled working with a dedicated Microsoft Support Engineer
    by contacting Microsoft Customer Support Services (CSS) at
    http://msdn.microsoft.com/en-us/subscriptions/aa948874.aspx
    ==================================================
    This posting is provided "AS IS" with no warranties, and confers no rights.
    Allen Chen [MSFT], Aug 12, 2009
    #3
  4. Hi,

    >We've got a page that's throwing HttpException "Request timed out" error
    >messages and for the life of us we can't figure out why. One of the

    problems
    >is that there is no stack trace with that exception so it's harder to

    figure
    >out what it's doing when the clock runs out. Attaching a debugger

    obviously
    >changes things.


    >I've found a number of posts online where people say there are 2 event log
    >messages for both the HttpException and the underlying

    ThreadAbortException.
    >In the screen caps I've found the event log message for the
    >ThreadAbortException includes the stack trace of the thread getting

    whacked.

    Do you have any progresss on this issue?

    Regards,
    Allen Chen
    Microsoft Online Support
    Allen Chen [MSFT], Aug 18, 2009
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?SmFzb24=?=

    forms authentication timeouts and session timeouts

    =?Utf-8?B?SmFzb24=?=, Jun 22, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    439
    =?Utf-8?B?SmFzb24=?=
    Jun 22, 2004
  2. =?Utf-8?B?RWQgQ2hpdQ==?=

    ASP.Net application session timeouts in 20 minutes

    =?Utf-8?B?RWQgQ2hpdQ==?=, May 4, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    411
    =?Utf-8?B?RWQgQ2hpdQ==?=
    May 4, 2005
  3. George Homorozeanu

    What are the timeouts that can be set in asp.net

    George Homorozeanu, Jun 17, 2005, in forum: ASP .Net
    Replies:
    3
    Views:
    10,666
    Juan T. Llibre
    Jun 17, 2005
  4. AV
    Replies:
    1
    Views:
    1,333
    djradon
    Mar 6, 2006
  5. Replies:
    0
    Views:
    321
Loading...

Share This Page