httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Bloom <>
Subject Which thread/process
Date Thu, 12 Aug 1999 14:52:56 GMT

Okay, we took out the only place in the 2.0 tree where we designated a
unique number for each thread within each process.  Namely, the
thread_num/child_num pair in the conn_rec.  So how am I now supposed to
get a deterministic value for the exact thread I am running in?

I am re-vamping mod_cgid to correct some of the issues that were brought
up the last time I posted it to the listserv.  One of the issues was that
I was creating a big array of named pipes names, to use for the
communication.  It was suggested I don't create the array, opting for
re-creating the pipe name when I need it, instead.  Without a way to get a
deterministic name, this is not possible.  I'm not even sure if the old
method would work without this information.  As I said when we were
removing this information, I think we removed it FAR too quickly without
thinking of the implications.  I would like to put back the thread_num and
child_num unless somebody else can give me a way to get this information.

For anybody who doesn't remember, mod_cgid is a module that creates a cgi
daemon.  It is VERY expensive on most *nix's to fork a threaded process,
because all of the memory for all of the threads is copied, even though
only one thread is active.  To get around this problem, mod_cgid creates
it's own cgi daemon at initialization time, and for all cgi's it, it forks
this single-threaded daemon.  Before anybody asks this time, this is not
like cgisock.  My goal is to keep 100% backward compatability.  cgisock
does not do this.  cgisock will not run standard cgi's.  mod_cgid MUST run
standard cgi's.


Ryan Bloom
4205 S Miami Blvd	
RTP, NC 27709		It's a beautiful sight to see good dancers 
			doing simple steps.  It's a painful sight to
			see beginners doing complicated patterns.	

View raw message