Branch: Tag:

2019-05-04

2019-05-04 09:12:19 by Arne Goedeke <el@laramies.com>

Merge remote-tracking branch 'origin/master' into new_utf8

2019-04-21

2019-04-21 11:04:28 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Protect lfuns.

2019-03-19

2019-03-19 12:33:55 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Merge commit '722771973bd' into patches/lyslyskom22891031

* commit '722771973bd': (6177 commits)
Verify that callablep responses are aligned with reality.
...

2019-03-14

2019-03-14 10:39:03 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Merge commit '2470270f500c728d10b8895314d8d8b07016e37b' into grubba/typechecker-automap

* commit '2470270f500c728d10b8895314d8d8b07016e37b': (18681 commits)
Removed the old typechecker.
...

2018-11-04

2018-11-04 16:11:11 by Arne Goedeke <el@laramies.com>

Merge remote-tracking branch 'origin/master' into new_utf8

2018-11-03

2018-11-03 14:21:37 by Marcus Comstedt <marcus@mc.pp.se>

Merge remote-tracking branch 'origin/8.1' into gobject-introspection

2018-06-29

2018-06-29 09:39:10 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Merge branch 'patches/pike116' into 8.1

* patches/pike116:
Filesystem.Monitor: Fix NULL-dereference in bump().

2018-06-29 09:37:39 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Merge branch 'patches/pike116' into 8.0

* patches/pike116:
Filesystem.Monitor: Fix NULL-dereference in bump().

2018-06-29 09:33:50 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fix NULL-dereference in bump().

Survive st being zero in bump().

Fixes [PIKE-116].

2018-04-05

2018-04-05 15:17:30 by Stefan Wallström <stewa@lysator.liu.se>

Filesystem.Monitor: Fixed trace message

2018-04-05 14:55:02 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor.basic: Fixed typo in debug message.

2018-04-05 13:03:50 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Add set_stable_time() function.

2018-04-05 13:02:42 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Fix race condition on file deletion.

This fixes a race that could occur on rapid exists => delete => exists
transitions, where the directory monitor never noticed the change but the
sub monitor was removed from the monitor lookup mapping. The directory
monitor is now notified on sub-monitor release.

2018-04-05 13:02:33 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor/inotify: Fix incorrect creation of new monitors.

Monitors were created using monitor() on the top level rather than using
Monitor::monitor(), which prevented the symlinks' overridden DefaultMonitor
from setting the correct state on newly created monitors.

We now force a check on the directory monitor instead, which will pick up the
new file instantly and create the sub monitor.

2018-04-05 13:00:32 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Add set_stable_time() function.

2018-04-05 12:57:21 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Fix race condition on file deletion.

This fixes a race that could occur on rapid exists => delete => exists
transitions, where the directory monitor never noticed the change but the
sub monitor was removed from the monitor lookup mapping. The directory
monitor is now notified on sub-monitor release.

2018-04-05 12:53:01 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor/inotify: Fix incorrect creation of new monitors.

Monitors were created using monitor() on the top level rather than using
Monitor::monitor(), which prevented the symlinks' overridden DefaultMonitor
from setting the correct state on newly created monitors.

We now force a check on the directory monitor instead, which will pick up the
new file instantly and create the sub monitor.

2018-03-28

2018-03-28 12:39:09 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Only multiply by file_interval_factor when path isn't a dir for sure.

Previously monitors on non-existing paths could get very long poll intervals, which
led to unexpected effects in Inotify mode, where the scan time typically is high but
Inotify isn't able to watch the non-existing path.

2018-03-28 12:34:37 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Only multiply by file_interval_factor when path isn't a dir for sure.

Previously monitors on non-existing paths could get very long poll intervals, which
led to unexpected effects in Inotify mode, where the scan time typically is high but
Inotify isn't able to watch the non-existing path.

2018-03-22

2018-03-22 14:44:05 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Revert "Filesystem.Monitor: don't auto monitor paths that don't exist."

This reverts commit d36e37245cbcb4b57d3e70b406b8415226a667da.

2018-03-22 14:43:10 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Revert "Filesystem.Monitor: don't auto monitor paths that don't exist."

This reverts commit a23b99eaeac4369f23689cea204b1aa7edf57835.

2018-03-21

2018-03-21 19:19:30 by Bill Welliver <bill@welliver.org>

Filesystem.Monitor: don't auto monitor paths that don't exist.

This should mitigate a race condition with inotify causing short lived
directory monitors to remain indefinitely.

2018-03-21 16:35:00 by Bill Welliver <bill@welliver.org>

Filesystem.Monitor: don't auto monitor paths that don't exist.

This should mitigate a race condition with inotify causing short lived
directory monitors to remain indefinitely.

2018-02-15

2018-02-15 15:54:26 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Merge commit '75c9d1806f1a69ca21c27a2c2fe1b4a6ea38e77e' into patches/pike63

* commit '75c9d1806f1a69ca21c27a2c2fe1b4a6ea38e77e': (19587 commits)
...

2018-02-07

2018-02-07 16:28:29 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Reschedule backend_check after register_path.

If the newly registered monitor ends up at the head of the monitor_queue,
the backend_check() call_out likely needs to be rescheduled.

Fixes [PIKE-65].

2018-02-07 16:28:18 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fix rescheduling by adjust_monitor().

adjust_monitor() didn't reschedule the backend_check() call_out
if the adjusted monitor already was at the head of monitor_queue.
This caused polls to be delayed in some common cases.

Fixes [PIKE-64].

2018-02-07 16:28:06 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Clean up rescheduling of backend_check().

2018-02-07 16:27:52 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Remove co_id == 1 special case.

The special case is no longer used as it was broken, so there's
no need to keep the code around.

2018-02-07 16:23:39 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Reschedule backend_check after register_path.

If the newly registered monitor ends up at the head of the monitor_queue,
the backend_check() call_out likely needs to be rescheduled.

