[...]e.g. Apache::document_root living in Apache vs Apache::ServerUtil::document_root living where it is now (Apache::ServerUtil)
actually, it lives in RequestUtil, though it probably should be in ServerUtil.
I grep'd through the code and here are the Apache:: functions I find
for the unescape_url(), LOG_MARK(), and log_pid(), I see no reason why they can't live in the classes that define them (that is, changing it to Apache::URI::unescape_url)
+1
my reading of method_register() is that it's global to all requests - it doesn't make sense to define a new http method during a request. so, move that to Apache::Server::method_register() (defined in ServerUtil)
It actually does, see the example at: http://perl.apache.org/docs/2.0/user/handlers/http.html#PerlHeaderParserHandler though I see no reason why not to have Apache::Server::method_register()
+1
add_version_component(), exists_config_define(), get_server_built(), get_status_line(), and get_server_version() are all built-in server properties, so put them in Apache::Server as well (defined in ServerUtil).
+1
server_root_relative() belongs in ServerUtil, so Apache::Server::server_root_relative() here too.
+1
current_callback() is a tough one. maybe we could do it similar to server_root_relative: support only object methods but both $s->current_callback and $r->current_callback, since it's phase related.
why? if it can work transparently to where it is called from, why complicating it with requiring an object? I think it's just fine with how it is. Just move it to Apache::Server::current_callback. Actually I thought that it really belongs to ModPerl::Util::current_callback since it gives us mp callbacks, not the apache ones.
that leaves Apache::request and Apache::server. I may have changed my mind about these, thinking it best to keep them where they are. But Apache::RequestRec->new() and Apache::Server->new() also have a certain appeal, so long as everyone understand the singleton-esque nature of the constructors.
I'm not sure what new() has to do with it. But I'm certainly fine with Apache::RequestRec->request and Apache::Server->server I'd even add the current_ into the API. Do you think they need to be class methods and not just functions?
This change will require special "ifdef" on the modperl version in certain CPAN modules, like CGI.pm :( So it's not only about those brave bleeding edge users, but CPAN authors hell.
__________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]