3 ms·
FSEvents is largely just a support infrastructure for Time Machine. Time Machine doesn't need to know about every single change, it just wants to be able to avo
by eridius 8y ago
FSEvents is largely just a support infrastructure for Time Machine. Time Machine doesn't need to know about every single change, it just wants to be able to avoid having to scan the entire disk every time it goes to make a backup. This can be generalized to other backup utilities as well, or really any utility that periodically needs to check the state of the disk against some snapshot of that state. Under these conditions, "something changed in directory /foo/bar/baz" is sufficient because the directory itself can then be scanned.
- tinus_hn 8y agoJust because you don’t know other examples doesn’t mean it only exists for Time Machine. Many other things are interested in changes to the file system, for instance programs that sync a folder to a cloud service, Finder which wants to show a live view of a folder or alternative backup applications. If there was no use for this outside of Apples own apps they wouldn’t have given it a public api.
- eridius 8y agoMany things that are interested in the filesystem would use kqueue instead of FSEvents, as kqueue can give fine-grained event notices as opposed to FSEvents's course-grained "something changed in this folder".
- mkj 8y agoIf you delete a font file from disk programs using it will instantly update - emojis gone from mail.app subject lines instantly! FSEevents in action.
- eridius 8y agoThat's probably kqueue, not FSEvents.