Fixes [PIKE-65].

2018-02-07 16:21:06 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fix rescheduling by adjust_monitor().

adjust_monitor() didn't reschedule the backend_check() call_out
if the adjusted monitor already was at the head of monitor_queue.
This caused polls to be delayed in some common cases.

Fixes [PIKE-64].

2018-02-07 16:20:14 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Clean up rescheduling of backend_check().

2018-02-07 16:10:56 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Remove co_id == 1 special case.

The special case is no longer used as it was broken, so there's
no need to keep the code around.

2017-12-31

2017-12-31 23:19:10 by Peter Bortas <bortas@gmail.com>

Merge remote-tracking branch 'origin/8.1' into peter/travis

2017-12-18

2017-12-18 10:09:17 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Documentation [Filesystem.Monitor]: Some clarifications.

2017-11-05

2017-11-05 15:53:18 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Merge branch 'grubba/rename_lfun_destroy' into 8.1

* grubba/rename_lfun_destroy:
Modules: Fixed logts of warnings.
Testsuite: Updated for LFUN::_destruct().
Compiler: Don't complain about LFUN::destroy() in compat mode.
Fix multiple warnings.
Runtime: LFUN::destroy() has been renamed to _destruct().
Compiler: Rename LFUN::destroy() to LFUN::_destruct().

2017-11-05 15:49:10 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Modules: Fixed logts of warnings.

More fall out from the LFUN::destroy ==> LFUN::_destruct rename.

2017-10-11

2017-10-11 10:07:28 by Karl Gustav Sterneberg <kg@roxen.com>

Fixed a null pointer exception.

2017-10-11 10:04:43 by Karl Gustav Sterneberg <kg@roxen.com>

Fixed a null pointer exception.

2017-10-06

2017-10-06 12:51:49 by Karl Gustav Sterneberg <kg@roxen.com>

Fixed bug in Monitor->update().

When checking if class was initialized code looked at the variable
"next_pol", this behaviour caused a bug if a subclass set "next_pol" to
0. This resulted in poll every second.

2017-10-06 12:51:49 by Karl Gustav Sterneberg <kg@roxen.com>

Removed trailing spaces.

2017-10-06 12:50:35 by Karl Gustav Sterneberg <kg@roxen.com>

Fixed bug in Monitor->update().

When checking if class was initialized code looked at the variable
"next_pol", this behaviour caused a bug if a subclass set "next_pol" to
0. This resulted in poll every second.

2017-07-19

2017-07-19 10:33:18 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Survive transient files.

Automatically created monitors for paths that are deleted before the
monitor has initialized are now removed instead of being kept until
the next time the path is created and deleted.

Fixes infinite loops on directory deletion some more.

2017-07-19 10:29:27 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Survive transient files.

Automatically created monitors for paths that are deleted before the
monitor has initialized are now removed instead of being kept until
the next time the path is created and deleted.

Fixes infinite loops on directory deletion some more.

2017-07-19 10:28:26 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Fixed infinite loop.

Creating new monitors for deleted files or directories is not a good idea...

Fixes testsuite failures on Linux.

2017-07-19 10:23:15 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Fixed infinite loop.

Creating new monitors for deleted files or directories is not a good idea...

Fixes testsuite failures on Linux.

2017-07-18

2017-07-18 12:50:35 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Added report().

This provides an API to simplify targeting tracing of the
Filesystem.Monitor operation.

Fixes [PIKE-17].

2017-07-18 12:49:04 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Added report().

This provides an API to simplify targeting tracing of the
Filesystem.Monitor operation.

Fixes [PIKE-17].

2017-07-17

2017-07-17 09:27:14 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [InotifyMonitor]: Improved handling of race.

Handle the case where Inotify notifies about a file that has been
deleted and then resurrected without its parent directory having
been updated in the interval. This is apparently an operation
characteristic of the MacOS X Finder.

Improves notification times for the above case.

Fixes [PIKE-16].

2017-07-17 09:12:40 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [InotifyMonitor]: Improved handling of race.

Handle the case where Inotify notifies about a file that has been
deleted and then resurrected without its parent directory having
been updated in the interval. This is apparently an operation
characteristic of the MacOS X Finder.

Improves notification times for the above case.

Fixes [PIKE-16].

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.

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

Filesystem.Monitor: Reduce initialization latency.

2017-06-30 10:21:45 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Reduce initialization latency.

2017-06-29

2017-06-29 09:59:51 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed symlink issue with Inotify.

2017-06-29 09:59:22 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed symlink issue with Inotify.

2017-06-27

2017-06-27 11:59:22 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved diagnostics.

Fixes some double messages with FILESYSTEM_MONITOR_DEBUG.

2017-06-27 11:59:13 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Removed some obsolete code.

2017-06-27 11:59:03 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved robustness in adjust_monitor().

When using acceleration, adjust_monitor() may get called with
monitors not on the monitor queue (typically due to deletions,
and both polled and accelerated checks).

