Branch: Tag:

2017-06-30

2017-06-30 12:53:34 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [FSEvents]: Reduce latency.

Reduce FSEvents notification latency by a factor 10.

Also adds some notes about initialization.

830:    int flags = System.FSEvents.kFSEventStreamCreateFlagNone;   #endif    +  // Note: We let the polling system find the initial contents of +  // any pre-existing directories.    eventstream = -  System.FSEvents.EventStream(({}), 1.0, +  System.FSEvents.EventStream(({}), 0.1,    System.FSEvents.kFSEventStreamEventIdSinceNow,    flags);    eventstream->callback_func = eventstream_callback;
890: Inside #if undefined(INHIBIT_EVENTSTREAM_MONITOR)
   // Note: Falling through to ::register_path() below.    // This is needed to handle paths mounted on eg network    // filesystems that are modified on other machines. +  // It is also used to find the initial contents of a monitored directory.    }   #endif /* !INHIBIT_EVENTSTREAM_MONITOR */    ::register_path(initial);