Skip Menu |

This queue is for tickets about the CGI-Application-Plugin-ActionDispatch CPAN distribution.

Report information
The Basics
Id: 66377
Status: resolved
Priority: 0/
Queue: CGI-Application-Plugin-ActionDispatch

People
Owner: Nobody in particular
Requestors: aku.kauste [...] curling.fi
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.98
Fixed in: (no value)



Subject: using multiple CGI::Application files under mod_perl fails
Having two or more CGI::Applications that use CAP::ActionDispatch fails when another App is using the same process that other App has used before. I was able to trace this to CAP::ActionDispatch::Attributes-file and there to init function. The patch that I've included seems to fix this issue for me.
Subject: Attributes.pm.diff
12c12 < my $init = 1; --- > my %inited; # Allow multiple CGI::Applications to be inited separately in mod_perl enivironment 42,43c42 < return unless $init; # Initialize only once < --- > my $class; 45c44,45 < my $class = $attr->[0]; --- > $class = $attr->[0]; > next if( exists $inited{$class}); 51c51 < $init = 0; --- > $inited{$class}++; # Mark our caller class inited now, so that it can be skipped on next run
Thanks for the patch. I'll push the change onto CPAN soon, for now though it is up on github. https://github.com/jaywhy/cgi-application-plugin-actiondispatch