Fixes [Pike-15#comment=89-766]/[LysLysKOM 22120285].

2017-06-27 11:58:53 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed some typos.

2017-06-27 11:58:35 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved polling heuristic in update().

2017-06-27 11:56:02 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Reschedule the poll earlier on demand.

Don't wait for the full old poll interval if we know that we need
to check earlier than it expires.

Reduces poll (and notification) delays in some circumstances.

2017-06-27 11:55:48 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Scan accelerated monitors too.

Both the Inotify and FSEvents APIs claim that they support
notifications on eg network file systems, and while they will
succeed in notifying on changes performed by the local host
on such file systems, they will not on changes performed by
other hosts. To avoid missing such changes such monitors
need to be actively scanned too.

Fixes [Pike-15].

2017-06-27 11:55:34 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Removed some dead and obsolete code.

This disabled code was intended to support separate backends
with EventStreamMonitor, but was broken and recently rendered
obsolete by proper support.

2017-06-27 09:33:09 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved diagnostics.

Fixes some double messages with FILESYSTEM_MONITOR_DEBUG.

2017-06-22

2017-06-22 09:50:55 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Removed some obsolete code.

2017-06-22 09:45:58 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved robustness in adjust_monitor().

When using acceleration, adjust_monitor() may get called with
monitors not on the monitor queue (typically due to deletions,
and both polled and accelerated checks).

Fixes [Pike-15#comment=89-766]/[LysLysKOM 22120285].

2017-06-21

2017-06-21 10:15:26 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed some typos.

2017-06-21 10:12:36 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved polling heuristic in update().

2017-06-21 10:03:29 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Reschedule the poll earlier on demand.

Don't wait for the full old poll interval if we know that we need
to check earlier than it expires.

Reduces poll (and notification) delays in some circumstances.

2017-06-21 09:50:39 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Scan accelerated monitors too.

Both the Inotify and FSEvents APIs claim that they support
notifications on eg network file systems, and while they will
succeed in notifying on changes performed by the local host
on such file systems, they will not on changes performed by
other hosts. To avoid missing such changes such monitors
need to be actively scanned too.

Fixes [Pike-15].

2017-06-21 09:43:50 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Removed some dead and obsolete code.

This disabled code was intended to support separate backends
with EventStreamMonitor, but was broken and recently rendered
obsolete by proper support.

2017-06-14

2017-06-14 13:51:36 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Fix EventStreamMonitor to work with other backends.

2017-06-14 13:49:54 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Fix EventStreamMonitor to work with other backends.

2016-05-17

2016-05-17 14:53:55 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Potential fix for [bug 7684].

Avoid recursive mutex locks from destroy() by only locking
on explicit destruct().

2016-05-17 14:53:01 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Potential fix for [bug 7684].

Avoid recursive mutex locks from destroy() by only locking
on explicit destruct().

2016-05-11

2016-05-11 10:55:48 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed typo in FILESYSTEM_MONITOR_DEBUG.

2016-05-11 10:54:56 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed typo in FILESYSTEM_MONITOR_DEBUG.

2016-05-10

2016-05-10 16:26:32 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Don't propagate all errors.

Errors thrown by check() on deletion could cause other deletion
notifications to be lost, as the errors were rethrown before
the rest of the notifications were handled.

Those errors are now instead sent directly to the master.

2016-05-10 16:26:27 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved FILESYSTEM_MONITOR_DEBUG diagnostics.

2016-05-10 16:26:20 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filexyxtem.Monitor: Got rid of update_monitor().

The function didn't work, and if it had worked it would've messed
with the internal state of monitors and caused stuff to break.

2016-05-10 16:26:15 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved error handling somewhat.

Errors were hidden in some cases.

2016-05-10 15:22:18 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Don't propagate all errors.

Errors thrown by check() on deletion could cause other deletion
notifications to be lost, as the errors were rethrown before
the rest of the notifications were handled.

Those errors are now instead sent directly to the master.

2016-05-10 15:21:20 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved FILESYSTEM_MONITOR_DEBUG diagnostics.

2016-05-10 15:00:56 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filexyxtem.Monitor: Got rid of update_monitor().

The function didn't work, and if it had worked it would've messed
with the internal state of monitors and caused stuff to break.

2016-05-10 14:58:39 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved error handling somewhat.

Errors were hidden in some cases.

2016-04-29

2016-04-29 14:37:53 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Inotify: Simulate events for directory content at watch creation.

This reduces the race window for tracking directory content.
It also simplifies code that does such tracking.

Also updates Filesystem.Monitor.basic accordingly.

2016-03-18

2016-03-18 15:35:47 by 0

Better filtering of directory paths before instantiating a monitor from a
subdirectory. This likely fixes a backtrace seen in check_monitor() where
the caller assumed a new monitor object was created. Also harden
check_monitor() from such invalid dereferencing.

2016-03-18 15:30:13 by 0

Better filtering of directory paths before instantiating a monitor from a
subdirectory. This likely fixes a backtrace seen in check_monitor() where
the caller assumed a new monitor object was created. Also harden
check_monitor() from such invalid dereferencing.

2016-03-18 12:45:12 by 0

Reporting of deleted subdirectories failed for accelerated monitors since
adjust_monitor() for submonitors was a no-op. We now check them immediately.

2016-03-18 12:45:08 by 0

Fix bit flags logic error.

2016-03-18 12:19:14 by 0

Reporting of deleted subdirectories failed for accelerated monitors since
adjust_monitor() for submonitors was a no-op. We now check them immediately.

2016-03-18 12:19:14 by 0

Fix bit flags logic error.

2016-03-17

2016-03-17 21:05:40 by 0

Need to register EventStream-accelerated monitors in register_path() before
calling check() since that may trigger callbacks to code which expects to find
all monitors there. (Same thing was already done in the Inotify class.)

2016-03-17 20:55:02 by 0

Need to register EventStream-accelerated monitors in register_path() before
calling check() since that may trigger callbacks to code which expects to find
all monitors there. (Same thing was already done in the Inotify class.)

2016-03-08

2016-03-08 17:20:08 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Inotify: Simulate events for directory content at watch creation.

This reduces the race window for tracking directory content.
It also simplifies code that does such tracking.

Also updates Filesystem.Monitor.basic accordingly.

2016-03-07

2016-03-07 22:07:37 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed handling of delayed delete notification.

2016-03-07 22:06:04 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed handling of delayed delete notification.

2016-03-07 18:18:53 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fix stable_data_change() for accellerated monitors.

The stable_data_change() notification was lost with the accellerated
monitors if it was on a preexisting file that was younger than the
stable time.

This adds a paranoia call_out loop to avoid losing track of the event.

2016-03-07 18:13:42 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fix stable_data_change() for accellerated monitors.

The stable_data_change() notification was lost with the accellerated
monitors if it was on a preexisting file that was younger than the
stable time.

This adds a paranoia call_out loop to avoid losing track of the event.

2016-02-15

2016-02-15 14:08:51 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved thread safety.

ADT.Heap is NOT thread-safe (especially not pop()), so use
a Thread.Mutex to control access to the monitor_queue.

Potential fix for [bug 7644] (where the top element becomes zero
instead of an ADT.Heap()->Element).

2016-02-15 14:08:22 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved thread safety.

ADT.Heap is NOT thread-safe (especially not pop()), so use
a Thread.Mutex to control access to the monitor_queue.

Potential fix for [bug 7644] (where the top element becomes zero
instead of an ADT.Heap()->Element).

2016-02-10

2016-02-10 10:38:03 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Don't attempt inotify on nonexisting paths.

Inotify will always fail if the monitored path doesn't exist.

Fixes complaint about attempting to monitor nonexistent paths.

2016-02-10 10:37:29 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Don't attempt inotify on nonexisting paths.

Inotify will always fail if the monitored path doesn't exist.

Fixes complaint about attempting to monitor nonexistent paths.

2016-02-09

2016-02-09 13:16:30 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved robustness.

It seems ADT.Heap()->peek() sometimes can index the NULL value
(cf [bug 7644]). The most likely cause is that the last element
of the heap was removed by a different thread during the call.
Inhibit propagation of the error to the caller.

Work around for [bug 7644].

2016-02-09 13:11:28 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved robustness.

It seems ADT.Heap()->peek() sometimes can index the NULL value
(cf [bug 7644]). The most likely cause is that the last element
of the heap was removed by a different thread during the call.
Inhibit propagation of the error to the caller.

Work around for [bug 7644].

2016-02-08

2016-02-08 15:32:14 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Improved support for symlinked directories.

Directories reached via symlinks need to be monitored too...

2016-02-08 15:30:22 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Improved support for symlinked directories.

Directories reached via symlinks need to be monitored too...

2016-02-08 13:21:52 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Reduce the number of complaints.

The inotify kernel subsystem has a maximum number of concurrent
watchpoints (controlled via /proc/sys/fs/inotify/max_user_watches).
With the default at just 8192 it is not hard to run out of watchpoints,
at which point the subsystem will start to complain.

With this change only every ~100th failure of this type will be logged
to stderr.

2016-02-08 13:15:12 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Reduce the number of complaints.

The inotify kernel subsystem has a maximum number of concurrent
watchpoints (controlled via /proc/sys/fs/inotify/max_user_watches).
With the default at just 8192 it is not hard to run out of watchpoints,
at which point the subsystem will start to complain.

With this change only every ~100th failure of this type will be logged
to stderr.

2016-02-08 13:13:38 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Always monitor explicitly added paths.

Fixes issue with symlinked root directories not being monitored.

2016-02-08 13:11:23 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Always monitor explicitly added paths.

Fixes issue with symlinked root directories not being monitored.

2016-02-05

2016-02-05 15:01:48 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Don't reinstate deleted MF_AUTO.

In some circumstances an already removed MF_AUTO InotifyMonitor could be
reinstated when the monitor was switched to polling mode.

2016-02-05 15:01:32 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Don't reinstate deleted MF_AUTO.

In some circumstances an already removed MF_AUTO InotifyMonitor could be
reinstated when the monitor was switched to polling mode.

2015-12-10

2015-12-10 15:09:15 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Always perform EventStream operations from the backend thread.

Paths added from a non-backend thread would not trigger any events, because
only the backend thread monitors its CFRunLoop event stuff.

2015-12-10 15:08:57 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Always perform EventStream operations from the backend thread.

Paths added from a non-backend thread would not trigger any events, because
only the backend thread monitors its CFRunLoop event stuff.

2015-11-19

2015-11-19 13:18:38 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Check newly registered EventStream monitors.

Fixes a bug where monitors weren't registered recursively until parent monitors
were notified for the first time.

2015-11-19 13:18:26 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Check newly registered EventStream monitors.

Fixes a bug where monitors weren't registered recursively until parent monitors
were notified for the first time.

2015-10-21

2015-10-21 08:34:30 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Let inotify monitors fallback to poll if file doesn't exist.

2015-10-21 08:34:17 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Let inotify monitors fallback to poll if file doesn't exist.

2015-10-20

2015-10-20 11:42:20 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Avoid double notifications on changed files.

We'll now avoid registering monitors on individual files and instead
expand the path of notified files on the callback. This will also reduce
the number of watchers in directory trees with many more files than dirs.
Also: notify stable_data_change instantly on IN_CLOSE_WRITE events.

2015-10-20 11:39:53 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Avoid double notifications on changed files.

We'll now avoid registering monitors on individual files and instead
expand the path of notified files on the callback. This will also reduce
the number of watchers in directory trees with many more files than dirs.
Also: notify stable_data_change instantly on IN_CLOSE_WRITE events.

2015-10-16

2015-10-16 14:22:50 by Martin Karlgren <marty@roxen.com>

Filesytem.Monitor: Enable file-level notification for FSEvents.

2015-10-16 14:22:50 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Reduce FSEvents coalescing window to 1 second.

2015-10-16 14:22:09 by Martin Karlgren <marty@roxen.com>

Filesytem.Monitor: Enable file-level notification for FSEvents.

2015-10-16 14:22:09 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Reduce FSEvents coalescing window to 1 second.

2015-10-15

2015-10-15 13:35:44 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Destruct monitors explicitly.

2015-10-15 13:35:39 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Avoid backtrace in canonic_path when path doesn't exist.

2015-10-15 13:34:39 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Destruct monitors explicitly.

2015-10-15 13:33:57 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Avoid backtrace in canonic_path when path doesn't exist.

2015-10-11

2015-10-11 14:04:24 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Merge branch '8.1' into grubba/typechecker-mk3

* 8.1: (51 commits)
Compiler [Types]: Got rid of my_describe_type().
Compiler [Types]: Fixed wide strings in nested types.
Compiler [Types]: low_describe_type() now uses string_builder.
string_builder_sprintf: Fixed '+' for floats.
string_builder_sprintf: Added support for %T.
Calendar.mkrules: Improved backward compat.
Auth.OAuth.Client: Fixed AutoDoc markup issue.
New modules for communicating with different (RESTful) web apis (including OAuth and OAuth2 client modules) .
Documentation [%]: Added some clarifications and improved markup.
Inotify: Minor code cleanup. Potential fix for [CID 1325796].
Inotify: Removed some debug output.
Filesystem.Monitor [Inotify]: Improved support for blocking mode.
Inotify: Don't reference count immediate circular references.
Inotify: Removed some dead code.
System.Inotify, Filesystem.Monitor: Updates to use new Inotify API.
Inotify: Use fd_callback_boxes, internal event parsing.
Search.Database.MySQL: Censor the SQL-url.
Sql: Added censor_sql_url().
Search.Database.MySQL: Avoid long lived database connections.
Inotify: Don't throw errors in rm_watch() on invalid watch descriptor.
...

2015-10-08

2015-10-08 10:01:35 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Improved support for blocking mode.

check() now also checks any InotifyMonitors.

2015-10-08 09:59:17 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Improved support for blocking mode.

check() now also checks any InotifyMonitors.

2015-10-07

2015-10-07 15:43:07 by Henrik Grubbström (Grubba) <grubba@grubba.org>

System.Inotify, Filesystem.Monitor: Updates to use new Inotify API.

System.Inotify.Instance now inherits _Instance directly. This
simplifies the code and caused some functions to become redundant.

Filesystem.Monitor now has some support for Inotify in blocking mode.

2015-10-07 15:38:12 by Henrik Grubbström (Grubba) <grubba@grubba.org>

System.Inotify, Filesystem.Monitor: Updates to use new Inotify API.

System.Inotify.Instance now inherits _Instance directly. This
simplifies the code and caused some functions to become redundant.

Filesystem.Monitor now has some support for Inotify in blocking mode.

2015-10-06

2015-10-06 15:22:12 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved robustness.

check_all() now survives check() throwing errors.

Also updates the comments about Inotify and its automatic invalidation
of watch descriptors.

2015-10-06 15:21:40 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Use the watchdescriptor to look up the monitor.

The path in an inotify event is usually just a single path segment,
and can typically not be used to look up the corresponding monitor.

This reduces the number of cases where a full monitor scan is performed
to negligible.

Also adds some handling of the IN_IGNORED event, which indicates that
a watchdescriptor has become invalid.

2015-10-06 15:20:49 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [FSEvents]: Make sure that check() doesn't terminate early.

As FSEvents only notifies on directories, and we don't have accellerated
monitors in the monitor_queue, we need to ensure that the monitors one
level down are also notified.

Also adds some (dead) placeholder code for handling switching of the
backend in the FSEvents case.

2015-10-06 15:20:38 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [FSEvents]: Added INHIBIT_EVENTSTREAM_MONITOR.

This #define turns of FSEvents accelleration.

2015-10-06 15:20:25 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [FSEvents]: Make sure that stable_data_change() works.

Also adds some more MON_WERR().

2015-10-06 15:20:15 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [FSEvents]: Ensure that the backend is in CF-mode.

Also disables use of FSEvents when other backends than the primary
(Pike.DefaultBackend) are in use.

2015-10-06 15:17:27 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved robustness.

check_all() now survives check() throwing errors.

Also updates the comments about Inotify and its automatic invalidation
of watch descriptors.

2015-10-06 15:11:04 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Use the watchdescriptor to look up the monitor.

The path in an inotify event is usually just a single path segment,
and can typically not be used to look up the corresponding monitor.

This reduces the number of cases where a full monitor scan is performed
to negligible.

Also adds some handling of the IN_IGNORED event, which indicates that
a watchdescriptor has become invalid.

2015-10-06 15:05:57 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [FSEvents]: Make sure that check() doesn't terminate early.

As FSEvents only notifies on directories, and we don't have accellerated
monitors in the monitor_queue, we need to ensure that the monitors one
level down are also notified.

Also adds some (dead) placeholder code for handling switching of the
backend in the FSEvents case.

2015-10-06 15:03:37 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [FSEvents]: Added INHIBIT_EVENTSTREAM_MONITOR.

This #define turns of FSEvents accelleration.

2015-10-06 15:01:47 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [FSEvents]: Make sure that stable_data_change() works.

Also adds some more MON_WERR().

2015-10-06 14:58:14 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [FSEvents]: Ensure that the backend is in CF-mode.

Also disables use of FSEvents when other backends than the primary
(Pike.DefaultBackend) are in use.

2015-10-05

2015-10-05 13:51:44 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Improved robustness.

rm_watch() often complains about unknown descriptors, even though
they seem to be correct (Linux 3.17.2). Add a work-around.

2015-10-05 13:48:55 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Improved robustness.

rm_watch() often complains about unknown descriptors, even though
they seem to be correct (Linux 3.17.2). Add a work-around.

2015-10-05 13:29:50 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Added DefaultMonitor.

This class alias simplifies other code by reducing the need for
preprocessor checks.

2015-10-05 13:29:40 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Added INHIBIT_INOTIFY_MONITOR.

This #define turns off Inotify accelleration.

2015-10-05 13:29:19 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Fixed initialization.

Inotify seems not to notify on preexisting paths, so help it along.

2015-10-05 13:28:40 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Fixed calling of stable_data_change().

The calling of stable_data_change() got lost when accellerated paths
were removed from the polling heap.

2015-10-05 13:26:31 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed call of unregister_path().

LFUN::destroy() was in the wrong class, and the logic
was inverted in unregister_path().

Also adds FILESYSTEM_MONITOR_DEBUG and MON_WERR().

2015-10-05 13:23:05 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Added DefaultMonitor.

This class alias simplifies other code by reducing the need for
preprocessor checks.

2015-10-05 13:23:04 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Fixed calling of stable_data_change().

The calling of stable_data_change() got lost when accellerated paths
were removed from the polling heap.

2015-10-05 12:57:21 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Added INHIBIT_INOTIFY_MONITOR.

This #define turns off Inotify accelleration.

2015-10-05 12:55:31 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Fixed initialization.

Inotify seems not to notify on preexisting paths, so help it along.

2015-10-05 12:53:23 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Fixed calling of stable_data_change().

The calling of stable_data_change() got lost when accellerated paths
were removed from the polling heap.

2015-10-05 12:49:58 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed call of unregister_path().

LFUN::destroy() was in the wrong class, and the logic
was inverted in unregister_path().

Also adds FILESYSTEM_MONITOR_DEBUG and MON_WERR().

2015-10-02

2015-10-02 13:48:05 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Don't filter paths with ".."...

Using Filesystem.Monitor with a relative path is common.

2015-10-02 13:44:48 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Don't filter paths with ".."...

Using Filesystem.Monitor with a relative path is common.

2015-10-02 11:34:01 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed some issues in the Inotify case.

Fixes [bug 7570].

2015-10-02 11:32:10 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fixed some issues in the Inotify case.

Fixes [bug 7570].

2015-09-18

2015-09-18 14:49:55 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: API fix for EventStreamMonitor()->check().

2015-09-18 14:48:54 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: API fix for EventStreamMonitor()->check().

2015-09-18 14:47:50 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Refactored the accellerated filesystem monitors.

This is to improve compatibility with older code, and to support
extending the monitor system to monitor virtual files (like eg
http URLs), and also to reduce the complexity of the code.

Also fixes issue with Inotify not supporting monitoring of
non-existing paths.

2015-09-18 14:44:05 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Survive an empty monitor_queue in check().

Preparation for only having polled monitors in the monitor_queue.

Currently monitors and monitor_queue always have the same size,
but with filesystem event systems there's no need to poll the
event monitored files by hand, so leave the monitor queue for
the paths that the event system doesn't support.

2015-09-18 14:43:59 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved robustness in release().

2015-09-18 14:43:53 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: set_backend() now knows about Inotify.

2015-09-18 14:43:47 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Use ADT.Heap()->remove().

2015-09-18 14:43:41 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Added adjust_monitor().

2015-09-18 14:43:35 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Fixed indentation.

2015-09-18 14:43:29 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Added check_all().

2015-09-18 13:48:30 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Refactored the accellerated filesystem monitors.

This is to improve compatibility with older code, and to support
extending the monitor system to monitor virtual files (like eg
http URLs), and also to reduce the complexity of the code.

Also fixes issue with Inotify not supporting monitoring of
non-existing paths.

2015-09-18 12:16:48 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Survive an empty monitor_queue in check().

Preparation for only having polled monitors in the monitor_queue.

Currently monitors and monitor_queue always have the same size,
but with filesystem event systems there's no need to poll the
event monitored files by hand, so leave the monitor queue for
the paths that the event system doesn't support.

2015-09-18 12:12:39 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Improved robustness in release().

2015-09-18 12:09:20 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: set_backend() now knows about Inotify.

2015-09-18 11:28:34 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Use ADT.Heap()->remove().

2015-09-18 10:13:35 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Added adjust_monitor().

2015-09-18 10:02:52 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor [Inotify]: Fixed indentation.

2015-09-18 10:00:36 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Added check_all().

2015-09-17

2015-09-17 12:14:48 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Add explanatory comment.

2015-09-17 12:14:47 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Import files marked as stable immediately.

2015-09-10

2015-09-10 13:45:26 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Use the new ADT.Heap adjust() API.

Improve performance by using the new ADT.Heap adjust() API.

2015-09-10 13:38:54 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Use the new ADT.Heap adjust() API.

Improve performance by using the new ADT.Heap adjust() API.

2015-05-26

2015-05-26 10:33:42 by Martin Nilsson <nilsson@opera.com>

Removed trailing spaces.

2015-05-25

2015-05-25 14:58:57 by Martin Nilsson <nilsson@opera.com>

Normalized file ends.

2015-02-09

2015-02-09 10:07:41 by Martin Karlgren <marty@roxen.com>

Filesystem.Monitor: Add way to treat files as immediately stable.

2014-10-05

2014-10-05 21:49:40 by Martin Nilsson <nilsson@opera.com>

Removed some old compat code.

2014-10-05 18:20:48 by Martin Nilsson <nilsson@opera.com>

Removed some useless version checks. Only relevant if you would moce the code to an older Pike binary.

2014-09-30

2014-09-30 16:20:55 by Martin Nilsson <nilsson@opera.com>

this_program:: -> this::

2014-08-15

2014-08-15 20:21:17 by Martin Nilsson <nilsson@opera.com>

Less zero_type.

2014-03-01

2014-03-01 07:17:31 by Bill Welliver <bill@welliver.org>

Filesystem.Monitor: generate data change events properly when using FSEvents.

2014-02-28

2014-02-28 19:27:37 by Bill Welliver <bill@welliver.org>

Filesystem.Monitor: some documentation cleanup.

2014-01-05

2014-01-05 15:14:13 by Marcus Comstedt <marcus@mc.pp.se>

Merge branch '8.0' into gobject-introspection

2013-07-12

2013-07-12 15:57:13 by 0

Limit stat frequency directly after stable change by adjusting constants in
update(). Also apply the file scaling factor at a more appropriate place.

2013-07-12 15:56:16 by 0

Always recompute next_poll after updating last_change.

2013-07-12 15:55:43 by 0

Change semantics of bump() to accept a time relative to now instead of a time
relative to next scheduled scan, and provide a better heuristics when no value
is provided. This new behavior is much more relevant in practical use, and the
method was only used internally as far as I know. Added refdoc.

2013-07-05

2013-07-05 17:07:13 by 0

Fix logic error in stable state for directories. This bug caused unmodified
directories to be listed over and over again.

2013-06-21

2013-06-21 09:18:55 by Arne Goedeke <el@laramies.com>

Merge remote-tracking branch 'origin/7.9' into pdf

2013-04-11

2013-04-11 10:53:49 by Arne Goedeke <el@laramies.com>

Filesystem.Monitor.basic: fixed references to Inotify module

2013-04-05

2013-04-05 02:46:54 by Bill Welliver <bill@welliver.org>

Filesystem.Monitor: enable Inotify and FSEvents, if present.

2013-02-25

2013-02-25 13:58:12 by Arne Goedeke <el@laramies.com>

System.Inotify: use files.Fd() objects instead of file descriptors

2012-10-28

2012-10-28 15:40:20 by Marcus Comstedt <marcus@mc.pp.se>

Merge branch '7.9' into gobject-introspection

2012-10-24

2012-10-24 12:37:04 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fix race-condition when monitoring directories.

There was an over-caching issue in the directory monitors for
the following case (everything happend during the same second):

1) A new directory is created.

2) The monitor detects that the directory was created, and checks
its contents -- empty.

