perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Hedges <hed...@scriptdolphin.org>
Subject Re: Initializing Sleepycat::DbXml (Berkeley, Oracle) objects in startup.pl
Date Fri, 16 Jan 2009 05:38:43 GMT


On Thu, 15 Jan 2009, Michael Ludwig wrote:

> PerlRequire /home/milu/www/eumel/startup.pl
> PerlChildInitHandler Eumel::Gurke::bla;
> PerlChildExitHandler Eumel::Gurke2::bla;

No trailing semicolons?

Probably if you first do PerlLoadModule Foo::Bar it will
fail and inform you

> >  my $container = XmlContainer->new('/path/to/whatever.xml');
> >
> >  sub handler {
> >      my ($r) = @_;
> >      $container->open(Db::DB_CREATE);
> >      $container->put...
> >      # ...
> >      $container->close();  # ?? not sure how it works
> >  }
>
> I tried this style of initialization. It doesn't solve
> things. Depending on how exactly I code this, I get either
> a SEGV on startup attempt or when attempting concurrent
> access to the application. I also saw this:
>
> *** glibc detected *** free(): invalid pointer: 0x084e6a14 ***

If this didn't work in a response handler, I'd guess there's
something else wrong.  That's the kind of error you get when
you use things under threads that are not thread-safe in
some way, I remember that sort of thing trying to use
List::MoreUtils::natatime() under threads.  (But the rest of
that library works.)  It's a sad state of affairs that a
large chunk of CPAN doesn't play nice with threads, and
there's usually not any way of knowing which library is
causing the problem.  It might not even be the oracle
thingy, maybe something else you're loading.

Mark

Mime
View raw message