On Dec 10, 2008, at 2:33 PM, JRF wrote:

>
> So, when merb (1.0.x) starts up with in cluster mode (-c 2 for
> example), It prepares a spawner process to quickly reproduce worker
> processes.  Fine.
>
> The problem is that the spawner has an open socket to Postgresql via
> DataObjects, via DataMapper.  That socket is replicated by the forking
> process so all workers share it.  Not good.  Then at some point, one
> of the workers (or maybe the spawner) closes the socket, and the
> server obliges by closing its end of the connection.   The other
> workers still have their end of the socket, but blow up when they try
> to use it.  Also not good.
>
> do_postgresql doesn't appear to have any connection re-establishment
> logic, but that is somewhat beside the point as the merb workers
> shouldn't be sharing the connection to begin with.
>
> Any suggestions as to where in the stack this is best addressed?


        Yeah this is definitely an issue. What we need to do is close all  
open IO handles after fork and reopen them. or even better just mke  
sure that no logs or db handles are opened until after fork.

        Can you please file a high priority ticket in the lighthouse tracker  
for this? I'm sure Yehuda will fix this quickly.

Cheers-

Ezra Zygmuntowicz
[EMAIL PROTECTED]




--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"merb" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/merb?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to