3) Some files are added to the directory.

When the monitor returned to check the directory a bit later, it
saw that the mtime was unchanged (since everything above happened
during the same second), so it didn't bother to check the contents.

Now the directory contents are rescanned anyway as long as the
directory hasn't been marked stable.

Also removed some priority bumping in check() that was already
performed properly by status_change().

Fixes [bug 6577] and possibly also some of [bug 6534].

2012-10-06

2012-10-06 11:38:03 by Marcus Comstedt <marcus@mc.pp.se>

Merge branch '7.9' into gobject-introspection

2012-07-18

2012-07-18 12:56:57 by Arne Goedeke <el@laramies.com>

Merge branch '7.9' into block_alloc

Conflicts:
src/modules/system/configure.in
src/post_modules/CritBit/tree_low.c
src/post_modules/CritBit/tree_low.h
src/post_modules/CritBit/tree_source.H

2012-07-04

2012-07-04 19:17:22 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: call_out mode now has some chance at working again.

2012-07-04 12:24:36 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Call stable_data_change() in more cases.

Files that were newer than stable_time at monitor initialization time
were never signaled as stable.

2012-07-04 12:22:50 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Filesystem.Monitor: Fix race-condition when a path is deleted and recreated.

A MF_RECURSE|MF_AUTO monitor for a deleted and then recreated path
could get lost if the parent directory monitor wasn't updated before
the path was recreated.

