Re: File API: Blob and underlying file changes.

On Wed, Jan 27, 2010 at 5:38 AM, Juan Lanus <juan.lanus@gmail.com> wrote:

> Quite right Bob. But still the lock is the way to go. At least as of today.
>
> HTML5 might be mainstream for the next 10 years, starting rather soon.
>
> In the meanwhile OSs will also evolve, in a way that we can't tell
> now. But if there are common issues, like this one, somebody will come
> up with a smart solution maybe soon.
> For example feeding an image of the file as of the instant it was
> opened (like relational databases do to provide stable queries) by
> keeping a temporary map to the original disk segments that comprised
> the file before it was changed.
> For example Apple is encouraging advisory locks
> http://developer.apple.com/mac/library/technotes/tn/tn2037.html#OSSolutions
> asking developers to design in an environment-aware mood.
>

In my experience, almost no code uses advisory locking unless it is being
explicitly designed for some kind of concurrent usage, i.e., Apple's advice
is not being followed. If that's not going to suddenly change --- and I see
no evidence it will --- then asking the UA to apply a mandatory lock is
asking the UA to do something impossible, which is generally not a good
idea.

Rob
-- 
"He was pierced for our transgressions, he was crushed for our iniquities;
the punishment that brought us peace was upon him, and by his wounds we are
healed. We all, like sheep, have gone astray, each of us has turned to his
own way; and the LORD has laid on him the iniquity of us all." [Isaiah
53:5-6]

Received on Wednesday, 27 January 2010 04:16:59 UTC