From 7733662b5aa9d880286ba35d0aa0ee8cf5987172 Mon Sep 17 00:00:00 2001 From: Jamie Wilkinson Date: Sat, 3 Mar 2018 14:23:58 +1100 Subject: [PATCH] Downgrade some log messages that were left over from debugging. Issue #143. --- tailer/tail.go | 4 ++-- vm/loader.go | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tailer/tail.go b/tailer/tail.go index d19cfb01f..d4d9dcf68 100644 --- a/tailer/tail.go +++ b/tailer/tail.go @@ -201,7 +201,7 @@ func (t *Tailer) handleTruncate(f afero.File) error { return err } - glog.Infof("File size is %d", fi.Size()) + glog.V(2).Infof("File size is %d", fi.Size()) if currentOffset == 0 || fi.Size() >= currentOffset { return fmt.Errorf("no truncate appears to have occurred") } @@ -227,7 +227,7 @@ func (t *Tailer) read(f afero.File, partial *bytes.Buffer) error { glog.V(2).Info("Suspected truncation.") // If there was nothing to be read, perhaps the file just got truncated. herr := t.handleTruncate(f) - glog.Infof("handletrunc with error '%v'", herr) + glog.V(2).Infof("handletrunc with error '%v'", herr) if herr == nil { // Try again: offset was greater than filesize and now we've seeked to start. continue diff --git a/vm/loader.go b/vm/loader.go index 0453c820d..33d9422df 100644 --- a/vm/loader.go +++ b/vm/loader.go @@ -90,11 +90,11 @@ func (l *Loader) LoadAllPrograms() error { func (l *Loader) LoadProgram(programPath string) error { name := filepath.Base(programPath) if strings.HasPrefix(name, ".") { - glog.Infof("Skipping %s because it is a hidden file.", programPath) + glog.V(2).Infof("Skipping %s because it is a hidden file.", programPath) return nil } if filepath.Ext(name) != fileExt { - glog.Infof("Skipping %s due to file extension.", programPath) + glog.V(2).Infof("Skipping %s due to file extension.", programPath) return nil } f, err := l.fs.Open(programPath)