Preparing report...

Report for github.com/apid/apid-core

A+    Excellent!    Found 16 issues across 29 files

Tweet

gofmt100%

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

No problems detected. Good job!


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!


gocyclo96%

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.


golint48%

Golint is a linter for Go source code.

    • apid-core/logger/logger.go
    • Line 27: warning: exported const ConfigLevel should have comment (or a comment on this block) or be unexported (golint)
    • Line 42: warning: exported function Base should have comment or be unexported (golint)
    • Line 53: warning: exported function ForModule should have comment or be unexported (golint)
    • Line 83: warning: exported function NewLogger should have comment or be unexported (golint)
    • apid-core/api_service.go
    • Line 19: warning: exported type APIService should have comment or be unexported (golint)
    • Line 29: warning: exported type Route should have comment or be unexported (golint)
    • Line 33: warning: comment on exported type Router should be of the form "Router ..." (with optional leading article) (golint)
    • apid-core/cipher/cipher.go
    • Line 1: warning: package comment should be of the form "Package cipher ..." (golint)
    • Line 22: warning: exported type Mode should have comment or be unexported (golint)
    • Line 23: warning: exported type Padding should have comment or be unexported (golint)
    • Line 26: warning: exported const ModeEcb should have comment (or a comment on this block) or be unexported (golint)
    • Line 30: warning: exported const PaddingPKCS7 should have comment (or a comment on this block) or be unexported (golint)
    • Line 71: warning: comment on exported function CreateAesCipher should be of the form "CreateAesCipher ..." (golint)
    • Line 81: warning: comment on exported type AesCipher should be of the form "AesCipher ..." (with optional leading article) (golint)
    • Line 154: warning: exported type ErrModeUnsupported should have comment or be unexported (golint)
    • Line 162: warning: exported type ErrPaddingUnsupported should have comment or be unexported (golint)
    • apid-core/config/config.go
    • Line 43: warning: exported type ConfigMgr should have comment or be unexported (golint)
    • Line 51: warning: exported method ConfigMgr.SetDefault should have comment or be unexported (golint)
    • Line 57: warning: exported method ConfigMgr.Set should have comment or be unexported (golint)
    • Line 63: warning: exported method ConfigMgr.Get should have comment or be unexported (golint)
    • Line 70: warning: exported method ConfigMgr.GetBool should have comment or be unexported (golint)
    • Line 77: warning: exported method ConfigMgr.GetFloat64 should have comment or be unexported (golint)
    • Line 84: warning: exported method ConfigMgr.GetInt should have comment or be unexported (golint)
    • Line 91: warning: exported method ConfigMgr.GetString should have comment or be unexported (golint)
    • Line 98: warning: exported method ConfigMgr.GetDuration should have comment or be unexported (golint)
    • Line 105: warning: exported method ConfigMgr.IsSet should have comment or be unexported (golint)
    • Line 121: warning: exported function GetConfig should have comment or be unexported (golint)
    • apid-core/util/util.go
    • Line 24: warning: exported const ConfigfwdProxyPortURL should have comment or be unexported (golint)
    • Line 26: warning: exported function IsValidUUID should have comment or be unexported (golint)
    • Line 31: warning: exported function GenerateUUID should have comment or be unexported (golint)
    • Line 35: warning: comment on exported function Transport should be of the form "Transport ..." (golint)
    • Line 50: warning: comment on exported function DistributeEvents should be of the form "DistributeEvents ..." (golint)
    • Line 79: warning: comment on exported function LongPolling should be of the form "LongPolling ..." (golint)
    • Line 94: warning: comment on exported function Debounce should be of the form "Debounce ..." (golint)
    • apid-core/data_service.go
    • Line 23: warning: exported type DataService should have comment or be unexported (golint)
    • Line 36: warning: exported type DB should have comment or be unexported (golint)
    • Line 53: warning: exported type Tx should have comment or be unexported (golint)
    • apid-core/events_service.go
    • Line 17: warning: exported type EventSelector should have comment or be unexported (golint)
    • Line 19: warning: exported type Event should have comment or be unexported (golint)
    • Line 21: warning: exported type EventHandler should have comment or be unexported (golint)
    • Line 25: warning: exported type EventHandlerFunc should have comment or be unexported (golint)
    • Line 27: warning: exported type EventsService should have comment or be unexported (golint)
    • Line 52: warning: exported const EventDeliveredSelector should have comment or be unexported (golint)
    • Line 54: warning: exported type EventDeliveryEvent should have comment or be unexported (golint)
    • Line 61: warning: comment on exported type PluginsInitializedEvent should be of the form "PluginsInitializedEvent ..." (with optional leading article) (golint)
    • Line 69: warning: exported type PluginData should have comment or be unexported (golint)
    • apid-core/api/api.go
    • Line 36: warning: exported const ConfigDBMaxConns should have comment (or a comment on this block) or be unexported (golint)
    • Line 48: warning: exported function CreateService should have comment or be unexported (golint)
    • apid-core/apid.go
    • Line 25: warning: exported const SystemEventsSelector should have comment (or a comment on this block) or be unexported (golint)
    • Line 36: warning: exported var APIDInitializedEvent should have comment or be unexported (golint)
    • Line 44: warning: exported type Services should have comment or be unexported (golint)
    • Line 69: warning: exported type PluginInitFunc should have comment or be unexported (golint)
    • Line 74: warning: exported function Initialize should have comment or be unexported (golint)
    • Line 94: warning: exported function RegisterPlugin should have comment or be unexported (golint)
    • Line 99: warning: exported function InitializePlugins should have comment or be unexported (golint)
    • Line 118: warning: comment on exported function ShutdownPluginsAndWait should be of the form "ShutdownPluginsAndWait ..." (golint)
    • Line 136: warning: exported function AllServices should have comment or be unexported (golint)
    • Line 140: warning: exported function Log should have comment or be unexported (golint)
    • Line 144: warning: exported function API should have comment or be unexported (golint)
    • Line 148: warning: exported function Config should have comment or be unexported (golint)
    • Line 152: warning: exported function Data should have comment or be unexported (golint)
    • Line 156: warning: exported function Events should have comment or be unexported (golint)
    • Line 192: warning: exported type ShutdownEvent should have comment or be unexported (golint)
    • apid-core/data/data.go
    • Line 58: warning: exported type ApidDb should have comment or be unexported (golint)
    • Line 63: warning: exported method ApidDb.Ping should have comment or be unexported (golint)
    • Line 67: warning: exported method ApidDb.SetMaxIdleConns should have comment or be unexported (golint)
    • Line 71: warning: exported method ApidDb.SetMaxOpenConns should have comment or be unexported (golint)
    • Line 75: warning: exported method ApidDb.SetConnMaxLifetime should have comment or be unexported (golint)
    • Line 79: warning: exported method ApidDb.Prepare should have comment or be unexported (golint)
    • Line 83: warning: exported method ApidDb.Exec should have comment or be unexported (golint)
    • Line 87: warning: exported method ApidDb.Query should have comment or be unexported (golint)
    • Line 91: warning: exported method ApidDb.QueryRow should have comment or be unexported (golint)
    • Line 95: warning: exported method ApidDb.QueryStructs should have comment or be unexported (golint)
    • Line 105: warning: exported method ApidDb.Begin should have comment or be unexported (golint)
    • Line 118: warning: exported method ApidDb.Stats should have comment or be unexported (golint)
    • Line 122: warning: exported type Tx should have comment or be unexported (golint)
    • Line 128: warning: exported method Tx.Commit should have comment or be unexported (golint)
    • Line 135: warning: exported method Tx.Exec should have comment or be unexported (golint)
    • Line 138: warning: exported method Tx.ExecContext should have comment or be unexported (golint)
    • Line 141: warning: exported method Tx.Prepare should have comment or be unexported (golint)
    • Line 144: warning: exported method Tx.PrepareContext should have comment or be unexported (golint)
    • Line 147: warning: exported method Tx.Query should have comment or be unexported (golint)
    • Line 150: warning: exported method Tx.QueryContext should have comment or be unexported (golint)
    • Line 153: warning: exported method Tx.QueryRow should have comment or be unexported (golint)
    • Line 156: warning: exported method Tx.QueryRowContext should have comment or be unexported (golint)
    • Line 159: warning: exported method Tx.Rollback should have comment or be unexported (golint)
    • Line 166: warning: exported method Tx.Stmt should have comment or be unexported (golint)
    • Line 169: warning: exported method Tx.StmtContext should have comment or be unexported (golint)
    • Line 173: warning: exported method Tx.QueryStructs should have comment or be unexported (golint)
    • Line 183: warning: exported function CreateDataService should have comment or be unexported (golint)
    • Line 342: warning: exported function Delete should have comment or be unexported (golint)
    • Line 357: warning: exported function VersionedDBID should have comment or be unexported (golint)
    • Line 361: warning: exported function DBPath should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign96%

IneffAssign detects ineffectual assignments in Go code.


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!