Re: Gnome Session Services Framework



Hey,
	(Just picking some random comments to reply to)

On Wed, 2005-07-13 at 11:03 -0400, Ray Strode wrote:

> >     If that is the case, I'm not sure why
> >     we're doing this ... certainly in the case of the panel, there's no
> >     reason to delay the panel startup that long; the current behaviour
> >     of spawning the panel immediately after the window manager is fine.
>
> Is it? what if the panel process puts up a dialog before the window
> manager is fully started?  The panel shouldn't really be started until
> the window manager can manage it properly I think.

	I guess the best way to respond is that of course you're right, in
theory. But in practice, we've been asynchronously starting g-s-d,
metacity, gnome-panel and nautilus forever now, and we've never come
across these dependancy issues for real.

	Perhaps we could be missing subtle dependancy issues which don't cause
user visible problems but does slow down login (e.g. the gtk theme
xsetting getting set after some apps have loaded the default theme, but
before they've mapped any windows).

	Essentially, I'd like to see some evidence of an actual problem rather
than fix a theoretical problem.

	The issue with a dependancy-based session startup like this is that
you're preventing the panel from even loading its shared libraries until
the window manager has fully initialized. That would have a negative
effect on login speed.

> >   - Importing the environment from ServiceManager into the service
> >     seems using the GetEnvironment D-BUS message like a really odd
> >     thing to do. 
>
> Yea, I never really liked this much.  One solution that's been
> discussed is to extend d-bus such that a dbus service foo can set a
> default environment for its own activations (if a service starts a
> program with execve it can pass an environment, why shouldn't it be
> able to with dbus?).
> 
> Of course, that has the issue of "what if the activated dbus service
> was already running from other means before dbus service foo tried to
> activate it?"

	Right; I think the simple fix is to make sure that any hacky env
variables gnome-session is currently setting should be set before even
starting D-BUS.

> >     What if the env variables affect the initialization
> >     of some library which has already been initialized? What if the
> >     locale changes and we've already called setlocale() etc. etc.?
>
> Well, a service really wants to acquire a dbus name as early in it's
> lifecycle as possible.  gnome_service_initialize needs to be called
> really early on.  It's a blocking function and--like you've pointed
> out--it changes the environment of the service, so it needs to be
> called before setlocale, before the display gets open, before
> gtk_init, before gnome_program_init, etc...

	So, no localized error messages from libgnomeservice? Or error dialogs?
Or command line options? :-)

Cheers,
Mark.




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