[squeak-dev] The Trunk: Files-tpr.156.mcz

Chris Muller asqueaker at gmail.com
Tue May 24 20:49:29 UTC 2016


A little research suggests #sync is a blocking operation, whereas
#flush is non-blocking.

So I should probably change Magma's atomic-writing to use #sync..


On Tue, May 24, 2016 at 2:45 PM, tim Rowledge <tim at rowledge.org> wrote:
>
>> On 24-05-2016, at 12:32 PM, Chris Muller <asqueaker at gmail.com> wrote:
>>
>> Since I'm not a systems programmer, I wasn't really following the
>> other discussion.  But this does interest me since Magma employs a
>> complex logging / playback mechanism which does depend on the idea
>> that returning from #flush assures all my puts on that Filestreams are
>> truly written to the disk.
>>
>> Should I be using #sync, instead of #flush?  Could you succinctly
>> summarize the difference between the two for a lay-person like myself?
>
> My level of understanding of this is roughly that flush is spelt f-l-u-s-h and sync is spelt s-y-n-c. I don’t understand why a system would ever let things get so out of sync that you would ever need to think of it. When you close a file it seems to me that everything should be cleaned up.
>
>
> tim
> --
> tim Rowledge; tim at rowledge.org; http://www.rowledge.org/tim
> Useful random insult:- Hypnotized as a child and couldn't be woken.
>
>
>


More information about the Squeak-dev mailing list