Re: Apache::Test question
[prev]
[thread]
[next]
[Date index for 2004/12/19]
--nextPart12288466.YTfFWPmMfd
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
On Thursday 16 December 2004 17:28, Stas Bekman wrote:
> grep the source for reconfigure() which I think will enforce the re-cache.
Sorry, I could not find it. Simply changing refresh to reconfigure yields:
Can't locate object method "reconfigure" via package "Apache::TestRunPerl" at /home/r2/work/Apache-ModSSL/t/TEST line 31.
Also grepping the source did not reveal something useful:
r2@opi:/usr/lib/perl5/vendor_perl/5.8.5/i586-linux-thread-multi/Apache> grep -i reconfigure Test*.pm
TestConfig.pm: $self->{clean_level} = shift || 2; #2 == really clean, 1 == reconfigure
TestConfig.pm: # we probably could reconfigure on the fly ($self->configure), but
TestRun.pm: # reconfigure or not.
TestRun.pm: $self->{reconfigure} = $opts{configure} ||
TestRun.pm: if ($self->{reconfigure}) {
TestRun.pm: delete $self->{reconfigure};
TestRun.pm: #if config is cached and MaxClients == 1, must reconfigure
TestRun.pm: warning "server is reconfigured for proxy";
While Apache::TestRunPerl::refresh is defined as:
#if Apache::TestRun refreshes config in the middle of configure
#we need to re-add modperl configure hooks
sub refresh {
my $self = shift;
$self->SUPER::refresh;
$self->configure_modperl;
}
and Apache::TestRun::refresh as:
#throw away cached config and start fresh
sub refresh {
my $self = shift;
$self->opt_clean(1);
$self->{conf_opts}->{save} = delete $self->{conf_opts}->{thaw} || 1;
$self->{test_config} = $self->new_test_config()->httpd_config;
$self->{test_config}->{server}->{run} = $self;
$self->{server} = $self->{test_config}->server;
}
At least the comments lead to the idea that refresh() is actually what I want.
Torsten
--nextPart12288466.YTfFWPmMfd
Content-Type: application/pgp-signature
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (GNU/Linux)
iD8DBQBBxZ8XwicyCTir8T4RAq+CAJ4pEE0eQRhg2Xf1wOkW6B+mWYws8wCfZvLj
5FJXQLViLZfgLgaCVjuIczM=
=dQGJ
-----END PGP SIGNATURE-----
--nextPart12288466.YTfFWPmMfd--
 |
(message missing)
|