Also makes sure to call filter_file() with a consistent argument.

2012-07-01

2012-07-01 22:05:19 by Arne Goedeke <el@laramies.com>

Merge remote branch 'origin/7.9' into block_alloc

2012-06-30

2012-06-30 04:19:17 by Bill Welliver <bill@welliver.org>

Filesystem.Monitor: use System.FSEvents or System.Inotify to provide low overhead
change notification.

NOTE: I originally envisioned something much more elegant, however when I started
down that path, I quickly realized that I don't really understand how the Monitor really
works. This code appears to work properly, however someone who understands it better
should probably take a closer look.

Feel free to use this as a guide for what needs to be done when solving the problem properly.

2011-11-05

2011-11-05 15:15:24 by Martin Nilsson <nilsson@opera.com>

Added #pike directives.

2011-11-05 15:02:44 by Martin Nilsson <nilsson@opera.com>

Removed $Id$.

2011-04-25

2011-04-25 16:41:40 by Martin Stjernholm <mast@lysator.liu.se>

No more foreign_idents.

More pain than they are worth.

2011-01-19

2011-01-19 15:54:50 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Merge branch 'pike-modules/monitor/5.0' into 7.9

This is the Filesystem.Monitor stuff from Roxen CMS 5.0/5.1.

2010-07-15

