Preparing report...

Report for github.com/tsaikd/gogstash

A+    Excellent!    Found 23 issues across 117 files

Tweet

gofmt97%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command


go_vet100%

go vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.

No problems detected. Good job!


gocyclo94%

Gocyclo calculates cyclomatic complexities of functions in Go source code. The cyclomatic complexity of a function is calculated according to the following rules: 1 is the base complexity of a function +1 for each 'if', 'for', 'case', '&&' or '||' Go Report Card warns on functions with cyclomatic complexity > 15.


golint92%

Golint is a linter for Go source code.

    • gogstash/input/file/sincedb.go
    • Line 15: warning: exported type SinceDBInfo should have comment or be unexported (golint)
    • Line 19: warning: exported method InputConfig.LoadSinceDBInfos should have comment or be unexported (golint)
    • Line 19: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
    • Line 49: warning: exported method InputConfig.SaveSinceDBInfos should have comment or be unexported (golint)
    • Line 49: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
    • Line 75: warning: exported method InputConfig.CheckSaveSinceDBInfos should have comment or be unexported (golint)
    • Line 91: warning: exported method InputConfig.CheckSaveSinceDBInfosLoop should have comment or be unexported (golint)
    • gogstash/input/http/inputhttp.go
    • Line 83: warning: exported method InputConfig.Request should have comment or be unexported (golint)
    • Line 103: warning: exported method InputConfig.SendRequest should have comment or be unexported (golint)
    • gogstash/input/dockerlog/sincefile.go
    • Line 12: warning: exported function NewSinceFile should have comment or be unexported (golint)
    • Line 18: warning: exported type SinceFile should have comment or be unexported (golint)
    • Line 23: warning: exported method SinceFile.Open should have comment or be unexported (golint)
    • Line 43: warning: exported method SinceFile.Close should have comment or be unexported (golint)
    • gogstash/input/dockerlog/sincedb.go
    • Line 12: warning: exported function NewSinceDB should have comment or be unexported (golint)
    • Line 18: warning: exported type SinceDB should have comment or be unexported (golint)
    • Line 23: warning: exported method SinceDB.Open should have comment or be unexported (golint)
    • Line 52: warning: exported method SinceDB.Close should have comment or be unexported (golint)
    • Line 64: warning: exported method SinceDB.Get should have comment or be unexported (golint)
    • Line 77: warning: exported method SinceDB.Del should have comment or be unexported (golint)
    • gogstash/config/logevent/logevent.go
    • Line 14: warning: exported type LogEvent should have comment or be unexported (golint)
    • Line 21: warning: exported type Config should have comment or be unexported (golint)
    • Line 129: warning: exported method LogEvent.MarshalJSON should have comment or be unexported (golint)
    • Line 134: warning: exported method LogEvent.MarshalIndent should have comment or be unexported (golint)
    • Line 139: warning: exported method LogEvent.Get should have comment or be unexported (golint)
    • Line 153: warning: exported method LogEvent.GetString should have comment or be unexported (golint)
    • Line 171: warning: exported method LogEvent.GetValue should have comment or be unexported (golint)
    • Line 175: warning: exported method LogEvent.SetValue should have comment or be unexported (golint)
    • Line 188: warning: exported method LogEvent.Remove should have comment or be unexported (golint)
    • gogstash/input/exec/MsgType.go
    • Line 9: warning: exported type MsgType should have comment or be unexported (golint)
    • Line 12: warning: exported const MsgTypeText should have comment (or a comment on this block) or be unexported (golint)
    • Line 25: warning: exported method MsgType.MarshalJSON should have comment or be unexported (golint)
    • Line 29: warning: exported method MsgType.UnmarshalJSON should have comment or be unexported (golint)
    • Line 33: warning: exported method MsgType.Scan should have comment or be unexported (golint)
    • Line 37: warning: exported method MsgType.Value should have comment or be unexported (golint)
    • Line 41: warning: exported function IsMsgType should have comment or be unexported (golint)
    • Line 45: warning: exported function ParseMsgType should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign98%

IneffAssign detects ineffectual assignments in Go code.


misspell94%

Misspell Finds commonly misspelled English words

    • gogstash/output/file/outputfile_test.go
    • Line 149: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 197: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 246: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 296: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 356: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 412: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 465: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 516: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 562: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 609: warning: "happends" is a misspelling of "happens" (misspell)
    • Line 656: warning: "happends" is a misspelling of "happens" (misspell)