From 4c467aedfa539acad2632a959695ec77cb6de56c Mon Sep 17 00:00:00 2001 From: John Date: Sun, 16 Sep 2018 12:46:56 +0800 Subject: [PATCH] =?UTF-8?q?gfsnotify/gfcache=E8=B0=83=E8=AF=95=E4=BF=A1?= =?UTF-8?q?=E6=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- g/os/gfcache/gfcache_cache.go | 1 + g/os/gfsnotify/gfsnotify.go | 1 + 2 files changed, 2 insertions(+) diff --git a/g/os/gfcache/gfcache_cache.go b/g/os/gfcache/gfcache_cache.go index 28cd50d99..c59fcc307 100644 --- a/g/os/gfcache/gfcache_cache.go +++ b/g/os/gfcache/gfcache_cache.go @@ -54,6 +54,7 @@ func (c *Cache) addMonitor(path string) { return } c.notify.Add(path, func(event *gfsnotify.Event) { + //glog.Debug("gfcache:", event) r := c.cache.Get(path).([]byte) // 是否删除 if event.IsRemove() { diff --git a/g/os/gfsnotify/gfsnotify.go b/g/os/gfsnotify/gfsnotify.go index 7f6fb89e0..9b27d2abf 100644 --- a/g/os/gfsnotify/gfsnotify.go +++ b/g/os/gfsnotify/gfsnotify.go @@ -162,6 +162,7 @@ func (w *Watcher) startWatchLoop() { // 监听事件 case ev := <- w.watcher.Events: + //glog.Debug("gfsnotify:", ev) w.events.Push(&Event{ Path : ev.Name, Op : Op(ev.Op),