Preparing report...

Report for gitlab.com/crdc/apex/master

A+    Excellent!    Found 58 issues across 79 files

Tweet

gofmt96%

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!


gocyclo100%

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.

No problems detected. Good job!


golint26%

Golint is a linter for Go source code.

    • /gitlab.com/crdc/apex/master/pkg/loader/module.go
    • Line 14: warning: exported function LoadModule should have comment or be unexported (golint)
    • Line 33: warning: exported function LoadModules should have comment or be unexported (golint)
    • Line 60: warning: exported type ModuleResult should have comment or be unexported (golint)
    • Line 65: warning: exported type ModuleResults should have comment or be unexported (golint)
    • Line 67: warning: exported method ModuleResults.WithoutErrors should have comment or be unexported (golint)
    • Line 82: warning: exported type ModuleLoader should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/pkg/model/module.go
    • Line 4: warning: exported const ModuleStateConnected should have comment (or a comment on this block) or be unexported (golint)
    • Line 14: warning: exported var ModuleState should have comment or be unexported (golint)
    • Line 25: warning: exported type Module should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/pkg/resolver/configuration_mutation.go
    • Line 35: warning: comment on exported function ConvertProperties should be of the form "ConvertProperties ..." (golint)
    • Line 72: warning: exported method Resolver.CreateConfiguration should have comment or be unexported (golint)
    • Line 131: warning: exported method Resolver.UpdateConfiguration should have comment or be unexported (golint)
    • Line 179: warning: exported method Resolver.DeleteConfiguration should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/pkg/handler/auth.go
    • Line 20: warning: exported function Authenticate should have comment or be unexported (golint)
    • Line 42: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 43: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 44: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 49: warning: exported function Login should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/pkg/service/role_service.go
    • Line 13: warning: exported type RoleService should have comment or be unexported (golint)
    • Line 18: warning: exported function NewRoleService should have comment or be unexported (golint)
    • Line 22: warning: exported method RoleService.FindByUserId should have comment or be unexported (golint)
    • Line 39: warning: exported method RoleService.FindByName should have comment or be unexported (golint)
    • Line 56: warning: exported method RoleService.CreateRole should have comment or be unexported (golint)
    • Line 69: warning: exported method RoleService.List should have comment or be unexported (golint)
    • Line 98: warning: exported method RoleService.Count should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/pkg/model/user.go
    • Line 8: warning: exported type User should have comment or be unexported (golint)
    • Line 17: warning: exported method User.HashedPassword should have comment or be unexported (golint)
    • Line 27: warning: exported method User.ComparePassword should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/pkg/service/broker_service.go
    • Line 20: warning: exported type BrokerService should have comment or be unexported (golint)
    • Line 26: warning: exported function NewBrokerService should have comment or be unexported (golint)
    • Line 51: warning: exported method BrokerService.Module should have comment or be unexported (golint)
    • Line 96: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 160: warning: comment on exported method BrokerService.GetModules should be of the form "GetModules ..." (golint)
    • Line 161: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 190: warning: comment on exported method BrokerService.GetModuleConfiguration should be of the form "GetModuleConfiguration ..." (golint)
    • Line 191: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 216: warning: comment on exported method BrokerService.GetModuleStatus should be of the form "GetModuleStatus ..." (golint)
    • Line 218: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 249: warning: comment on exported method BrokerService.GetModuleSettings should be of the form "GetModuleSettings ..." (golint)
    • Line 250: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 276: warning: comment on exported method BrokerService.GetModuleJob should be of the form "GetModuleJob ..." (golint)
    • Line 277: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 297: warning: comment on exported method BrokerService.GetModuleJobs should be of the form "GetModuleJobs ..." (golint)
    • Line 298: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 322: warning: comment on exported method BrokerService.GetModuleActiveJob should be of the form "GetModuleActiveJob ..." (golint)
    • Line 323: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 343: warning: comment on exported method BrokerService.ModuleCancelJob should be of the form "ModuleCancelJob ..." (golint)
    • Line 344: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 367: warning: comment on exported method BrokerService.ModuleSubmitJob should be of the form "ModuleSubmitJob ..." (golint)
    • Line 368: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 393: warning: comment on exported method BrokerService.ModuleSubmitEvent should be of the form "ModuleSubmitEvent ..." (golint)
    • Line 394: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 402: warning: comment on exported method BrokerService.ModuleAvailableEvents should be of the form "ModuleAvailableEvents ..." (golint)
    • Line 403: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 411: warning: comment on exported method BrokerService.GetModuleProperty should be of the form "GetModuleProperty ..." (golint)
    • Line 412: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 436: warning: comment on exported method BrokerService.GetModuleProperties should be of the form "GetModuleProperties ..." (golint)
    • Line 437: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 516: warning: comment on exported method BrokerService.SetModuleProperty should be of the form "SetModuleProperty ..." (golint)
    • Line 517: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • Line 542: warning: comment on exported method BrokerService.SetModuleProperties should be of the form "SetModuleProperties ..." (golint)
    • Line 543: warning: receiver name b should be consistent with previous receiver name s for BrokerService (golint)
    • /gitlab.com/crdc/apex/master/pkg/service/configure_service.go
    • Line 18: warning: exported type ConfigureService should have comment or be unexported (golint)
    • Line 23: warning: exported function NewConfigureService should have comment or be unexported (golint)
    • Line 27: warning: exported method ConfigureService.FindById should have comment or be unexported (golint)
    • Line 59: warning: exported method ConfigureService.List should have comment or be unexported (golint)
    • Line 93: warning: exported method ConfigureService.Count should have comment or be unexported (golint)
    • Line 115: warning: exported method ConfigureService.CreateConfiguration should have comment or be unexported (golint)
    • Line 145: warning: exported method ConfigureService.UpdateConfiguration should have comment or be unexported (golint)
    • Line 181: warning: exported method ConfigureService.DeleteConfiguration should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/cmd/master/main.go
    • Line 77: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 78: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 79: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 80: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 81: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 82: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 83: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • Line 84: warning: should not use basic type untyped string as key in context.WithValue (golint)
    • /gitlab.com/crdc/apex/master/pkg/resolver/module_query.go
    • Line 15: warning: exported method Resolver.Module should have comment or be unexported (golint)
    • Line 31: warning: exported method Resolver.Modules should have comment or be unexported (golint)
    • Line 84: warning: exported method Resolver.ModuleConfiguration should have comment or be unexported (golint)
    • Line 100: warning: exported method Resolver.ModuleStatus should have comment or be unexported (golint)
    • Line 116: warning: exported method Resolver.ModuleSettings should have comment or be unexported (golint)
    • Line 137: warning: exported method Resolver.ModuleJob should have comment or be unexported (golint)
    • Line 154: warning: exported method Resolver.ModuleJobs should have comment or be unexported (golint)
    • Line 178: warning: exported method Resolver.ModuleProperty should have comment or be unexported (golint)
    • Line 196: warning: exported method Resolver.ModuleProperties should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/pkg/service/auth_service.go
    • Line 15: warning: exported type AuthService should have comment or be unexported (golint)
    • Line 22: warning: exported function NewAuthService should have comment or be unexported (golint)
    • Line 26: warning: exported method AuthService.SignJWT should have comment or be unexported (golint)
    • Line 38: warning: exported method AuthService.ValidateJWT should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/pkg/loader/loader.go
    • Line 23: warning: exported type Client should have comment or be unexported (golint)
    • Line 27: warning: comment on exported function NewLoaderCollection should be of the form "NewLoaderCollection ..." (golint)
    • Line 48: warning: comment on exported type LoaderCollection should be of the form "LoaderCollection ..." (with optional leading article) (golint)
    • Line 54: warning: exported method LoaderCollection.Attach should have comment or be unexported (golint)
    • /gitlab.com/crdc/apex/master/pkg/service/user_service.go
    • Line 19: warning: exported type UserService should have comment or be unexported (golint)
    • Line 25: warning: exported function NewUserService should have comment or be unexported (golint)
    • Line 29: warning: exported method UserService.FindByEmail should have comment or be unexported (golint)
    • Line 53: warning: exported method UserService.FindByID should have comment or be unexported (golint)
    • Line 77: warning: exported method UserService.CreateUser should have comment or be unexported (golint)
    • Line 91: warning: exported method UserService.List should have comment or be unexported (golint)
    • Line 120: warning: exported method UserService.Count should have comment or be unexported (golint)
    • Line 130: warning: exported method UserService.ComparePassword should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!