You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by zw...@apache.org on 2014/01/27 22:28:12 UTC

[1/2] git commit: TS-2304 Make the healthcheck plugin watch for file permission changes

Updated Branches:
  refs/heads/master 77e2776ba -> dff82e38e


TS-2304 Make the healthcheck plugin watch for file permission changes


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/c952398f
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/c952398f
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/c952398f

Branch: refs/heads/master
Commit: c952398ff733b119337d0406f21e2e32eddd2e4a
Parents: 77e2776
Author: Leif Hedstrom <zw...@apache.org>
Authored: Thu Jan 23 09:10:47 2014 -0700
Committer: Leif Hedstrom <zw...@apache.org>
Committed: Mon Jan 27 14:27:17 2014 -0700

----------------------------------------------------------------------
 plugins/experimental/healthchecks/healthchecks.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/c952398f/plugins/experimental/healthchecks/healthchecks.c
----------------------------------------------------------------------
diff --git a/plugins/experimental/healthchecks/healthchecks.c b/plugins/experimental/healthchecks/healthchecks.c
index bb27505..89ee7a9 100644
--- a/plugins/experimental/healthchecks/healthchecks.c
+++ b/plugins/experimental/healthchecks/healthchecks.c
@@ -153,7 +153,7 @@ setup_watchers(int fd)
   char *dname;
 
   while (conf) {
-    conf->wd = inotify_add_watch(fd, conf->fname, IN_DELETE_SELF|IN_CLOSE_WRITE);
+    conf->wd = inotify_add_watch(fd, conf->fname, IN_DELETE_SELF|IN_CLOSE_WRITE|IN_ATTRIB);
     TSDebug(PLUGIN_NAME, "Setting up a watcher for %s", conf->fname);
     strncpy(fname, conf->fname, MAX_FILENAME_LEN - 1);
     dname = dirname(fname);
@@ -163,7 +163,7 @@ setup_watchers(int fd)
       dir = TSmalloc(sizeof(HCDirEntry));
       memset(dir, 0, sizeof(HCDirEntry));
       strncpy(dir->dname, dname, MAX_FILENAME_LEN - 1);
-      dir->wd = inotify_add_watch(fd, dname, IN_CREATE|IN_MOVED_FROM|IN_MOVED_TO);
+      dir->wd = inotify_add_watch(fd, dname, IN_CREATE|IN_MOVED_FROM|IN_MOVED_TO|IN_ATTRIB);
       if (!head_dir)
         head_dir = dir;
       else
@@ -242,7 +242,7 @@ hc_thread(void *data ATS_UNUSED)
           HCFileData *new_data = TSmalloc(sizeof(HCFileData));
           HCFileData *old_data;
 
-          if (event->mask & (IN_CLOSE_WRITE)) {
+          if (event->mask & (IN_CLOSE_WRITE|IN_ATTRIB)) {
             TSDebug(PLUGIN_NAME, "Modify file event (%d) on %s", event->mask, finfo->fname);
           } else if (event->mask & (IN_CREATE|IN_MOVED_TO)) {
             TSDebug(PLUGIN_NAME, "Create file event (%d) on %s", event->mask, finfo->fname);


[2/2] git commit: Added TS-2304 to CHANGES.

Posted by zw...@apache.org.
Added TS-2304 to CHANGES.


Project: http://git-wip-us.apache.org/repos/asf/trafficserver/repo
Commit: http://git-wip-us.apache.org/repos/asf/trafficserver/commit/dff82e38
Tree: http://git-wip-us.apache.org/repos/asf/trafficserver/tree/dff82e38
Diff: http://git-wip-us.apache.org/repos/asf/trafficserver/diff/dff82e38

Branch: refs/heads/master
Commit: dff82e38e409be1e785e091ef8d83ff66f6e4c1f
Parents: c952398
Author: Leif Hedstrom <zw...@apache.org>
Authored: Mon Jan 27 14:27:49 2014 -0700
Committer: Leif Hedstrom <zw...@apache.org>
Committed: Mon Jan 27 14:27:49 2014 -0700

----------------------------------------------------------------------
 CHANGES | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/trafficserver/blob/dff82e38/CHANGES
----------------------------------------------------------------------
diff --git a/CHANGES b/CHANGES
index d2cce2d..f1802a4 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,6 +1,8 @@
                                                          -*- coding: utf-8 -*-
 Changes with Apache Traffic Server 4.2.0
 
+  *) [TS-2304] Make the healthcheck plugin watch for file permission changes.
+
   *) [TS-2519] Make build version metrics non-persistent.
 
   *) [TS-1606] Log buffers are not flushed periodically when TS is launched