Concurrent processing of ASP.NET pages

Discussion in 'ASP .Net' started by Hitesh, Sep 29, 2006.

  1. Hitesh

    Hitesh Guest

    We all know that IIS and asp.net are suppose to be muti-threaded
    applications running on a pre-emptive multi-tasking model. But, what I
    have
    found is that under the default installation of ASP.NET, aspx pages get

    executed serially. I know that it's easy to say that this can't be
    right,
    but I have found threads where others have confirmed this same
    behavior.


    The situation is _very_ easy to reproduce. Simply place two aspx pages
    on a
    web site, on the one page put some code that will take a bit to execute
    (say
    a while loop) and on the other page simply put some text (perhaps
    "hello").
    Now open two browser windows, in the first browser open the long
    running
    page, now in the second window open the hello page. What you will find
    is
    that you will not receive the hello page until the long running page
    completes and is sent to the browser. The pages are running serially
    on the
    server!


    How does one configure asp.net so that the pages run under a preemptive

    multitasking model?
    Hitesh, Sep 29, 2006
    #1
    1. Advertising

  2. The pages are not running serially, your requests are - and as they are from
    the same client they are dealt with serially.

    Fish about on google, but if I remember correctly this can happen if you
    open IE and then do new window, both IE sessions are the same. Try running
    IE and then run another instance of IE rather than a new IE window. You
    should get a different session ID and thus non-sequential requests.

    --
    Regards

    John Timney (MVP)
    VISIT MY WEBSITE:
    http://www.johntimney.com


    "Hitesh" <> wrote in message
    news:...
    > We all know that IIS and asp.net are suppose to be muti-threaded
    > applications running on a pre-emptive multi-tasking model. But, what I
    > have
    > found is that under the default installation of ASP.NET, aspx pages get
    >
    > executed serially. I know that it's easy to say that this can't be
    > right,
    > but I have found threads where others have confirmed this same
    > behavior.
    >
    >
    > The situation is _very_ easy to reproduce. Simply place two aspx pages
    > on a
    > web site, on the one page put some code that will take a bit to execute
    > (say
    > a while loop) and on the other page simply put some text (perhaps
    > "hello").
    > Now open two browser windows, in the first browser open the long
    > running
    > page, now in the second window open the hello page. What you will find
    > is
    > that you will not receive the hello page until the long running page
    > completes and is sent to the browser. The pages are running serially
    > on the
    > server!
    >
    >
    > How does one configure asp.net so that the pages run under a preemptive
    >
    > multitasking model?
    >
    John Timney \(MVP\), Sep 29, 2006
    #2
    1. Advertising

  3. Hitesh

    Hitesh Guest

    Thanks John for correcting me.

    I am using two different instances of IE. I mean with different
    sessionID's.

    Hitesh

    John Timney (MVP) wrote:
    > The pages are not running serially, your requests are - and as they are from
    > the same client they are dealt with serially.
    >
    > Fish about on google, but if I remember correctly this can happen if you
    > open IE and then do new window, both IE sessions are the same. Try running
    > IE and then run another instance of IE rather than a new IE window. You
    > should get a different session ID and thus non-sequential requests.
    >
    > --
    > Regards
    >
    > John Timney (MVP)
    > VISIT MY WEBSITE:
    > http://www.johntimney.com
    >
    >
    > "Hitesh" <> wrote in message
    > news:...
    > > We all know that IIS and asp.net are suppose to be muti-threaded
    > > applications running on a pre-emptive multi-tasking model. But, what I
    > > have
    > > found is that under the default installation of ASP.NET, aspx pages get
    > >
    > > executed serially. I know that it's easy to say that this can't be
    > > right,
    > > but I have found threads where others have confirmed this same
    > > behavior.
    > >
    > >
    > > The situation is _very_ easy to reproduce. Simply place two aspx pages
    > > on a
    > > web site, on the one page put some code that will take a bit to execute
    > > (say
    > > a while loop) and on the other page simply put some text (perhaps
    > > "hello").
    > > Now open two browser windows, in the first browser open the long
    > > running
    > > page, now in the second window open the hello page. What you will find
    > > is
    > > that you will not receive the hello page until the long running page
    > > completes and is sent to the browser. The pages are running serially
    > > on the
    > > server!
    > >
    > >
    > > How does one configure asp.net so that the pages run under a preemptive
    > >
    > > multitasking model?
    > >
    Hitesh, Sep 29, 2006
    #3
  4. there are two causes for this.

    1) the two browsers are using the same session. say you opened the second
    one from IE's new window rather than from the start menu. asp.net serializes
    accss to session.

    2) IE limits the number of requests to the same server, so will serial the
    requests. yucan bump this up in the registry.

    -- bruce (sqlwork.com)

    "Hitesh" <> wrote in message
    news:...
    > We all know that IIS and asp.net are suppose to be muti-threaded
    > applications running on a pre-emptive multi-tasking model. But, what I
    > have
    > found is that under the default installation of ASP.NET, aspx pages get
    >
    > executed serially. I know that it's easy to say that this can't be
    > right,
    > but I have found threads where others have confirmed this same
    > behavior.
    >
    >
    > The situation is _very_ easy to reproduce. Simply place two aspx pages
    > on a
    > web site, on the one page put some code that will take a bit to execute
    > (say
    > a while loop) and on the other page simply put some text (perhaps
    > "hello").
    > Now open two browser windows, in the first browser open the long
    > running
    > page, now in the second window open the hello page. What you will find
    > is
    > that you will not receive the hello page until the long running page
    > completes and is sent to the browser. The pages are running serially
    > on the
    > server!
    >
    >
    > How does one configure asp.net so that the pages run under a preemptive
    >
    > multitasking model?
    >
    bruce barker \(sqlwork.com\), Sep 29, 2006
    #4
  5. Hitesh

    Hitesh Guest

    Bruce,

    Point 1 is not the case with me.

    Could you please give me some more detail on Point 2 .Actually i am
    accessing a Page on which I am sending multiple async requests. But
    response is coming seuentiall.

    I found that IIS is hadling the request serially.


    bruce barker (sqlwork.com) wrote:
    > there are two causes for this.
    >
    > 1) the two browsers are using the same session. say you opened the second
    > one from IE's new window rather than from the start menu. asp.net serializes
    > accss to session.
    >
    > 2) IE limits the number of requests to the same server, so will serial the
    > requests. yucan bump this up in the registry.
    >
    > -- bruce (sqlwork.com)
    >
    > "Hitesh" <> wrote in message
    > news:...
    > > We all know that IIS and asp.net are suppose to be muti-threaded
    > > applications running on a pre-emptive multi-tasking model. But, what I
    > > have
    > > found is that under the default installation of ASP.NET, aspx pages get
    > >
    > > executed serially. I know that it's easy to say that this can't be
    > > right,
    > > but I have found threads where others have confirmed this same
    > > behavior.
    > >
    > >
    > > The situation is _very_ easy to reproduce. Simply place two aspx pages
    > > on a
    > > web site, on the one page put some code that will take a bit to execute
    > > (say
    > > a while loop) and on the other page simply put some text (perhaps
    > > "hello").
    > > Now open two browser windows, in the first browser open the long
    > > running
    > > page, now in the second window open the hello page. What you will find
    > > is
    > > that you will not receive the hello page until the long running page
    > > completes and is sent to the browser. The pages are running serially
    > > on the
    > > server!
    > >
    > >
    > > How does one configure asp.net so that the pages run under a preemptive
    > >
    > > multitasking model?
    > >
    Hitesh, Oct 3, 2006
    #5
  6. Somehow I am positive that point 1 is the case with you .
    But anyway.
    By default IE issues 4 simultaneous requests to the same server. All others
    are put on hold.

    It's done to prevent you killing your network with 100s simultaneous
    requests if html page has 100s pictures on it.

    Check http://www.speedguide.net/ they have a registry tweak that will bump
    that number (4) up.

    George.


    "Hitesh" <> wrote in message
    news:...
    > Bruce,
    >
    > Point 1 is not the case with me.
    >
    > Could you please give me some more detail on Point 2 .Actually i am
    > accessing a Page on which I am sending multiple async requests. But
    > response is coming seuentiall.
    >
    > I found that IIS is hadling the request serially.
    >
    >
    > bruce barker (sqlwork.com) wrote:
    >> there are two causes for this.
    >>
    >> 1) the two browsers are using the same session. say you opened the second
    >> one from IE's new window rather than from the start menu. asp.net
    >> serializes
    >> accss to session.
    >>
    >> 2) IE limits the number of requests to the same server, so will serial
    >> the
    >> requests. yucan bump this up in the registry.
    >>
    >> -- bruce (sqlwork.com)
    >>
    >> "Hitesh" <> wrote in message
    >> news:...
    >> > We all know that IIS and asp.net are suppose to be muti-threaded
    >> > applications running on a pre-emptive multi-tasking model. But, what I
    >> > have
    >> > found is that under the default installation of ASP.NET, aspx pages get
    >> >
    >> > executed serially. I know that it's easy to say that this can't be
    >> > right,
    >> > but I have found threads where others have confirmed this same
    >> > behavior.
    >> >
    >> >
    >> > The situation is _very_ easy to reproduce. Simply place two aspx pages
    >> > on a
    >> > web site, on the one page put some code that will take a bit to execute
    >> > (say
    >> > a while loop) and on the other page simply put some text (perhaps
    >> > "hello").
    >> > Now open two browser windows, in the first browser open the long
    >> > running
    >> > page, now in the second window open the hello page. What you will find
    >> > is
    >> > that you will not receive the hello page until the long running page
    >> > completes and is sent to the browser. The pages are running serially
    >> > on the
    >> > server!
    >> >
    >> >
    >> > How does one configure asp.net so that the pages run under a preemptive
    >> >
    >> > multitasking model?
    >> >

    >
    George Ter-Saakov, Oct 3, 2006
    #6
  7. Hitesh

    Hitesh Guest

    I tried running the same scenario on the machine with windows 2003
    server and IIS 6 installed. It is giving the expected results.Requests
    are handled parallely and results are according to the default IE
    settings


    But on the machine having Windows XP and IIS 5.0 the requests are
    handled serially as i mentioned.

    I also tried running the same scenario on the machine having Dual
    processor with windows XP and IIS 5.0.This is also giving the expected
    result.


    Did anyone of you is able to re-produce the same on your end?

    George Ter-Saakov wrote:
    > Somehow I am positive that point 1 is the case with you .
    > But anyway.
    > By default IE issues 4 simultaneous requests to the same server. All others
    > are put on hold.
    >
    > It's done to prevent you killing your network with 100s simultaneous
    > requests if html page has 100s pictures on it.
    >
    > Check http://www.speedguide.net/ they have a registry tweak that will bump
    > that number (4) up.
    >
    > George.
    >
    >
    > "Hitesh" <> wrote in message
    > news:...
    > > Bruce,
    > >
    > > Point 1 is not the case with me.
    > >
    > > Could you please give me some more detail on Point 2 .Actually i am
    > > accessing a Page on which I am sending multiple async requests. But
    > > response is coming seuentiall.
    > >
    > > I found that IIS is hadling the request serially.
    > >
    > >
    > > bruce barker (sqlwork.com) wrote:
    > >> there are two causes for this.
    > >>
    > >> 1) the two browsers are using the same session. say you opened the second
    > >> one from IE's new window rather than from the start menu. asp.net
    > >> serializes
    > >> accss to session.
    > >>
    > >> 2) IE limits the number of requests to the same server, so will serial
    > >> the
    > >> requests. yucan bump this up in the registry.
    > >>
    > >> -- bruce (sqlwork.com)
    > >>
    > >> "Hitesh" <> wrote in message
    > >> news:...
    > >> > We all know that IIS and asp.net are suppose to be muti-threaded
    > >> > applications running on a pre-emptive multi-tasking model. But, what I
    > >> > have
    > >> > found is that under the default installation of ASP.NET, aspx pages get
    > >> >
    > >> > executed serially. I know that it's easy to say that this can't be
    > >> > right,
    > >> > but I have found threads where others have confirmed this same
    > >> > behavior.
    > >> >
    > >> >
    > >> > The situation is _very_ easy to reproduce. Simply place two aspx pages
    > >> > on a
    > >> > web site, on the one page put some code that will take a bit to execute
    > >> > (say
    > >> > a while loop) and on the other page simply put some text (perhaps
    > >> > "hello").
    > >> > Now open two browser windows, in the first browser open the long
    > >> > running
    > >> > page, now in the second window open the hello page. What you will find
    > >> > is
    > >> > that you will not receive the hello page until the long running page
    > >> > completes and is sent to the browser. The pages are running serially
    > >> > on the
    > >> > server!
    > >> >
    > >> >
    > >> > How does one configure asp.net so that the pages run under a preemptive
    > >> >
    > >> > multitasking model?
    > >> >

    > >
    Hitesh, Oct 4, 2006
    #7
    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. Manish
    Replies:
    1
    Views:
    634
    Steve C. Orr [MVP, MCSD]
    Nov 17, 2003
  2. Balbir Singh

    IIS not processing ASP.Net pages

    Balbir Singh, Jan 13, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    455
    Balbir Singh
    Jan 13, 2004
  3. Pep
    Replies:
    6
    Views:
    810
  4. trilla

    JMS Concurrent processing

    trilla, Nov 29, 2005, in forum: Java
    Replies:
    0
    Views:
    349
    trilla
    Nov 29, 2005
  5. Gilles Ganault

    Concurrent threads to pull web pages?

    Gilles Ganault, Oct 1, 2009, in forum: Python
    Replies:
    5
    Views:
    330
Loading...

Share This Page