2010-07-15 09:03:32 by Jonas Wallden <jonasw@roxen.com>

Don't consider ctime when comparing stat. (Backport from 5.0.)

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.34

2010-07-14

2010-07-14 14:11:08 by Jonas Wallden <jonasw@roxen.com>

Disable ctime detection as a workaround for [bug 5587].

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.39

2010-04-27

2010-04-27 16:05:49 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Backported lots of fixes from FeedImport 5.0.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.33
Rev: lib/modules/Filesystem.pmod/Monitor.pmod/symlinks.pike:1.4

2010-04-27 15:00:54 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added Monitor::bump().
Avoid excessive immediate scanning on recursion by using bump().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.38

2010-04-27 14:58:11 by Henrik Grubbström (Grubba) <grubba@grubba.org>

status_change() needs one more argument to avoid excessive recursion.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.37
Rev: lib/modules/Filesystem.pmod/Monitor.pmod/symlinks.pike:1.9

2010-02-03

2010-02-03 15:24:48 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed issue with propagation of symlink ids for newly monitored directories.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.32
Rev: lib/modules/Filesystem.pmod/Monitor.pmod/symlinks.pike:1.2

2010-02-03 15:24:41 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed issue with propagation of symlink ids for newly monitored directories.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.36
Rev: lib/modules/Filesystem.pmod/Monitor.pmod/debug.pike:1.3
Rev: lib/modules/Filesystem.pmod/Monitor.pmod/symlinks.pike:1.7

