All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joshua Brindle <jbrindle@tresys.com>
To: Ivan Gyurdiev <ivg2@cornell.edu>
Cc: selinux@tycho.nsa.gov, Stephen Smalley <sds@tycho.nsa.gov>
Subject: Re: [SEPOL] Remove defrole from sepol
Date: Fri, 25 Nov 2005 10:46:09 -0500	[thread overview]
Message-ID: <438731C1.2030408@tresys.com> (raw)
In-Reply-To: <4384EEB2.6000000@cornell.edu>

Ivan Gyurdiev wrote:
>>
>>>
>>> Readers should be inside the transaction to guard against race 
>>> condition. You mentioned commit numbers, and I pointed out I don't 
>>> use them yet - and I don't see how they're a win over using a 
>>> transaction.
>>>
>> Copying the whole store to read a boolean is pretty bad. If the user 
>> (app) intends to make a modification they can start a transaction 
>> before  querying, to ensure consistency but a standard reader should 
>> not need to do this. Why copy a whole directory over to do 2 queries 
>> when genhomedircon can just compare 2 numbers?
> 
> 
> ..because then it has to deal with the failure case of when the two 
> numbers are different. I guess in the general case, maybe the reader 
> doesn't want to handle the failure case, so it makes sense to add commit 
> numbers.
> 
> 
Either way you have to handle failure to obtain the lock. Transaction
locks are more likely to be held longer since they are given up
discretionally, whereas query locks are only held for the duration of
that query.

--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to majordomo@tycho.nsa.gov with
the words "unsubscribe selinux" without quotes as the message.

  reply	other threads:[~2005-11-25 15:46 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-19  5:50 [SEPOL] Remove defrole from sepol Ivan Gyurdiev
2005-11-21 12:37 ` Ivan Gyurdiev
2005-11-23 11:28 ` Ivan Gyurdiev
2005-11-23 15:32 ` Ivan Gyurdiev
2005-11-23 16:38   ` Joshua Brindle
2005-11-23 19:52     ` Ivan Gyurdiev
2005-11-23 19:46       ` Joshua Brindle
2005-11-23 20:22         ` Ivan Gyurdiev
2005-11-23 20:57           ` Ivan Gyurdiev
2005-11-23 21:40             ` Joshua Brindle
2005-11-23 21:58       ` Joshua Brindle
2005-11-23 22:35         ` Ivan Gyurdiev
2005-11-25 15:46           ` Joshua Brindle [this message]
2005-11-28 19:27 ` Stephen Smalley
2005-11-28 21:22   ` Ivan Gyurdiev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=438731C1.2030408@tresys.com \
    --to=jbrindle@tresys.com \
    --cc=ivg2@cornell.edu \
    --cc=sds@tycho.nsa.gov \
    --cc=selinux@tycho.nsa.gov \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.