[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gentoo-dev
Subject:    Re: [gentoo-dev] has_version etc parallelisability
From:       Ciaran McCreesh <ciaran.mccreesh () blueyonder ! co ! uk>
Date:       2007-12-31 14:28:44
Message-ID: 20071231142844.5e2a09aa () snowcone
[Download RAW message or body]

On Sun, 30 Dec 2007 20:11:16 -0800
"Alec Warner" <antarus@gentoo.org> wrote:
> On 12/30/07, Ciaran McCreesh <ciaran.mccreesh@blueyonder.co.uk> wrote:
> > Is it legal for ebuilds to call has_version and friends in
> > parallel? Is it legal for ebuilds to call has_version and friends
> > after the ebuild process has terminated? Discuss.
> 
> If the pm implements read/write locking on the underlying datastore
> (which it should probably have regardless of this request) then I
> don't see a problem in parallel has_version calls.

Actually, it's the communication channel that's the issue... If, for
example, has_version is implemented in terms of a request on a pipe
rather than execing a new package manager, we get into messy bash
locking territory...

> I don't get your second example..do you mean the ebuild is running
> has_version in the background and then terminating?

Yeah. Again, consider the pipe example. If the package manager closes
off the pipe when it thinks the ebuild's done, calling has_version will
get the backgrounded process SIGPIPEd.

-- 
Ciaran McCreesh

["signature.asc" (application/pgp-signature)]
-- 
gentoo-dev@gentoo.org mailing list


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic