|
|
Subscribe / Log in / New account

Go filesystems and file embedding

Go filesystems and file embedding

Posted Jul 31, 2020 9:14 UTC (Fri) by benhoyt (subscriber, #138463)
In reply to: Go filesystems and file embedding by Cyberax
Parent article: Go filesystems and file embedding

By cancellation in this context, do you mean timeouts/deadlines? Or actually being able to cancel a read/write at any given time? If it's timeouts, does it work to specify a read/write timeout when you open the filesystem client (or Open() a file), rather than for example having a ctx/timeout on every Read call? Similar to what Russ Cox asks here: https://www.reddit.com/r/golang/comments/hv976o/qa_iofs_d...


to post comments

Go filesystems and file embedding

Posted Jul 31, 2020 14:28 UTC (Fri) by ibukanov (subscriber, #3942) [Link]

By cancelable in my initial response I meant ability to interrupt a given blocked call so it returns immediately. Timeouts are a subset of that.

What would be ideal if FileHandle can be used as a pseudo-channel in the select statements in Go. But that requires very non-trivial implementation especially on Linux.


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds