[tahoe-lafs-trac-stream] [tahoe-lafs] #1425: blacklist support

tahoe-lafs trac at tahoe-lafs.org
Wed Aug 3 20:30:06 PDT 2011


#1425: blacklist support
-----------------------------------+--------------------
     Reporter:  warner             |      Owner:  warner
         Type:  enhancement        |     Status:  new
     Priority:  major              |  Milestone:  1.9.0
    Component:  code-frontend-web  |    Version:  1.8.2
   Resolution:                     |   Keywords:
Launchpad Bug:                     |
-----------------------------------+--------------------

Comment (by zooko):

 If a request happens at the same time as the access.blacklist file is
 being rewritten, the request may reread an incomplete copy of the file.
 (The process that rewrites access.blacklist could avoid this by writing
 the new file and then moving it into place, but the patch doesn't document
 that this is necessary, and also it won't work on Windows.)

 If you use
 [http://twistedmatrix.com/documents/current/api/twisted.python.filepath.FilePath.html#setContent
 FilePath.setContent] then your code can be simple while having this
 behavior. In addition, on Windows it will write to a new file, delete the
 old file, move the new file into place. That should, if I understand
 correctly, guarantee that an uncoordinated reader will see one of (old
 file, new file, no file).

-- 
Ticket URL: <http://tahoe-lafs.org/trac/tahoe-lafs/ticket/1425#comment:6>
tahoe-lafs <http://tahoe-lafs.org>
secure decentralized storage


More information about the tahoe-lafs-trac-stream mailing list