Skip to content

Please add polling #8

@Andrei-Stepanov

Description

@Andrei-Stepanov

Hello,

Problematic code is:

that.watcher = that.fs.watch(that.dirPaths[NEW], {}, function(err, messages) {

      that.watcher = that.fs.watch(that.dirPaths[NEW], {}, function(err, messages) {
        that.emit('new', [messages]);
      });

This code doesn't work for NFS3.

http://docs.libuv.org/en/v1.x/fs_event.html

    UV_FS_EVENT_WATCH_ENTRY = 1,
    /*
    * By default uv_fs_event will try to use a kernel interface such as inotify
    * or kqueue to detect events. This may not work on remote file systems such
    * as NFS mounts. This flag makes fs_event fall back to calling stat() on a
    * regular interval.
    * This flag is currently not implemented yet on any backend.
    */

Please, add polling: say for each 30-60 seconds fs.readdir -> if files are present emit 'new' event.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions