lihao has asked for the wisdom of the Perl Monks concerning the following question:
Hi, monks
I am using HTML::Mason + mod_perl + Apache2 under RHEL5, an YAML file is used for Marketing to maintain a complex data structure: a tree of questionnairs (HOH). The problem is that each time I update this YAML file, the change does not shown on live until I restart the Apache server. I tried:
the YAML file is loaded with YAML::Syck:
my $TREE = LoadFile('/path/to/tree.yml');
The problem sounds to be from the server side. Is there any method in the mod_perl enviromental that I can Reload the YAML file without restarting Apache? i.e. something like Apache2:Reload ReloadTouchFile on Perl files.
thanks
lihao
Update: Never mind, after more testings, I found putting the YAML::Syck::LoadFile line into <%init> tag instead of <%once> tag solved my problem. this turns out to be just a problem on how to use HTML::Mason properly. thanks again.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: YAML file update issue under mod_perl
by Anonymous Monk on Nov 07, 2010 at 00:56 UTC | |
|
Re: YAML file update issue under mod_perl
by zwon (Abbot) on Nov 07, 2010 at 03:14 UTC |