Re: [RELEASE CANDIDATE] Apache-Reload-0.14 RC1

2023-08-07 Thread Philippe Chiasson
+1 on Fedora 38 with system versions of httpd and perl

Sent from the depths of my mind on an iPhone

> On Aug 6, 2023, at 06:30, Steve Hay  
> wrote:
> 
> Thanks.
> 
> +1 here with Apache 2.4.57 / Perl 5.38.0 / VC2022 on Windows 11.
> 
> I've pushed one further minor update to avoid a (long-standing)
> warning when building inside the mod_perl build (see
> https://svn.apache.org/viewvc?view=revision=1911479) but I
> don't think it warrants another RC. It will get retested (and more
> meaningfully) when testing the mod_perl RC which is coming next...
> 
> This standalone Apache::Reload release doesn't go on
> https://dist.apache.org/ (it's just released to CPAN) so I will crack
> on with that now even though we only have two +1s.
> 
>> On Sat, 29 Jul 2023 at 15:17, Adam Prime  wrote:
>> 
>> +1
>> 
>> tests pass on apache 2.4.41 w/ perl 5.28.0, which is what i've got
>> immediately available to test with.
>> 
>> Adam
>> 
>>> On 7/21/23 18:56, Steve Hay wrote:
>>> In preparation for an upcoming release of mod_perl to support Perl
>>> 5.38.0, I am making a new release of Apache-Reload.
>>> 
>>> Please download, test, and report back on this Apache-Reload 0.14
>>> release candidate.
>>> 
>>> https://people.apache.org/~stevehay/Apache-Reload-0.14-rc1.tar.gz
>>> 
>>> MD5  = 53a2201f98d05b9868581b730d2032c3
>>> SHA256 = 38fcc0234e9db91624b5bc704ffe93928aa3f1d044bcc26f4839787b21123769
>>> 
>>> Major changes in this release are as follows:
>>> 
>>> Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl
>>> or mod_perl2.
>>> [Andreas Koenig , CPAN RT#34316; Steve Hay]
>>> 
>>> Fix spelling error.
>>> [, CPAN RT#127004]
>>> 
>>> Fix Makefile.PL when Apache::Test is not present.
>>> [Nigel Gregoire, CPAN RT#113778]



svn commit: r1911485 - in /perl/Apache-Reload/trunk: Changes RELEASE lib/Apache/Reload.pm lib/Apache2/Reload.pm

2023-08-06 Thread stevehay
Author: stevehay
Date: Sun Aug  6 11:00:04 2023
New Revision: 1911485

URL: http://svn.apache.org/viewvc?rev=1911485=rev
Log:
start 0.15-dev cycle

Modified:
perl/Apache-Reload/trunk/Changes
perl/Apache-Reload/trunk/RELEASE
perl/Apache-Reload/trunk/lib/Apache/Reload.pm
perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1911485=1911484=1911485=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Sun Aug  6 11:00:04 2023
@@ -6,6 +6,8 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
+=item 0.15-dev
+
 =item 0.14 August 06, 2023
 
 Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl or

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1911485=1911484=1911485=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Sun Aug  6 11:00:04 2023
@@ -26,7 +26,7 @@ Instructions for Apache-Reload Release M
  - change -dev to -rc\d+ starting with -rc1
 
   b. commit Changes
- % svn ci -m "0.14 rc1" Changes
+ % svn ci -m "0.15 rc1" Changes
 
   c. nuke any preinstalled Apache-Reload libs and run 'make test'
 
@@ -45,7 +45,7 @@ Instructions for Apache-Reload Release M
(or maybe longer to give most people a chance to catch up). no need
to tag this package
 
-   Subject: [RELEASE CANDIDATE] Apache-Reload 0.14 RC\d+
+   Subject: [RELEASE CANDIDATE] Apache-Reload 0.15 RC\d+
 
   a. if problems are detected during stage 2, repeat stages 1 and 2.
 
@@ -62,7 +62,7 @@ Instructions for Apache-Reload Release M
  % make -n tag
 
   c. commit Changes
- % svn ci -m "0.14 release" Changes
+ % svn ci -m "0.15 release" Changes
 
   d. tag
  % make tag
@@ -80,7 +80,7 @@ Instructions for Apache-Reload Release M
 
  o modperl/perl.apache.org
 
-   Subject: [ANNOUNCE] Apache-Reload 0.14
+   Subject: [ANNOUNCE] Apache-Reload 0.15
 
  include:
  - MD5 sig (as it comes from CPAN upload announce).
@@ -93,7 +93,7 @@ Instructions for Apache-Reload Release M
   b. edit ./Changes:
  - start a new item with incremented version + '-dev'
 
- =item 0.15-dev
+ =item 0.16-dev
 
   c. bump up version numbers in this file to make it easier to do the
  next release.
@@ -102,5 +102,5 @@ Instructions for Apache-Reload Release M
  (undo the change to the PAUSE menu item number in item 0d. above)
 
   d. commit Changes
- % svn ci -m "start 0.14-dev cycle" Changes RELEASE \
+ % svn ci -m "start 0.15-dev cycle" Changes RELEASE \
    lib/Apache/Reload.pm lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/lib/Apache/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache/Reload.pm?rev=1911485=1911484=1911485=diff
======
--- perl/Apache-Reload/trunk/lib/Apache/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache/Reload.pm Sun Aug  6 11:00:04 2023
@@ -17,7 +17,7 @@ package Apache::Reload;
 
 use strict;
 
-$Apache::Reload::VERSION = '0.14';
+$Apache::Reload::VERSION = '0.15';
 
 use vars qw(%INCS %Stat $TouchTime %UndefFields %Ignore);
 

Modified: perl/Apache-Reload/trunk/lib/Apache2/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache2/Reload.pm?rev=1911485=1911484=1911485=diff
======
--- perl/Apache-Reload/trunk/lib/Apache2/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache2/Reload.pm Sun Aug  6 11:00:04 2023
@@ -18,7 +18,7 @@ package Apache2::Reload;
 use strict;
 use warnings FATAL => 'all';
 
-our $VERSION = '0.14';
+our $VERSION = '0.15';
 
 use Apache2::Const -compile => qw(OK);
 




[ANNOUNCE] Apache-Reload-0.14

2023-08-06 Thread Steve Hay
We are pleased to announce the release of Apache-Reload 0.14.

This release is now, or soon will be, available for download from your
favourite CPAN mirror or you can find it at:

https://metacpan.org/release/Apache-Reload

Checksums for this release are:

MD5  = 3c9527ba565ba3f21d7a8a1ef1d3e7c5
SHA256 = f4f56508e4a9fd8f9488aea6be8e7e7180774e820aa982b1afb7a2dd33c4ba61

Major changes in this release are as follows:

Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl
or mod_perl2.
[Andreas Koenig , CPAN RT#34316; Steve Hay]

Fix spelling error.
[, CPAN RT#127004]

Fix Makefile.PL when Apache::Test is not present.
[Nigel Gregoire, CPAN RT#113778]


svn commit: r1911482 - /perl/Apache-Reload/tags/0_14/

2023-08-06 Thread stevehay
Author: stevehay
Date: Sun Aug  6 10:38:29 2023
New Revision: 1911482

URL: http://svn.apache.org/viewvc?rev=1911482=rev
Log:
0_14 tag

Added:
perl/Apache-Reload/tags/0_14/
  - copied from r1911481, perl/Apache-Reload/trunk/



svn commit: r1911481 - /perl/Apache-Reload/trunk/Changes

2023-08-06 Thread stevehay
Author: stevehay
Date: Sun Aug  6 10:37:55 2023
New Revision: 1911481

URL: http://svn.apache.org/viewvc?rev=1911481=rev
Log:
0.14 release

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1911481=1911480=1911481=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Sun Aug  6 10:37:55 2023
@@ -6,7 +6,7 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
-=item 0.14-rc1
+=item 0.14 August 06, 2023
 
 Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl or
 mod_perl2.




Re: [RELEASE CANDIDATE] Apache-Reload-0.14 RC1

2023-08-06 Thread Steve Hay
Thanks.

+1 here with Apache 2.4.57 / Perl 5.38.0 / VC2022 on Windows 11.

I've pushed one further minor update to avoid a (long-standing)
warning when building inside the mod_perl build (see
https://svn.apache.org/viewvc?view=revision=1911479) but I
don't think it warrants another RC. It will get retested (and more
meaningfully) when testing the mod_perl RC which is coming next...

This standalone Apache::Reload release doesn't go on
https://dist.apache.org/ (it's just released to CPAN) so I will crack
on with that now even though we only have two +1s.

On Sat, 29 Jul 2023 at 15:17, Adam Prime  wrote:
>
> +1
>
> tests pass on apache 2.4.41 w/ perl 5.28.0, which is what i've got
> immediately available to test with.
>
> Adam
>
> On 7/21/23 18:56, Steve Hay wrote:
> > In preparation for an upcoming release of mod_perl to support Perl
> > 5.38.0, I am making a new release of Apache-Reload.
> >
> > Please download, test, and report back on this Apache-Reload 0.14
> > release candidate.
> >
> > https://people.apache.org/~stevehay/Apache-Reload-0.14-rc1.tar.gz
> >
> > MD5  = 53a2201f98d05b9868581b730d2032c3
> > SHA256 = 38fcc0234e9db91624b5bc704ffe93928aa3f1d044bcc26f4839787b21123769
> >
> > Major changes in this release are as follows:
> >
> > Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl
> > or mod_perl2.
> > [Andreas Koenig , CPAN RT#34316; Steve Hay]
> >
> > Fix spelling error.
> > [, CPAN RT#127004]
> >
> > Fix Makefile.PL when Apache::Test is not present.
> > [Nigel Gregoire, CPAN RT#113778]


svn commit: r1911479 - /perl/Apache-Reload/trunk/Makefile.PL

2023-08-06 Thread stevehay
Author: stevehay
Date: Sun Aug  6 10:18:46 2023
New Revision: 1911479

URL: http://svn.apache.org/viewvc?rev=1911479=rev
Log:
Avoid a "Subroutine set_version redefined" warning when this is used within the 
mod_perl build

(Apache::SizeLimit and Apache::Test also have set_version() in their 
Makefile.PLs.)

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=1911479=1911478=1911479=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Sun Aug  6 10:18:46 2023
@@ -25,7 +25,7 @@ else {
 my $HAS_APACHE_TEST = check_for_apache_test();
 
 my $VERSION;
-set_version();
+set_apache_reload_version();
 
 my %common_opts = (
VERSION => $VERSION,
@@ -85,7 +85,7 @@ sub check_for_apache_test {
 return 1;
 }
 
-sub set_version {
+sub set_apache_reload_version {
 require Apache::Reload;
 $VERSION = $Apache::Reload::VERSION;
 




svn commit: r1911477 - /perl/Apache-Reload/trunk/Changes

2023-08-06 Thread stevehay
Author: stevehay
Date: Sun Aug  6 10:16:15 2023
New Revision: 1911477

URL: http://svn.apache.org/viewvc?rev=1911477=rev
Log:
Make Apache-Reload-0.14-rc1

(This was actually done on 21 Jul 2023, but I forgot to push the Changes 
update.)

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1911477=1911476=1911477=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Sun Aug  6 10:16:15 2023
@@ -6,7 +6,7 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
-=item 0.14-dev
+=item 0.14-rc1
 
 Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl or
 mod_perl2.




Re: [RELEASE CANDIDATE] Apache-Reload-0.14 RC1

2023-07-29 Thread Adam Prime

+1

tests pass on apache 2.4.41 w/ perl 5.28.0, which is what i've got 
immediately available to test with.


Adam

On 7/21/23 18:56, Steve Hay wrote:

In preparation for an upcoming release of mod_perl to support Perl
5.38.0, I am making a new release of Apache-Reload.

Please download, test, and report back on this Apache-Reload 0.14
release candidate.

https://people.apache.org/~stevehay/Apache-Reload-0.14-rc1.tar.gz

MD5  = 53a2201f98d05b9868581b730d2032c3
SHA256 = 38fcc0234e9db91624b5bc704ffe93928aa3f1d044bcc26f4839787b21123769

Major changes in this release are as follows:

Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl
or mod_perl2.
[Andreas Koenig , CPAN RT#34316; Steve Hay]

Fix spelling error.
[, CPAN RT#127004]

Fix Makefile.PL when Apache::Test is not present.
[Nigel Gregoire, CPAN RT#113778]


[RELEASE CANDIDATE] Apache-Reload-0.14 RC1

2023-07-21 Thread Steve Hay
In preparation for an upcoming release of mod_perl to support Perl
5.38.0, I am making a new release of Apache-Reload.

Please download, test, and report back on this Apache-Reload 0.14
release candidate.

https://people.apache.org/~stevehay/Apache-Reload-0.14-rc1.tar.gz

MD5  = 53a2201f98d05b9868581b730d2032c3
SHA256 = 38fcc0234e9db91624b5bc704ffe93928aa3f1d044bcc26f4839787b21123769

Major changes in this release are as follows:

Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl
or mod_perl2.
[Andreas Koenig , CPAN RT#34316; Steve Hay]

Fix spelling error.
[, CPAN RT#127004]

Fix Makefile.PL when Apache::Test is not present.
[Nigel Gregoire, CPAN RT#113778]


svn commit: r1911187 - /perl/Apache-Reload/trunk/Makefile.PL

2023-07-21 Thread stevehay
Author: stevehay
Date: Fri Jul 21 22:09:37 2023
New Revision: 1911187

URL: http://svn.apache.org/viewvc?rev=1911187=rev
Log:
Update Makefile.PL as per r1911186

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=1911187=1911186=1911187=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Fri Jul 21 22:09:37 2023
@@ -14,7 +14,7 @@ my $mp_gen;
 # also set MP_APXS
 if ($ENV{MOD_PERL_2_BUILD}) {
 push @ARGV, "-apxs", $ENV{MP_APXS};
-my $mp_gen = satisfy_mp_generation(2);
+$mp_gen = satisfy_mp_generation(2);
 }
 else {
 $mp_gen = satisfy_mp_generation();




svn commit: r1911163 - /perl/Apache-Reload/trunk/Changes

2023-07-21 Thread stevehay
Author: stevehay
Date: Fri Jul 21 09:21:40 2023
New Revision: 1911163

URL: http://svn.apache.org/viewvc?rev=1911163=rev
Log:
Update Changes

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1911163=1911162=1911163=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Fri Jul 21 09:21:40 2023
@@ -8,6 +8,16 @@ Changes - Apache::Reload change logfile
 
 =item 0.14-dev
 
+Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl or
+mod_perl2.
+[Andreas Koenig , CPAN RT#34316; Steve Hay]
+
+Fix spelling error.
+[, CPAN RT#127004]
+
+Fix Makefile.PL when Apache::Test is not present.
+[Nigel Gregoire, CPAN RT#113778]
+
 =item 0.13 May 09, 2015
 
 Fix reload.t. Reported in CPAN RT#96656.




svn commit: r1911162 - /perl/Apache-Reload/trunk/Makefile.PL

2023-07-21 Thread stevehay
Author: stevehay
Date: Fri Jul 21 09:15:22 2023
New Revision: 1911162

URL: http://svn.apache.org/viewvc?rev=1911162=rev
Log:
Try mod_perl2 if mod_perl failed

The attempt to load mod_perl2 was accidentally being skipped by a successful 
load of File::Spec in-between.

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=1911162=1911161=1911162=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Fri Jul 21 09:15:22 2023
@@ -229,7 +229,7 @@ EOF
 unshift @INC, $atlib if -d $atlib;
 } 
 
-eval { require mod_perl2 } if ($@);
+eval { require mod_perl2 };
 unless ($@) {
 $wanted = 2;
 }




svn commit: r1911161 - /perl/Apache-Reload/trunk/Makefile.PL

2023-07-21 Thread stevehay
Author: stevehay
Date: Fri Jul 21 09:12:50 2023
New Revision: 1911161

URL: http://svn.apache.org/viewvc?rev=1911161=rev
Log:
Fix unnecessary FAIL reports on CPAN Testers by checking for mod_perl or 
mod_perl2

Fix by Andreas Koenig  on CPAN RT#34316

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=1911161=1911160=1911161=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Fri Jul 21 09:12:50 2023
@@ -122,13 +122,14 @@ sub satisfy_mp_generation {
 
 unless ($wanted == 1 || $wanted == 2) {
 die "don't know anything about mod_perl generation: $wanted\n" .
-"currently supporting only generations 1 and 2";
+"currently supporting only generations 1 and 2.\n" .
+"Please specify MOD_PERL=1 or MOD_PERL=2 on the commandline\n";
 }
 
 my $selected = 0;
 
 if ($wanted == 1) {
-require_mod_perl();
+require_mod_perl(1);
 if ($mod_perl::VERSION >= 1.99) {
 # so we don't pick 2.0 version if 1.0 is wanted
 die "You don't seem to have mod_perl 1.0 installed";
@@ -137,7 +138,7 @@ sub satisfy_mp_generation {
 }
 elsif ($wanted == 2) {
 #warn "Looking for mod_perl 2.0";
-require_mod_perl();
+require_mod_perl(2);
 if ($mod_perl::VERSION < 2.0) {
 die "You don't seem to have mod_perl 2.0 installed";
 }
@@ -153,8 +154,25 @@ sub satisfy_mp_generation {
 }
 
 sub require_mod_perl {
-eval { require mod_perl };
-eval { require mod_perl2 }  if ($@);
+my($rversion) = @_;
+if (!$rversion || $rversion==1){
+eval { require mod_perl };
+if ($rversion == 1){
+if ($@){
+   warn "Note: Did not find mod_perl installed\n";
+   }
+return; # do not die, let PREREQ_PM handle it
+}
+}
+if ($@ || !$rversion || $rversion==2){
+eval { require mod_perl2 };
+if ($rversion == 2){
+if ($@){
+   warn "Note: Did not find mod_perl2 installed\n";
+   }
+return; # do not die, let PREREQ_PM handle it
+}
+}
 die "Can't find mod_perl installed\nThe error was: $@" if $@;
 }
 




svn commit: r1911160 - /perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

2023-07-21 Thread stevehay
Author: stevehay
Date: Fri Jul 21 08:36:40 2023
New Revision: 1911160

URL: http://svn.apache.org/viewvc?rev=1911160=rev
Log:
Fix spelling error

Fix by x.guim...@free.fr in CPAN RT#127004

Modified:
perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/lib/Apache2/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache2/Reload.pm?rev=1911160=1911159=1911160=diff
==
--- perl/Apache-Reload/trunk/lib/Apache2/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache2/Reload.pm Fri Jul 21 08:36:40 2023
@@ -363,7 +363,7 @@ a module.
 
   Apache2::Reload->unregister_module('Some::Module');
 
-But be carefull, since unregistering a module in this way will only
+But be careful, since unregistering a module in this way will only
 do so for the current interpreter. This feature should be used with
 care.
 




svn commit: r1863274 - /perl/Apache-Reload/trunk/RELEASE

2019-07-18 Thread stevehay
Author: stevehay
Date: Thu Jul 18 12:16:08 2019
New Revision: 1863274

URL: http://svn.apache.org/viewvc?rev=1863274=rev
Log:
Don't announce new releases to annou...@apache.org since the release goes on 
CPAN, not in https://dist.apache.org/repos/dist/release/perl

Modified:
perl/Apache-Reload/trunk/RELEASE

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1863274=1863273=1863274=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Thu Jul 18 12:16:08 2019
@@ -76,10 +76,9 @@ Instructions for Apache-Reload Release M
 
 5. Announce the package
 
-  a. post to the following lists:
+  a. post to the following list:
 
  o modperl/perl.apache.org
- o announce/apache.org
 
Subject: [ANNOUNCE] Apache-Reload 0.14
 




svn commit: r1759464 - /perl/Apache-Reload/trunk/Makefile.PL

2016-09-06 Thread stevehay
Author: stevehay
Date: Tue Sep  6 17:22:41 2016
New Revision: 1759464

URL: http://svn.apache.org/viewvc?rev=1759464=rev
Log:
Update Makefile.PL as per r1759432

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=1759464=1759463=1759464=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Tue Sep  6 17:22:41 2016
@@ -228,12 +228,13 @@ package MY;
 sub postamble {
 my $self = shift;
 
+my $q = ($^O =~ /MSWin32/i ? '"' : "'");
+
 my $string = $self->SUPER::postamble;
 
-$string .= <<'EOF';
+$string .= <<"EOF";
 tag :
-   svn copy https://svn.apache.org/repos/asf/perl/Apache-Reload/trunk 
https://svn.apache.org/repos/asf/perl/Apache-Reload/tags/$(VERSION_SYM)
-   @echo update lib/Apache/Reload.pm VERSION now
+   svn copy -m $q\$(VERSION_SYM) tag$q 
https://svn.apache.org/repos/asf/perl/Apache-Reload/trunk 
https://svn.apache.org/repos/asf/perl/Apache-Reload/tags/\$(VERSION_SYM)
 EOF
 
 return $string;




svn commit: r1759461 - /perl/Apache-Reload/trunk/RELEASE

2016-09-06 Thread stevehay
Author: stevehay
Date: Tue Sep  6 17:19:37 2016
New Revision: 1759461

URL: http://svn.apache.org/viewvc?rev=1759461=rev
Log:
Update RELEASE as per r1759430

Modified:
perl/Apache-Reload/trunk/RELEASE

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1759461=1759460=1759461=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Tue Sep  6 17:19:37 2016
@@ -1,22 +1,21 @@
 Instructions for Apache-Reload Release Manager
 
-0.  Ask the PMC to verify that you have the appropriate CPAN permissions
-on dev@perl.
+0. Ask the PMC to verify that you have the appropriate CPAN permissions
+   on dev@perl.
 
-If this is your first release, ask someone with APML karma on PAUSE
-to verify you have the appropriate permissions.  Likely someone on
-the PMC can do this.
-
-a. login into https://pause.perl.org
-b. menu click: Select Mailinglist/Action
-c. choose APML and Change Permissions and click go
-d. click 3.1 Make somebody else co-maintainer
-e. choose the modules to give the perms to
-   type the username of the new co-maintainer
-f. if you happen to know that packages were added this release,
-   make sure you give the correct permissions to them.
-
- MAINTAINER_BUILDING_RELEASE=1 perl Makefile.PL
+   If this is your first release, ask someone with APML karma on PAUSE
+   to verify you have the appropriate permissions.  Likely someone on
+   the PMC can do this.
+
+  a. login into https://pause.perl.org
+  b. menu click: Select Mailinglist/Action
+  c. choose APML and Change Permissions and click go
+  d. click 3.1 Make somebody else co-maintainer
+  e. choose the modules to give the perms to
+ type the username of the new co-maintainer
+  f. if you happen to know that packages were added this release,
+ make sure you give the correct permissions to them.
+ % MAINTAINER_BUILDING_RELEASE=1 perl Makefile.PL
 
 1. 'make disttest' - to make sure nothing is missing from the manifest.
Now 'make dist', and test this generated package (not svn)
@@ -26,26 +25,28 @@ Instructions for Apache-Reload Release M
   a. edit ./Changes:
  - change -dev to -rc\d+ starting with -rc1
 
-  b. nuke any preinstalled Apache-Reload libs and run 'make test'
+  b. commit Changes
+ % svn ci -m "0.14 rc1" Changes
 
-  c. test that you can 'make install' and then run 'make test' again
+  c. nuke any preinstalled Apache-Reload libs and run 'make test'
 
-  d. test whether we still 100% OK on systems with no LWP:
+  d. test that you can 'make install' and then run 'make test' again
 
+  e. test whether we are still 100% OK on systems with no LWP:
  % APACHE_TEST_PRETEND_NO_LWP=1 make test
 
-2. once confident that the package is good, upload a release candidate
-   to people.apache.org/~username and post 24 hour-ish candidate alert
-   to the various lists
+2. once confident that the package is good, commit the release candidate
+   to https://dist.apache.org/repos/dist/dev/perl and post 24 hour-ish
+   candidate alert to the various lists
 
  o dev/perl.apache.org
  o modperl/perl.apache.org
 
-  Subject: [RELEASE CANDIDATE] Apache-Reload 0.14 RC\d+
-
(or maybe longer to give most people a chance to catch up). no need
to tag this package
 
+   Subject: [RELEASE CANDIDATE] Apache-Reload 0.14 RC\d+
+
   a. if problems are detected during stage 2, repeat stages 1 and 2.
 
 3. when the package has been reported to be good, prepare a new
@@ -61,7 +62,7 @@ Instructions for Apache-Reload Release M
  % make -n tag
 
   c. commit Changes
- % svn ci Changes
+ % svn ci -m "0.14 release" Changes
 
   d. tag
  % make tag
@@ -75,11 +76,16 @@ Instructions for Apache-Reload Release M
 
 5. Announce the package
 
-  a. post ... to the modperl, announce lists
-  Subject: [ANNOUNCE] Apache-Reload 0.14
- include 
-  - MD5 sig (as it comes from CPAN upload announce).
-  - the latest Changes
+  a. post to the following lists:
+
+ o modperl/perl.apache.org
+ o announce/apache.org
+
+   Subject: [ANNOUNCE] Apache-Reload 0.14
+
+ include:
+ - MD5 sig (as it comes from CPAN upload announce).
+ - the latest Changes
 
 6. Prepare for the next cycle
 
@@ -88,12 +94,11 @@ Instructions for Apache-Reload Release M
   b. edit ./Changes:
  - start a new item with incremented version + '-dev'
 
-  =item 0.15-dev
+ =item 0.15-dev
 
   c. bump up version numbers in this file to make it easier to do the
  next release.
-
- $ perl -pi -e 's/(\d+)\.(\d+)/join(".", $1, $2+1)/eg' RELEASE
+ % perl -pi.bak -e 's/(\d+)\.(\d+)/join(".", $1, $2+1)/eg' RELEASE
 
  (undo the change to the PAUSE menu item number in item 0d. above)
 




Re: [RELEASE CANDIDATE] Apache-Reload 0.13 RC2

2016-07-13 Thread Jie Gao
* Ruben Safir <ru...@mrbrklyn.com> wrote:

> Date: Wed, 13 Jul 2016 11:48:03 -0400
> From: Ruben Safir <ru...@mrbrklyn.com>
> To: Jie Gao <j@sydney.edu.au>
> CC: Steve Hay <steve.m@googlemail.com>, d...@perl.apache.org,
>  "modperl@perl.apache.org" <modperl@perl.apache.org>
> Subject: Re: [RELEASE CANDIDATE] Apache-Reload 0.13 RC2
> User-Agent: Mutt/1.5.21 (2010-09-15)
> 
> what version of apache is that?
 
That would have been httpd-2.4.12 at that time.

Regards,



Jie


> 
> On Fri, Apr 24, 2015 at 10:48:45AM +1000, Jie Gao wrote:
> > Red Hat Enterprise Linux Server release 6.6 (Santiago)
> > 
> > perl Makefile.PL -httpd /usr/local/apache/bin/httpd  -apxs 
> > /usr/local/apache/bin/apxs
> > 
> > All tests successful.
> > 
> > Regards,
> > 
> > Jie 
> > 
> > Please think of our environment and only print this e-mail if necessary.
> > 
> > * Steve Hay <steve.m@googlemail.com> wrote:
> > 
> > > Date: Thu, 23 Apr 2015 13:21:37 +0100
> > > From: Steve Hay <steve.m@googlemail.com>
> > > To: d...@perl.apache.org, "modperl@perl.apache.org" 
> > > <modperl@perl.apache.org>
> > > Subject: [RELEASE CANDIDATE] Apache-Reload 0.13 RC2
> > > 
> > > Please download, test, and report back on this Apache-Reload 0.13
> > > release candidate.
> > > 
> > > http://people.apache.org/~stevehay/Apache-Reload-0.13-rc2.tar.gz
> > > 
> > > MD5 =70720b76ca7b7ab8798c37922c882648
> > > SHA1 = 3836123e4fee33174eb98c06f211f8c60550f46d
> > > 
> > > [Note: I bumped the version to RC2 to avoid confusion because I made a
> > > couple of internal changes relating to the creation of the
> > > distribution tarball after committing the RC1 version bump.]
> > > 
> > > =item 0.13-rc2
> > > 
> > > Fix reload.t. Reported in CPAN RT#96656.
> > > [Steve Hay]
> 
> -- 
> So many immigrant groups have swept through our town
> that Brooklyn, like Atlantis, reaches mythological
> proportions in the mind of the world - RI Safir 1998
> http://www.mrbrklyn.com 
> 
> DRM is THEFT - We are the STAKEHOLDERS - RI Safir 2002
> http://www.nylxs.com - Leadership Development in Free Software
> http://www2.mrbrklyn.com/resources - Unpublished Archive 
> http://www.coinhangout.com - coins!
> http://www.brooklyn-living.com 
> 
> Being so tracked is for FARM ANIMALS and and extermination camps, 
> but incompatible with living as a free human being. -RI Safir 2013
> 


Re: [RELEASE CANDIDATE] Apache-Reload 0.13 RC2

2016-07-13 Thread Ruben Safir
what version of apache is that?


On Fri, Apr 24, 2015 at 10:48:45AM +1000, Jie Gao wrote:
> Red Hat Enterprise Linux Server release 6.6 (Santiago)
> 
> perl Makefile.PL -httpd /usr/local/apache/bin/httpd  -apxs 
> /usr/local/apache/bin/apxs
> 
> All tests successful.
> 
> Regards,
> 
> Jie 
> 
> Please think of our environment and only print this e-mail if necessary.
> 
> * Steve Hay <steve.m@googlemail.com> wrote:
> 
> > Date: Thu, 23 Apr 2015 13:21:37 +0100
> > From: Steve Hay <steve.m@googlemail.com>
> > To: d...@perl.apache.org, "modperl@perl.apache.org" 
> > <modperl@perl.apache.org>
> > Subject: [RELEASE CANDIDATE] Apache-Reload 0.13 RC2
> > 
> > Please download, test, and report back on this Apache-Reload 0.13
> > release candidate.
> > 
> > http://people.apache.org/~stevehay/Apache-Reload-0.13-rc2.tar.gz
> > 
> > MD5 =70720b76ca7b7ab8798c37922c882648
> > SHA1 = 3836123e4fee33174eb98c06f211f8c60550f46d
> > 
> > [Note: I bumped the version to RC2 to avoid confusion because I made a
> > couple of internal changes relating to the creation of the
> > distribution tarball after committing the RC1 version bump.]
> > 
> > =item 0.13-rc2
> > 
> > Fix reload.t. Reported in CPAN RT#96656.
> > [Steve Hay]

-- 
So many immigrant groups have swept through our town
that Brooklyn, like Atlantis, reaches mythological
proportions in the mind of the world - RI Safir 1998
http://www.mrbrklyn.com 

DRM is THEFT - We are the STAKEHOLDERS - RI Safir 2002
http://www.nylxs.com - Leadership Development in Free Software
http://www2.mrbrklyn.com/resources - Unpublished Archive 
http://www.coinhangout.com - coins!
http://www.brooklyn-living.com 

Being so tracked is for FARM ANIMALS and and extermination camps, 
but incompatible with living as a free human being. -RI Safir 2013



svn commit: r1678482 - /perl/Apache-Reload/tags/0_13/

2015-05-09 Thread stevehay
Author: stevehay
Date: Sat May  9 12:03:17 2015
New Revision: 1678482

URL: http://svn.apache.org/r1678482
Log: (empty)

Added:
perl/Apache-Reload/tags/0_13/
  - copied from r1678481, perl/Apache-Reload/trunk/



svn commit: r1678480 - /perl/Apache-Reload/trunk/RELEASE

2015-05-09 Thread stevehay
Author: stevehay
Date: Sat May  9 12:00:27 2015
New Revision: 1678480

URL: http://svn.apache.org/r1678480
Log:
We no longer have -rc $VERSIONs in the .pm files

Modified:
perl/Apache-Reload/trunk/RELEASE

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1678480r1=1678479r2=1678480view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Sat May  9 12:00:27 2015
@@ -52,7 +52,7 @@ Instructions for Apache-Reload Release M
package to be released
 
   a. edit ./Changes
- - remove -rc\d+ (from lib/Apache/Reload.pm and lib/Apache2/Reload.pm also)
+ - remove -rc\d+
  - add release date
 
   b. rerun:




svn commit: r1678481 - /perl/Apache-Reload/trunk/Changes

2015-05-09 Thread stevehay
Author: stevehay
Date: Sat May  9 12:01:11 2015
New Revision: 1678481

URL: http://svn.apache.org/r1678481
Log:
0.13 release

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1678481r1=1678480r2=1678481view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Sat May  9 12:01:11 2015
@@ -6,7 +6,7 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
-=item 0.13-rc2
+=item 0.13 May 09, 2015
 
 Fix reload.t. Reported in CPAN RT#96656.
 [Steve Hay]




[ANNOUNCE] Apache-Reload 0.13

2015-05-09 Thread Steve Hay
We are pleased to announce the release of Apache-Reload 0.13.

This release is now available for download from your favourite CPAN
mirror or you can find it at:

  https://metacpan.org/release/SHAY/Apache-Reload-0.13/

The MD5 digest for this release is: c68a315bc17b2e7419d2820262bbd749

Major changes in this release are as follows:

Fix reload.t. Reported in CPAN RT#96656.
[Steve Hay]


Re: [RELEASE CANDIDATE] Apache-Reload 0.13 RC2

2015-04-23 Thread Adam Prime

+1

apache 2.2.24 on solaris

t/TEST  -bugreport -verbose=0
[warning] Skipping 'set unlimited ulimit for coredumps', since we are 
running as a non-root user on Solaris
/oanda/system/bin/httpd  -d /tmp/Apache-Reload-0.13-rc2/t -f 
/tmp/Apache-Reload-0.13-rc2/t/conf/httpd.conf -D APACHE2

using Apache/2.2.24 (prefork MPM)

waiting 60 seconds for server to start: .[Thu Apr 23 11:32:45 2015] 
[warn] module apreq_module is already loaded, skipping

.
waiting 60 seconds for server to start: ok (waited 1 secs)
server localhost:8529 started
[warning] Using random number seed: 1368693243 (autogenerated)
t/reload.t .. ok
All tests successful.
Files=1, Tests=3,  0 wallclock secs ( 0.01 usr  0.01 sys +  0.24 cusr 
0.04 csys =  0.30 CPU)

Result: PASS

apache 2.0.54 on linux

t/TEST  -bugreport -verbose=0
[warning] setting ulimit to allow core files
ulimit -c unlimited; /usr/bin/perl5.8.6 
/tmp/Apache-Reload-0.13-rc2/t/TEST -bugreport -verbose=0
/usr/local/prefork/bin/httpd  -d /tmp/Apache-Reload-0.13-rc2/t -f 
/tmp/Apache-Reload-0.13-rc2/t/conf/httpd.conf -D APACHE2

using Apache/2.0.54 (prefork MPM)

waiting 60 seconds for server to start: ..
waiting 60 seconds for server to start: ok (waited 1 secs)
server localhost:8529 started
t/reloadok 


All tests successful.
Files=1, Tests=3,  2 wallclock secs ( 1.25 cusr +  0.11 csys =  1.36 CPU)
[warning] server localhost:8529 shutdown

Adam




On 15-04-23 08:21 AM, Steve Hay wrote:

Please download, test, and report back on this Apache-Reload 0.13
release candidate.

http://people.apache.org/~stevehay/Apache-Reload-0.13-rc2.tar.gz

MD5 =70720b76ca7b7ab8798c37922c882648
SHA1 = 3836123e4fee33174eb98c06f211f8c60550f46d

[Note: I bumped the version to RC2 to avoid confusion because I made a
couple of internal changes relating to the creation of the
distribution tarball after committing the RC1 version bump.]

=item 0.13-rc2

Fix reload.t. Reported in CPAN RT#96656.
[Steve Hay]





Re: [RELEASE CANDIDATE] Apache-Reload 0.13 RC2

2015-04-23 Thread Jie Gao
Red Hat Enterprise Linux Server release 6.6 (Santiago)

perl Makefile.PL -httpd /usr/local/apache/bin/httpd  -apxs 
/usr/local/apache/bin/apxs

All tests successful.

Regards,

Jie 

Please think of our environment and only print this e-mail if necessary.

* Steve Hay steve.m@googlemail.com wrote:

 Date: Thu, 23 Apr 2015 13:21:37 +0100
 From: Steve Hay steve.m@googlemail.com
 To: d...@perl.apache.org, modperl@perl.apache.org modperl@perl.apache.org
 Subject: [RELEASE CANDIDATE] Apache-Reload 0.13 RC2
 
 Please download, test, and report back on this Apache-Reload 0.13
 release candidate.
 
 http://people.apache.org/~stevehay/Apache-Reload-0.13-rc2.tar.gz
 
 MD5 =70720b76ca7b7ab8798c37922c882648
 SHA1 = 3836123e4fee33174eb98c06f211f8c60550f46d
 
 [Note: I bumped the version to RC2 to avoid confusion because I made a
 couple of internal changes relating to the creation of the
 distribution tarball after committing the RC1 version bump.]
 
 =item 0.13-rc2
 
 Fix reload.t. Reported in CPAN RT#96656.
 [Steve Hay]


svn commit: r1675551 - /perl/Apache-Reload/trunk/Changes

2015-04-23 Thread stevehay
Author: stevehay
Date: Thu Apr 23 07:52:08 2015
New Revision: 1675551

URL: http://svn.apache.org/r1675551
Log:
Make Apache-Reload-0.13-rc1

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1675551r1=1675550r2=1675551view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Thu Apr 23 07:52:08 2015
@@ -6,7 +6,7 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
-=item 0.13-dev
+=item 0.13-rc1
 
 Fix reload.t. Reported in CPAN RT#96656.
 [Steve Hay]




svn commit: r1675550 - /perl/Apache-Reload/trunk/RELEASE

2015-04-23 Thread stevehay
Author: stevehay
Date: Thu Apr 23 07:45:38 2015
New Revision: 1675550

URL: http://svn.apache.org/r1675550
Log:
Remove instruction not to commit the -dev - -rc1 edit to Changes

This instruction isn't given for Apache-Test (where I recently committed such a 
change), and nobody seems to know of any reason for it. See messages in this 
thread:
http://mail-archives.apache.org/mod_mbox/perl-dev/201504.mbox/%3CCADED%3DK6zKjWhNG7_e6fY7_PrGwWr-DOgczR8VM%3DCLMy%2BKHRGyw%40mail.gmail.com%3E

Modified:
perl/Apache-Reload/trunk/RELEASE

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1675550r1=1675549r2=1675550view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Thu Apr 23 07:45:38 2015
@@ -26,8 +26,6 @@ Instructions for Apache-Reload Release M
   a. edit ./Changes:
  - change -dev to -rc\d+ starting with -rc1
 
- - don't commit this (see dev@ archives)
-
   b. nuke any preinstalled Apache-Reload libs and run 'make test'
 
   c. test that you can 'make install' and then run 'make test' again




svn commit: r1675553 - /perl/Apache-Reload/trunk/Makefile.PL

2015-04-23 Thread stevehay
Author: stevehay
Date: Thu Apr 23 08:09:11 2015
New Revision: 1675553

URL: http://svn.apache.org/r1675553
Log:
Borrow the MAINTAINER_BUILDING_RELEASE=1 hack from Apache-SizeLimit so that the 
instruction about setting it to 1 when making a release actually works! 
(Otherwise we end up with a release called Apache2-Reload.)

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=1675553r1=1675552r2=1675553view=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Thu Apr 23 08:09:11 2015
@@ -33,7 +33,13 @@ my %common_opts = (
clean   = { FILES = 't/TEST' },
   );
 
-if ($mp_gen == 1) {
+### MAINTAINER_BUILDING_RELEASE is hack
+### for the Release Manager's use only.
+### We will set it so that the resulting
+### distribution will be called Apache-Reload-\d+.tar.gz
+### and NOT Apache2-Reload-\d+.tar.gz
+### This is for historical reasons and consistency
+if ($mp_gen == 1 || $ENV{MAINTAINER_BUILDING_RELEASE}) {
 require ExtUtils::MakeMaker;
 ExtUtils::MakeMaker::WriteMakefile(
%common_opts,




[RELEASE CANDIDATE] Apache-Reload 0.13 RC2

2015-04-23 Thread Steve Hay
Please download, test, and report back on this Apache-Reload 0.13
release candidate.

http://people.apache.org/~stevehay/Apache-Reload-0.13-rc2.tar.gz

MD5 =70720b76ca7b7ab8798c37922c882648
SHA1 = 3836123e4fee33174eb98c06f211f8c60550f46d

[Note: I bumped the version to RC2 to avoid confusion because I made a
couple of internal changes relating to the creation of the
distribution tarball after committing the RC1 version bump.]

=item 0.13-rc2

Fix reload.t. Reported in CPAN RT#96656.
[Steve Hay]


svn commit: r1675578 - /perl/Apache-Reload/trunk/Makefile.PL

2015-04-23 Thread stevehay
Author: stevehay
Date: Thu Apr 23 12:08:13 2015
New Revision: 1675578

URL: http://svn.apache.org/r1675578
Log:
Borrow the set_version() trick from Apache-Test so that the 'dist' target makes 
a distribution whose version number is constructed from this 
lib/Apache/Reload.pm file's $VERSION plus the -dev or -rcX suffix from the 
Changes file. (Otherwise, when making a release candidate the package will just 
have the final release number without the -rcX suffix because we're no longer 
putting the -dev or -rcX suffix in the *.pm files' $VERSIONs; see r1675431.)

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=1675578r1=1675577r2=1675578view=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Thu Apr 23 12:08:13 2015
@@ -1,5 +1,6 @@
 use strict;
 
+use lib qw(lib);
 use Config;
 
 my %prereqs = ();
@@ -22,7 +23,11 @@ else {
 
 my $HAS_APACHE_TEST = check_for_apache_test();
 
+my $VERSION;
+set_version();
+
 my %common_opts = (
+   VERSION = $VERSION,
PREREQ_PM   = \%prereqs,
dist= {
COMPRESS = 'gzip -9f', SUFFIX = 'gz',
@@ -43,7 +48,6 @@ if ($mp_gen == 1 || $ENV{MAINTAINER_BUIL
 require ExtUtils::MakeMaker;
 ExtUtils::MakeMaker::WriteMakefile(
%common_opts,
-   VERSION_FROM= 
lib/Apache/Reload.pm,
NAME= Apache::Reload,
ABSTRACT_FROM   = 
'lib/Apache/Reload.pm',
   );
@@ -53,7 +57,6 @@ else {
 require ModPerl::MM;
 ModPerl::MM::WriteMakefile(
%common_opts,
-   VERSION_FROM= lib/Apache2/Reload.pm,
NAME= Apache2::Reload,
ABSTRACT_FROM   = 'lib/Apache2/Reload.pm',
   );
@@ -81,6 +84,22 @@ sub check_for_apache_test {
 return 1;
 }
 
+sub set_version {
+require Apache::Reload;
+$VERSION = $Apache::Reload::VERSION;
+
+my $fh = Symbol::gensym();
+open $fh, 'Changes' or die Can't open Changes: $!;
+while ($fh) {
+if(/^=item.*-(dev|rc\d+)/) {
+$VERSION .= -$1;
+last;
+}
+last if /^=item/;
+}
+close $fh;
+}
+
 # If a specific generation was passed as an argument,
 # if satisfied
 # return the same generation




svn commit: r1675580 - /perl/Apache-Reload/trunk/Changes

2015-04-23 Thread stevehay
Author: stevehay
Date: Thu Apr 23 12:12:20 2015
New Revision: 1675580

URL: http://svn.apache.org/r1675580
Log:
Make Apache-Reload-0.13-rc2

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1675580r1=1675579r2=1675580view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Thu Apr 23 12:12:20 2015
@@ -6,7 +6,7 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
-=item 0.13-rc1
+=item 0.13-rc2
 
 Fix reload.t. Reported in CPAN RT#96656.
 [Steve Hay]




svn commit: r1675431 - /perl/Apache-Reload/trunk/RELEASE

2015-04-22 Thread stevehay
Author: stevehay
Date: Wed Apr 22 17:26:09 2015
New Revision: 1675431

URL: http://svn.apache.org/r1675431
Log:
Remove instruction to bump *.pm $VERSIONs from -dev to -rc1 etc

We don't have -dev $VERSIONs to start with, and I don't think either 0.13-dev 
or 0.13-rc1 is a valid $VERSION number anyway. (It *is* currently that way in 
Apache-SizeLimit, but I don't think it's a good idea and I'd rather change that 
to be like this than change this to be like that.)

Modified:
perl/Apache-Reload/trunk/RELEASE

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1675431r1=1675430r2=1675431view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Wed Apr 22 17:26:09 2015
@@ -24,11 +24,9 @@ Instructions for Apache-Reload Release M
as possible.
 
   a. edit ./Changes:
- - find lib -type f -name *.pm | \
- xargs perl -pi -e 's,0.13-dev,0.13-rc1,g'
- - perl -pi -e 's,0.13-dev,0.13-rc1,g' Changes
+ - change -dev to -rc\d+ starting with -rc1
 
- - don't commit these (see dev@ archives)
+ - don't commit this (see dev@ archives)
 
   b. nuke any preinstalled Apache-Reload libs and run 'make test'
 




svn commit: r1675268 - /perl/Apache-Reload/trunk/Changes

2015-04-22 Thread stevehay
Author: stevehay
Date: Wed Apr 22 07:42:29 2015
New Revision: 1675268

URL: http://svn.apache.org/r1675268
Log:
Fill in previously missed Changes file entry

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1675268r1=1675267r2=1675268view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Wed Apr 22 07:42:29 2015
@@ -8,6 +8,9 @@ Changes - Apache::Reload change logfile
 
 =item 0.13-dev
 
+Fix reload.t. Reported in CPAN RT#96656.
+[Steve Hay]
+
 =item 0.12 March 31, 2012
 
 Set the -apxs argument correctly when building from mod_perl.




svn commit: r1675271 - /perl/Apache-Reload/trunk/RELEASE

2015-04-22 Thread stevehay
Author: stevehay
Date: Wed Apr 22 07:59:01 2015
New Revision: 1675271

URL: http://svn.apache.org/r1675271
Log:
Update PAUSE instructions in RELEASE

Modified:
perl/Apache-Reload/trunk/RELEASE

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1675271r1=1675270r2=1675271view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Wed Apr 22 07:59:01 2015
@@ -25,8 +25,8 @@ Instructions for Apache-Reload Release M
 
 a. login into https://pause.perl.org
 b. menu click: Select Mailinglist/Action
-c. choose APML and share_perms and click go
-d. click 3.3 Make somebody else co-maintainer
+c. choose APML and Change Permissions and click go
+d. click 3.1 Make somebody else co-maintainer
 e. choose the modules to give the perms to
type the username of the new co-maintainer
 f. if you happen to know that packages were added this release,




svn commit: r1675272 - /perl/Apache-Reload/trunk/RELEASE

2015-04-22 Thread stevehay
Author: stevehay
Date: Wed Apr 22 08:01:07 2015
New Revision: 1675272

URL: http://svn.apache.org/r1675272
Log:
KEYS are not required for an Apache-Reload release since it is distributed via 
CPAN

Modified:
perl/Apache-Reload/trunk/RELEASE

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1675272r1=1675271r2=1675272view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Wed Apr 22 08:01:07 2015
@@ -3,22 +3,6 @@ Instructions for Apache-Reload Release M
 0.  Ask the PMC to verify that you have the appropriate CPAN permissions
 on dev@perl.
 
-make sure your public key is in the KEYS file in the mod_perl docs.
-you should only need to do this if this is your first time playing
-Release Manager
-
- $ cd mod_perl-docs
- $ grep $USER src/dist/KEYS
-
-note that the KEYS file itself contains all the instructions you
-need on how to add your key.  if you need further help on gpg
-(like how to create a key in the first place) you can look here
-
-  http://people.apache.org/~geoff/gpghowto.html
-
-Copy the KEYS file into place:
-% scp KEYS www.apache.org:/www/www.apache.org/dist/perl/KEYS
-
 If this is your first release, ask someone with APML karma on PAUSE
 to verify you have the appropriate permissions.  Likely someone on
 the PMC can do this.




svn commit: r1675273 - /perl/Apache-Reload/trunk/RELEASE

2015-04-22 Thread stevehay
Author: stevehay
Date: Wed Apr 22 08:07:11 2015
New Revision: 1675273

URL: http://svn.apache.org/r1675273
Log:
Note that the automated update of RELEASE accidentally updates something that 
it shouldn't, which then needs undoing

Modified:
perl/Apache-Reload/trunk/RELEASE

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1675273r1=1675272r2=1675273view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Wed Apr 22 08:07:11 2015
@@ -99,6 +99,8 @@ Instructions for Apache-Reload Release M
 
  $ perl -pi -e 's/(\d+)\.(\d+)/join(., $1, $2+1)/eg' RELEASE
 
+ (undo the change to the PAUSE menu item number in item 0d. above)
+
   d. commit Changes
  % svn ci -m start 0.13-dev cycle Changes RELEASE \
lib/Apache/Reload.pm lib/Apache2/Reload.pm




svn commit: r1675267 - in /perl/Apache-Reload/trunk: Changes RELEASE lib/Apache/Reload.pm

2015-04-22 Thread stevehay
Author: stevehay
Date: Wed Apr 22 07:41:03 2015
New Revision: 1675267

URL: http://svn.apache.org/r1675267
Log:
start 0.13-dev cycle

[This should have been done when 0.12 was made, but seems to have been 
forgotten. Doing it now since we're about to start the release process for 
0.13.]

Modified:
perl/Apache-Reload/trunk/Changes
perl/Apache-Reload/trunk/RELEASE
perl/Apache-Reload/trunk/lib/Apache/Reload.pm

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1675267r1=1675266r2=1675267view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Wed Apr 22 07:41:03 2015
@@ -6,6 +6,8 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
+=item 0.13-dev
+
 =item 0.12 March 31, 2012
 
 Set the -apxs argument correctly when building from mod_perl.

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1675267r1=1675266r2=1675267view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Wed Apr 22 07:41:03 2015
@@ -1,120 +1,120 @@
-Instructions for Apache-Reload Release Manager
-
-0.  Ask the PMC to verify that you have the appropriate CPAN permissions
-on dev@perl.
-
-make sure your public key is in the KEYS file in the mod_perl docs.
-you should only need to do this if this is your first time playing
-Release Manager
-
- $ cd mod_perl-docs
- $ grep $USER src/dist/KEYS
-
-note that the KEYS file itself contains all the instructions you
-need on how to add your key.  if you need further help on gpg
-(like how to create a key in the first place) you can look here
-
-  http://people.apache.org/~geoff/gpghowto.html
-
-Copy the KEYS file into place:
-% scp KEYS www.apache.org:/www/www.apache.org/dist/perl/KEYS
-
-If this is your first release, ask someone with APML karma on PAUSE
-to verify you have the appropriate permissions.  Likely someone on
-the PMC can do this.
-
-a. login into https://pause.perl.org
-b. menu click: Select Mailinglist/Action
-c. choose APML and share_perms and click go
-d. click 3.3 Make somebody else co-maintainer
-e. choose the modules to give the perms to
-   type the username of the new co-maintainer
-f. if you happen to know that packages were added this release,
-   make sure you give the correct permissions to them.
-
- MAINTAINER_BUILDING_RELEASE=1 perl Makefile.PL
-
-1. 'make disttest' - to make sure nothing is missing from the manifest.
-   Now 'make dist', and test this generated package (not svn)
-   with as many configurations as possible on as many platforms
-   as possible.
-
-  a. edit ./Changes:
- - find lib -type f -name *.pm | \
- xargs perl -pi -e 's,0.12-dev,0.12-rc1,g'
- - perl -pi -e 's,0.12-dev,0.12-rc1,g' Changes
-
- - don't commit these (see dev@ archives)
-
-  b. nuke any preinstalled Apache-Reload libs and run 'make test'
-
-  c. test that you can 'make install' and then run 'make test' again
-
-  d. test whether we still 100% OK on systems with no LWP:
-
- % APACHE_TEST_PRETEND_NO_LWP=1 make test
-
-2. once confident that the package is good, upload a release candidate
-   to people.apache.org/~username and post 24 hour-ish candidate alert
-   to the various lists
-
- o dev/perl.apache.org
- o modperl/perl.apache.org
-
-  Subject: [RELEASE CANDIDATE] Apache-Reload 0.12 RC\d+
-
-   (or maybe longer to give most people a chance to catch up). no need
-   to tag this package
-
-  a. if problems are detected during stage 2, repeat stages 1 and 2.
-
-3. when the package has been reported to be good, prepare a new
-   package to be released
-
-  a. edit ./Changes
- - remove -rc\d+ (from lib/Apache/Reload.pm and lib/Apache2/Reload.pm also)
- - add release date
-
-  b. rerun:
- % perl Makefile.PL
- make sure tag looks right
- % make -n tag
-
-  c. commit Changes
- % svn ci Changes
-
-  d. tag
- % make tag
-
-  e. create the final package
- % make dist
-
-  f. test the final package again at least once
-
-4. Upload the package to CPAN
-
-5. Announce the package
-
-  a. post ... to the modperl, announce lists
-  Subject: [ANNOUNCE] Apache-Reload 0.12
- include 
-  - MD5 sig (as it comes from CPAN upload announce).
-  - the latest Changes
-
-6. Prepare for the next cycle
-
-  a. increment version in lib/Apache/Reload.pm
-
-  b. edit ./Changes:
- - start a new item with incremented version + '-dev'
-
-  =item 0.13-dev
-
-  c. bump up version numbers in this file to make it easier to do the
- next release.
-
- $ perl -pi -e 's/(\d+)\.(\d+)/join(., $1, $2+1)/eg' RELEASE
-
-  d. commit Changes
- % svn ci -m start 0.12-dev cycle Changes

svn commit: r1675269 - /perl/Apache-Reload/trunk/Makefile.PL

2015-04-22 Thread stevehay
Author: stevehay
Date: Wed Apr 22 07:48:49 2015
New Revision: 1675269

URL: http://svn.apache.org/r1675269
Log:
Ensure file permissions and EOLs are set correctly when creating the release 
tarball

Otherwise EOLs in particular are not set correctly (i.e. LF) when creating a 
release from a workspace on a Windows machine since native EOLs (i.e. CRLF in 
this case) are used by default in client-side workspaces.

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=1675269r1=1675268r2=1675269view=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Wed Apr 22 07:48:49 2015
@@ -24,6 +24,12 @@ my $HAS_APACHE_TEST = check_for_apache_t
 
 my %common_opts = (
PREREQ_PM   = \%prereqs,
+   dist= {
+   COMPRESS = 'gzip -9f', SUFFIX = 'gz',
+   PREOP   = 'find $(DISTVNAME) -type d -print|xargs 
chmod 0755  ' .
+  'find $(DISTVNAME) -type f -print|xargs 
chmod 0644',
+   TO_UNIX = 'find $(DISTVNAME) -type f -print|xargs 
dos2unix'
+   },
clean   = { FILES = 't/TEST' },
   );
 




svn commit: r1675270 - in /perl/Apache-Reload/trunk: RELEASE lib/Apache2/Reload.pm

2015-04-22 Thread stevehay
Author: stevehay
Date: Wed Apr 22 07:54:52 2015
New Revision: 1675270

URL: http://svn.apache.org/r1675270
Log:
Missed a $VERSION bump in lib/Apache2/Reload.pm

Update RELEASE notes too so that this doesn't get forgotten again.

Modified:
perl/Apache-Reload/trunk/RELEASE
perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=1675270r1=1675269r2=1675270view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Wed Apr 22 07:54:52 2015
@@ -103,7 +103,7 @@ Instructions for Apache-Reload Release M
 
 6. Prepare for the next cycle
 
-  a. increment version in lib/Apache/Reload.pm
+  a. increment version in lib/Apache/Reload.pm and lib/Apache2/Reload.pm also
 
   b. edit ./Changes:
  - start a new item with incremented version + '-dev'

Modified: perl/Apache-Reload/trunk/lib/Apache2/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache2/Reload.pm?rev=1675270r1=1675269r2=1675270view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache2/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache2/Reload.pm Wed Apr 22 07:54:52 2015
@@ -18,7 +18,7 @@ package Apache2::Reload;
 use strict;
 use warnings FATAL = 'all';
 
-our $VERSION = '0.12';
+our $VERSION = '0.13';
 
 use Apache2::Const -compile = qw(OK);
 




Re: bug in trunk in Apache::Reload test

2014-06-26 Thread Joshua Narins
On Mon, Jun 23, 2014 at 06:21:37PM +, Mark Hedges wrote:
 Perl 5.20.0, Apache 2.2.27, APR 1.5.1, APR-util 1.5.3, mod_perl trunk.
 
 2014-06-23 11:16:32 Mon  $ svn diff t/lib/Apache2/TestReload.pm
 Index: t/lib/Apache2/TestReload.pm
 ===
 --- t/lib/Apache2/TestReload.pm (revision 1604706)
 +++ t/lib/Apache2/TestReload.pm  (working copy)
 @@ -15,7 +15,8 @@
 sub handler {
  my $r = shift;
  $pass++;
 -if ($r-args eq 'last') {
 +my $args = $r-args;
 +if (defined $args  $r-args eq 'last') {
  Apache2::Reload-unregister_module($package);
  ModPerl::Util::unload_package($package);
  $pass = 0;

Why not just

my $args = $r-args;
if (defined $args and $args eq 'last') {

I guess repeat calls to $r-args have virtually no cost?



Re: bug in trunk in Apache::Reload test

2014-06-26 Thread Sergiy Borodych
Hello,

another question:
 why not just

my $args = $r-args;
if ( $args and $args eq 'last' ) {

(without defined)

or even

 if ( my $args = $r-args and $args eq 'last' ) {

:)


2014-06-26 10:52 GMT+03:00 Joshua Narins j...@mobehr.net:

 On Mon, Jun 23, 2014 at 06:21:37PM +, Mark Hedges wrote:
  Perl 5.20.0, Apache 2.2.27, APR 1.5.1, APR-util 1.5.3, mod_perl trunk.
 
  2014-06-23 11:16:32 Mon  $ svn diff t/lib/Apache2/TestReload.pm
  Index: t/lib/Apache2/TestReload.pm
  ===
  --- t/lib/Apache2/TestReload.pm (revision 1604706)
  +++ t/lib/Apache2/TestReload.pm  (working copy)
  @@ -15,7 +15,8 @@
  sub handler {
   my $r = shift;
   $pass++;
  -if ($r-args eq 'last') {
  +my $args = $r-args;
  +if (defined $args  $r-args eq 'last') {
   Apache2::Reload-unregister_module($package);
   ModPerl::Util::unload_package($package);
   $pass = 0;

 Why not just

 my $args = $r-args;
 if (defined $args and $args eq 'last') {

 I guess repeat calls to $r-args have virtually no cost?




-- 
Sergiy Borodych
http://bor.org.ua


Re: bug in trunk in Apache::Reload test

2014-06-26 Thread Joshua Narins
On Thu, Jun 26, 2014 at 03:52:33AM -0400, Joshua Narins wrote:
 On Mon, Jun 23, 2014 at 06:21:37PM +, Mark Hedges wrote:
  Perl 5.20.0, Apache 2.2.27, APR 1.5.1, APR-util 1.5.3, mod_perl trunk.
  
  2014-06-23 11:16:32 Mon  $ svn diff t/lib/Apache2/TestReload.pm
  Index: t/lib/Apache2/TestReload.pm
  ===
  --- t/lib/Apache2/TestReload.pm (revision 1604706)
  +++ t/lib/Apache2/TestReload.pm  (working copy)
  @@ -15,7 +15,8 @@
  sub handler {
   my $r = shift;
   $pass++;
  -if ($r-args eq 'last') {
  +my $args = $r-args;
  +if (defined $args  $r-args eq 'last') {
   Apache2::Reload-unregister_module($package);
   ModPerl::Util::unload_package($package);
   $pass = 0;
 
 Why not just
 
 my $args = $r-args;
 if (defined $args and $args eq 'last') {
 
 I guess repeat calls to $r-args have virtually no cost?
 

I am sorry. I am not competent to help with the big stuff in mod_perl, so
I just nip around the fringes like an annoying dog.
 Also reported on Apache::Reload at rt.cpan.org.
 
 Thanks.
 
 Mark


RE: bug in trunk in Apache::Reload test

2014-06-26 Thread Mark Hedges
Nope Joshua you're right, I missed that.

defined() is faster than the logical check because the logical check checks 
defined, then checks if empty string, then checks if numerically 0, except if 
it is 0E0 (zero but true).  One operation versus the same operation plus three 
more; the one by itself is certainly less computation.

However I'm not sure about the last one.  That is a cool idea.  We'd have to 
benchmark it.  :-)

Also is '' faster than 'and'?

Mark



From: sergiy.borod...@gmail.com [mailto:sergiy.borod...@gmail.com] On Behalf Of 
Sergiy Borodych
Sent: Thursday, June 26, 2014 2:14 AM
To: Joshua Narins
Cc: Mark Hedges; modperl@perl.apache.org
Subject: Re: bug in trunk in Apache::Reload test

Hello,
another question:
 why not just 

my $args = $r-args;
if ( $args and $args eq 'last' ) {

(without defined)

or even

 if ( my $args = $r-args and $args eq 'last' ) {

:)

2014-06-26 10:52 GMT+03:00 Joshua Narins j...@mobehr.net:
On Mon, Jun 23, 2014 at 06:21:37PM +, Mark Hedges wrote:
 Perl 5.20.0, Apache 2.2.27, APR 1.5.1, APR-util 1.5.3, mod_perl trunk.

 2014-06-23 11:16:32 Mon  $ svn diff t/lib/Apache2/TestReload.pm
 Index: t/lib/Apache2/TestReload.pm
 ===
 --- t/lib/Apache2/TestReload.pm             (revision 1604706)
 +++ t/lib/Apache2/TestReload.pm          (working copy)
 @@ -15,7 +15,8 @@
 sub handler {
      my $r = shift;
      $pass++;
 -    if ($r-args eq 'last') {
 +    my $args = $r-args;
 +    if (defined $args  $r-args eq 'last') {
          Apache2::Reload-unregister_module($package);
          ModPerl::Util::unload_package($package);
          $pass = 0;

Why not just

my $args = $r-args;
if (defined $args and $args eq 'last') {

I guess repeat calls to $r-args have virtually no cost?



-- 
Sergiy Borodych
http://bor.org.ua 


Re: bug in trunk in Apache::Reload test

2014-06-26 Thread André Warnier
There is also something to be said for writing clear and obvious code, even if it does 
cost a couple of CPU cycles of which there are about 2.5 billion available every second.


I prefer this version :

my $args = $r-args;
if (defined($args)  ($args eq 'last')) {
...
}

unless $args is used exclusively inside the if {} block (*).
Clear, no side-effects, no hidden meaning behind the if ($args), no double dereferencing 
overhead - assuming perl doesn't optimise this itself - , no worries about operator 
precedence etc.
Syntactic sugar and perl virtuosity are nice if they are for one's self-satisfaction, 
hubris and laziness, but if some junior has to handle this code after you lose interest, 
it's better to be plain and obvious.


(*) in which case I might just about forgive you for writing
if (defined(my $args = $r-args)  ($args eq 'last')) {
, although that would probably force the junior to consult the (otherwise excellent and 
humorous) perl documentation to verify the scope of $args.


Mark Hedges wrote:

Nope Joshua you're right, I missed that.

defined() is faster than the logical check because the logical check checks 
defined, then checks if empty string, then checks if numerically 0, except if 
it is 0E0 (zero but true).  One operation versus the same operation plus three 
more; the one by itself is certainly less computation.

However I'm not sure about the last one.  That is a cool idea.  We'd have to 
benchmark it.  :-)

Also is '' faster than 'and'?

Mark



From: sergiy.borod...@gmail.com [mailto:sergiy.borod...@gmail.com] On Behalf Of 
Sergiy Borodych
Sent: Thursday, June 26, 2014 2:14 AM
To: Joshua Narins
Cc: Mark Hedges; modperl@perl.apache.org
Subject: Re: bug in trunk in Apache::Reload test

Hello,
another question:
 why not just 


my $args = $r-args;
if ( $args and $args eq 'last' ) {

(without defined)

or even

 if ( my $args = $r-args and $args eq 'last' ) {

:)

2014-06-26 10:52 GMT+03:00 Joshua Narins j...@mobehr.net:
On Mon, Jun 23, 2014 at 06:21:37PM +, Mark Hedges wrote:

Perl 5.20.0, Apache 2.2.27, APR 1.5.1, APR-util 1.5.3, mod_perl trunk.

2014-06-23 11:16:32 Mon  $ svn diff t/lib/Apache2/TestReload.pm
Index: t/lib/Apache2/TestReload.pm
===
--- t/lib/Apache2/TestReload.pm (revision 1604706)
+++ t/lib/Apache2/TestReload.pm  (working copy)
@@ -15,7 +15,8 @@
sub handler {
 my $r = shift;
 $pass++;
-if ($r-args eq 'last') {
+my $args = $r-args;
+if (defined $args  $r-args eq 'last') {
 Apache2::Reload-unregister_module($package);
 ModPerl::Util::unload_package($package);
 $pass = 0;


Why not just

my $args = $r-args;
if (defined $args and $args eq 'last') {

I guess repeat calls to $r-args have virtually no cost?







svn commit: r1605020 - /perl/Apache-Reload/trunk/t/lib/Apache2/TestReload.pm

2014-06-24 Thread stevehay
Author: stevehay
Date: Tue Jun 24 07:29:59 2014
New Revision: 1605020

URL: http://svn.apache.org/r1605020
Log:
Fix reload.t as per r1565579. Reported in CPAN RT#96656.

Modified:
perl/Apache-Reload/trunk/t/lib/Apache2/TestReload.pm

Modified: perl/Apache-Reload/trunk/t/lib/Apache2/TestReload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/t/lib/Apache2/TestReload.pm?rev=1605020r1=1605019r2=1605020view=diff
==
--- perl/Apache-Reload/trunk/t/lib/Apache2/TestReload.pm (original)
+++ perl/Apache-Reload/trunk/t/lib/Apache2/TestReload.pm Tue Jun 24 07:29:59 
2014
@@ -15,7 +15,7 @@ our $pass = 0;
 sub handler {
 my $r = shift;
 $pass++;
-if ($r-args eq 'last') {
+if (defined $r-args and $r-args eq 'last') {
 Apache2::Reload-unregister_module($package);
 ModPerl::Util::unload_package($package);
 $pass = 0;




bug in trunk in Apache::Reload test

2014-06-23 Thread Mark Hedges
Perl 5.20.0, Apache 2.2.27, APR 1.5.1, APR-util 1.5.3, mod_perl trunk.

2014-06-23 11:16:32 Mon  $ svn diff t/lib/Apache2/TestReload.pm
Index: t/lib/Apache2/TestReload.pm
===
--- t/lib/Apache2/TestReload.pm (revision 1604706)
+++ t/lib/Apache2/TestReload.pm  (working copy)
@@ -15,7 +15,8 @@
sub handler {
 my $r = shift;
 $pass++;
-if ($r-args eq 'last') {
+my $args = $r-args;
+if (defined $args  $r-args eq 'last') {
 Apache2::Reload-unregister_module($package);
 ModPerl::Util::unload_package($package);
 $pass = 0;

Also reported on Apache::Reload at rt.cpan.org.

Thanks.

Mark


svn commit: r1452119 - in /perl/Apache-Reload/tags/0_12/t/conf: ./ extra.conf.in

2013-03-03 Thread torsten
Author: torsten
Date: Sun Mar  3 20:34:40 2013
New Revision: 1452119

URL: http://svn.apache.org/r1452119
Log:
If built as part of the modperl distibution, t/conf/httpd.conf loads

   Apache-Reload/../src/modules/perl/mod_perl.so

but could load Perl modules like Apache2::RequestIO that are installed
elsewhere in the system. That might cause false test failures.

This commit fixes that.

Added:
perl/Apache-Reload/tags/0_12/t/conf/extra.conf.in
Modified:
perl/Apache-Reload/tags/0_12/t/conf/   (props changed)

Propchange: perl/Apache-Reload/tags/0_12/t/conf/
--
--- svn:ignore (original)
+++ svn:ignore Sun Mar  3 20:34:40 2013
@@ -1,7 +1,7 @@
 extra.conf
 httpd.conf
 extra.last.conf
-extra.conf.in
+extra.conf
 apache_test_config.pm
 mime.types
 modperl_inc.pl

Added: perl/Apache-Reload/tags/0_12/t/conf/extra.conf.in
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/tags/0_12/t/conf/extra.conf.in?rev=1452119view=auto
==
--- perl/Apache-Reload/tags/0_12/t/conf/extra.conf.in (added)
+++ perl/Apache-Reload/tags/0_12/t/conf/extra.conf.in Sun Mar  3 20:34:40 2013
@@ -0,0 +1,3 @@
+PerlSwitches -I@ServerRoot@/../../Apache-Test/lib   \
+ -I@ServerRoot@/../../blib/lib  \
+ -I@ServerRoot@/../../blib/arch




Apache::Reload

2012-06-17 Thread cfaust-dougot
Hello,
I'm having a problem with Apache::Reload and I'm not sure what I can do to 
debug.

Long story short, I use Apache::Reload all the time but I recently setup a new 
development server and its under the new machine that its a problem.
 
The module is installed and when I add to my conf:
 
  PerlInitHandler Apache::Reload
  PerlSetVar ReloadAll Off
 
I can restart apache and everything loads up (apache starts and will serve 
static pages etc). The problem happens as soon as you invoke a mod_perl content 
handler. The first time you hit a script URL you get a 500 internal server 
error, but as soon as you comment out those 2 lines everything works (except 
apache reload of course).
 
What is killing me is there is NOTHING logged!!! The apache log and domain logs 
show nothing.
 
This server is a WHM/CPANEL server and I'm wondering if that has anything to do 
with it? I don't know if its just a coincidence, but on every non-cpanel 
machine I have ever seen has apache reload, but on the cpanel machines its 
apache graceful. I wouldn't think that should matter but the timing is there 
because the module does load via the conf but the first time you invoke a 
mod_perl content handler, Apache::Reload should be tell apache to reload its 
configs and that's when you get the 500 error.
 
My install is old because I'm trying to stay within the available repositores 
instead of building from source, I guess I could update but I don't know if 
that's going to solved my problem.
 
CentOS 5.8
Apache/2.2.22 (Unix) 
mod_apreq2-20090110/2.8.0 
mod_perl/2.0.5 
Perl/v5.8.8 
 
Any ideas of how I can debug this? I can't believe that apache is throwing a 
500 error and no information about it is being logged, that at least might tell 
me something.
 
TIA!
-Chris
 


[announce] Apache-Reload 0.12

2012-03-31 Thread Fred Moyer
Apache-Reload 0.12 is headed to a CPAN mirror near you.

MD5  232daa7e1f6ddfbbeac505010f1b20f7


Changes summary

=item 0.12 March 31, 2012

Set the -apxs argument correctly when building from mod_perl.
[Steve Hay]

Doc spelling fix
[Nicholas Bamber]

Add Apache-Test 1.34 dependency.
[Phred]


svn commit: r1307860 - /perl/Apache-Reload/trunk/Changes

2012-03-31 Thread phred
Author: phred
Date: Sat Mar 31 17:36:03 2012
New Revision: 1307860

URL: http://svn.apache.org/viewvc?rev=1307860view=rev
Log:
Ship 0.12

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1307860r1=1307859r2=1307860view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Sat Mar 31 17:36:03 2012
@@ -6,7 +6,7 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
-=item 0.12-dev
+=item 0.12 March 31, 2012
 
 Set the -apxs argument correctly when building from mod_perl.
 [Steve Hay]




svn commit: r1307861 - /perl/Apache-Reload/tags/0_12/

2012-03-31 Thread phred
Author: phred
Date: Sat Mar 31 17:37:10 2012
New Revision: 1307861

URL: http://svn.apache.org/viewvc?rev=1307861view=rev
Log:
Tagging 0.12

Added:
perl/Apache-Reload/tags/0_12/
  - copied from r1307860, perl/Apache-Reload/trunk/



svn commit: r1205130 - in /perl/Apache-Reload/trunk: ./ t/ t/conf/

2011-11-22 Thread gozer
Author: gozer
Date: Tue Nov 22 19:06:46 2011
New Revision: 1205130

URL: http://svn.apache.org/viewvc?rev=1205130view=rev
Log:
Add some svn:ignores

Modified:
perl/Apache-Reload/trunk/   (props changed)
perl/Apache-Reload/trunk/t/   (props changed)
perl/Apache-Reload/trunk/t/conf/   (props changed)

Propchange: perl/Apache-Reload/trunk/
--
--- svn:ignore (added)
+++ svn:ignore Tue Nov 22 19:06:46 2011
@@ -0,0 +1,8 @@
+blib
+glue_pods
+pm_to_blib
+pm_to_blib.ts
+blibdirs
+blibdirs.ts
+Makefile
+Makefile.old

Propchange: perl/Apache-Reload/trunk/t/
--
--- svn:ignore (added)
+++ svn:ignore Tue Nov 22 19:06:46 2011
@@ -0,0 +1,4 @@
+logs
+htdocs
+TEST
+SMOKE

Propchange: perl/Apache-Reload/trunk/t/conf/
--
--- svn:ignore (added)
+++ svn:ignore Tue Nov 22 19:06:46 2011
@@ -0,0 +1,8 @@
+extra.conf
+httpd.conf
+extra.last.conf
+extra.conf.in
+apache_test_config.pm
+mime.types
+modperl_inc.pl
+modperl_startup.pl




svn commit: r1149225 - /perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

2011-07-21 Thread phred
Author: phred
Date: Thu Jul 21 15:34:31 2011
New Revision: 1149225

URL: http://svn.apache.org/viewvc?rev=1149225view=rev
Log:
[rt.cpan.org #69643] [PATCH] Spelling fix

Modified:
perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/lib/Apache2/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache2/Reload.pm?rev=1149225r1=1149224r2=1149225view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache2/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache2/Reload.pm Thu Jul 21 15:34:31 2011
@@ -358,7 +358,7 @@ mode described before.
 
 =head2 Unregistering a module
 
-In some cases, it might be necessary to explicitely stop reloading
+In some cases, it might be necessary to explicitly stop reloading
 a module.
 
   Apache2::Reload-unregister_module('Some::Module');




svn commit: r1149233 - /perl/Apache-Reload/trunk/Changes

2011-07-21 Thread phred
Author: phred
Date: Thu Jul 21 15:41:54 2011
New Revision: 1149233

URL: http://svn.apache.org/viewvc?rev=1149233view=rev
Log:
69643

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1149233r1=1149232r2=1149233view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Thu Jul 21 15:41:54 2011
@@ -8,6 +8,8 @@ Changes - Apache::Reload change logfile
 
 =item 0.12-dev
 
+Doc spelling fix
+[Nicholas Bamber]
 
 =item 0.11 August 21, 2010
 




svn commit: r1060992 - /perl/Apache-Reload/trunk/Changes

2011-01-19 Thread phred
Author: phred
Date: Wed Jan 19 21:16:00 2011
New Revision: 1060992

URL: http://svn.apache.org/viewvc?rev=1060992view=rev
Log:
minor fix

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1060992r1=1060991r2=1060992view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Wed Jan 19 21:16:00 2011
@@ -6,7 +6,7 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
-=item 0.12+dev
+=item 0.12-dev
 
 
 =item 0.11 August 21, 2010




svn commit: r1023551 - in /perl/Apache-Reload/trunk: Changes Makefile.PL lib/Apache2/Reload.pm

2010-10-17 Thread phred
Author: phred
Date: Sun Oct 17 18:41:46 2010
New Revision: 1023551

URL: http://svn.apache.org/viewvc?rev=1023551view=rev
Log:
Add Apache-Test 1.34 dependency, and install in the same directory as mod_perl 
to prevent conflicts with cpan module installs.


Modified:
perl/Apache-Reload/trunk/Changes
perl/Apache-Reload/trunk/Makefile.PL
perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=1023551r1=1023550r2=1023551view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Sun Oct 17 18:41:46 2010
@@ -11,6 +11,9 @@ Changes - Apache::Reload change logfile
 
 =item 0.11 August 21, 2010
 
+Add Apache-Test 1.34 dependency.
+[Phred]
+
 Ignore require-hooks which exist in %INC
 [Ryan Gies r...@livesite.net]
 

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=1023551r1=1023550r2=1023551view=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Sun Oct 17 18:41:46 2010
@@ -5,7 +5,7 @@ use Config;
 my %prereqs = ();
 my %mp2 = ( mod_perl2 = 1.99022 );
 my %mp1 = ( mod_perl  = 0 );
-my $at_min_ver = 1.30;
+my $at_min_ver = 1.34;
 
 my $mp_gen;
 if ($ENV{MOD_PERL_2_BUILD}) {
@@ -45,6 +45,7 @@ else {
   );
 }
 
+# MOD_PERL_2_BUILD is set from building from mod_perl Makefile.PL
 if ($ENV{MOD_PERL_2_BUILD}) {
 pop @ARGV;
 }
@@ -53,10 +54,9 @@ sub check_for_apache_test {
 return unless eval {
 require Apache::Test;
 if ($Apache::Test::VERSION  $at_min_ver) {
-warn Apache::Test version is  . $Apache::Test::VERSION . 
+die Apache::Test version is  . $Apache::Test::VERSION . 
 , minimum version required is $at_min_ver . 
 , tests will be skipped\n;
-die;
 }
 require Apache::TestMM;
 require Apache::TestRunPerl;
@@ -67,13 +67,6 @@ sub check_for_apache_test {
 
 my %args = @Apache::TestMM::Argv;
 
-return 0
-unless (( Apache::TestConfig-can('custom_config_path')
-  and -f Apache::TestConfig-custom_config_path())
-or $args{apxs} or $args{httpd}
-or $ENV{APACHE_TEST_HTTPD} or $ENV{APACHE_TEST_APXS});
-
-
 Apache::TestRunPerl-generate_script();
 
 return 1;
@@ -180,6 +173,15 @@ EOF
 eval { require mod_perl };
 if ($@) {
 # if we don't have mp1, check for mp2
+# see if we are in the mp2 build structure
+eval { require File::Spec };
+unless ($@) {
+my $mplib = File::Spec-catdir('..', 'lib');
+unshift @INC, $mplib if -e 
File::Spec-catfile($mplib,'mod_perl2.pm');
+my $atlib = File::Spec-catdir('../', 'Apache-Test', 'lib');
+unshift @INC, $atlib if -d $atlib;
+} 
+
 eval { require mod_perl2 } if ($@);
 unless ($@) {
 $wanted = 2;
@@ -236,3 +238,24 @@ sub clean {
 
 return $self-SUPER::clean(@_);
 }
+
+sub constants {
+my $self = shift;
+
+my $string = $self-MM::constants;
+
+# mp2 installs this into INSTALLSITEARCH, so in order to avoid
+# problems when users forget 'make install UNINST=1', trick MM into
+# installing pure perl modules to the sitearch location, when this is
+# not installed as a part of mp2 build
+if (!$ENV{MOD_PERL_2_BUILD}) {
+$string .= 'EOI';
+
+# install into the same location as mod_perl 2.0
+INSTALLSITELIB = $(INSTALLSITEARCH)
+DESTINSTALLSITELIB = $(DESTINSTALLSITEARCH)
+EOI
+}
+
+$string;
+}

Modified: perl/Apache-Reload/trunk/lib/Apache2/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache2/Reload.pm?rev=1023551r1=1023550r2=1023551view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache2/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache2/Reload.pm Sun Oct 17 18:41:46 2010
@@ -18,8 +18,6 @@ package Apache2::Reload;
 use strict;
 use warnings FATAL = 'all';
 
-use mod_perl2;
-
 our $VERSION = '0.12';
 
 use Apache2::Const -compile = qw(OK);




[ANNOUNCE] Apache-Reload 0.11

2010-08-21 Thread Fred Moyer
Apache::Reload 0.11 has been shipped to CPAN, and will be appearing at
a mirror near you shortly.

  md5: ec02f93aeef08f2d9e6734645a131a21


Thanks to the contributors who provided new features and bug fixes.
Summary of changes:

Ignore require-hooks which exist in %INC
[Ryan Gies r...@livesite.net]

Reloads by file, not module name
[Ryan Gies r...@livesite.net]

Add a no Apache::Reload directive which skips reloading for modules
that have it included (useful for Moose compatibility).
[Graham Barr, gb...@pobox.com]

Add Empty NOTICE file
http://rt.cpan.org/Ticket/Display.html?id=34786
[Niko Tyni (Debian Perl Group) nt...@debian.org]


svn commit: r987816 - in /perl/Apache-Reload/trunk: Changes RELEASE lib/Apache/Reload.pm lib/Apache2/Reload.pm

2010-08-21 Thread phred
Author: phred
Date: Sat Aug 21 19:48:28 2010
New Revision: 987816

URL: http://svn.apache.org/viewvc?rev=987816view=rev
Log:
0.11 release version

Modified:
perl/Apache-Reload/trunk/Changes
perl/Apache-Reload/trunk/RELEASE
perl/Apache-Reload/trunk/lib/Apache/Reload.pm
perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=987816r1=987815r2=987816view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Sat Aug 21 19:48:28 2010
@@ -6,7 +6,7 @@ Changes - Apache::Reload change logfile
 
 =over 1
 
-=item 0.11-dev
+=item 0.11 August 21, 2010
 
 Ignore require-hooks which exist in %INC
 [Ryan Gies r...@livesite.net]

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=987816r1=987815r2=987816view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Sat Aug 21 19:48:28 2010
@@ -71,8 +71,8 @@ Instructions for Apache-Reload Release M
 3. when the package has been reported to be good, prepare a new
package to be released
 
-  a. edit ./Changes:
- - remove -rc\d+
+  a. edit ./Changes
+ - remove -rc\d+ (from lib/Apache/Reload.pm and lib/Apache2/Reload.pm also)
  - add release date
 
   b. rerun:

Modified: perl/Apache-Reload/trunk/lib/Apache/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache/Reload.pm?rev=987816r1=987815r2=987816view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache/Reload.pm Sat Aug 21 19:48:28 2010
@@ -17,7 +17,7 @@ package Apache::Reload;
 
 use strict;
 
-$Apache::Reload::VERSION = '0.11-dev';
+$Apache::Reload::VERSION = '0.11';
 
 use vars qw(%INCS %Stat $TouchTime %UndefFields %Ignore);
 

Modified: perl/Apache-Reload/trunk/lib/Apache2/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache2/Reload.pm?rev=987816r1=987815r2=987816view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache2/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache2/Reload.pm Sat Aug 21 19:48:28 2010
@@ -20,7 +20,7 @@ use warnings FATAL = 'all';
 
 use mod_perl2;
 
-our $VERSION = '0.12';
+our $VERSION = '0.11';
 
 use Apache2::Const -compile = qw(OK);
 




svn commit: r984198 - /perl/Apache-Reload/trunk/lib/Apache/Reload.pm

2010-08-10 Thread phred
Author: phred
Date: Tue Aug 10 20:18:35 2010
New Revision: 984198

URL: http://svn.apache.org/viewvc?rev=984198view=rev
Log:
Add global %Ignore variable.  Thanks to Adam Prime for the spot.

Modified:
perl/Apache-Reload/trunk/lib/Apache/Reload.pm

Modified: perl/Apache-Reload/trunk/lib/Apache/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache/Reload.pm?rev=984198r1=984197r2=984198view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache/Reload.pm Tue Aug 10 20:18:35 2010
@@ -19,7 +19,7 @@ use strict;
 
 $Apache::Reload::VERSION = '0.11-dev';
 
-use vars qw(%INCS %Stat $TouchTime %UndefFields);
+use vars qw(%INCS %Stat $TouchTime %UndefFields %Ignore);
 
 %Stat = ($INC{Apache/Reload.pm} = time);
 




Re: [RELEASE CANDIDATE] Apache-Reload 0.11 RC1

2010-08-09 Thread Fred Moyer
Thanks for the +1, but I put up a poorly named link.  Here's the
updated link (I've been in mp2 land for too long apparently):

http://people.apache.org/~phred/Apache-Reload-0.11-rc1.tar.gz

+1 from me on Darwin / perl 5.12

Any others?  (note that the package contents are the same as the previous link)

On Mon, Aug 2, 2010 at 5:49 PM, Philip M. Gollucci pgollu...@p6m7g8.com wrote:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 +1 FreeBSD (ports) and $work applications.

 http://people.freebsd.org/~pgollucci/FreeBSD/diffs/p5-Apache2-Reload-0.11.r1.log

 Don't use this diff, I'll make a real update after the release:

 http://people.freebsd.org/~pgollucci/FreeBSD/diffs/www_p5-Apache-Reload-0.11.r1.diff



 On 08/02/10 18:20, Fred Moyer wrote:
 Please download this release candidate and report back on test results
 for your platform:

 http://people.apache.org/~phred/Apache2-Reload-0.11-rc1.tar.gz


 Summary of changeset for 0.11

 Ignore require-hooks which exist in %INC
 [Ryan Gies r...@livesite.net]

 Reloads by file, not module name
 [Ryan Gies r...@livesite.net]

 Add a no Apache::Reload directive which skips reloading for modules
 that have it included (useful for Moose compatibility).
 [Graham Barr, gb...@pobox.com]

 Add Empty NOTICE file
 http://rt.cpan.org/Ticket/Display.html?id=34786
 [Niko Tyni (Debian Perl Group) nt...@debian.org]

 -
 To unsubscribe, e-mail: dev-unsubscr...@perl.apache.org
 For additional commands, e-mail: dev-h...@perl.apache.org


 - --
 - 
 1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C
 Philip M. Gollucci (pgollu...@p6m7g8.com) c: 703.336.9354
 VP Apache Infrastructure; Member, Apache Software Foundation
 Committer,                        FreeBSD Foundation
 Consultant,                       P6M7G8 Inc.
 Sr. System Admin,                 Ridecharge Inc.

 Work like you don't need the money,
 love like you'll never get hurt,
 and dance like nobody's watching.
 -BEGIN PGP SIGNATURE-
 Version: GnuPG v2.0.14 (FreeBSD)

 iD8DBQFMV2ePdbiP+9ubjBwRAuxYAJ9eLcOIsmGBOwitUDXTPB0ODiKqugCeLSRf
 Z3Yiyb7g2pjTxYUx4HLXrdI=
 =f3RD
 -END PGP SIGNATURE-



[RELEASE CANDIDATE] Apache-Reload 0.11 RC1

2010-08-02 Thread Fred Moyer
Please download this release candidate and report back on test results
for your platform:

http://people.apache.org/~phred/Apache2-Reload-0.11-rc1.tar.gz


Summary of changeset for 0.11

Ignore require-hooks which exist in %INC
[Ryan Gies r...@livesite.net]

Reloads by file, not module name
[Ryan Gies r...@livesite.net]

Add a no Apache::Reload directive which skips reloading for modules
that have it included (useful for Moose compatibility).
[Graham Barr, gb...@pobox.com]

Add Empty NOTICE file
http://rt.cpan.org/Ticket/Display.html?id=34786
[Niko Tyni (Debian Perl Group) nt...@debian.org]


Re: [RELEASE CANDIDATE] Apache-Reload 0.11 RC1

2010-08-02 Thread Philip M. Gollucci
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

+1 FreeBSD (ports) and $work applications.

http://people.freebsd.org/~pgollucci/FreeBSD/diffs/p5-Apache2-Reload-0.11.r1.log

Don't use this diff, I'll make a real update after the release:

http://people.freebsd.org/~pgollucci/FreeBSD/diffs/www_p5-Apache-Reload-0.11.r1.diff



On 08/02/10 18:20, Fred Moyer wrote:
 Please download this release candidate and report back on test results
 for your platform:
 
 http://people.apache.org/~phred/Apache2-Reload-0.11-rc1.tar.gz
 
 
 Summary of changeset for 0.11
 
 Ignore require-hooks which exist in %INC
 [Ryan Gies r...@livesite.net]
 
 Reloads by file, not module name
 [Ryan Gies r...@livesite.net]
 
 Add a no Apache::Reload directive which skips reloading for modules
 that have it included (useful for Moose compatibility).
 [Graham Barr, gb...@pobox.com]
 
 Add Empty NOTICE file
 http://rt.cpan.org/Ticket/Display.html?id=34786
 [Niko Tyni (Debian Perl Group) nt...@debian.org]
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@perl.apache.org
 For additional commands, e-mail: dev-h...@perl.apache.org


- -- 
- 
1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C
Philip M. Gollucci (pgollu...@p6m7g8.com) c: 703.336.9354
VP Apache Infrastructure; Member, Apache Software Foundation
Committer,FreeBSD Foundation
Consultant,   P6M7G8 Inc.
Sr. System Admin, Ridecharge Inc.

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.
-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.14 (FreeBSD)

iD8DBQFMV2ePdbiP+9ubjBwRAuxYAJ9eLcOIsmGBOwitUDXTPB0ODiKqugCeLSRf
Z3Yiyb7g2pjTxYUx4HLXrdI=
=f3RD
-END PGP SIGNATURE-


svn commit: r980971 - in /perl/Apache-Reload/trunk: Changes lib/Apache/Reload.pm lib/Apache2/Reload.pm

2010-07-30 Thread phred
Author: phred
Date: Fri Jul 30 21:32:17 2010
New Revision: 980971

URL: http://svn.apache.org/viewvc?rev=980971view=rev
Log:
Ignore require-hooks which exist in %INC
Reloads by file, not module name

Submitted by:  Ryan Gies
Reviewed by:  Gozer
Applied by:  Phred

Modified:
perl/Apache-Reload/trunk/Changes
perl/Apache-Reload/trunk/lib/Apache/Reload.pm
perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=980971r1=980970r2=980971view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Fri Jul 30 21:32:17 2010
@@ -8,6 +8,12 @@ Changes - Apache::Reload change logfile
 
 =item 0.11-dev
 
+Ignore require-hooks which exist in %INC
+[Ryan Gies r...@livesite.net]
+
+Reloads by file, not module name
+[Ryan Gies r...@livesite.net]
+
 Add a no Apache::Reload directive which skips reloading for modules
 that have it included (useful for Moose compatibility).
 [Graham Barr, gb...@pobox.com]

Modified: perl/Apache-Reload/trunk/lib/Apache/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache/Reload.pm?rev=980971r1=980970r2=980971view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache/Reload.pm Fri Jul 30 21:32:17 2010
@@ -17,7 +17,7 @@ package Apache::Reload;
 
 use strict;
 
-$Apache::Reload::VERSION = '0.11';
+$Apache::Reload::VERSION = '0.11-dev';
 
 use vars qw(%INCS %Stat $TouchTime %UndefFields);
 

Modified: perl/Apache-Reload/trunk/lib/Apache2/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache2/Reload.pm?rev=980971r1=980970r2=980971view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache2/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache2/Reload.pm Fri Jul 30 21:32:17 2010
@@ -20,7 +20,7 @@ use warnings FATAL = 'all';
 
 use mod_perl2;
 
-our $VERSION = '0.11';
+our $VERSION = '0.12';
 
 use Apache2::Const -compile = qw(OK);
 
@@ -86,6 +86,8 @@ sub handler {
 
 my $DEBUG = ref($o)  (lc($o-dir_config(ReloadDebug) || '') eq 'on');
 
+my $ReloadByModuleName = ref($o)  
(lc($o-dir_config(ReloadByModuleName) || '') eq 'on');
+
 my $TouchFile = ref($o)  $o-dir_config(ReloadTouchFile);
 
 my $ConstantRedefineWarnings = ref($o)  
@@ -138,6 +140,7 @@ sub handler {
 my $file = $Apache2::Reload::INCS{$key};
 
 next unless defined $file;
+next if ref $file;
 next if @watch_dirs  !grep { $file =~ /^$_/ } @watch_dirs;
 warn Apache2::Reload: Checking mtime of $key\n if $DEBUG;
 
@@ -158,24 +161,29 @@ sub handler {
 }
 
 if ($mtime  $Stat{$file}) {
-push @changed, $key;
+push @changed, [$key, $file];
 }
 $Stat{$file} = $mtime;
 }
 
 #First, let's unload all changed modules
-foreach my $module (@changed) {
+foreach my $change (@changed) {
+my ($module, $file) = @$change;
 my $package = module_to_package($module);
 ModPerl::Util::unload_package($package);
 }
-
+
 #Then, let's reload them all, so that module dependencies can satisfy
 #themselves in the correct order.
-foreach my $module (@changed) {
-my $package = module_to_package($module);
-require $module;
-warn(Apache2::Reload: process $$ reloading $package from $module\n)
-if $DEBUG;
+foreach my $change (@changed) {
+my ($module, $file) = @$change;
+my $name = $ReloadByModuleName ? $module : $file;
+require $name;
+if ($DEBUG) {
+  my $package = module_to_package($module);
+  warn sprintf(Apache2::Reload: process %d reloading %s from %s\n,
+$$, $package, $name);
+}
 }
 
 return Apache2::Const::OK;
@@ -206,6 +214,7 @@ Apache2::Reload - Reload Perl Modules wh
   PerlSetVar ReloadAll Off
   PerlSetVar ReloadModules ModPerl::* Apache2::*
   #PerlSetVar ReloadDebug On
+  #PerlSetVar ReloadByModuleName On
   
   # Reload a single module from within itself:
   package My::Apache2::Module;
@@ -226,16 +235,28 @@ modules that have registered themselves 
 also do the check for modified modules, when a special touch-file has
 been modified.
 
-Note that CApache2::Reload operates on the current context of
-C@INC.  Which means, when called as a CPerl*Handler it will not
-see C@INC paths added or removed by CModPerl::Registry scripts, as
-the value of C@INC is saved on server startup and restored to that
-value after each request.  In other words, if you want
-CApache2::Reload to work with modules that live in custom C@INC
-paths, you should modify C@INC when the server is started.  Besides,
-C'use lib

svn commit: r908240 - in /perl/Apache-Reload/trunk: Changes lib/Apache/Reload.pm

2010-02-09 Thread phred
Author: phred
Date: Tue Feb  9 21:37:20 2010
New Revision: 908240

URL: http://svn.apache.org/viewvc?rev=908240view=rev
Log:
'no Apache::Reload' option to ignore reloading modules with that directive.

When Moose is being used, reloading a class will probably result in it being 
unusable.

Especially if the class uses roles or any of the method wrapping calls.

This adds no Apache::Reload to make sure that such modules are not attempted 
to be reloaded.

Submitted by:  Graham Barr gb...@pobox.com
Signed off by:  Fred Moyer ph...@apache.orgg

Modified:
perl/Apache-Reload/trunk/Changes
perl/Apache-Reload/trunk/lib/Apache/Reload.pm

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=908240r1=908239r2=908240view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Tue Feb  9 21:37:20 2010
@@ -8,6 +8,10 @@
 
 =item 0.11-dev
 
+Add a no Apache::Reload directive which skips reloading for modules
+that have it included (useful for Moose compatibility).
+[Graham Barr, gb...@pobox.com]
+
 Add Empty NOTICE file
 http://rt.cpan.org/Ticket/Display.html?id=34786
 [Niko Tyni (Debian Perl Group) nt...@debian.org]

Modified: perl/Apache-Reload/trunk/lib/Apache/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache/Reload.pm?rev=908240r1=908239r2=908240view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache/Reload.pm Tue Feb  9 21:37:20 2010
@@ -32,6 +32,13 @@
 $class-register_module($package, $file);
 }
 
+sub unimport {
+my $class = shift;
+my ($package,$file) = (caller)[0,1];
+
+$class-unregister_module($package, $file);
+}
+
 sub package_to_module {
 my $package = shift;
 $package =~ s/::/\//g;
@@ -58,6 +65,13 @@
 }
 }
 
+sub unregister_module {
+my ($class, $package, $file) = @_;
+my $module = package_to_module($package);
+
+$Ignore{$module} = 1;
+}
+
 sub handler {
 my $r = shift;
 
@@ -135,9 +149,14 @@
 }
# remove the modules
 if ($mtime  $Stat{$file}) {
-delete $INC{$key};
-push @changed, $key;
-   }
+if ($Ignore{$key}) {
+warn Apache::Reload: Not reloading $key\n;
+}
+else {
+delete $INC{$key};
+push @changed, $key;
+}
+}
 $Stat{$file} = $mtime;
 }
 
@@ -230,6 +249,15 @@
 Note that these are split on whitespace, but the module list Bmust
 be in quotes, otherwise Apache tries to parse the parameter list.
 
+=head2 Un-Register Modules Explicitly
+
+If ReloadAll is set to On, then you can explicity force a module not to be 
reloaded with
+
+  no Apache::Reload;
+
+A warning will appear in the error log that the file has changed, but will
+not be reloaded
+
 =head2 Special Touch File
 
 You can also set a file that you can touch() that causes the reloads to be




make fails at Apache-Reload

2009-07-31 Thread George Karabotsos
Hi guys,

I got the trunk version from SVN:

svn checkout https://svn.apache.org/repos/asf/perl/modperl/trunk/ mod_perl-trunk

I am using Apache 2.2.12.

To build mod_perl I did:
% perl Makefile.PL MP_APXS=/usr/local/httpd/bin/apxs  # Completed successfuly.
% make
which failed at:
...
make[1]: Entering directory `/usr/local/src/mod_perl-trunk/Apache-Reload'
Makefile:14: *** empty variable name.  Stop.
make[1]: Leaving directory `/usr/local/src/mod_perl-trunk/Apache-Reload'
make: *** [subdirs] Error 2

Here's my system info:
# uname -a
Linux athina 2.6.30.3 #3 SMP Tue Jul 28 11:56:46 PDT 2009 i686
Intel(R) Core(TM)2 Duo CPU T7250  @ 2.00GHz GenuineIntel GNU/Linux

Any ideas?
TIA,
George


Re: Apache::Reload/ModPerl::Util/base.pm incompatibility prospective patch

2009-01-07 Thread Philippe M. Chiasson

Have you tried the alternate unload_package implementation, the one in C/XS?

You can try it out by doing

BEGIN {
  $ModPerl::Util::DEFAULT_UNLOAD_METHOD = 'unload_package_xs';
}
use ModPerl::Util;

Somewhere early in your server startup scripts.

On 29/12/08 15:08, David Ihnen wrote:

Philip M. Gollucci wrote:

David Ihnen wrote:

1. Problem Description:

While developing with CGI::Application and utilizing Apache::Reload,
we encountered an issue where our modules were not being succesfully
reinitialized on reload. It was traced down to @ISA not containing
the proper values after a 'use base' directive, but only on automatic
reload, and freshly on perl 5.10, not our previous version of perl
5.8.8!

Are you able to try 5.8.9, its at least a smaller change set to look
at if 5.8.9 breaks too.


No, not easily when I considered the mod_perl ramifications
particularly. I did find a way around this particular problem on the web
server though.

I noticed line 79. of base.pm

79 next if grep $_-isa($base), ($inheritor, @bases);

Experimentally, if I commented it out, the web server could reload
properly! Score!

Hm. I know -isa is a UNIVERSAL function. UNIVERSAL.pm is... not
implimented in perl. Must be in the C code.

So I found UNIVERSAL.c

whose isa function implimentation said after some error checks essentially

ST(0) = boolSV(sv_derived_from(sv, name));


which function had the documentation

=head1 SV Manipulation Functions

=for apidoc sv_derived_from

Returns a boolean indicating whether the SV is derived from the specified class
Iat the C level.  To check derivation at the Perl level, call Cisa()  as a
normal Perl method.

=cut


Ooh. at the **C** level. I bet the unload utility doesn't even *affect*
the C level!

Those who understand perl C code might be better able to tell if
unloading in the C levels is possible, a good idea, or just bad mojo.
Having taken some medicine to deal with the C-inspired headache that
inspection brought on, I returned to base.pm.

ISA is a package local variable list that lists the parents. In order to
see all-the-parents, or replicate -isa, I have to get the list of all
the packages in ISA, all THEIR ISAs, and so on, as long as there are
contents therein. And my scan will pay attention only to the interpreter
state, not the C state...

I should be able to do that in perl easily enough. PATCH

--- 510base.pm 2008-12-29 12:48:27.0 -0700
+++ /usr/share/perl/5.10.0/base.pm 2008-12-29 12:48:48.0 -0700
@@ -76,7 +76,20 @@
warn Class '$inheritor' tried to inherit from itself\n;
}

- next if grep $_-isa($base), ($inheritor, @bases);
+ my @classlist = ($inheritor, @bases);
+ foreach ($inheritor, @bases) {
+ my @parents = @$_::ISA;
+ do {
+ my $class = shift @parents;
+ foreach my $parent (@$class::ISA) {
+ unless (grep { $_ eq $parent } @classlist) {
+ push @classlist, $parent;
+ push @parents, @$parent::ISA;
+ }
+ }
+ } while (scalar @parents);
+ }
+ next if grep {$_ eq $base} @classlist;

if (has_version($base)) {
${$base.'::VERSION'} = '-1, set by base.pm'

I know thats kind of ugly, and verbose, and maybe not very performant.
But it works for the web server. Its not in any of the ISAs at
re-require time so it does not skip loading the module even if the C HAS
seen it before, and the application continues happily.

So at any rate, its a patch that works for my case (much as I hate
patching base.pm) - and to my somewhat weak understanding of the C code
implimentation, does the same thing in perl that the isa-iteration did
in c. What is the proper path here?

David Ihnen
Perl Programmer
Norchem Laboratories, Inc



--
Philippe M. Chiasson GPG: F9BFE0C2480E7680 1AE53631CB32A107 88C3A5A5
http://gozer.ectoplasm.org/   m/gozer\@(apache|cpan|ectoplasm)\.org/


Re: Apache::Reload - ModPerl::Util::unload_package under perl 5.10 use base directive malfunction

2009-01-07 Thread Philippe M. Chiasson



On 26/12/08 20:39, David Ihnen wrote:

1. Problem Description:

While developing with CGI::Application and utilizing Apache::Reload, we
encountered an issue where our modules were not being succesfully
reinitialized on reload.  It was traced down to @ISA not containing the
proper values after a 'use base' directive, but only on automatic
reload, and freshly on perl 5.10, not our previous version of perl 5.8.8!

I determined that when ModPerl::Util::unload_package is used to unload a
package, when it is then re-required in perl 5.10, 'use base' directives
don't function as expected.

I recreated the problem with this simple use case.  It happens when a
sub-module (required by something else) is unloaded then re-required.  I
included the workaround using the push @ISA method to contrast working
with not working.

This is the output when the program below is run.

$ perl t.pl
X
X
V
Not a CODE reference at t.pl line 14.

Where did the inheritance go after the require of v?  Is this a bug in
the do-file functionality utilized by require?  Did
ModPerl::Util::unload_package not do something it was supposed to?  Is
there a subtle interaction between 5.10 and ModPerl::Util?

I was initially going to submit this to the perl bug database, but
realized that the unload_package function was a ModPerl functionality,
so this is my first place to go.   Five files to test with itemized
below.  As you can see, I can recreate it without utilizing the mod_perl
environment specifically.

--- begin t.pl ---
#!/usr/bin/perl
use ModPerl::Util;
# Using push @ISA
require w;
w-x();
ModPerl::Util::unload_package('w');
require w;
w-x();
# Using use base
require u;
u-v();
ModPerl::Util::unload_package('v');
require u;


This is strange, as you are unloading 'v' and reloading 'u', probably not
what was intended.

--
Philippe M. Chiasson GPG: F9BFE0C2480E7680 1AE53631CB32A107 88C3A5A5
http://gozer.ectoplasm.org/   m/gozer\@(apache|cpan|ectoplasm)\.org/


Apache::Reload/ModPerl::Util/base.pm incompatibility prospective patch

2008-12-29 Thread David Ihnen

Philip M. Gollucci wrote:

David Ihnen wrote:

1. Problem Description:

While developing with CGI::Application and utilizing Apache::Reload, 
we encountered an issue where our modules were not being succesfully 
reinitialized on reload.  It was traced down to @ISA not containing 
the proper values after a 'use base' directive, but only on automatic 
reload, and freshly on perl 5.10, not our previous version of perl 
5.8.8!
Are you able to try 5.8.9, its at least a smaller change set to look 
at if 5.8.9 breaks too.


No, not easily when I considered the mod_perl ramifications 
particularly.  I did find a way around this particular problem on the 
web server though.


I noticed line 79. of base.pm

79 next if grep $_-isa($base), ($inheritor, @bases);

Experimentally, if I commented it out, the web server could reload 
properly!  Score!


Hm.   I know -isa is a UNIVERSAL function.  UNIVERSAL.pm is... not 
implimented in perl.  Must be in the C code.


So I found UNIVERSAL.c

whose isa function implimentation said after some error checks essentially

ST(0) = boolSV(sv_derived_from(sv, name));


which function had the documentation

=head1 SV Manipulation Functions

=for apidoc sv_derived_from

Returns a boolean indicating whether the SV is derived from the specified class
Iat the C level.  To check derivation at the Perl level, call Cisa() as a
normal Perl method.

=cut


Ooh. at the **C** level.  I bet the unload utility doesn't even *affect* 
the C level!


Those who understand perl C code might be better able to tell if 
unloading in the C levels is possible, a good idea, or just bad mojo.  
Having taken some medicine to deal with the C-inspired headache that 
inspection brought on, I returned to base.pm.


ISA is a package local variable list that lists the parents.  In order 
to see all-the-parents, or replicate -isa, I have to get the list of 
all the packages in ISA, all THEIR ISAs, and so on, as long as there are 
contents therein.  And my scan will pay attention only to the 
interpreter state, not the C state...


I should be able to do that in perl easily enough.  PATCH

--- 510base.pm2008-12-29 12:48:27.0 -0700
+++ /usr/share/perl/5.10.0/base.pm2008-12-29 12:48:48.0 -0700
@@ -76,7 +76,20 @@
warn Class '$inheritor' tried to inherit from itself\n;
}

-next if grep $_-isa($base), ($inheritor, @bases);
+my @classlist = ($inheritor, @bases);
+foreach ($inheritor, @bases) {
+my @parents = @$_::ISA;
+do {
+my $class = shift @parents;
+foreach my $parent (@$class::ISA) {
+unless (grep { $_ eq $parent } @classlist) {
+push @classlist, $parent;
+push @parents, @$parent::ISA;
+}
+}
+} while (scalar @parents);
+}
+next if grep {$_ eq $base} @classlist;

if (has_version($base)) {
${$base.'::VERSION'} = '-1, set by base.pm'

I know thats kind of ugly, and verbose, and maybe not very performant.  
But it works for the web server.  Its not in any of the ISAs at 
re-require time so it does not skip loading the module even if the C HAS 
seen it before, and the application continues happily.


So at any rate, its a patch that works for my case (much as I hate 
patching base.pm) - and to my somewhat weak understanding of the C code 
implimentation, does the same thing in perl that the isa-iteration did 
in c.  What is the proper path here?


David Ihnen
Perl Programmer
Norchem Laboratories, Inc



Re: Apache::Reload - ModPerl::Util::unload_package under perl 5.10 use base directive malfunction

2008-12-27 Thread Philip M. Gollucci

David Ihnen wrote:

1. Problem Description:

While developing with CGI::Application and utilizing Apache::Reload, we 
encountered an issue where our modules were not being succesfully 
reinitialized on reload.  It was traced down to @ISA not containing the 
proper values after a 'use base' directive, but only on automatic 
reload, and freshly on perl 5.10, not our previous version of perl 5.8.8!
Are you able to try 5.8.9, its at least a smaller change set to look at if 
5.8.9 breaks too.





--

1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C
Philip M. Gollucci (pgollu...@p6m7g8.com) c: 703.336.9354
Consultant  - P6M7G8 Inc.http://p6m7g8.net
Director IT - RideCharge, Inc.   http://ridecharge.com
Contractor  - PositiveEnergyUSA  http://positiveenergyusa.com
ASF Member  - Apache Software Foundation http://apache.org
FreeBSD Committer   - FreeBSD Foundation http://freebsd.org

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.


Apache::Reload - ModPerl::Util::unload_package under perl 5.10 use base directive malfunction

2008-12-26 Thread David Ihnen

1. Problem Description:

While developing with CGI::Application and utilizing Apache::Reload, we 
encountered an issue where our modules were not being succesfully 
reinitialized on reload.  It was traced down to @ISA not containing the 
proper values after a 'use base' directive, but only on automatic 
reload, and freshly on perl 5.10, not our previous version of perl 5.8.8!


I determined that when ModPerl::Util::unload_package is used to unload a 
package, when it is then re-required in perl 5.10, 'use base' directives 
don't function as expected.


I recreated the problem with this simple use case.  It happens when a 
sub-module (required by something else) is unloaded then re-required.  I 
included the workaround using the push @ISA method to contrast working 
with not working.


This is the output when the program below is run.

$ perl t.pl
X
X
V
Not a CODE reference at t.pl line 14.

Where did the inheritance go after the require of v?  Is this a bug in 
the do-file functionality utilized by require?  Did 
ModPerl::Util::unload_package not do something it was supposed to?  Is 
there a subtle interaction between 5.10 and ModPerl::Util?


I was initially going to submit this to the perl bug database, but 
realized that the unload_package function was a ModPerl functionality, 
so this is my first place to go.   Five files to test with itemized 
below.  As you can see, I can recreate it without utilizing the mod_perl 
environment specifically.


--- begin t.pl ---
#!/usr/bin/perl
use ModPerl::Util;
# Using push @ISA
require w;
w-x();
ModPerl::Util::unload_package('w');
require w;
w-x();
# Using use base
require u;
u-v();
ModPerl::Util::unload_package('v');
require u;
u-v();
-- end t.pl --
--- begin u.pm ---
package u;
use v;
use base 'v';
1;
--- end u.pm
--- begin v.pm ---
package v;
sub v { print V\n;}
1;
--- end v.pm
--- begin w.pm ---
package w;
use x;
BEGIN { push @ISA, 'x'; }
1;
--- end w.pm
--- begin x.pm ---
package x;
sub x {print X\n;}
1;
--- end x.pm


2. Used Components and their Configuration:

*** mod_perl version 2.04

*** using /usr/lib/perl5/Apache2/BuildConfig.pm

*** Makefile.PL options:
 MP_APR_LIB = aprext
 MP_APXS= /usr/bin/apxs2
 MP_CCOPTS  = -g -Wall
 MP_COMPAT_1X   = 1
 MP_GENERATE_XS = 1
 MP_INCLUDE_DIR = /usr/include/apache2 /usr/include/apr-1.0
 MP_LIBNAME = mod_perl
 MP_TRACE   = 0
 MP_USE_DSO = 1
 MP_USE_GTOP= 1
 MP_USE_STATIC  = 0


*** The httpd binary was not found


*** (apr|apu)-config linking info

-L/usr/lib -laprutil-1  
-L/usr/lib -lapr-1 -luuid -lrt -lcrypt  -lpthread -ldl




*** /usr/bin/perl -V
Summary of my perl5 (revision 5 version 10 subversion 0) configuration:
 Platform:
   osname=linux, osvers=2.6.24-16-server, 
archname=x86_64-linux-gnu-thread-multi
   uname='linux yellow 2.6.24-16-server #1 smp thu apr 10 13:15:38 utc 
2008 x86_64 gnulinux '
   config_args='-Dusethreads -Duselargefiles -Dccflags=-DDEBIAN 
-Dcccdlflags=-fPIC -Darchname=x86_64-linux-gnu -Dprefix=/usr 
-Dprivlib=/usr/share/perl/5.10 -Darchlib=/usr/lib/perl/5.10 
-Dvendorprefix=/usr -Dvendorlib=/usr/share/perl5 
-Dvendorarch=/usr/lib/perl5 -Dsiteprefix=/usr/local 
-Dsitelib=/usr/local/share/perl/5.10.0 
-Dsitearch=/usr/local/lib/perl/5.10.0 -Dman1dir=/usr/share/man/man1 
-Dman3dir=/usr/share/man/man3 -Dsiteman1dir=/usr/local/man/man1 
-Dsiteman3dir=/usr/local/man/man3 -Dman1ext=1 -Dman3ext=3perl 
-Dpager=/usr/bin/sensible-pager -Uafs -Ud_csh -Ud_ualarm -Uusesfio 
-Uusenm -DDEBUGGING=-g -Doptimize=-O2 -Duseshrplib 
-Dlibperl=libperl.so.5.10.0 -Dd_dosuid -des'

   hint=recommended, useposix=true, d_sigaction=define
   useithreads=define, usemultiplicity=define
   useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef
   use64bitint=define, use64bitall=define, uselongdouble=undef
   usemymalloc=n, bincompat5005=undef
 Compiler:
   cc='cc', ccflags ='-D_REENTRANT -D_GNU_SOURCE -DDEBIAN 
-fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE 
-D_FILE_OFFSET_BITS=64',

   optimize='-O2 -g',
   cppflags='-D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing 
-pipe -I/usr/local/include'

   ccversion='', gccversion='4.3.2', gccosandvers=''
   intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678
   d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
   ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', 
lseeksize=8

   alignbytes=8, prototype=define
 Linker and Libraries:
   ld='cc', ldflags =' -L/usr/local/lib'
   libpth=/usr/local/lib /lib /usr/lib /lib64 /usr/lib64
   libs=-lgdbm -lgdbm_compat -ldb -ldl -lm -lpthread -lc -lcrypt
   perllibs=-ldl -lm -lpthread -lc -lcrypt
   libc=/lib/libc-2.8.90.so, so=so, useshrplib=true, 
libperl=libperl.so.5.10.0

   gnulibc_version='2.8.90'
 Dynamic Linking:
   dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'
   cccdlflags='-fPIC', lddlflags='-shared -O2 -g -L/usr/local/lib'


Characteristics of this binary (from libperl

[FreeBSD]: port - www/p5-Apache-Reload updated to 0.10

2008-05-08 Thread Philip M. Gollucci

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/123536

Not yet committed...

- --
- 
Philip M. Gollucci ([EMAIL PROTECTED])
o:703.549.2050x206
Senior System Admin - Riderway, Inc.
http://riderway.com / http://ridecharge.com
1024D/DB9B8C1C B90B FBC3 A3A1 C71A 8E70  3F8C 75B8 8FFB DB9B 8C1C

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.

-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.8 (FreeBSD)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFII6TpdbiP+9ubjBwRAvnfAJ9l5nFxfgpzRB6FWoLr08/h5ihTzwCeP3Sa
qQjC+WPbTWdyHodENZolkfE=
=/xBr
-END PGP SIGNATURE-


svn commit: r631338 - in /perl/Apache-Reload/trunk: Changes RELEASE lib/Apache/Reload.pm lib/Apache2/Reload.pm

2008-02-26 Thread phred
Author: phred
Date: Tue Feb 26 11:06:00 2008
New Revision: 631338

URL: http://svn.apache.org/viewvc?rev=631338view=rev
Log:
start 0.11-dev cycle

Modified:
perl/Apache-Reload/trunk/Changes
perl/Apache-Reload/trunk/RELEASE
perl/Apache-Reload/trunk/lib/Apache/Reload.pm
perl/Apache-Reload/trunk/lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=631338r1=631337r2=631338view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Tue Feb 26 11:06:00 2008
@@ -6,6 +6,9 @@
 
 =over 1
 
+=item 0.11-dev
+
+
 =item 0.10 February 25, 2008
 
 Add make disttest procedure to RELEASE document - fred

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=631338r1=631337r2=631338view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Tue Feb 26 11:06:00 2008
@@ -26,7 +26,7 @@
 a. login into https://pause.perl.org
 b. menu click: Select Mailinglist/Action
 c. choose APML and share_perms and click go
-d. click 3.1 Make somebody else co-maintainer
+d. click 3.2 Make somebody else co-maintainer
 e. choose the modules to give the perms to
type the username of the new co-maintainer
 f. if you happen to know that packages were added this release,
@@ -41,8 +41,8 @@
 
   a. edit ./Changes:
  - find lib -type f -name *.pm | \
- xargs perl -pi -e 's,0.10-dev,0.10-rc1,g'
- - perl -pi -e 's,0.10-dev,0.10-rc1,g' Changes
+ xargs perl -pi -e 's,0.11-dev,0.11-rc1,g'
+ - perl -pi -e 's,0.11-dev,0.11-rc1,g' Changes
 
  - don't commit these (see dev@ archives)
 
@@ -61,7 +61,7 @@
  o dev/perl.apache.org
  o modperl/perl.apache.org
 
-  Subject: [RELEASE CANDIDATE] Apache-Reload 0.10 RC\d+
+  Subject: [RELEASE CANDIDATE] Apache-Reload 0.11 RC\d+
 
(or maybe longer to give most people a chance to catch up). no need
to tag this package
@@ -96,7 +96,7 @@
 5. Announce the package
 
   a. post ... to the modperl, announce lists
-  Subject: [ANNOUNCE] Apache-Reload 0.10
+  Subject: [ANNOUNCE] Apache-Reload 0.11
  include 
   - MD5 sig (as it comes from CPAN upload announce).
   - the latest Changes
@@ -108,7 +108,7 @@
   b. edit ./Changes:
  - start a new item with incremented version + '-dev'
 
-  =item 0.11-dev
+  =item 0.12-dev
 
   c. bump up version numbers in this file to make it easier to do the
  next release.
@@ -116,4 +116,5 @@
  $ perl -pi -e 's/(\d+)\.(\d+)/join(., $1, $2+1)/eg' RELEASE
 
   d. commit Changes
- % svn ci -m start 0.11-dev cycle Changes RELEASE lib/Apache/Reload.pm
+ % svn ci -m start 0.11-dev cycle Changes RELEASE \
+   lib/Apache/Reload.pm lib/Apache2/Reload.pm

Modified: perl/Apache-Reload/trunk/lib/Apache/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache/Reload.pm?rev=631338r1=631337r2=631338view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache/Reload.pm Tue Feb 26 11:06:00 2008
@@ -17,7 +17,7 @@
 
 use strict;
 
-$Apache::Reload::VERSION = '0.10';
+$Apache::Reload::VERSION = '0.11';
 
 use vars qw(%INCS %Stat $TouchTime %UndefFields);
 

Modified: perl/Apache-Reload/trunk/lib/Apache2/Reload.pm
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/lib/Apache2/Reload.pm?rev=631338r1=631337r2=631338view=diff
==
--- perl/Apache-Reload/trunk/lib/Apache2/Reload.pm (original)
+++ perl/Apache-Reload/trunk/lib/Apache2/Reload.pm Tue Feb 26 11:06:00 2008
@@ -20,7 +20,7 @@
 
 use mod_perl2;
 
-our $VERSION = '0.10';
+our $VERSION = '0.11';
 
 use Apache2::Const -compile = qw(OK);
 




svn commit: r631082 - /perl/Apache-Reload/trunk/Changes

2008-02-25 Thread phred
Author: phred
Date: Mon Feb 25 20:51:04 2008
New Revision: 631082

URL: http://svn.apache.org/viewvc?rev=631082view=rev
Log:
0.10 release

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=631082r1=631081r2=631082view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Mon Feb 25 20:51:04 2008
@@ -6,7 +6,7 @@
 
 =over 1
 
-=item 0.10-RC5
+=item 0.10 February 25, 2008
 
 Add make disttest procedure to RELEASE document - fred
 




svn commit: r631084 - /perl/Apache-Reload/tags/0_10/

2008-02-25 Thread phred
Author: phred
Date: Mon Feb 25 20:52:18 2008
New Revision: 631084

URL: http://svn.apache.org/viewvc?rev=631084view=rev
Log:
Tag 0_10

Added:
perl/Apache-Reload/tags/0_10/
  - copied from r631083, perl/Apache-Reload/trunk/



[Fwd: [RELEASE CANDIDATE] Apache-Reload-0.10-RC5]

2008-02-20 Thread Fred Moyer
FYI - RC5 has gone through some vetting on the dev list and no test
failures have been found so far.  Please take if for a spin if you have a
chance and report back success or failure.

http://people.apache.org/~phred/Apache-Reload-0.10-RC5.tar.gz

 Original Message 
Subject: [RELEASE CANDIDATE] Apache-Reload-0.10-RC5
From:Fred Moyer [EMAIL PROTECTED]
Date:Thu, February 14, 2008 7:16 am
To:  [EMAIL PROTECTED]
--

Greetings,

RC5 for Apache::Reload is now available.  RC4 was a bust since I didn't
follow my own additions to the RELEASE document :)  Note to self -
caffeinate before releasing.

Thanks to Steve Hay for working through some win32 related issues with me.
 I'd like to get that resolved at some point but it appears to be
non-trivial.

There are a few other nits I would like to get taken care of but if this
candidate passes tests I'd like to let it into the main list, then into
the wild if passing reports come back.  One nit is that 'perl Makefile.PL'
will die on platforms that don't have mod_perl installed, causing a test
failure in CPAN testers.  I ran into this issue with Apache::Dispatch - no
solution yet.

http://people.apache.org/~phred/Apache-Reload-0.10-RC5.tar.gz

- all tests skipped successfully in environment without mod_perl.c on
Linux 2.6, perl 5.8.8
- all tests pass on mp1, perl 5.8.8, darwin 10.5.2
- all tests pass on mp2, perl 5.8.8, darwin 10.5.2
- all tests pass on mp2, perl 5.8.8, darwin 10.5.2,
APACHE_TEST_PRETEND_NO_LWP=1


- To
unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






svn commit: r628250 - /perl/Apache-Reload/trunk/Makefile.PL

2008-02-16 Thread phred
Author: phred
Date: Sat Feb 16 00:03:37 2008
New Revision: 628250

URL: http://svn.apache.org/viewvc?rev=628250view=rev
Log:
Fix a small spelling error found while testing.

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=628250r1=628249r2=628250view=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Sat Feb 16 00:03:37 2008
@@ -224,7 +224,7 @@
 [EMAIL PROTECTED]
 [EMAIL PROTECTED] sorry, cannot run tests without a properly
 [EMAIL PROTECTED] configured Apache-Test environment, mininum
[EMAIL PROTECTED] Apache::Test version needes is $at_min_ver
[EMAIL PROTECTED] Apache::Test version needed is $at_min_ver
 [EMAIL PROTECTED]
 EOF
 }




svn commit: r627753 - /perl/Apache-Reload/trunk/MANIFEST

2008-02-14 Thread phred
Author: phred
Date: Thu Feb 14 06:13:58 2008
New Revision: 627753

URL: http://svn.apache.org/viewvc?rev=627753view=rev
Log:
Forgot to include all.t in the MANIFEST - perhaps I should follow my
own additions to RELEASE :) Thanks to Steve Hay for the spot.


Modified:
perl/Apache-Reload/trunk/MANIFEST

Modified: perl/Apache-Reload/trunk/MANIFEST
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/MANIFEST?rev=627753r1=627752r2=627753view=diff
==
--- perl/Apache-Reload/trunk/MANIFEST (original)
+++ perl/Apache-Reload/trunk/MANIFEST Thu Feb 14 06:13:58 2008
@@ -5,6 +5,7 @@
 lib/Apache/Reload.pm
 lib/Apache2/Reload.pm
 t/conf/extra.last.conf.in
+t/all.t
 t/reload.t
 t/lib/Apache/TestReload.pm
 t/lib/Apache2/TestReload.pm




svn commit: r627550 - in /perl/Apache-Reload/trunk: Changes t/conf/extra.last.conf.in

2008-02-13 Thread phred
Author: phred
Date: Wed Feb 13 10:10:02 2008
New Revision: 627550

URL: http://svn.apache.org/viewvc?rev=627550view=rev
Log:
If PERL is defined, load mod_perl manually, thanks to Steve Hay for the spot.

Modified:
perl/Apache-Reload/trunk/Changes
perl/Apache-Reload/trunk/t/conf/extra.last.conf.in

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=627550r1=627549r2=627550view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Wed Feb 13 10:10:02 2008
@@ -8,6 +8,9 @@
 
 =item 0.10-RC3
 
+Load mod_perl manually if PERL is defined, thanks to Steve Hay for the
+spot - fred
+
 Add make disttest procedure to RELEASE document - fred
 
 Check for Apache::Test version 1.30, needed to run tests - fred

Modified: perl/Apache-Reload/trunk/t/conf/extra.last.conf.in
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/t/conf/extra.last.conf.in?rev=627550r1=627549r2=627550view=diff
==
--- perl/Apache-Reload/trunk/t/conf/extra.last.conf.in (original)
+++ perl/Apache-Reload/trunk/t/conf/extra.last.conf.in Wed Feb 13 10:10:02 2008
@@ -1,3 +1,9 @@
+IfDefine PERL
+ LoadModule perl_module modules/mod_perl.so
+/IfDefine
+IfDefine PERL
+ AddModule mod_perl.c
+/IfDefine
 IfModule mod_perl.c
 IfDefine APACHE2
 PerlModule Apache2::Reload




svn commit: r620695 - /perl/Apache-Reload/trunk/t/all.t

2008-02-11 Thread phred
Author: phred
Date: Mon Feb 11 19:35:02 2008
New Revision: 620695

URL: http://svn.apache.org/viewvc?rev=620695view=rev
Log:
Skip all tests if mod_perl.c is not present, irregardless of the operating
system.  Win32 test compatibility will be handled (hopefully) via IfDefine
PERL pragma.

Added:
perl/Apache-Reload/trunk/t/all.t

Added: perl/Apache-Reload/trunk/t/all.t
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/t/all.t?rev=620695view=auto
==
--- perl/Apache-Reload/trunk/t/all.t (added)
+++ perl/Apache-Reload/trunk/t/all.t Mon Feb 11 19:35:02 2008
@@ -0,0 +1,7 @@
+use strict;
+use warnings FATAL = 'all';
+
+use Apache::Test;
+plan tests = 1, need_module('mod_perl.c');
+
+ok(1);
\ No newline at end of file




Re: [RELEASE CANDIDATE] Apache-Reload 0.10 RC3

2008-01-16 Thread Philippe M. Chiasson

Fred Moyer wrote:

Greetings,

Third time is the charm :)  RC1 and RC2 were missing 
t/conf/extra.conf.in from the MANIFEST.


I've updated the release procedure to run make disttest to identify 
these errors, and fixed the problem.


All tests pass for me on:

1) Leopard mp2, 5.8.8


Same here on Leopard.

All tests successful.
Files=1, Tests=3,  1 wallclock secs ( 0.01 usr  0.00 sys +  0.36 cusr  0.07 
csys =  0.44 CPU)
Result: PASS

--
Philippe M. Chiasson GPG: F9BFE0C2480E7680 1AE53631CB32A107 88C3A5A5
http://gozer.ectoplasm.org/   m/gozer\@(apache|cpan|ectoplasm)\.org/



signature.asc
Description: OpenPGP digital signature


[RELEASE CANDIDATE] Apache-Reload 0.10 RC3

2008-01-12 Thread Fred Moyer

Greetings,

Third time is the charm :)  RC1 and RC2 were missing 
t/conf/extra.conf.in from the MANIFEST.


I've updated the release procedure to run make disttest to identify 
these errors, and fixed the problem.


All tests pass for me on:

1) Leopard mp2, 5.8.8
2) Linux 2.6.22, mp1, mp2, 5.8.8

http://people.apache.org/~phred/Apache-Reload-0.10-RC3.tar.gz


svn commit: r611479 - /perl/Apache-Reload/trunk/Changes

2008-01-12 Thread phred
Author: phred
Date: Sat Jan 12 13:00:32 2008
New Revision: 611479

URL: http://svn.apache.org/viewvc?rev=611479view=rev
Log:
note change to release procedure, check for a:t 1.3

Modified:
perl/Apache-Reload/trunk/Changes

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=611479r1=611478r2=611479view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Sat Jan 12 13:00:32 2008
@@ -6,7 +6,11 @@
 
 =over 1
 
-=item 0.10-dev
+=item 0.10-RC3
+
+Add make disttest procedure to RELEASE document - fred
+
+Check for Apache::Test version 1.30, needed to run tests - fred
 
 Apache::Reload and Apache2::Reload bundled for CPAN release
 This release incorporates unreleased changes in 0.08 and 0.09




svn commit: r611104 - /perl/Apache-Reload/trunk/MANIFEST

2008-01-11 Thread phred
Author: phred
Date: Fri Jan 11 00:35:13 2008
New Revision: 611104

URL: http://svn.apache.org/viewvc?rev=611104view=rev
Log:
Add extra.last.conf.in to the MANIFEST.  I managed to get through two
release candidates before being informed it was broken ;)

Modified:
perl/Apache-Reload/trunk/MANIFEST

Modified: perl/Apache-Reload/trunk/MANIFEST
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/MANIFEST?rev=611104r1=611103r2=611104view=diff
==
--- perl/Apache-Reload/trunk/MANIFEST (original)
+++ perl/Apache-Reload/trunk/MANIFEST Fri Jan 11 00:35:13 2008
@@ -4,6 +4,7 @@
 LICENSE
 lib/Apache/Reload.pm
 lib/Apache2/Reload.pm
+t/conf/extra.last.conf.in
 t/reload.t
 t/lib/Apache/TestReload.pm
 t/lib/Apache2/TestReload.pm




svn commit: r611105 - /perl/Apache-Reload/trunk/RELEASE

2008-01-11 Thread phred
Author: phred
Date: Fri Jan 11 00:42:28 2008
New Revision: 611105

URL: http://svn.apache.org/viewvc?rev=611105view=rev
Log:
add make disttest to identify any files missing from the manifest

Modified:
perl/Apache-Reload/trunk/RELEASE

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=611105r1=611104r2=611105view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Fri Jan 11 00:42:28 2008
@@ -34,9 +34,10 @@
 
  MAINTAINER_BUILDING_RELEASE=1 perl Makefile.PL
 
-1. 'make dist' - to make sure nothing is missing from the manifest,
-   etc. Now test this generated package (not svn) with as many
-   configurations as possible on as many platforms as possible.
+1. 'make disttest' - to make sure nothing is missing from the manifest.
+   Now 'make dist', and test this generated package (not svn)
+   with as many configurations as possible on as many platforms
+   as possible.
 
   a. edit ./Changes:
  - find lib -type f -name *.pm | \




svn commit: r608149 - /perl/Apache-Reload/trunk/Makefile.PL

2008-01-02 Thread phred
Author: phred
Date: Wed Jan  2 09:14:25 2008
New Revision: 608149

URL: http://svn.apache.org/viewvc?rev=608149view=rev
Log:
Check for Apache::Test v1.30, needed to run the tests (t_write_test_lib).
Don't run any tests if Apache::Test isn't installed.

Modified:
perl/Apache-Reload/trunk/Makefile.PL

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=608149r1=608148r2=608149view=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Wed Jan  2 09:14:25 2008
@@ -5,6 +5,7 @@
 my %prereqs = ();
 my %mp2 = ( mod_perl2 = 1.99022 );
 my %mp1 = ( mod_perl  = 0 );
+my $at_min_ver = 1.30;
 
 my $mp_gen;
 if ($ENV{MOD_PERL_2_BUILD}) {
@@ -51,6 +52,12 @@
 sub check_for_apache_test {
 return unless eval {
 require Apache::Test;
+if ($Apache::Test::VERSION  $at_min_ver) {
+warn Apache::Test version is  . $Apache::Test::VERSION . 
+, minimum version required is $at_min_ver . 
+, tests will be skipped\n;
+die;
+}
 require Apache::TestMM;
 require Apache::TestRunPerl;
 1;
@@ -212,7 +219,14 @@
 
 return $self-Apache::TestMM::test(@_) if $HAS_APACHE_TEST;
 
-return $self-SUPER::test(@_);
+return EOF
+test::
[EMAIL PROTECTED]
[EMAIL PROTECTED] sorry, cannot run tests without a properly
[EMAIL PROTECTED] configured Apache-Test environment, mininum
[EMAIL PROTECTED] Apache::Test version needes is $at_min_ver
[EMAIL PROTECTED]
+EOF
 }
 
 sub clean {




svn commit: r606234 - in /perl/Apache-Reload/trunk: ./ lib/Apache/ lib/Apache2/ t/ t/conf/ t/lib/ t/lib/Apache/ t/lib/Apache2/

2007-12-21 Thread phred
Author: phred
Date: Fri Dec 21 08:22:23 2007
New Revision: 606234

URL: http://svn.apache.org/viewvc?rev=606234view=rev
Log:
Matt Sergeant has graciously donated Apache::Reload to the ASF.  This commit
moves Apache2::Reload from the mod_perl core to the Apache::Reload distribution,
including svn mv's of a few files in changeset 606232 from the mod_perl core
to this distro.

Reviewed in part by Gozer, Phillip, and Geoff.

Added:
perl/Apache-Reload/trunk/lib/Apache2/
perl/Apache-Reload/trunk/lib/Apache2/Reload.pm
  - copied, changed from r594783, perl/modperl/trunk/lib/Apache2/Reload.pm
perl/Apache-Reload/trunk/t/conf/
perl/Apache-Reload/trunk/t/conf/extra.last.conf.in
perl/Apache-Reload/trunk/t/lib/
perl/Apache-Reload/trunk/t/lib/Apache/
perl/Apache-Reload/trunk/t/lib/Apache/TestReload.pm
perl/Apache-Reload/trunk/t/lib/Apache2/
perl/Apache-Reload/trunk/t/lib/Apache2/TestReload.pm
  - copied, changed from r594783, 
perl/modperl/trunk/t/response/TestModules/reload.pm
perl/Apache-Reload/trunk/t/reload.t
  - copied, changed from r594783, perl/modperl/trunk/t/modules/reload.t
Modified:
perl/Apache-Reload/trunk/Changes
perl/Apache-Reload/trunk/MANIFEST
perl/Apache-Reload/trunk/Makefile.PL
perl/Apache-Reload/trunk/README
perl/Apache-Reload/trunk/RELEASE
perl/Apache-Reload/trunk/lib/Apache/Reload.pm

Modified: perl/Apache-Reload/trunk/Changes
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Changes?rev=606234r1=606233r2=606234view=diff
==
--- perl/Apache-Reload/trunk/Changes (original)
+++ perl/Apache-Reload/trunk/Changes Fri Dec 21 08:22:23 2007
@@ -6,7 +6,17 @@
 
 =over 1
 
-=item 0.08-dev
+=item 0.10-dev
+
+Apache::Reload and Apache2::Reload bundled for CPAN release
+This release incorporates unreleased changes in 0.08 and 0.09
+[Fred Moyer [EMAIL PROTECTED]]
+
+=item 0.09
+
+Apache2::Reload was part of mod_perl2 core in this version
+
+=item 0.08
 
 Remove modified modules before reloading them
 [Javier Ureuen Val]

Modified: perl/Apache-Reload/trunk/MANIFEST
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/MANIFEST?rev=606234r1=606233r2=606234view=diff
==
--- perl/Apache-Reload/trunk/MANIFEST (original)
+++ perl/Apache-Reload/trunk/MANIFEST Fri Dec 21 08:22:23 2007
@@ -3,4 +3,9 @@
 README
 LICENSE
 lib/Apache/Reload.pm
+lib/Apache2/Reload.pm
+t/reload.t
+t/lib/Apache/TestReload.pm
+t/lib/Apache2/TestReload.pm
 RELEASE
+Changes

Modified: perl/Apache-Reload/trunk/Makefile.PL
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/Makefile.PL?rev=606234r1=606233r2=606234view=diff
==
--- perl/Apache-Reload/trunk/Makefile.PL (original)
+++ perl/Apache-Reload/trunk/Makefile.PL Fri Dec 21 08:22:23 2007
@@ -38,9 +38,9 @@
 require ModPerl::MM;
 ModPerl::MM::WriteMakefile(
%common_opts,
-   VERSION_FROM= lib/Apache/Reload.pm,
-   NAME= Apache::Reload,
-   ABSTRACT_FROM   = 'lib/Apache/Reload.pm',
+   VERSION_FROM= lib/Apache2/Reload.pm,
+   NAME= Apache2::Reload,
+   ABSTRACT_FROM   = 'lib/Apache2/Reload.pm',
   );
 }
 

Modified: perl/Apache-Reload/trunk/README
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/README?rev=606234r1=606233r2=606234view=diff
==
--- perl/Apache-Reload/trunk/README (original)
+++ perl/Apache-Reload/trunk/README Fri Dec 21 08:22:23 2007
@@ -101,6 +101,10 @@
 AUTHOR
 Matt Sergeant, [EMAIL PROTECTED]
 
+MAINTAINERS
+
+the mod_perl developers, [EMAIL PROTECTED]
+
 SEE ALSO
 Apache::StatINC, Stonehenge::Reload
 

Modified: perl/Apache-Reload/trunk/RELEASE
URL: 
http://svn.apache.org/viewvc/perl/Apache-Reload/trunk/RELEASE?rev=606234r1=606233r2=606234view=diff
==
--- perl/Apache-Reload/trunk/RELEASE (original)
+++ perl/Apache-Reload/trunk/RELEASE Fri Dec 21 08:22:23 2007
@@ -40,8 +40,8 @@
 
   a. edit ./Changes:
  - find lib -type f -name *.pm | \
- xargs perl -pi -e 's,0.08-dev,0.08-rc1,g'
- - perl -pi -e 's,0.08-dev,0.08-rc1,g' Changes
+ xargs perl -pi -e 's,0.10-dev,0.10-rc1,g'
+ - perl -pi -e 's,0.10-dev,0.10-rc1,g' Changes
 
  - don't commit these (see dev@ archives)
 
@@ -60,7 +60,7 @@
  o dev/perl.apache.org
  o modperl/perl.apache.org
 
-  Subject: [RELEASE CANDIDATE] Apache-Reload 0.08 RC\d+
+  Subject: [RELEASE CANDIDATE] Apache-Reload 0.10 RC\d+
 
(or maybe longer to give most people

Re: Problems using Apache::Reload

2007-07-01 Thread Tony van der Hoff
On 30 Jun at 16:55 Jonathan Vanasco [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]

[snip]
 assuming you're on a nix/bsd -- you need to be able to restart the server.
 if you can't , then you shouldn't be using mod_perl. 
[snip]

Thank you, Jonathan, for your more detailed explanation. I have to say, I am
extremely disappointed with my experience. I've used PHP for some years to
create interactive web sites with some success, but having read about the
significant performance boost available from mod_perl, I bit the bullet, and
used PERL for the first time on my current project. Had I known then what I
know now, I wouldn't have bothered :-( 

I don't even like the language much, but I'm sure that's a personal thing.

It looks then like I have two options:
1. abandon mod-perl and just use cgi. 
2. move the project to a server over which I have full control.

(1) rather defeats the object of using PERL, and I am loth to acknowledge
defeat; (2) adds significant expense, and extra effort, to the project. Bah
- what a mess!

Thanks again, Tony

-- 
Tony van der Hoff| mailto:[EMAIL PROTECTED]
Buckinghamshire, England


Re: Problems using Apache::Reload

2007-07-01 Thread Clinton Gormley
Tony - There are lots of people using Registry successfully (in fact the
new Bugzilla uses Registry, if I remember correctly).

 Thank you, Jonathan, for your more detailed explanation. I have to say, I am
 extremely disappointed with my experience. I've used PHP for some years to
 create interactive web sites with some success, but having read about the
 significant performance boost available from mod_perl, I bit the bullet, and
 used PERL for the first time on my current project. Had I known then what I
 know now, I wouldn't have bothered :-( 
 
 I don't even like the language much, but I'm sure that's a personal thing.

Give it time. I'm maintaining some PHP code, and all I want to do is
rewrite it in Perl.

 
 It looks then like I have two options:
 1. abandon mod-perl and just use cgi. 
 2. move the project to a server over which I have full control.
 
 (1) rather defeats the object of using PERL, and I am loth to acknowledge
 defeat; (2) adds significant expense, and extra effort, to the project. Bah
 - what a mess!

I think that Jonathan is exaggerating the risks, and if you don't have
the luxury of running your own server then it is quite acceptable to use
these modules. See here for some points about the trade-offs that you
make :
http://search.cpan.org/~pgollucci/mod_perl-2.0.3/docs/api/Apache2/Reload.pod#Performance_Issues

I have little exposure to it, but from reading these lists over the last
decade, and reading the docs for Apache2::Reload, ModPerl::Registry etc,
I think that Registry is a perfectly usable product, with a couple of
gotchas.

I would welcome feedback on the experiences of others.

The biggest gotchas are:
 * GLOBAL VARIABLES
  In a CGI script, maybe you have:
our $var;
$var = 'xx' if $flag;

  But because Registry scripts are persistent, variables that 
  haven't been properly intialiased, may contain data from
  previous requests.

  So instead write:

 my $var;
 OR
 our $var = undef;
  
 * CLOSURES : you can't do this:

   my $var;
   sub my_sub {
   print $var;
   }

   ... because Registry loads this script as:

   sub handler {
  my $var;
  sub my_sub {
 print $var
  }
   }
   
   which will give you the warning: $var will not stay shared

Instead, do this:
   sub my_sub {
  my $var = shift;
  print $var

OR
  our $var = undef;
 
  sub my_sub {
  print $var;

 * CHDIR
 chdir is not thread safe, and cannot be relied upon, and the
 current working dir is not reset for each call to a script.  
 Instead use absolute paths (plus use lib '/path');

 * IMPORTING FROM MODULES / BEGIN/CHECK/END BLOCKS

   If a Registry script imports subs/variables from a use'd module, 
   and the module is reloaded - the imported sub isn't updated. This
   is because the 'use' statement executes on the first compile, and 
   not subsequently.

   So instead of:
 use MyModule qw(sub1 sub2);

   Do:
 require MyModule;
 MyModule-import(qw(sub1 sub2));

   Read more about the BEGIN/CHECK/END blocks issue here:
   
http://search.cpan.org/~pgollucci/mod_perl-2.0.3/docs/api/Apache2/Reload.pod#Caveats
 

Other than that, Registry works well.  There will be edge cases where
Perl modules are doing some dark magic, which may have unexpected side
effects, but for the most part, it should all just work.

Clint



Re: Problems using Apache::Reload

2007-07-01 Thread Tony van der Hoff
On 30 Jun at 11:13 Clinton Gormley [EMAIL PROTECTED]  wrote in message
[EMAIL PROTECTED]

Thanks, Clint, for your helpful reply.

 Disclaimer: I have never used Apache::Reload, but:
 
 Apache::Registry already looks for changes to your scripts and reloads
 them as necessary. So you shouldn't need to use both of them.  

Well, I agree it says that, but when I tried using Registry without Reload,
it didn't seem to work, so I gave up, and used Reload, more-or-less
successfully.

[snip]
 
 Secondly, the problem of it not finding your modules - you need to add a :
 use lib '/path/to/my/modules'; somewhere early on, for instance in a
 startup.pl file that is included in your config, or in one of the first
 lines of your .pl files.
 
Yeah, well, startup.pl is out of the question if the httpd.conf is
unavailable, and the server can't be restarted. 

My understanding is that adding the use lib line is certainly required,
but only takes effect on invocation of the .pl code. If the modules are
already cached, then they are not reloaded. So that's where Apache::Reload
comes in. Any registered modules are stat'ed, and reloaded as necessary
*before* the .pl code are executed, and therefore *before* any use lib
instructions are processed. 

So, I would, for instance, have a .pl file which contains
...
use lib .;# I believe this is implicit, anyway.
use CCC::MyDBI;
...

Then, if MyDBI.pm contains use Apache::Reload (because Apache::ReloadAll
is off), Apache::Reload then registers CCC::MyDBI when it is first compiled.


On subsequent invocations it will look for CCC::MyDBI in @INC. Now, as you
correctly say, I could make a permanent change to @INC in a startup.pl, but
let's agree that's out of the question. 
It would appear, that CCC::MyDBI can't be found in @INC; and I can fix
things (in development) by putting a symlink to CCC/ in any one of the
directories which do appear in @INC, or, for that matter (both in
development and production) in my root. That works well enough, but my
puzzlement derived from seeing . in @INC; which I had expected to refer to
the project directory, which containc CCC. Apparently not, and I was
wondering why not. 

Personally I would have expected Apache::Reload to have registered the full
path to CCC, which would overcome this problem, but, as I find with so many
other things in PERL, It don't work that way.

[snip] 
   PERL5LIB=/home/httpd/perl/extra; export PERL5LIB
 
 in the script that starts Apache. Alternatively, you can set this
 environment variable in httpd.conf:
 
   PerlSetEnv PERL5LIB /home/httpd/perl/extra
 
Anything that can be set in a .htaccess file is OK, and using the PerlSetEnv
there seems to work. So that's another small step forward, much better than
the symlink in root.

[snip]
 
 With regards the redefined warnings, what about this:
 
 use strict; use warnings FATAL = 'all'; no warnings 'redefine';
 
Yay! that works, too. Thank you.

[snip]
 If you are not able to restart your server, then you need to rely on some
 sort of stat'ing mechanism: Registry for scripts, and Reload for modules.
 A lot of people use this setup successfully.  Just be aware that there may
 be non-obvious issues.
 
I think that's the pragmatic approach. Abandoning mod_perl now goes against
the grain; I may have to invest in a VPS solution, but I'll see how things
go. 

At least with your help, I have overcome the most immediate ugliness, for
which I'm truly grateful. 

Thanks again, Tony

-- 
Tony van der Hoff| mailto:[EMAIL PROTECTED]
Buckinghamshire, England


Re: Problems using Apache::Reload

2007-07-01 Thread Clinton Gormley

  
  Apache::Registry already looks for changes to your scripts and
 reloads
  them as necessary. So you shouldn't need to use both of them.  
 
 Well, I agree it says that, but when I tried using Registry without
 Reload,
 it didn't seem to work, so I gave up, and used Reload, more-or-less
 successfully.
 

Registry checks whether your script has changed:
 - eg cgi-bin/login.pl

But if login.pl contains 'use My::Module', it doesn't check for that
module, which is why you would need Apache::Reload as well.


 So, I would, for instance, have a .pl file which contains
 ...
 use lib .;  # I believe this is implicit, anyway.
 use CCC::MyDBI;
 ...

This is one of the gotchas I mentioned before: CHDIR.

You can't rely on it.  Something somewhere (maybe Registry itself) is
changing the current dir, so '.' now refers to / rather than
to /path/to/your/modules.

Change that to : use lib '/path/to/your/modules'; and it should work.

Re a virtual server solution - I've been looking for one as well. Here
are a few I've found (haven't tried them yet):

http://order.1and1.co.uk/xml/order/VpsRoot?__frame=_top__lf=Static
http://www.spry.com/plesk-vps/
http://www.vpslink.com/


Good luck.  When you get to grips with these issues, you'll end up
loving Perl.

Clint



Re: Problems using Apache::Reload

2007-07-01 Thread Perrin Harkins

On 7/1/07, Clinton Gormley [EMAIL PROTECTED] wrote:

This is one of the gotchas I mentioned before: CHDIR.

You can't rely on it.  Something somewhere (maybe Registry itself) is
changing the current dir, so '.' now refers to / rather than
to /path/to/your/modules.


It's actually not that something is doing a chdir, but that Registry
is NOT doing one.  In a CGI environment, the current directory is
always set to the directory where the script lives.  Unfortunately,
this is not safe for a threaded environment, so Registry doesn't do it
by default.

A subclass of Registry that deals with this is included in the
mod_perl distribution.  It's called ModPerl::RegistryPrefork.  There's
more explanation here:
http://perl.apache.org/docs/2.0/user/porting/compat.html#C_Apache__Registry___C_Apache__PerlRun__and_Friends

- Perrin


Re: Problems using Apache::Reload

2007-07-01 Thread Jonathan Vanasco


You're comparing Apples to Rocks with php  mod_perl ( rocks was the  
first non-fruit thing I could think of )


php has 3 main flavors - mod_php , php-cgi , php-cli

lets just look at mod_php and php-cgi

	if you run perl and php through a fastcgi proxy , you're going to  
get similar performance from an architecture standpoint.  each  
language will be a bit faster or slower depending on its strengh or  
weakness in whatever you test, but the overall design of the systems  
will be the same, and you won't see much of a difference.


mod_php and mod_perl sound kind of similar..


		mod_php is sticking a php interpreter in apache , and using that to  
process files
		mod_perl is sticking a perl interpreter in apache , and using that  
to process files ( it can script apache + integrate with hooks too )


	but they behave a little differently because of the way they have  
very different approaches in the way they handle memory - shared  
memory, loading libraries, copy on write, etc

they also have slightly different architectures

most people use mod_perl in dedicated environments -- it achieves its  
speed performance by compiling  caching code -- which eats up  
memory.  because code is handled with the package namespaces, people  
generally don't run it in shared environments, as you provide  
security from people overwriting namespaces can only happen by  
consuming more memory to create isolated namespaces in the children.


some people here may disagree with me and chime in...

	but i strongly advise not depending on mod_perl if you don't have  
'root' access for apache.  you're going to create a lot of headaches  
for yourself, and you're only going to be able to experience a  
limited subset of features  optimizations that are offered.  as a  
bad analogy, your experience with mod_perl is going to be like  
driving a sportscar around in a crowded parkinglot - you're stuck  
with a small speedlimit and you can't leave the lot and really see  
whats under the hood.


if i were in your situation, i'd do the following:
		1, try to get root access , so you can run/write handlers or  
registry stuff that won't depend on reload

2, look into your options with running perl via fast-cgi
		3, stick to php.  drop apache, switch to nginx and run php via fast- 
cgi , utilizing the APC cache ( or the eaccelerator one if its  
working again )


a while back I benched a simple app in php  perl, using the phptal   
petal libraries:

20 r/s - mod_php / Apache
150 r/s/ - php-cgi / apc / nginx
200 r/s - mod_perl

the huge speed differences between nginx and mod_php was due to:
a- nginx is faster/more lightweight, tied up less resources than apache
	b- apc cached the phptal templates  engines way better than the  
standard php stat or whatever it does.  i didn't bench rps under  
apache using apc and not, but the generation time went from .7  
seconds to .09 per page.   it was a HUGE difference on that alone.
	c- mp likely edged out php because perl is just kickass with text- 
processing, which is primarily what i benched.


that said, if you don't like perl - don't use it.  there are lots of  
ways to improve your php performance.


i still use php -- we have a lot of micro-sites and templates that we  
don't want to cache.  running that stuff in php lets us easily  
specify how much memory we want to limit that too , and keep it  
isolated from our main perl servers.  all of the db interaction on  
that stuff is handled by requests to internal perl-servers which  
return json objects.  its really gives us the best of both worlds.



On Jul 1, 2007, at 4:47 AM, Tony van der Hoff wrote:

On 30 Jun at 16:55 Jonathan Vanasco [EMAIL PROTECTED] wrote in  
message

[EMAIL PROTECTED]

[snip]
assuming you're on a nix/bsd -- you need to be able to restart the  
server.

if you can't , then you shouldn't be using mod_perl.

[snip]

Thank you, Jonathan, for your more detailed explanation. I have to  
say, I am
extremely disappointed with my experience. I've used PHP for some  
years to
create interactive web sites with some success, but having read  
about the
significant performance boost available from mod_perl, I bit the  
bullet, and
used PERL for the first time on my current project. Had I known  
then what I

know now, I wouldn't have bothered :-(

I don't even like the language much, but I'm sure that's a personal  
thing.


It looks then like I have two options:
1. abandon mod-perl and just use cgi.
2. move the project to a server over which I have full control.

(1) rather defeats the object of using PERL, and I am loth to  
acknowledge
defeat; (2) adds significant expense, and extra effort, to the  
project. Bah

- what a mess!

Thanks again, Tony

--
Tony van der Hoff| mailto:[EMAIL PROTECTED]
Buckinghamshire, England


// Jonathan Vanasco

| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - 

Re: Problems using Apache::Reload

2007-06-30 Thread Tony van der Hoff
On 29 Jun at 21:47 Jonathan Vanasco [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]

 
 On Jun 29, 2007, at 4:09 PM, Tony van der Hoff wrote:
  Well, thank you for that advice.
 
  Um, Why?
 
  How does that help solve my problems?
 
 
 Apache::Reload checks perl modules and *reloads* them on every hit if
 they've changed.  It's essentially saying hi, i'm running under a
 persistant environment , where code shouldn't be changing, but I'm going
 to take a performance hit each time.  you get a perfomance hit AND you
 start to lose memory ( stuff goes from shared to unshared )
 
 it also performs very awkwardly and has been the cause of numerous
 problems on this list.   its likely not the culprit of the problem you're
 seeing now, but it will be causing many issues down the road. its not
 meant for production, its geared for dev servers.
 
[snip]

Well, it is my intention that the modules should be reloaded if they've
changed; that's the whole point of using Apache::Reload, so I'm pleased it
works. Presumably, if they haven't changed, the only performance hit is a
stat to the file system, and then only on those modules which explicitly
call Apache::Reload. I think I can live with that :)

However, without the ability to restart the server, and short of renaming
the files, how should I update my software? It won't happen much at the
production end, but it will certainly happen. Shouting Never, Never, Never
is all very well, and undoubtedly good advice, but it's a bit impractical
without an alternative.

What are the other problems you refer to? I've been lurking on this list for
some months, but have not seen anything mentioned, and Google doesn't throw
up anything on the first few pages.

Anyway, this all pales into insignificance against the real problems which
started this thread; I'd really appreciate some pointers as to how to fix
those.

Cheers, Tony

-- 
Tony van der Hoff| mailto:[EMAIL PROTECTED]
Buckinghamshire, England


Re: Problems using Apache::Reload

2007-06-30 Thread Clinton Gormley
Disclaimer: I have never used Apache::Reload, but:

Apache::Registry already looks for changes to your scripts and reloads
them as necessary. So you shouldn't need to use both of them.  However,
reading the docs for Apache2::Reload, it mentions using it at the same
time as Registry scripts, which I think refers to using reload for other
modules, rather than duplicating the effort for Registry scripts.

It says that you will have a problem if, in your Registry script, you
'use' another module.  Updates to that module will not be noticed by
Registry.  Instead, you should do an explicit 'require module;
import(...)'.

 The first time after an apache restart (on the development box) it works
 fine; obviously it is able to find CCC in the project directory, but after I
 edit one of the .pm files, it all goes titsup.

Secondly, the problem of it not finding your modules - you need to add
a : use lib '/path/to/my/modules'; somewhere early on, for instance in a
startup.pl file that is included in your config, or in one of the first
lines of your .pl files.

Actually, reading the Apache2::Reload docs:

Note that Apache2::Reload operates on the current context of @INC. Which
means, when called as a Perl*Handler it will not see @INC paths added or
removed by ModPerl::Registry scripts, as the value of @INC is saved on
server startup and restored to that value after each request. In other
words, if you want Apache2::Reload to work with modules that live in
custom @INC paths, you should modify @INC when the server is started.
Besides, 'use lib' in the startup script, you can also set the PERL5LIB
variable in the httpd's environment to include any non-standard 'lib'
directories that you choose. For example, to accomplish that you can
include a line:

  PERL5LIB=/home/httpd/perl/extra; export PERL5LIB

in the script that starts Apache. Alternatively, you can set this
environment variable in httpd.conf:

  PerlSetEnv PERL5LIB /home/httpd/perl/extra

 
 Note that . is present in @INC, but I guess it refers to /, because I
 can work round this by placing a symlink to CCC in my root directory on the
 development server, and in my chroot home on the production server.
 Annoying, but not too desperate.
 
 The second, and I assume associated, problem is that I get a shedload of
 warnings each time the modules are recompiled, of the form:

With regards the redefined warnings, what about this:

use strict;
use warnings FATAL = 'all';
no warnings 'redefine';

From the source for ModPerl::Registry:

  # we try to develop so we reload ourselves without die'ing on the warning
  no warnings qw(redefine); # XXX, this should go away in production!

It doesn't explain WHY they should go away in production, but I presume
that having the warnings means that you can spot a redefine that
SHOULDN'T have happened.

With regards using Apache::Reload in production, my understanding is
that, while Apache::Reload is really useful for development, there are
edge cases where things get messed up, and which require a stop-start to
get them working again.  And for this reason, we would not usually
consider using this module in production.

If you are not able to restart your server, then you need to rely on
some sort of stat'ing mechanism: Registry for scripts, and Reload for
modules. A lot of people use this setup successfully.  Just be aware
that there may be non-obvious issues.

Repeated disclaimer: I have never used either Registry or Reload, but
have a look at the docs for Apache2::Reload - it sheds more light on the
issues you've been having, and probably works in a similar way to
Apache::Reload.

good luck

Clint



Re: Problems using Apache::Reload

2007-06-30 Thread Jonathan Vanasco


On Jun 30, 2007, at 2:40 AM, Tony van der Hoff wrote:


Well, it is my intention that the modules should be reloaded if  
they've
changed; that's the whole point of using Apache::Reload, so I'm  
pleased it
works. Presumably, if they haven't changed, the only performance  
hit is a
stat to the file system, and then only on those modules which  
explicitly

call Apache::Reload. I think I can live with that :)


Thats the intention of the devel environment.  But aside from the  
performance hit, reload doesn't work perfectly.  some module changes  
won't get picked up due to class override / superclass conflicts,  
other changes will cause Reload to just crash your server.  when  
you're running reload, you're ideally having the stat and a clean  
reload -- in practice you can get larger performance hits from the  
stat being read wrong and tons of crashes.


However, without the ability to restart the server, and short of  
renaming
the files, how should I update my software? It won't happen much at  
the
production end, but it will certainly happen. Shouting Never,  
Never, Never
is all very well, and undoubtedly good advice, but it's a bit  
impractical

without an alternative.


assuming you're on a nix/bsd -- you need to be able to restart the  
server.  if you can't , then you shouldn't be using mod_perl.   see  
if you can run apache on a port you can control, then proxypass to it.
mod_perl does a lot of performance/memory optimizations by using the  
copy-on-write model for vars and caching compiled subs.  when you  
'reload' code, you're just redefining the subs... which means they  
get unshared.


illustration
start   parent-a
forkchild-a child-a child-a
update code
reload
child-a child-a child-b
child-a child-b child-b
child-b child-b child-b
	i'm not sure how reload affects the master-process memory--  but I  
have a funny feeling that new children will spawn with the pre-update  
code, then stat to the new  code




What are the other problems you refer to? I've been lurking on this  
list for
some months, but have not seen anything mentioned, and Google  
doesn't throw

up anything on the first few pages.


look back within the past 18-6 months.  there was a lot of reload  
talk then.  not as much lately.


also, you should never do an apachectl restart/graceful.
you want to do a full apache stop,  and then apache  start.  the  
integrated restart command will essentially cause a memory leak ( its  
not really leaking, but the memory isn't recycled/overwrriten -- so  
your process will double on size the first restart, etc etc etc )




On Jun 30, 2007, at 6:13 AM, Clinton Gormley wrote:

With regards using Apache::Reload in production, my understanding is
that, while Apache::Reload is really useful for development, there are
edge cases where things get messed up, and which require a stop- 
start to

get them working again.  And for this reason, we would not usually
consider using this module in production.


its much less edge-cases than it is use-cases.



// Jonathan Vanasco

| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -

|   CEO/Founder SyndiClick Networks
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -

| Founder/CTO/CVO
|  FindMeOn.com - The cure for Multiple Web Personality Disorder
|  Web Identity Management and 3D Social Networking
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -

|  RoadSound.com - Tools For Bands, Stuff For Fans
|  Collaborative Online Management And Syndication Tools
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -





Problems using Apache::Reload

2007-06-29 Thread Tony van der Hoff
I'm a bit of a newbie with respect to mod_perl, but with some perseverence,
I seem to have googled and hacked my way 'round most of it.

A couple of problems continue to dog me, though:

Because of constraints by my service provider, I'm running apache/1.3.37
with mod_perl/1.30 under linux on both my production and development
servers. 

On my production server, I have no access to httpd/conf, so I have put the
various PERL init commands in .htaccess, thus:

Order allow,deny
Allow from all
Options Indexes FollowSymLinks MultiViews ExecCGI
DirectoryIndex index.pl
PerlModule Apache::Registry
PerlModule Apache::DBI
PerlInitHandler Apache::Reload
PerlSetVar ReloadAll Off
AddHandler perl-script .pl
PerlSendHeader On
PerlHandler Apache::Registry

Obviously, I want to keep as much similarity between my production and
development environments as I can, so I've done the same on the development
server. 

The directory stucture is fairly deep, but ends up as a project directory,
containing the .htaccess, a bunch of .pl files, and a CCC subdirectory
containing a bunch of .pm modules.

This all seems to work well enough, except that on reload, PERL is unable to
find the .pm files which it wants to re-compile:
[Fri Jun 29 17:28:59 2007] [error] Can't locate CCC/MyDBI.pm in @INC (@INC
contains: /usr/lib/perl5/5.8.8/i386-linux /usr/lib/perl5/5.8.8
/usr/lib/perl5/site_perl/5.8.8/i386-linux /usr/lib/perl5/site_perl/5.8.8
/usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.8/i386-linux
/usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl/5.8.7
/usr/lib/perl5/vendor_perl/5.8.7/i386-linux /usr/lib/perl5/vendor_perl/5.8.6
/usr/lib/perl5/vendor_perl . /etc/apache1/ /etc/apache1/lib/perl) at
/usr/lib/perl5/site_perl/5.8.8/Apache/Reload.pm line 132.\n

The first time after an apache restart (on the development box) it works
fine; obviously it is able to find CCC in the project directory, but after I
edit one of the .pm files, it all goes titsup.

Note that . is present in @INC, but I guess it refers to /, because I
can work round this by placing a symlink to CCC in my root directory on the
development server, and in my chroot home on the production server.
Annoying, but not too desperate.

The second, and I assume associated, problem is that I get a shedload of
warnings each time the modules are recompiled, of the form:

[Fri Jun 29 17:41:05 2007] MyDBI.pm: Subroutine update_site_params redefined
at CCC/MyDBI.pm line 3659.

I assume this is because of the differing paths to the CCC directory. Now
this *is* a pain, because it masks any genuine errors, and it fills up the
apache error_log. 


So, sorry to have rambled on a bit, but does anyone have any suggestions as
to how I can properly fix these problems, or tell me what I'm doing wrong.
Any advice will be very welcome.

Cheers,
-- 
Tony van der Hoff| mailto:[EMAIL PROTECTED]
Buckinghamshire, England


Re: Problems using Apache::Reload

2007-06-29 Thread Jonathan Vanasco


On Jun 29, 2007, at 1:24 PM, Tony van der Hoff wrote:
So, sorry to have rambled on a bit, but does anyone have any  
suggestions as
to how I can properly fix these problems, or tell me what I'm doing  
wrong.

Any advice will be very welcome.


I don't have time to analyze your config, but

you should NEVER run Apache::Reload in a production server.

NEVER

NEVER NEVER NEVER.




// Jonathan Vanasco

| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -

|   CEO/Founder SyndiClick Networks
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -

| Founder/CTO/CVO
|  FindMeOn.com - The cure for Multiple Web Personality Disorder
|  Web Identity Management and 3D Social Networking
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -

|  RoadSound.com - Tools For Bands, Stuff For Fans
|  Collaborative Online Management And Syndication Tools
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -





Re: Problems using Apache::Reload

2007-06-29 Thread Tony van der Hoff
On 29 Jun at 20:08 Jonathan Vanasco [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]

 
 On Jun 29, 2007, at 1:24 PM, Tony van der Hoff wrote:
  So, sorry to have rambled on a bit, but does anyone have any suggestions
  as to how I can properly fix these problems, or tell me what I'm doing
  wrong. Any advice will be very welcome.
 
 I don't have time to analyze your config, but
 
 you should NEVER run Apache::Reload in a production server.
 
 NEVER
 
 NEVER NEVER NEVER.
 

Well, thank you for that advice.

Um, Why?

How does that help solve my problems?

-- 
Tony van der Hoff| mailto:[EMAIL PROTECTED]
Buckinghamshire, England


Re: Problems using Apache::Reload

2007-06-29 Thread Jonathan Vanasco


On Jun 29, 2007, at 4:09 PM, Tony van der Hoff wrote:

Well, thank you for that advice.

Um, Why?

How does that help solve my problems?



Apache::Reload checks perl modules and *reloads* them on every hit if  
they've changed.  It's essentially saying hi, i'm running under a  
persistant environment , where code shouldn't be changing, but I'm  
going to take a performance hit each time.  you get a perfomance hit  
AND you start to lose memory ( stuff goes from shared to unshared )


it also performs very awkwardly and has been the cause of numerous  
problems on this list.   its likely not the culprit of the problem  
you're seeing now, but it will be causing many issues down the road.   
its not meant for production, its geared for dev servers.



// Jonathan Vanasco

| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -

|   CEO/Founder SyndiClick Networks
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -

| Founder/CTO/CVO
|  FindMeOn.com - The cure for Multiple Web Personality Disorder
|  Web Identity Management and 3D Social Networking
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -

|  RoadSound.com - Tools For Bands, Stuff For Fans
|  Collaborative Online Management And Syndication Tools
| - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - - - - - - - - - -





  1   2   >