[ic] $Tag->forum() fails in [perl] in prefork/rpc mode after one successful page view
Mike Heins
interchange-users@icdevgroup.org
Tue Jul 1 10:22:00 2003
Quoting John Young (john_young@sonic.net):
> I am unable to make $Tag->forum() work from within [perl] in a flypage
> in prefork mode. After starting Interchange, it will work once, but
> then fail for all subsequent page views.
>
> Interchange V4.9.7-200303310658 w/some patches
> Perl 5.8.0
> Linux and Solaris
>
> In flypage.html:
> [perl tables="forum userdb"]
> ...
> $out .= $Tag->forum({ top => $sku, display_page => 'forum/display' });
> ...
> [/perl]
>
> Logs:
> Safe: Can't locate object method "new" via package "Vend::Tags"
> (perhaps you forgot to load "Vend::Tags"?) at (tag 'perl') line 101.
>
> The log entry is referring to the following line in code/UserTag/forum.tag:
> my $Tag = new Vend::Tags;
>
>
> $Tag->forum() in [perl] always works in 'low' traffic mode.
> [forum] (not embedded perl) always works regardless of traffic mode (low
> or prefork).
> $Tag->forum() in [perl] in prefork mode works once and then fails for
> all subsequent views.
>
> If anyone has any ideas about how $Tag->forum() might forget
> about Vend::Tags after using it once in prefork mode, I would
> much appreciate any shared insight...
Bug. Try this patch:
--- /r/Interpolate.pm Wed Jun 18 22:20:28 2003
+++ /rt/Interpolate.pm Tue Jul 1 10:16:56 2003
@@ -1836,7 +1836,7 @@
}
}
- $Tag = $hole->wrap($Tag) if $hole and ! $tag_wrapped++;
+ $Tag = $hole->wrap($Tag) if $hole and ! $Vend::TagWrapped++;
init_calc() if ! $Vend::Calc_initialized;
$ready_safe->share(@share) if @share;
--
Mike Heins
Perusion -- Expert Interchange Consulting http://www.perusion.com/
phone +1.513.523.7621 <mike@perusion.com>
Prove you aren't stupid. Say NO to Passport.