Re: new core module mod_version
On Fri, 30 Jan 2004 13:38:35 -0500 Glenn [EMAIL PROTECTED] wrote: And what about having directive namespaces to avoid having to search all modules for a directive? That is nothing, we want to avoid. Some directives want to be evaulated by more than one module (DECLINE_CMD). Alternatively, build a hash of directives when modules are loaded, which will be a one-time-cost. In fact. most configuration is already a one time approach (at startup). Together with the information above a simple hash would be bad, because order is important. Anyway, it may be interesting to build a hash of tolower(directive) - {module1, module2 ...} to speed up htaccess parsing. nd
Re: new core module mod_version
* Justin Erenkrantz [EMAIL PROTECTED] wrote: --On Wednesday, January 28, 2004 1:15 AM +0100 André Malo [EMAIL PROTECTED] wrote: I've uploaded the module here: http://cvs.apache.org/~nd/mod_version.c. The are some more detailed descriptions at the beginning of the file after the license. What do you think? +1 (concept). -- justin Well, thank you both. If there come no objections, I'll commit it these days into modules/metadata. nd
Re: new core module mod_version
Well, thank you both. If there come no objections, I'll commit it these days into modules/metadata. actually, while I still like the idea, does it make sense to broaden the scope of the module a bit? I had started a discussion on IfThreaded, which turned into more of an IfServerIs ... idea could ping ap_mpm_query and other things. the main objection, IIRC, was that people weren't too interested in adding more containers to core. so, if mod_version were to be renamed to something like mod_server_attribute (ok, too long, but I'm bad with names), then perhaps it could (eventually) be expanded to hold not only IfVersion but whatever other IfFOO server attributes people are intersted in. I still think that a container which could demark a threaded server would be valuable, even if the discussion died :) probably not what you had in mind, though - just a thought. if you like the idea, though, I'd commit it as is, just with a different name - no need to wait on other things first. --Geoff
Re: new core module mod_version
On Fri, Jan 30, 2004 at 10:46:11AM -0500, Geoffrey Young wrote: Well, thank you both. If there come no objections, I'll commit it these days into modules/metadata. actually, while I still like the idea, does it make sense to broaden the scope of the module a bit? I had started a discussion on IfThreaded, which turned into more of an IfServerIs ... idea could ping ap_mpm_query and other things. the main objection, IIRC, was that people weren't too interested in adding more containers to core. so, if mod_version were to be renamed to something like mod_server_attribute (ok, too long, but I'm bad with names), then perhaps it could (eventually) be expanded to hold not only IfVersion but whatever other IfFOO server attributes people are intersted in. I still think that a container which could demark a threaded server would be valuable, even if the discussion died :) probably not what you had in mind, though - just a thought. if you like the idea, though, I'd commit it as is, just with a different name - no need to wait on other things first. I think someone else previously mentioned something like this: IfAttr Module ... (replace IfModule) /IfAttr IfAttr Defined ...(replace IfDefine) /IfAttr IfAttr Version ... /IfAttr IfAttr MPM ... /IfAttr And what about having directive namespaces to avoid having to search all modules for a directive? Say an underscore. If the directive contains an underscore, then check for a module that registered that namespace (in a yet-to-be-defined table). If found, search the module for that directive. If not found, fall back to existing behavior. For example, RewriteBase RewriteCond RewriteEngine RewriteLock RewriteLog RewriteLogLevel RewriteMap RewriteOptions RewriteRule would become Rewrite_Base Rewrite_Cond Rewrite_Engine Rewrite_Lock Rewrite_Log Rewrite_LogLevel Rewrite_Map Rewrite_Options Rewrite_Rule Alternatively, build a hash of directives when modules are loaded, which will be a one-time-cost. Cheers, Glenn
Re: new core module mod_version
Geoffrey Young wrote: Well, thank you both. If there come no objections, I'll commit it these days into modules/metadata. actually, while I still like the idea, does it make sense to broaden the scope of the module a bit? I had started a discussion on IfThreaded, which turned into more of an IfServerIs ... idea could ping ap_mpm_query and other things. the main objection, IIRC, was that people weren't too interested in adding more containers to core. alternatively, mod_predefine that defines all sorts of wonderful symbols (platform, server version in different flavors, etc.) for use in IfDefine
Re: new core module mod_version
André Malo wrote: That has been long time on my todo (hello Stas! :-) There's a new module I'd like to add to the core distribution. It makes use of the new httpd version query function (ap_get_server_revision). It introduces IfVersion containers, where you can depend your config on a particular httpd version. I consider this as a very useful feature for test suites and big companies, which typically switch smoothly between versions. this is a nice idea. I had even started in on it myself not too long ago :) I've uploaded the module here: http://cvs.apache.org/~nd/mod_version.c. The are some more detailed descriptions at the beginning of the file after the license. What do you think? cool :) --Geoff
Re: new core module mod_version
--On Wednesday, January 28, 2004 1:15 AM +0100 André Malo [EMAIL PROTECTED] wrote: I've uploaded the module here: http://cvs.apache.org/~nd/mod_version.c. The are some more detailed descriptions at the beginning of the file after the license. What do you think? +1 (concept). -- justin
new core module mod_version
That has been long time on my todo (hello Stas! :-) There's a new module I'd like to add to the core distribution. It makes use of the new httpd version query function (ap_get_server_revision). It introduces IfVersion containers, where you can depend your config on a particular httpd version. I consider this as a very useful feature for test suites and big companies, which typically switch smoothly between versions. I've uploaded the module here: http://cvs.apache.org/~nd/mod_version.c. The are some more detailed descriptions at the beginning of the file after the license. What do you think? nd