2010-02-03 14:06:18 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Backported lots of changes and fixes from FeedImport 5.0:

Added trampolines for calling the callback functions to the Monitor class, to allow for more flexible extension.
Separated out the status change analysis code from Monitor::check() to the new function Monitor::status_change().
Decreased the backoff speed from 1/16 to 1/256.
This means that files need to be older than max_dir_check_interval * file_interval_factor * 256 seconds before they will be polled at the maximum interval.
ie with the defaults this will be for files older than 60*5*256 seconds = 1280 minutes ~ 21 hours.
Improved robustness against files being replaced with directories or vice versa or similar.
Fixed bug regarding stability of deleted files.
Added check_for_release().
Added MF_HARD to keep track of monitors that have hard links from other monitors.

basic.pike is now on level with revision 1.35 from FeedImport 5.0.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.31

2010-02-02

2010-02-02 14:34:47 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added check_for_release().
Added MF_HARD to keep track of monitors that have hard links from other monitors.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.35

2010-02-01

2010-02-01 14:36:18 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed bug regarding stability of deleted files.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.34

2010-01-28

2010-01-28 15:15:01 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Improved robustness against files being replaced with directories or vice versa or similar.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.33

2010-01-28 14:19:52 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Decreased the backoff speed from 1/16 to 1/256.
This means that files need to be older than max_dir_check_interval * file_interval_factor * 256 seconds before they will be polled at the maximum interval.
ie with the defaults this will be for files older than 60*5*256 seconds = 1280 minutes ~ 21 hours.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.32

