Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(506)

Issue 115229: Add support for almost-recursive watches in Linux DirectoryWatcher (Closed)

Created:
11 years, 7 months ago by Paweł Hajdan Jr.
Modified:
9 years, 7 months ago
Reviewers:
Evan Martin
CC:
chromium-reviews_googlegroups.com, j.dinata, Aaron Boodman
Visibility:
Public.

Description

Add support for almost-recursive watches in Linux DirectoryWatcher After this patch DirectoryWatcher when asked for recursive watch will scan the subtree and add inotify watches for each subfolder, but further changes to the tree structure won't trigger adding/removing watches. Support for really recursive watches is planned. This is just to divide the work, because the task is not easy. Based on patch by Janwar Dinata <j.dinata@gmail.com>; reviewed at http://codereview.chromium.org/92151 http://crbug.com/8968 Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=16070

Patch Set 1 #

Total comments: 4

Patch Set 2 : fixes #

Patch Set 3 : fix threading issues #

Patch Set 4 : fix NULL file_thread scenario #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+300 lines, -118 lines) Patch
M AUTHORS View 1 chunk +1 line, -0 lines 0 comments Download
M base/directory_watcher.h View 1 2 4 chunks +10 lines, -5 lines 0 comments Download
M base/directory_watcher_inotify.cc View 1 2 9 chunks +234 lines, -87 lines 0 comments Download
M base/directory_watcher_mac.cc View 2 chunks +2 lines, -1 line 0 comments Download
M base/directory_watcher_stub.cc View 1 chunk +1 line, -1 line 0 comments Download
M base/directory_watcher_unittest.cc View 1 2 14 chunks +28 lines, -21 lines 0 comments Download
M base/directory_watcher_win.cc View 2 chunks +3 lines, -2 lines 0 comments Download
M base/file_util.h View 1 2 2 chunks +6 lines, -0 lines 0 comments Download
M base/file_util_posix.cc View 1 2 1 chunk +10 lines, -0 lines 0 comments Download
M chrome/browser/extensions/user_script_master.cc View 3 2 chunks +5 lines, -1 line 1 comment Download

Messages

Total messages: 10 (0 generated)
Paweł Hajdan Jr.
Evan, please do the final review, and also verify that Janwar Dinata has signed the ...
11 years, 7 months ago (2009-05-12 07:29:25 UTC) #1
Evan Martin
CLA is signed. I'm uncomfortable with how many threads are involved in this. I worry ...
11 years, 7 months ago (2009-05-12 18:27:54 UTC) #2
Paweł Hajdan Jr.
On 2009/05/12 18:27:54, Evan Martin wrote: > CLA is signed. > > I'm uncomfortable with ...
11 years, 7 months ago (2009-05-12 19:15:18 UTC) #3
Evan Martin
Looks good to me (except for the threads bit).
11 years, 7 months ago (2009-05-12 19:42:22 UTC) #4
Evan Martin
+aaron Aaron, Watch() is blocking on Windows, right? Is there a plan to move that ...
11 years, 7 months ago (2009-05-12 19:43:04 UTC) #5
Paweł Hajdan Jr.
This is sort of WIP, because in test code file_thread will be NULL or something. ...
11 years, 7 months ago (2009-05-13 19:12:05 UTC) #6
Evan Martin
Yeah, this looks good. You can either pass in MessageLoop::current() for the extra thread argument, ...
11 years, 7 months ago (2009-05-13 19:15:48 UTC) #7
Paweł Hajdan Jr.
Problem with NULL file_thread fixed, verified on trybot. Please look.
11 years, 7 months ago (2009-05-14 17:33:23 UTC) #8
Evan Martin
LGTM http://codereview.chromium.org/115229/diff/1032/25 File chrome/browser/extensions/user_script_master.cc (right): http://codereview.chromium.org/115229/diff/1032/25#newcode273 Line 273: // TODO(aa): Enable this when DirectoryWatcher is ...
11 years, 7 months ago (2009-05-14 17:48:28 UTC) #9
Paweł Hajdan Jr.
11 years, 7 months ago (2009-05-14 17:51:14 UTC) #10
On 2009/05/14 17:48:28, Evan Martin wrote:
> http://codereview.chromium.org/115229/diff/1032/25#newcode273
> Line 273: // TODO(aa): Enable this when DirectoryWatcher is implemented for
> linux.
> I guess this TODO can be fixed now!  Maybe in a differnt CL if you prefer.

The Linux recursive implementation is incomplete now. The code will now compile
and run, but I'd prefer to wait for complete recursive implementation.

Powered by Google App Engine
This is Rietveld 408576698