httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian Pratt <Brian.Pr...@watchguard.com>
Subject [users@httpd] data collection module for apache 2 - has anyone tried anything l ike this?
Date Tue, 27 Aug 2002 00:41:48 GMT
Greetings all:

Hopefully this is an interesting one:  I'm trying to do something fairly
strange with Apache 2 in its capacity as a multiprotocol server (Apache:
it's not just for breakfast anymore!).  I want to set it up to collect data
from a device which uses a proprietary binary format+protocol over TCP/IP on
a configurable port (ie NOT port 80).  This scheme is a legacy that I don't
have any control over, and I need to reimplement the server that collects
the data from these devices in order to get to new platforms, among other
things.   

Why do this with Apache?  Well, all my other server needs are handily met by
Apache, so I could have a single install, and it would be nice to have all
the crunchy goodness of MPMs for talking to a bunch (hundreds) of these
legacy devices all at the same time.  Otherwise I'm looking at using ACE or
somesuch to get that nice connection multiplexing - but it just seems silly
to be implementing yet another server.

I've tinkered with the 'modules/experimental/example' code from the Apache
2.0.40 distro, using it as a basis for implementing my module's own versions
of the various hookable steps in the cycle.  I'm to the point where for each
hook my module can look at the port number and decline if it isn't the one
used by this protocol.  I've used the logging facility to verify that the
decline/OK logic works.  So, I'd think that I should at this point be able
to telnet to my server on and type in any sort of garbage (like "dddd")
without the server barking.  But it seems that mod_http ultimately still
gets in there and tries to deal with the connection as if it was HTTP:
[Mon Aug 26 17:04:47 2002] [error] [client 10.0.1.1] Invalid method in
request dddd

So my question is, has anybody else tried to do anything as twisted as this?
I know Covalent has done a nice Apache-based FTP server, but I'm wondering
if there's some built-in bias in Apache toward protocols where the commands
are human readable.  It seems like this should be possible, I feel like I've
simply missed something and wonder if anyone else has trod this path before.
If so, I could use some tips and tricks if anyone has a ready supply.  For
simplicity the problem can be pared down to "accept a simple TCP connection
from anywhere and copy fixed-sized chunks of data from the stream to a file
until the client kills the connection".

Thanks In Advance,

Brian

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message