2010-01-28 14:06:45 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added trampolines for calling the callback functions to the Monitor class, to allow for more flexible extension.
Separated out the status change analysis code from Monitor::check() to the new function Monitor::status_change().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.31

2009-10-22

2009-10-22 15:45:01 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed bug in set_nonblocking().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.30

2009-10-22 15:45:01 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed bug in set_nonblocking().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.30

2009-10-20

2009-10-20 14:33:26 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed notification issue with created directories.
More paranoid indexing of the monitors mapping.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.29

2009-10-20 14:33:26 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed notification issue with created directories.
More paranoid indexing of the monitors mapping.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.29

2009-10-19

2009-10-19 14:23:45 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed notification issue with deleted directories.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.28

2009-10-19 14:23:45 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed notification issue with deleted directories.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.28

2009-10-13

2009-10-13 12:39:20 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed issue where check() only loocked at a single monitor.
Improved robustness against directories without read permission.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.27

2009-10-13 12:39:20 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed issue where check() only loocked at a single monitor.
Improved robustness against directories without read permission.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.27

2009-10-12

2009-10-12 15:00:11 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Improved documentation and logging.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.26

2009-10-12 14:59:53 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Improved documentation and logging.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.26

2009-09-21

2009-09-21 11:23:17 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Improved doc for is_monitored().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.25

2009-09-21 11:15:36 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added is_monitored().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.24

2009-08-11

2009-08-11 09:51:14 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Improved compat with older pikes.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.23

2009-08-07

2009-08-07 12:46:48 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed typo.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.22

2009-08-06

2009-08-06 11:53:01 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added support for limiting the number of paths to check in a single call of check().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.21

2009-08-05

2009-08-05 13:06:15 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Improved polling heuristics for polling interval on systems with unreliable mtime and ctime.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.20

2009-08-04

2009-08-04 10:51:33 by Henrik Grubbström (Grubba) <grubba@grubba.org>

check() now returns the number of seconds to the next call of check().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.19

2009-07-22

2009-07-22 15:37:40 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added canonic_path().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.18

2009-07-22 15:08:28 by Henrik Grubbström (Grubba) <grubba@grubba.org>

More object-oriented approach.

Moved implementation of update_monitor() and check_monitor() to the Monitor object.
Added monitor_factory().
The above two in combination simplifies implementation of custom monitors.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.17

2009-07-17

2009-07-17 16:44:33 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added set_{max_dir_check_interval,file_interval_factor}().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.16

2009-07-17 16:03:50 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed typo.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.15

2009-07-17 16:00:20 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Attempt to schedule polls evenly at startup.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.14

2009-07-17 15:56:50 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Removed Monitor()->`==(), since it might affect search() as used by ADT.Heap()->adjust().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.13

2009-07-17 15:34:31 by Jonas Wallden <jonasw@roxen.com>

Add missing fallback to default values. /grubba

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.12

2009-07-17 13:58:13 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Bugfix for newly added directories.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.11

2009-07-16

2009-07-16 14:14:20 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Autodoc mk II update.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.10

2009-07-16 14:13:44 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added support for monitor-specific overrides for stable_time.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.9

2009-07-15

2009-07-15 16:28:52 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Cleaned up the check() code somewhat.
Added some more Autodoc mk II markup.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.8

2009-07-15 16:11:44 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Minor change of the heuristics in update_monitor().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.7

2009-07-15 13:07:08 by Henrik Grubbström (Grubba) <grubba@grubba.org>

stable_data_change() now gets a Stdio.Stat as the second parameter.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.6

2009-07-14

2009-07-14 16:33:49 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added optional flags argument to check_monitor().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.5

2009-07-14 16:14:07 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Fixed bug when calling monitor() for an existing monitor.
monitor() and release_monitor() now canonicalize the path.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.4

2009-07-13

2009-07-13 12:40:30 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added callback file_exists().
Datastructure initialization is now delayed to the next call of check().
This means that all filesystem operations are now done via check().

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.3

2009-07-13 09:08:19 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added some more Autodoc mk II markup.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.2

2009-07-13 08:55:30 by Henrik Grubbström (Grubba) <grubba@grubba.org>

First version.

Rev: lib/modules/Filesystem.pmod/Monitor.pmod/basic.pike:1.1
Rev: lib/modules/Filesystem.pmod/Monitor.pmod/debug.pike:1.1