Re: Apache HTTP Request Prioritize

From: D. Stussy (kd6lvw_at_bde-arc.ampr.org)
Date: 07/26/03

  • Next message: jacco_at_honeypots.net: "Re: Security Tools RoundUp"
    Date: Sat, 26 Jul 2003 01:11:17 GMT
    
    

    On Fri, 25 Jul 2003, Joshua Slive wrote:
    > stevema@alum.berkeley.edu (Steve) wrote in message news:<c7a92151.0307250352.3f047f5b@posting.google.com>...
    > > Is it possible to configure Apache HTTP Server to prioritize incoming
    > > HTTP requests? Is there a HTTP request threading model that can be
    > > modified to detect certain requests (ie. base on IP) and assign them
    > > with higher priority so they can be processed to the application
    > > before other requests are served?
    >
    > I don't believe so.
    >
    > I'm no expert, but I expect it would be fairly easy to impliment.
    > You'd just need to have a module that stuck itself in the filter chain
    > and yielded the processor if it didn't have priority.
    >
    > But then what could likely happen on a busy server is that all the
    > available apache child threads/processes would get occupied with
    > non-priority requests. What you would need then is to only accept
    > "high priority" requests. But since
    > you can't tell if a request is high priority until it is accepted, you
    > are out
    > of luck.

    That part is true, except that when the next child process becomes available,
    it can select the highest priority request that is waiting. For it to be
    otherwise, it would have to suspend a [lower priority] request in process - in
    which case one may as well then make the web server part of the OS scheduler!

    Therefore, a partial solution is possible - with the problem of queuing
    requests when all "max_children" processes are busy, thus postponing a high
    priority request while serving the lower ones. However, is that significantly
    different from postponing a high priority request while all child processes are
    serving other high priority requests? :-)

    > An event-based server wouldn't have this problem. But progress on an
    > event-loop
    > mpm has been rather slow.

    And how is one going to predict events? The server has no control over whether
    or not there will even be another request, let alone what it might be.... Even
    if one has the time and spare resources to "pre-fetch" all the possible pages
    and links (except for user forms where the input cannot be anticipated), is it
    even worth the effort to do so? (I say not).


  • Next message: jacco_at_honeypots.net: "Re: Security Tools RoundUp"

    Relevant Pages

    • Re: pythons threading has no "interrupt"?
      ... > The language in question was a VM language with it's own internal ... > When a web request would come in, the handling of the request would be ... > temporarily halt and for the next process of equal priority that was ... > and terminate them (freeing up the process and socket resources, ...
      (comp.lang.python)
    • Re: Hi I have one web application and i want to get the number of users who are currently accessing
      ... Some user who has sent a request for a page and is now ... >>>to a list of online user objects. ... the server is only ever ... going to know when the user sends HTTP requests. ...
      (comp.lang.java.programmer)
    • Re: Counting with multiple criteria in separate Columns
      ... Strange thing is that I tried doing a countif with the same wildcard ... ADD or IF conditions, The spreadsheet accepted the formula; ... and Col E has the priority of the request. ...
      (microsoft.public.excel.misc)
    • [PATCH] Priorities in Anticipatory I/O scheduler
      ... Modifications to the Anticipatory I/O scheduler to add multiple priority ... Minimizes the latency of highest priority level. ... Higher priority request break any anticipating low priority request. ...
      (Linux-Kernel)
    • [PATCH] Priorities in Anticipatory I/O scheduler
      ... Modifications to the Anticipatory I/O scheduler to add multiple priority ... Minimizes the latency of highest priority level. ... Higher priority request break any anticipating low priority request. ...
      (Linux-Kernel)