Re: server lifecycle



On 30Aug2001 02:30PM (-0400), Havoc Pennington wrote:
> 
> Hi,
> 
> Right now the GNOME desktop leaks components left and right.  We need
> to fix this problem for 2.0, I think it's a showstopper.
> 
> "Hope nothing ever crashes" won't work; there's always out of memory
> and ctrl-alt-backspace if nothing else. Apps will die unexpectedly.
> 
> The bad hack on logout is not a good solution; it keeps you from
> having multiple sessions, and forces you to log out periodically to GC
> your stale server processes.
> 
> Do we have a plan to fix this?
> 

I plan to fix the specific case of oafd (well,
bonobo-activation-server) in time for GNOME2. I think the more general
problem really needs a solution like leases. This is what most
distriuted refcounting / GC systems have settled on.

The trick is to come up with a system that's as convenient to use as
refcounting, but uses leases underneath. I have a vague proposal for
this.

bonobo-activation knows when you are activating a remote (process or
machine) server, and when you are activating an in-proc server. I
propose that we add a Bonobo::RemoteUnknown interface that uses
leases. bonobo-activation would then wrap remote servers to proxy the
RemoteUnknown interface into something that looks like Unknown on the
client side. In-proc servers are just used directly.

This implies a potential minor performance hit in the case of out of
proc components, but this hit will be dwarfed by the cross-process
communication overhead.

I've left out a lot of implementation details here but perhaps this
rough sketch will point out some good directions to go in.

Actually, I just realized my plan is woefully incomplete because you
can pass object references across a remote CORBA link and you'd need
to be sure to pass RemmoteUnknowns instead of Unknowns. Perhaps
special cooperation is required from the IDL compiler and/or the
ORB. The IDL compiler has the advantage of knowing the types of
everything you are passing and when you are actually sending things
over a remote link so in a way it's the ideal place to turn an Unknown
into a RemoteUnknown and vice versa.

Any thoughts on this?

 - Maciej


_______________________________________________
gnome-hackers mailing list
gnome-hackers gnome org
http://mail.gnome.org/mailman/listinfo/gnome-hackers




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]