MasonX::Apache2Handler

Experimental (beta) Mason/mod_perl2 interface
Download

MasonX::Apache2Handler Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Beau E. Cox
  • Publisher web site:
  • http://search.cpan.org/~beau/Env-Bash-0.04/lib/Env/Bash.pm

MasonX::Apache2Handler Tags


MasonX::Apache2Handler Description

Experimental (beta) Mason/mod_perl2 interface MasonX::Apache2Handler is a simple clone of Mason's HTML::Mason::ApacheHandler, and, as such, seems to be solid. However the components used, mod_perl 2 and libapreq2, are currently under development each give a version of the above warning.If you are interested in moving to mod_perl 2 when it reaches production status, I encourage you to try these modules in a test environment; your feedback will help getting mod_perl 2 out the door. I have been using this module on two live sites since mid-January 2004, with no problems.MasonX::Apache2Handler was written to allow Mason to run in a 'pure' mod_perl2/Apache2 environment using the mod_perl2 native request structure as implemented by libapreq2. This is an unofficial release, not supported by the Mason group. If you want to use this module in a testing environment, please address problems, issues, comments, and improvements to me, not Mason.When deciding to port Mason to mod_perl2 I took the approach to add Module(s) rather than patching core Mason modules. Upon investigation I discovered that all the Apache 'glue' code in Mason was contained in HTML::Mason::ApacheHandler. Therefore, I renamed and modified that module to create MasonX::Apache2Handler.The actual changes I made can be found in the distribution in diff/ApacheHandler.diff ( made with 'diff -Naru' ... ).As a result of my approach, you may install the normal Mason ( >= 1.25 ), the modules in "PREREQUISITES" below, and this module. After configuring ( see "CONFIGURATION" below ), you're ready to play.The Apache2Handler object links Mason to mod_perl2, running components in response to HTTP requests. It is controlled primarily through parameters to the new() constructor.handle_request() is not a user method, but rather is called from the HTML::Mason::handler() routine in handler.pl.MasonX::Apache2Handler is a modified copy of the standard HTML::Mason::ApacheHandler. Apache2Handler MUST be used with mod_perl2.You may, however, run Mason with Apache2/mod_perl2 without Apache2Handler (see my rather dated mini-HOWTO at http://beaucox.com/mason/mason-with-apmp2-mini-HOWTO.htm), but you then use use 'CGI' requests rather than the native 'mod_perl' requests.The interface is the same as ApacheHandler's, Please refer to HTML::Mason, HTML::Mason::ApacheHandler, and http://masonhq.com/docs/manual/Admin.html.SYNOPSIS use MasonX::Apache2Handler; my $ah = MasonX::Apache2Handler->new (..name/value params..); ... sub handler { my $r = shift; $ah->handle_request($r); } Requirements: · Perl


MasonX::Apache2Handler Related Software