>> I don't, however, do any error checking on that eval.
>
>Jinx!

Heh, heh :)

>> that if a) the eval fails or it gets cached or whatever, then
>> b) I'd be returning a blessed object for a module that hasn't
>> been loaded. *That* could cause the ->connect to not exist,
>> thus causing my error. Right?
>
>Right.

And this is confirmed further: if I just add "use LibDB::DB::MySQL"
to the top of my .cgi scripts (yeah, yeah, the whole "in the same
codebase" stuff), then I can't replicate the missing ->connect.

>It's not random; you just don't know what series of steps reproduces it
>yet.  If you run with -X, you can probably find a sequence that will do

This is what I'm hoping happens (I'm still in the process
of building a dev server that exactly mimicks my prod, thus
allowing me to run -X). Does the following sound possible?

 * the first load of index.cgi uses no DB calls (well,
   it does "use LibDB::DB", but DB.pm never gets around
   to eval'ing MySQL.pm), so things are cached without it.

 * with all the modules and whatnot cached in the child,
   a "use the database" call to that process fails because
   LibDB::DB::MySQL isn't part of that cache. Refreshing
   like mad eventually brings me to a child that has not
   previously cached things, and thus, LibDB::DB::MySQL
   is loaded and cached.

If that's the case, then I should consider eval'ing my
database module in the .cgi script, regardless of whether
I'm actually using any of it's functions.



--
Morbus Iff ( i put the demon back in codemonkey )
Culture: http://www.disobey.com/ and http://www.gamegrene.com/
Spidering Hacks: http://amazon.com/exec/obidos/ASIN/0596005776/disobeycom
icq: 2927491 / aim: akaMorbus / yahoo: morbus_iff / jabber.org: morbus


-- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html



Reply via email to