A trip through Super Search didn't help much with this one, so hopefully someone has been down this road before.

We're starting to use mod_perl in our development as we expose "web services" interfaces to many of our backend systems. But I'm running into a problem that I can't figure a solution to.

We have a single Apache2 dev server. I've configured it with virtual hosts such that each developer has his/her own port. So, calling 192.168.0.100:8001 accesses my virtual host and port 8002 accesses another developer's virtual host.

Each virtual host entry has a "PerlSetEnv PERL5LIB" pointing to the /perllib directory in each developers' individual home directory, so /home/sheridancat/perllib and /home/otherguy/perllib.

In the base apache2 config file, I have the following:

PerlRequire "/etc/apache2/startup.pl" <Location /handleit> SetHandler perl-script PerlResponseHandler MyNamespace::Apache2::RequestHandler::HandleStuf +f </Location>
The problem is that which PerlResponseHandler is being called is ambiguous. It could be the version in /home/sheridancat/perllib or the one in /home/otherguy/perllib. If we're out of synch (like because one of us is working) there is frustration because the module in memory may not be the one being worked on.

My hope is that there's a way such that a call to port 8001 will grab /home/sheridancat/perllib/MyNameSpace... and a call to port 8002 will load /home/otherguy/perllib/MyNameSpace....

So, does anyone have any experience setting up mod_perl like this? Any help is appreciated.

SheridanCat


In reply to Writing mod_perl in multi-developer environment by SheridanCat

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.