Preparing report...

Report for github.com/shima-park/agollo

A    Great!    Found 16 issues across 21 files

Tweet

gofmt76%

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!


golint47%

Golint is a linter for Go source code.

    • agollo/apollo_client_options.go
    • Line 3: warning: exported type ApolloClientOption should have comment or be unexported (golint)
    • Line 5: warning: exported function WithDoer should have comment or be unexported (golint)
    • Line 11: warning: exported function WithIP should have comment or be unexported (golint)
    • Line 17: warning: exported function WithConfigType should have comment or be unexported (golint)
    • Line 23: warning: exported function WithAccessKey should have comment or be unexported (golint)
    • Line 29: warning: exported function WithSignatureFunc should have comment or be unexported (golint)
    • agollo/balancer.go
    • Line 15: warning: exported var ErrNoConfigServerAvailable should have comment or be unexported (golint)
    • Line 18: warning: exported type Balancer should have comment or be unexported (golint)
    • Line 36: warning: exported type GetConfigServersFunc should have comment or be unexported (golint)
    • Line 38: warning: exported function NewAutoFetchBalancer should have comment or be unexported (golint)
    • Line 175: warning: exported function NewRoundRobin should have comment or be unexported (golint)
    • agollo/configurations.go
    • Line 5: warning: exported type Configurations should have comment or be unexported (golint)
    • Line 7: warning: exported method Configurations.Different should have comment or be unexported (golint)
    • agollo/log.go
    • Line 9: warning: exported type Logger should have comment or be unexported (golint)
    • Line 13: warning: exported type LoggerOption should have comment or be unexported (golint)
    • Line 15: warning: exported function LoggerWriter should have comment or be unexported (golint)
    • Line 21: warning: exported function NewLogger should have comment or be unexported (golint)
    • agollo/agollo.go
    • Line 22: warning: exported type Agollo should have comment or be unexported (golint)
    • Line 32: warning: exported type ApolloResponse should have comment or be unexported (golint)
    • Line 40: warning: exported type LongPollerError should have comment or be unexported (golint)
    • Line 70: warning: exported function NewWithConfigFile should have comment or be unexported (golint)
    • Line 102: warning: exported function New should have comment or be unexported (golint)
    • Line 564: warning: exported function Init should have comment or be unexported (golint)
    • Line 569: warning: exported function InitWithConfigFile should have comment or be unexported (golint)
    • Line 574: warning: exported function InitWithDefaultConfigFile should have comment or be unexported (golint)
    • Line 578: warning: exported function Start should have comment or be unexported (golint)
    • Line 582: warning: exported function Stop should have comment or be unexported (golint)
    • Line 586: warning: exported function Get should have comment or be unexported (golint)
    • Line 590: warning: exported function GetNameSpace should have comment or be unexported (golint)
    • Line 594: warning: exported function Watch should have comment or be unexported (golint)
    • Line 598: warning: exported function WatchNamespace should have comment or be unexported (golint)
    • Line 602: warning: exported function GetAgollo should have comment or be unexported (golint)
    • agollo/apollo_client.go
    • Line 24: warning: exported type Doer should have comment or be unexported (golint)
    • Line 36: warning: exported function NewApolloClient should have comment or be unexported (golint)
    • agollo/apollo_client_signature.go
    • Line 12: warning: exported const AUTHORIZATION_FORMAT should have comment (or a comment on this block) or be unexported (golint)
    • Line 18: warning: exported type Header should have comment or be unexported (golint)
    • Line 20: warning: exported type SignatureContext should have comment or be unexported (golint)
    • Line 28: warning: exported type SignatureFunc should have comment or be unexported (golint)
    • Line 30: warning: exported function DefaultSignatureFunc should have comment or be unexported (golint)
    • agollo/change.go
    • Line 3: warning: exported type ChangeType should have comment or be unexported (golint)
    • Line 6: warning: exported const ChangeTypeAdd should have comment (or a comment on this block) or be unexported (golint)
    • Line 11: warning: exported type Change should have comment or be unexported (golint)
    • Line 17: warning: exported type Changes should have comment or be unexported (golint)
    • agollo/options.go
    • Line 18: warning: exported type Options should have comment or be unexported (golint)
    • Line 106: warning: exported type Option should have comment or be unexported (golint)
    • Line 108: warning: exported function Cluster should have comment or be unexported (golint)
    • Line 114: warning: exported function DefaultNamespace should have comment or be unexported (golint)
    • Line 120: warning: exported function PreloadNamespaces should have comment or be unexported (golint)
    • Line 126: warning: exported function WithApolloClient should have comment or be unexported (golint)
    • Line 132: warning: exported function WithLogger should have comment or be unexported (golint)
    • Line 138: warning: exported function AutoFetchOnCacheMiss should have comment or be unexported (golint)
    • Line 144: warning: exported function LongPollerInterval should have comment or be unexported (golint)
    • Line 150: warning: exported function BackupFile should have comment or be unexported (golint)
    • Line 156: warning: exported function FailTolerantOnBackupExists should have comment or be unexported (golint)
    • Line 162: warning: exported function EnableSLB should have comment or be unexported (golint)
    • Line 168: warning: exported function WithBalancer should have comment or be unexported (golint)
    • Line 174: warning: exported function ConfigServerRefreshIntervalInSecond should have comment or be unexported (golint)
    • Line 180: warning: exported function AccessKey should have comment or be unexported (golint)
    • Line 186: warning: exported function WithClientOptions should have comment or be unexported (golint)
    • Line 192: warning: exported type GetOptions should have comment or be unexported (golint)
    • Line 214: warning: exported type GetOption should have comment or be unexported (golint)
    • Line 216: warning: exported function WithDefault should have comment or be unexported (golint)
    • Line 222: warning: exported function WithNamespace should have comment or be unexported (golint)
    • agollo/viper-remote/remote.go
    • Line 17: warning: exported var ErrUnsupportedProvider should have comment or be unexported (golint)
    • Line 38: warning: exported function SetAppID should have comment or be unexported (golint)
    • Line 42: warning: exported function SetConfigType should have comment or be unexported (golint)
    • Line 46: warning: exported function SetAgolloOptions should have comment or be unexported (golint)
    • agollo/apollo.go
    • Line 7: warning: comment on exported type ApolloClient should be of the form "ApolloClient ..." (with optional leading article) (golint)
    • Line 23: warning: exported type Notifications should have comment or be unexported (golint)
    • Line 30: warning: exported type Notification should have comment or be unexported (golint)
    • Line 35: warning: exported type NotificationsOptions should have comment or be unexported (golint)
    • Line 39: warning: exported type NotificationsOption should have comment or be unexported (golint)
    • Line 41: warning: exported function ReleaseKey should have comment or be unexported (golint)
    • Line 47: warning: exported type Config should have comment or be unexported (golint)
    • Line 55: warning: exported type ConfigServer should have comment or be unexported (golint)

gocyclo90%

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.


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!