Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^3: Fork-safe DBI handles via ChildHandles and InactiveDestroy

by sgt (Deacon)
on Jun 07, 2007 at 12:39 UTC ( [id://619798]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Fork-safe DBI handles via ChildHandles and InactiveDestroy
in thread Fork-safe DBI handles via ChildHandles and InactiveDestroy

A few months ago, to make a point about some of the pitfalls of fork and IO, I wrote a few tests to show the potential problems (from a Un*x perspective following the R. Stevens books for instance), and all my tests were negative in the sense that (at least on cygwin -- I think I tested HP-UX which has been my perl platform for years, but I cannot remember for sure) implicit flushing was going on ...It would be interesting to know how much perl departs from Un*x on this (and since when).

In general for this kind of problem, maybe the best way to go is a process manager maintaining a pool of processes each one with one DB connection, and some protocol to reach the process manager. Anyway I find the "forks" module interesting.

cheers --stephan
  • Comment on Re^3: Fork-safe DBI handles via ChildHandles and InactiveDestroy

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://619798]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (4)
As of 2024-04-24 21:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found