Robert Landrum <[EMAIL PROTECTED]> wrote:
> Tracy12 wrote:
> >How can we retrieve the URL Scheme (http/https ?) from a perl module, Port
> >given that only input parameter is $r
> >
> >should we use my $uri = Apache::URI->parse($r) and $uri->scheme;
> I use $r->get_server_port. If it's 80 i
Will Fould <[EMAIL PROTECTED]> wrote:
> I've started testing a handler (configured at '/') that parses $r->uri and
> checks the object, doing a redirect accordingly, but this seems wasteful for
> every hit.
> I've thought about using the handler for only 404...
>
> How can this most effeciently be
Has anybody figured this out yet? Is there going to be a new version of
mod_perl coming out soon that fixes this problem? It seems pretty serious...
- Tyler
--- Begin Message ---
I just upgraded to httpd 2.2.2 and tried to install mod_perl. This upgrade
was made on top of my existing 2.2.0
Matthew <[EMAIL PROTECTED]> wrote:
> It could be that I just don't understand completely the nature of
> mod_perl, but here goes.
>
> Reason I'm confused is because there exists CGI::Cookie for handling
> cookies in MP2, but there's also the libapreq library "for MP2". It
> seems to me that th
Lionel MARTIN <[EMAIL PROTECTED]> wrote:
> To be honest, I'm running Apache, mod_perl and DBI under Win32 (+Mason) and
> I can't complain about it.
>
> I'd like to test and compare with LAMP to see what's the best (in term of
> speed and memory managament), but what you told me made me jump, thi
Jie Gao <[EMAIL PROTECTED]> wrote:
> Hi All,
>
> Any issue with this combination? For I am getting:
Yes, there are. Me and at least 3 friends have run into it now. What
you need to do, is compile mod_perl 2.0.2 against apache 2.2.0, then upgrade
apache and leave your old mod_perl in place
Thomas Hilbig <[EMAIL PROTECTED]> wrote:
> I was getting the error even from running perl
> interactively
> linux>perl
> use CGI ;
> Can't locate Apache.pm in @INC
>
> I think the problem may be that I am simply missing
> the MOD_PERL_API_VERSION environment variable in my
> shell environment. I
Thomas Hilbig <[EMAIL PROTECTED]> wrote:
> > Ack! Before you drive yourself nuts with this, read
> > this page:
> >
> > http://perl.apache.org/docs/2.0/rename.html
> I shouldn't have to clean up the perl tree of old
> Apache*.pm stuff as I blew away the whole tree by
> renaming it. Now, i
Thomas Hilbig <[EMAIL PROTECTED]> wrote:
> I tried to reinstall CGI, Bundle::Apache2, but still
> got the error. Finally, I renamed the /usr/lib/perl5
> directory and am trying to reinstall Perl 5.8.8 from
> source tar. However, in the "make test" section I am
> still getting the same errors on a
I just upgraded to httpd 2.2.2 and tried to install mod_perl. This upgrade
was made on top of my existing 2.2.0 installation. Here's what happens when
I run "make" in mod_perl's source directory:
$ make
cd "src/modules/perl" && make
make[1]: Entering directory
/home/faraway/src/mod_perl-2.0.2/src/
Jonathan Vanasco <[EMAIL PROTECTED]> wrote:
>
> I'd like to flag whether my app is running on dev or prod with a
> variable that's in httpd.conf
> ( right now i manually toggle a var in a config file, and its driving
> me nuts )
>
> i wanted to use PerlSetVar, but that's read at request time
Igor Chudov <[EMAIL PROTECTED]> wrote:
> I run algebra.com with a few thousand registered users and a lot more
> unregistered. I use Apache::Session to store their session info. Right
> now I clean sessions every month. I would like to be smarter and clean
> sessions based on date information (ie r
Happy 4/20! After over a year of hiatus, mod_bt 0.0.14 has been released.
This is primarily a maintenence release to make compiling and portability
easier, restore mod_perl2 compatibility (when 0.0.13 was released they were
still using the Apache:: namespace and had an Apache2.pm) and get us in
po
Does the path to the apr-config that was used to build mod_perl2 get saved
anywhere? There's an "apr_config_path" method in Apache2::Build, but this is
what I get when I run it:
[EMAIL PROTECTED]:/opt/apache2/perl5lib$ perl -I. -MApache2::Build -e 'print
Apache2::Build->new->apr_config_path'
Use o
I want to run system tests on my mod_perl2 handlers using
Apache::Test after my application is installed. Ideally, I don't want any
Makefile.PL / etc around, I'd rather just have the individual tests do their
own setup and teardown. Has anybody else done this / got any tips?
Thanks
I just got some cpan testers reports on a new module, CGI::JSONRPC. 1 pass,
2 failures. One of the failures seems to be my fault, but the other one
seems really odd:
http://www.nntp.perl.org/group/perl.cpan.testers/298838
The odd part is here:
[ERROR] [Wed Mar 15 10:06:14 2006] MAKE TEST failed:
Apache2::JSONRPC and CGI::JSONRPC have entered CPAN:
http://search.cpan.org/~crakrjack/CGI-JSONRPC-0.01/
It is an attempt to leverage the jsonrpc protocol (http://json-rpc.org) in
an object-oriented perl environment. It obeys the JSONRPC spec, with a perl
twist:
* All requests pass the n
Arne Skjaerholt <[EMAIL PROTECTED]> wrote:
> Hi,
> All the Apache constants are available in the Apache2::Const module. See
> perldoc Apache2::Const for details on how to import symbols and so on.
You know, I'm probably asking this question on the wrong list. :-)
httpd-2.0.53/incl
I see that there's a $r->header_only method... but every other method (GET,
POST, and even exotic ones like CHECKOUT) have an M_ constant... I'm
guessing that this carries over from the apache2 API, but I'm curious, is
there a good reason for this or is it just how things ended up? It seems
like it
Foo Ji-Haw <[EMAIL PROTECTED]> wrote:
> The basis for the need is because I am thinking of having my process
> call itself (but another uri) to activate another process.
>
> Appreciate any tips you can offer. Thanks.
According to the docs a PerlCleanupHandler may do the trick:
http://pe
I have a function that does this to get database settings, to test an
apache2 handler that uses a database:
sub test_db {
my $build = Apache::TestMB->current;
return unless $build->notes('DBI_DSN');
return map {
defined $build->notes($_) ? $build->notes($_) : ''
} qw(DBI_DS
I've found the TestCommon::LogDiff package in the mod_perl unit tests to be
useful in testing my own mod_perl-based packages, and I can see how it would
be useful in lots of other applications as well.
Could a separate distribution (Test::LogDiff, say) be made out of it so that
it's easily re-used
;re looking for the mod_perl equivalent of the php scriptname or
> whatever its called. that i don't know.
>
> sorry for the confusion.
>
>
>
> On Feb 22, 2006, at 7:32 PM, Tyler MacDonald wrote:
>
> > What class is that method a part of? I didn't
Jonathan Vanasco <[EMAIL PROTECTED]> wrote:
>
> is this what you want?
> $apr->location()
What class is that method a part of? I didn't see anything about
"location" in PerlSections...
Apache2::Directive seems to have what I'm after (filename and
line_num methods), if I co
Harry Zhu <[EMAIL PROTECTED]> wrote:
> Say I have a file directory with hundreds of modules, I want to know if
> there is a tool I can scan and identify the uninitalized variables in all
> the files once (or through a loop) without actually running through all the
> pages.
If you don't
I've been poking around in the documentation but I can't seem to
find this... Is there any way for a section in a httpd.conf file to
know what file it's been evaluated out of? Ideally I'd like to be able to do
something similar to this for packaging mod_perl handlers and apache
configurati
Harry Zhu <[EMAIL PROTECTED]> wrote:
> "use strict" will find the undeclared/undefined variables.
>
> something like
> my $var;
>
> and later on used in the program will not be find by the "use strict", but
> will cause "use uninitialized variables" warnings if -w switch is on.
If you
Tyler MacDonald <[EMAIL PROTECTED]> wrote:
> I'm writing a handler whose goal is to set an environment variable, then
> issue an internal redirect to another page;
>
> $r->subprocess_env("FOO", "bar");
> $r->internal_redirect("/somew
I'm writing a handler whose goal is to set an environment variable, then
issue an internal redirect to another page;
$r->subprocess_env("FOO", "bar");
$r->internal_redirect("/somewhere/else");
The problem is that when the redirected page loads, my "FOO" environment
variable has become "REDIRE
Daniel McBrearty <[EMAIL PROTECTED]> wrote:
> I'm currently using mysql, but I'm considering changing over to firebird or
> postgre.
>
> Anyone have any reasoned loves/hates/useful experiences to pass on?
I love postgresql!
OK, to make it reasoned:
* Better license than
Mark Galbreath <[EMAIL PROTECTED]> wrote:
> Why is brian d joy's name uncapitalized on the cover of the 4th edition of
> the Llama book?
I always thought it was brian d foy (http://search.cpan.org/~bdfoy/).. and
he did it because he likes it that way. :)
- Tyler
Here's what I've got so far:
http://search.cpan.org/src/CRAKRJACK/Schema-RDBMS-AUS-0.01/Build.PL
I'm forcing the "install" action to fail without the Module::Build subclass
in DBIx::Migration::Directories (which I've noticed lately has a few
similarities with App::Build), because without
Foo Ji-Haw <[EMAIL PROTECTED]> wrote:
> > I knew that perl could do OO and I couldn't find
> > design patterns to go to the next step.
> You brought up a good point. I wish someone will write a Design Patterns
> book based on Perl...
This helps:
http://perldesignpatterns.com/perld
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> > My biggest complaint for perl for web apps, however,
> > is the templating. I haven't found a template module
> > in perl that rivals Smarty templates in PHP.
> It sounds like you somehow missed Template Toolkit:
> http://www.template-toolkit.org/docs/
Mark Galbreath <[EMAIL PROTECTED]> wrote:
> No, I'm saying modules that have been upgraded to 8.7 may no longer work
> in a 5.6 envirnoment. Mine didn't.
Ahh. I'd upgrade to 5.8 in that case. ;-)
> Way cool. Where (geographically) ru?
Vancouver, BC, Canada.
- T
Mark Galbreath <[EMAIL PROTECTED]> wrote:
> At the office, installing ActivePerl just annoyed the sysadmins because it
> didn't really break anything but I found myself in the position of begin
> able to take advantage of some pretty cool modules (like IO::ALL, e.g.)
> that have been upgraded or de
Bennett Haselton <[EMAIL PROTECTED]> wrote:
> But, just to make sure, I tried doing it again -- ran the command
> find /usr/lib/perl5 -name 'Apache2*' -exec rm -rf {} \;
> to clean out those files, and then did
> perl Makefile.PL MP_APXS=/usr/sbin/apxs
There's also files named "mod_perl.pm
rguing about it. I
like a good argument. ;-)
- Tyler
>
> >>> Tyler MacDonald [EMAIL PROTECTED]> 01-Feb-06 17:06 PM >>
>
> Yeah, I ditched Apache::DBI early in diagnosing this problem. Then I
> wrote that hack to solve it, which is what has sta
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> > And here's some more conjecture: What if the ping just times out
> > because the server is really, really busy?
> DBI will replace it, removing all references to the one that failed to
> ping, and it will go out of scope and get DESTROY'ed.
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> > Yes and no. If you can't ping the server, but the TCP socket is
> > still open, that means you essentially have this TCP connection to the
> > server that's not being used, in an open state, for the rest of the lifetime
> > of your apache server ins
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> > I am opening a handle before apache forks. However, I was
> > able to verify that Apache::DBI wasn't loaded yet at that point (no
> > $INC{'Apache/DBI.pm'}), and I was issuing a disconnect() before the fork
> > took place.
> If Apache::DBI w
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> I've never seen Apache::DBI or connect_cached return a dead handle. I
> have had problems in the past with forking apps where I get back a
> handle that still pings but has been shared across processes so it no
> longer really works. Were you doing s
Apache::DBI and DBI's connect_cached both claim to keep your database
handles fresh and happy, but I've had numerous problems trying to get either
of them to work properly. If a database connection is dropped, sometimes I'd
have to refresh the page two or three times before the "internal server
err
Mark Galbreath <[EMAIL PROTECTED]> wrote:
> Close enough to perl, I hope...
>
> I'm trying to string the filename from the path:
>
>/dir/subdir/file.ext => file.ext
>
> with
>
> /\w+\.\w+$/
>
> and am getting the entire path returned. I am falling asleep reading the
> perldoc regex
allan juul <[EMAIL PROTECTED]> wrote:
> actually we can remove that stuff from the style sheet since they were
> introduced when trying to avoid using a transparent gif. a recent update
> on the src files this transparent gif was introduced making those class
> selectors unnesecary
>
> i'll send a
Hey,
Since the new FireFox displays CSS parsing errors in the javascript
console, my daily visits to perl.apache.org have resulted in that filling up
rather quickly with the same two errors:
Error: Error in parsing value for property 'display'. Declaration dropped.
Source File: http://per
<[EMAIL PROTECTED]> wrote:
> but, if i had a project, i want put the all thing a directory. Can i do like
> that? if I don't use the ModPerl::Registry or edit the ModPerl::Registry,
> that is correct? or there are the other way? thanks.
Do you mean have real Apache2 request handlers (
> On the other hand, I have some funky code going on after trying to deal
> with DBI's handling of transactions -- I don't want AutoCommit, but it
> seems to be impossible to do "set transaction isolation level serializable"
> without it, because DBI won't open a transaction if you send that comman
Jeremy Nixon <[EMAIL PROTECTED]> wrote:
> It looks like it would work perfectly with connect_cached, which I hadn't
> known about, but now that I do, I'm all excited to change my code to use
> it instead of Apache::DBI.
*instead*, eh... I'm using it as well... Could this be part of the
pro
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> Tyler MacDonald wrote:
> >[Fri Jan 13 23:46:28 2006] [error] [client 192.168.99.112] DBD::Pg::db
> >prepare_cached failed
>
> Do you only have the problem with prepare_cached? Can you replicate it
> in a small script t
Apache::DBI claims that it will reconnect to a database if it's gone away.
DBD::Pg claims that it supports the ping method. However, when I restart my
database server while apache2 is running, all mod_perl pages that are
database driven return internal server errors, no matter how many times I
refr
Joe Deal <[EMAIL PROTECTED]> wrote:
> .
>
> waiting 120 seconds for server to start: not ok
> [ error] giving up after 121 secs. If you think that your system
> is slow or o
Nicholas Aaron Philbrook <[EMAIL PROTECTED]> wrote:
> I recently put together a Gentoo server with apache and mod_perl. I'm
> trying to run a perl script that has a require statement for a local
> file, i.e.
>
> require "database_util.pl"
>
> where database_util.pl is another perl file in the sam
Philip M. Gollucci <[EMAIL PROTECTED]> wrote:
> sub handler {
> my $r = shift;
>
> my $user = ISST::User->getLoggedIn($r);
>
> ## IS THIS CORRECT ?
> ## can't used DECLINED or you get the REALM popup
> return Apache2::Const::OK if $r->uri =~
> m#/timeline/(login|logout|r
> >>Issueing an "apachectl restart" (or kill -HUP) make the apache parent
> >>process size grow !
> >This was a well-known issue with mod_perl 1.x built using DSO. I never
> >use graceful restart because of this. I thought 2.x got rid of this
> >issue though. You could try making a static build
Peter1 Alvin <[EMAIL PROTECTED]> wrote:
> I'm trying to set up modperl on Windows XP. Instead of executing the
> file, I get this returned to my browser:
Peter,
> But, I can't seem to configure Apache to actually *run* my script.
> I've tried all these directives:
>
>
> SetHandler modperl
>
Jon Keller <[EMAIL PROTECTED]> wrote:
> I'm trying to build apache 1.3.34 and mod_perl 1.29 on a debian 3.1
> machine and whenever mod_perl is loaded apache segfaults at any type of
> request.
I had a similar problem with Apache2 and mod_perl2. It drove me
absolutely nuts. When I changed
Matt Sergeant <[EMAIL PROTECTED]> wrote:
> >Thread::Semaphore with the same results. If anyone would like the URL
> >to see this for themselves write me off list. If there is need for
> >additional information than I apologize in advance for not submitting
> >it and will do so upon request.
>
Senthil Nathan <[EMAIL PROTECTED]> wrote:
> im using globals with the keyword "use".
> also it worked fine without mod_perl.
>
> thats what worries now...
> i tried ModPerl:;PerlRun in the httpd.conf and see no change in the global
> data being used by others.
> so how can i do away with that pro
Senthil Nathan <[EMAIL PROTECTED]> wrote:
> in the multiuser environment, everyone login to the page and their
> respective profile gets displayed. after every click, other user's data also
> gets aappended to this current view for the user, which is not the expected
> one in mod_perl.
>
> the sam
Tyler MacDonald <[EMAIL PROTECTED]> wrote:
> > Can you try this on another system? That would tell you whether or not
> > there is truly anything wrong with the code, or if you should be looking
> > at reinstalling this system.
> I'm going to test this exten
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> > If it is "some old junk" left in the @INC how would I go about
> > correcting it?
>
> My approach would be to start with a new Perl install and a new
> mod_perl. There is no official way to uninstall a Perl module, so it's
> hard to be sure that you
"Balázs Szabó (dLux)" <[EMAIL PROTECTED]> wrote:
> What I did in my module is the following:
>
> delete $ENV{TZ};
> tzset();
> ($a, $b) = tzname();
>
> $a should contain the local timezone (according to the documentation of
> the tzset manual), although it is UTC always. What I suspect is that
>
Tyler MacDonald <[EMAIL PROTECTED]> wrote:
> I'm going to test this extensively this weekend if I get the time,
> including testing it on another system. Unfortuantely the other system is
> also perl 5.6.7, httpd 2.0.55, linux 2.6, so if I get the same problems mo
Boysenberry Payne <[EMAIL PROTECTED]> wrote:
> I would like to do the "make uninstall" approach below first before
> going
> through reinstalling perl and MP2.
> Before I do this I want to make sure I have the right syntax first.
> would I just type 'make uninstall' in the source directory for MP2
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> > http://search.cpan.org/~CRAKRJACK/ModPerl-PackageRegistry-0.01/
> See also, Apache::Dispatch. Not ported to mp2 yet, I think.
Nice. :-) Geoffrey is using a slightly different model than me
(having multiple pages inside one class, different
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> That's pretty strange. I've only seen errors like this before once, and
> that was on a Win32 system running ActiveState's PerlEX on IIS. At the
> time, I thought it might be a threading issue. Are you using a threaded
> MPM? I see that your Perl was
Perrin Harkins <[EMAIL PROTECTED]> wrote:
> Well, we know there's nothing wrong with HTTP::Request on CPAN, so
> either you have a messed up copy of it there (no idea why this would
> happen), or something is wrong with your system at a pretty low level.
> Possible problems include compiling mod_pe
What a fun problem to solve. Instead of banging my head against the
wall trying to get things to compile at runtime, I stopped using
ModPerl::Registry entirely and switched to defining my own pacakges with
handlers. Problem solved. Of course, how do I map these things to URLs now?
I ended u
Geoffrey Young <[EMAIL PROTECTED]> wrote:
> > Disregard, I just searched the archives and apparently just before I
> > subscribed to the list Phillippe announced the 'testcover' parameter...
> > which is documented in Apache::TestMB, but not yet in Apache::TestMM :-/
> but that's only half the stor
Disregard, I just searched the archives and apparently just before I
subscribed to the list Phillippe announced the 'testcover' parameter...
which is documented in Apache::TestMB, but not yet in Apache::TestMM :-/
- Tyler
Tyler MacDonald <[EMAIL PROTECTED]> wrote:
>
I'm trying to get code coverage metrics of an apache2 module I'm developing,
using Devel::Cover. I've figured out a way to do it, but it's a bit hacky
:-)
Devel::Cover instructs you to run "make test" like so:
HARNESS_PERL_SWITCHES=-MDevel::Cover make test
to get coverage analysis. What I've don
-8<-- Start Bug Report 8<--
1. Problem Description:
Today, I'm getting registry errors on my friend's virtual host using
ModPerl::Registry on mod_perl 2.0.2:
[Thu Oct 27 14:59:44 2005] [error] Global symbol "$class" requires explicit
package name at /usr/sh
Philip M. Gollucci <[EMAIL PROTECTED]> wrote:
> Tyler MacDonald wrote:
> >17 -$r->print(" >HREF=\"/yi.css\" />\n");
> I know this doesn't answer your question, but it popped out at me that
> you're using xhtml /> syntax, but
Philip M. Gollucci <[EMAIL PROTECTED]> wrote:
> Tyler MacDonald wrote:
> >Global symbol "$r" requires explicit package name at
> >/opt/weedns-4/skins/yi/perl5lib/yi/page/css.pm line 16.\nCompilation failed
> >in require at /opt/weedns-4/skins/yi/htdocs/css.pl
I recently made the move from mod_perl 1.99 to mod_perl 2.0.2. After a bit
of porting (changing Apache:: to Apache2::, etc), everything seemed to be
working fairly well. But then some bizarre things started happening.
About 1 in 50 times, a page will fail to load with "internal server error".
The
> Tyler, have you by chance read:
> http://perl.apache.org/docs/2.0/user/help/help.html#Resolving_Segmentation_Faults
> plus the short script that we can reproduce the problem with.
Maybe... I'll look into it in more detail later. My main point was
that no segmentation fault occurs in 1.99
-8<-- Start Bug Report 8<--
1. Problem Description:
Hello,
I just tried an upgrade to 2.0RC1... only to have to back out.
All of my scripts run fine, except for one -- which exits with a
segmentation fault reliably.
The segfault h
78 matches
Mail list logo