httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Williams" <dwi...@cisco.com>
Subject RE: beta?
Date Fri, 02 Feb 2001 06:10:56 GMT
> From: Ben Laurie [mailto:ben@algroup.co.uk]
> > > > James Sutherland wrote:
> > > > [snip]
> > > > >
> > > > > The question is, what "protocol" to use? Just sending a
> > > struct describing
> > > > > what's going on is one option; have each process send to a socket
> > > > > (UDP??) with the monitoring module/process running on?
> > > >
> > > > This is solution that works.
> > > >
> > > > However, I also miss still a protocol field in the
> > > > server_rec. If Apache can support multiple protocol
> > > > via protocol modules it is my opinion that each
> > > > server ('server_rec') needs to know which protocol
> > > > it serves.
> >
> > Seems that each server does need to know which protocol it is capable of
> > serving.  And in cases where it supports multiple ones, use the
> > request_rec->protocol field to determine how to handle that particular
> > request.
>
> Now you've lost me ... a "server" in this context is a binding of an IP
> address and port - it inherently "knows" what it should do through the
> configuration (which is derived from that binding).

I am under the impression that ap_hook_process_connection() was provided to
allow non-http protocol modules to hook into the processing path?  So that a
given server process (e.g. child_main() in prefork.c) could handle multiple
protocols, which could all be sent to the same port if desired.

>
> >
> > > ?? So how come mod_echo works without one of these?
> >
> > mod_echo might not be the best example, since it doesn't care about the
> > protocol at all, simply echoing what was received.
>
> Errr ... and how is this not a protocol? Wouldn't you be a little upset
> if your webserver thought that's what it should do?

I meant mod_echo is not a protocol in the sense that it cares about request.
It would treat
  GET http://www.foo.org HTTP/1.1
  METHOD_X  New_Transport_Protocol:Resource_locator  NTP/1.0
the same and hijack the incoming request.   Where as a more protocol aware
module would examine the PDU and decline the request if it doesn't
understand it.  Giving ap_process_http_connection() or other protocol
modules a chance to handle it.

-david

>
> Cheers,
>
> Ben.
>
> --
> http://www.apache-ssl.org/ben.html
>
> "There is no limit to what a man can do or how far he can go if he
> doesn't mind who gets the credit." - Robert Woodruff
>


Mime
View raw message