Preparing report...

Report for github.com/cloudfoundry-incubator/eirini

A+    Excellent!    Found 101 issues across 286 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!


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!


golint64%

Golint is a linter for Go source code.

    • eirini/models.go
    • Line 6: warning: comment on exported const EnvEiriniNamespace should be of the form "EnvEiriniNamespace ..." (golint)
    • Line 8: warning: exported const EnvDownloadURL should have comment (or a comment on this block) or be unexported (golint)
    • Line 29: warning: comment on exported const TLSSecretKey should be of the form "TLSSecretKey ..." (golint)
    • Line 44: warning: exported var ErrNotFound should have comment or be unexported (golint)
    • Line 46: warning: exported var ErrInvalidInstanceIndex should have comment or be unexported (golint)
    • Line 48: warning: exported type CommonConfig should have comment or be unexported (golint)
    • Line 60: warning: exported type APIConfig should have comment or be unexported (golint)
    • Line 70: warning: exported type ControllerConfig should have comment or be unexported (golint)
    • Line 79: warning: exported type KubeConfig should have comment or be unexported (golint)
    • Line 83: warning: exported type EventReporterConfig should have comment or be unexported (golint)
    • Line 94: warning: exported type TaskReporterConfig should have comment or be unexported (golint)
    • Line 106: warning: exported type MigrationConfig should have comment or be unexported (golint)
    • Line 111: warning: exported type InstanceIndexEnvInjectorConfig should have comment or be unexported (golint)
    • Line 116: warning: exported type ResourceValidatorConfig should have comment or be unexported (golint)
    • eirini/k8s/informers/event/crash_event_generator.go
    • Line 17: warning: exported type DefaultCrashEventGenerator should have comment or be unexported (golint)
    • Line 21: warning: exported function NewDefaultCrashEventGenerator should have comment or be unexported (golint)
    • Line 27: warning: exported method DefaultCrashEventGenerator.Generate should have comment or be unexported (golint)
    • eirini/k8s/patching/label.go
    • Line 9: warning: exported type LabelPatch should have comment or be unexported (golint)
    • Line 14: warning: exported function NewLabel should have comment or be unexported (golint)
    • Line 21: warning: exported method LabelPatch.Type should have comment or be unexported (golint)
    • Line 25: warning: exported method LabelPatch.GetPatchBytes should have comment or be unexported (golint)
    • eirini/k8s/jobs/list.go
    • Line 13: warning: exported type JobLister should have comment or be unexported (golint)
    • Line 17: warning: exported type Lister should have comment or be unexported (golint)
    • Line 21: warning: exported function NewLister should have comment or be unexported (golint)
    • Line 29: warning: exported method Lister.List should have comment or be unexported (golint)
    • eirini/k8s/stset/statefulset_to_lrp.go
    • Line 9: warning: exported type StatefulSetToLRP should have comment or be unexported (golint)
    • Line 11: warning: exported function NewStatefulSetToLRPConverter should have comment or be unexported (golint)
    • Line 15: warning: exported method StatefulSetToLRP.Convert should have comment or be unexported (golint)
    • Line 19: warning: exported function MapStatefulSetToLRP should have comment or be unexported (golint)
    • eirini/migrations/adjust_cpu_resource.go
    • Line 16: warning: exported type CPURequestSetter should have comment or be unexported (golint)
    • Line 20: warning: exported function NewAdjustCPURequest should have comment or be unexported (golint)
    • Line 26: warning: exported type AdjustCPURequest should have comment or be unexported (golint)
    • Line 30: warning: exported method AdjustCPURequest.SequenceID should have comment or be unexported (golint)
    • Line 38: warning: exported method AdjustCPURequest.Apply should have comment or be unexported (golint)
    • Line 61: warning: exported method AdjustCPURequest.AppliesTo should have comment or be unexported (golint)
    • eirini/handler/stage_handler.go
    • Line 15: warning: exported type Stage should have comment or be unexported (golint)
    • Line 20: warning: exported function NewStageHandler should have comment or be unexported (golint)
    • Line 29: warning: exported method Stage.Run should have comment or be unexported (golint)
    • eirini/k8s/client/statefulset_client.go
    • Line 17: warning: exported type StatefulSet should have comment or be unexported (golint)
    • Line 22: warning: exported function NewStatefulSet should have comment or be unexported (golint)
    • Line 29: warning: exported method StatefulSet.Create should have comment or be unexported (golint)
    • Line 36: warning: exported method StatefulSet.Get should have comment or be unexported (golint)
    • Line 43: warning: exported method StatefulSet.GetBySourceType should have comment or be unexported (golint)
    • Line 57: warning: exported method StatefulSet.GetByLRPIdentifier should have comment or be unexported (golint)
    • Line 75: warning: exported method StatefulSet.Update should have comment or be unexported (golint)
    • Line 82: warning: exported method StatefulSet.SetAnnotation should have comment or be unexported (golint)
    • Line 97: warning: exported method StatefulSet.SetCPURequest should have comment or be unexported (golint)
    • Line 112: warning: exported method StatefulSet.Delete should have comment or be unexported (golint)
    • eirini/k8s/reconciler/pod_crash.go
    • Line 32: warning: exported type CrashEventGenerator should have comment or be unexported (golint)
    • Line 38: warning: exported type EventsClient should have comment or be unexported (golint)
    • Line 46: warning: exported type StatefulSetGetter should have comment or be unexported (golint)
    • Line 50: warning: exported type PodCrash should have comment or be unexported (golint)
    • Line 58: warning: exported function NewPodCrash should have comment or be unexported (golint)
    • Line 70: warning: exported method PodCrash.Reconcile should have comment or be unexported (golint)
    • eirini/k8s/jobs/task_to_job.go
    • Line 21: warning: exported type Converter should have comment or be unexported (golint)
    • Line 28: warning: exported function NewTaskToJobConverter should have comment or be unexported (golint)
    • Line 42: warning: exported method Converter.Convert should have comment or be unexported (golint)
    • eirini/k8s/webhook/instance_index_injector.go
    • Line 20: warning: exported type InstanceIndexEnvInjector should have comment or be unexported (golint)
    • Line 25: warning: exported function NewInstanceIndexEnvInjector should have comment or be unexported (golint)
    • Line 32: warning: exported method InstanceIndexEnvInjector.Handle should have comment or be unexported (golint)
    • eirini/api/model.go
    • Line 8: warning: exported const RunningState should have comment (or a comment on this block) or be unexported (golint)
    • Line 16: warning: exported type LRPIdentifier should have comment or be unexported (golint)
    • Line 20: warning: exported method LRPIdentifier.ProcessGUID should have comment or be unexported (golint)
    • Line 24: warning: comment on exported type LRP should be of the form "LRP ..." (with optional leading article) (golint)
    • Line 54: warning: exported type Sidecar should have comment or be unexported (golint)
    • Line 61: warning: exported type PrivateRegistry should have comment or be unexported (golint)
    • Line 67: warning: exported type VolumeMount should have comment or be unexported (golint)
    • Line 72: warning: exported type Instance should have comment or be unexported (golint)
    • Line 79: warning: exported type Healthcheck should have comment or be unexported (golint)
    • eirini/tests/integration/k8s.go
    • Line 23: warning: should not use dot imports (golint)
    • Line 34: warning: exported function ListJobs should have comment or be unexported (golint)
    • Line 46: warning: exported function GetTaskJobConditions should have comment or be unexported (golint)
    • Line 54: warning: exported function GetRegistrySecretName should have comment or be unexported (golint)
    • Line 71: warning: exported function CreateEmptySecret should have comment or be unexported (golint)
    • Line 82: warning: exported function CreateSecretWithStringData should have comment or be unexported (golint)
    • Line 94: warning: exported function MakeTestHTTPClient should have comment or be unexported (golint)
    • Line 120: warning: exported function DefaultAPIConfig should have comment or be unexported (golint)
    • Line 136: warning: exported function DefaultControllerConfig should have comment or be unexported (golint)
    • Line 152: warning: exported function CreateConfigFile should have comment or be unexported (golint)
    • Line 168: warning: exported function CreateTestServer should have comment or be unexported (golint)
    • Line 185: warning: exported function GetPDBItems should have comment or be unexported (golint)
    • Line 196: warning: exported function GetPDB should have comment or be unexported (golint)
    • Line 216: warning: exported function GetStatefulSet should have comment or be unexported (golint)
    • Line 237: warning: exported function GetLRP should have comment or be unexported (golint)
    • Line 248: warning: exported function GetTaskExecutionStatus should have comment or be unexported (golint)
    • eirini/bifrost/lrp.go
    • Line 16: warning: exported type LRPConverter should have comment or be unexported (golint)
    • Line 20: warning: exported type LRPClient should have comment or be unexported (golint)
    • Line 30: warning: exported type LRPNamespacer should have comment or be unexported (golint)
    • Line 34: warning: exported type LRP should have comment or be unexported (golint)
    • Line 40: warning: exported method LRP.Transfer should have comment or be unexported (golint)
    • Line 51: warning: exported method LRP.List should have comment or be unexported (golint)
    • Line 75: warning: exported method LRP.Update should have comment or be unexported (golint)
    • Line 94: warning: exported method LRP.GetApp should have comment or be unexported (golint)
    • Line 110: warning: exported method LRP.Stop should have comment or be unexported (golint)
    • Line 114: warning: exported method LRP.StopInstance should have comment or be unexported (golint)
    • Line 122: warning: exported method LRP.GetInstances should have comment or be unexported (golint)
    • eirini/stager/staging_completer.go
    • Line 16: warning: exported type CallbackClient should have comment or be unexported (golint)
    • Line 20: warning: exported type CallbackStagingCompleter should have comment or be unexported (golint)
    • Line 25: warning: exported function NewCallbackStagingCompleter should have comment or be unexported (golint)
    • Line 32: warning: exported method CallbackStagingCompleter.CompleteStaging should have comment or be unexported (golint)
    • eirini/tests/env.go
    • Line 9: warning: should not use dot imports (golint)
    • Line 12: warning: should not use dot imports (golint)
    • Line 15: warning: exported function GetKubeconfig should have comment or be unexported (golint)
    • Line 38: warning: exported function GetEiriniDockerHubPassword should have comment or be unexported (golint)
    • Line 42: warning: exported function GetEiriniSystemNamespace should have comment or be unexported (golint)
    • Line 46: warning: exported function GetEiriniWorkloadsNamespace should have comment or be unexported (golint)
    • Line 54: warning: exported function GetEiriniAddress should have comment or be unexported (golint)
    • Line 67: warning: exported function GetTelepresenceServiceName should have comment or be unexported (golint)
    • Line 74: warning: exported function GetTelepresencePort should have comment or be unexported (golint)
    • eirini/k8s/pdb/update.go
    • Line 20: warning: exported type K8sClient should have comment or be unexported (golint)
    • Line 25: warning: exported const PdbMinAvailableInstances should have comment or be unexported (golint)
    • Line 27: warning: exported type Updater should have comment or be unexported (golint)
    • Line 31: warning: exported function NewUpdater should have comment or be unexported (golint)
    • Line 37: warning: exported method Updater.Update should have comment or be unexported (golint)
    • eirini/cmd/commons.go
    • Line 21: warning: exported function ReadConfigFile should have comment or be unexported (golint)
    • Line 34: warning: exported function CreateKubeClient should have comment or be unexported (golint)
    • Line 47: warning: exported function ExitIfError should have comment or be unexported (golint)
    • Line 51: warning: exported function ExitfIfError should have comment or be unexported (golint)
    • Line 58: warning: exported function Exitf should have comment or be unexported (golint)
    • Line 62: warning: exported function GetOrDefault should have comment or be unexported (golint)
    • Line 70: warning: exported function GetEnvOrDefault should have comment or be unexported (golint)
    • Line 74: warning: exported function VerifyFileExists should have comment or be unexported (golint)
    • Line 80: warning: exported function GetExistingFile should have comment or be unexported (golint)
    • Line 87: warning: exported function GetExistingEnvFile should have comment or be unexported (golint)
    • Line 94: warning: exported function GetCertPaths should have comment or be unexported (golint)
    • Line 109: warning: exported function GetLatestMigrationIndex should have comment or be unexported (golint)
    • eirini/bifrost/docker_staging.go
    • Line 19: warning: exported type StagingCompleter should have comment or be unexported (golint)
    • Line 23: warning: exported type ImageMetadataFetcher should have comment or be unexported (golint)
    • Line 25: warning: exported method ImageMetadataFetcher.Fetch should have comment or be unexported (golint)
    • Line 29: warning: exported type ImageRefParser should have comment or be unexported (golint)
    • Line 31: warning: exported method ImageRefParser.Parse should have comment or be unexported (golint)
    • Line 35: warning: exported type DockerStaging should have comment or be unexported (golint)
    • Line 42: warning: exported type StagingResult should have comment or be unexported (golint)
    • Line 49: warning: exported type LifecycleMetadata should have comment or be unexported (golint)
    • Line 53: warning: exported type ProcessTypes should have comment or be unexported (golint)
    • Line 67: warning: exported method DockerStaging.TransferStaging should have comment or be unexported (golint)
    • Line 108: warning: exported method DockerStaging.CompleteStaging should have comment or be unexported (golint)
    • eirini/k8s/reconciler/pod_crash_predicate.go
    • Line 8: warning: exported type SourceTypeUpdatePredicate should have comment or be unexported (golint)
    • Line 12: warning: exported function NewSourceTypeUpdatePredicate should have comment or be unexported (golint)
    • Line 16: warning: exported method SourceTypeUpdatePredicate.Update should have comment or be unexported (golint)
    • Line 20: warning: exported method SourceTypeUpdatePredicate.Create should have comment or be unexported (golint)
    • Line 24: warning: exported method SourceTypeUpdatePredicate.Delete should have comment or be unexported (golint)
    • Line 28: warning: exported method SourceTypeUpdatePredicate.Generic should have comment or be unexported (golint)
    • eirini/handler/app_handler.go
    • Line 17: warning: exported function NewAppHandler should have comment or be unexported (golint)
    • Line 21: warning: exported type App should have comment or be unexported (golint)
    • Line 26: warning: exported method App.Desire should have comment or be unexported (golint)
    • Line 60: warning: exported method App.List should have comment or be unexported (golint)
    • Line 91: warning: exported method App.Get should have comment or be unexported (golint)
    • Line 127: warning: exported method App.GetInstances should have comment or be unexported (golint)
    • Line 158: warning: exported method App.Update should have comment or be unexported (golint)
    • Line 179: warning: exported method App.Stop should have comment or be unexported (golint)
    • Line 196: warning: exported method App.StopInstance should have comment or be unexported (golint)
    • eirini/tests/eats_fixture.go
    • Line 17: warning: should not use dot imports (golint)
    • Line 20: warning: should not use dot imports (golint)
    • Line 28: warning: exported type EATSFixture should have comment or be unexported (golint)
    • Line 39: warning: exported function NewEATSFixture should have comment or be unexported (golint)
    • Line 47: warning: exported method EATSFixture.SetUp should have comment or be unexported (golint)
    • Line 52: warning: exported method EATSFixture.TearDown should have comment or be unexported (golint)
    • Line 70: warning: exported method EATSFixture.GetEiriniHTTPClient should have comment or be unexported (golint)
    • Line 138: warning: exported method EATSFixture.GetEiriniWorkloadsNamespace should have comment or be unexported (golint)
    • Line 150: warning: exported method EATSFixture.GetNATSPassword should have comment or be unexported (golint)
    • Line 157: warning: exported function NewWiremock should have comment or be unexported (golint)
    • Line 166: warning: exported function CopyRolesAndBindings should have comment or be unexported (golint)
    • eirini/k8s/client/event_client.go
    • Line 13: warning: exported type Event should have comment or be unexported (golint)
    • Line 17: warning: exported function NewEvent should have comment or be unexported (golint)
    • Line 23: warning: exported method Event.GetByPod should have comment or be unexported (golint)
    • Line 42: warning: exported method Event.GetByInstanceAndReason should have comment or be unexported (golint)
    • Line 69: warning: exported method Event.Create should have comment or be unexported (golint)
    • Line 76: warning: exported method Event.Update should have comment or be unexported (golint)
    • eirini/k8s/reconciler/task.go
    • Line 21: warning: exported type Task should have comment or be unexported (golint)
    • Line 31: warning: exported type TasksCrClient should have comment or be unexported (golint)
    • Line 38: warning: exported type TaskWorkloadClient should have comment or be unexported (golint)
    • Line 44: warning: exported function NewTask should have comment or be unexported (golint)
    • Line 54: warning: exported method Task.Reconcile should have comment or be unexported (golint)
    • eirini/k8s/stset/get.go
    • Line 25: warning: exported type PodGetter should have comment or be unexported (golint)
    • Line 29: warning: exported type EventGetter should have comment or be unexported (golint)
    • Line 33: warning: exported type Getter should have comment or be unexported (golint)
    • Line 41: warning: exported function NewGetter should have comment or be unexported (golint)
    • Line 57: warning: exported method Getter.Get should have comment or be unexported (golint)
    • Line 63: warning: exported method Getter.GetInstances should have comment or be unexported (golint)
    • eirini/k8s/stset/list.go
    • Line 15: warning: exported type StatefulSetToLRPConverter should have comment or be unexported (golint)
    • Line 19: warning: exported type StatefulSetsBySourceTypeGetter should have comment or be unexported (golint)
    • Line 23: warning: exported type Lister should have comment or be unexported (golint)
    • Line 29: warning: exported function NewLister should have comment or be unexported (golint)
    • Line 41: warning: exported method Lister.List should have comment or be unexported (golint)
    • eirini/util/lager_logr.go
    • Line 13: warning: exported function NewLagerLogr should have comment or be unexported (golint)
    • Line 19: warning: exported method LagerLogr.Enabled should have comment or be unexported (golint)
    • Line 23: warning: exported method LagerLogr.Info should have comment or be unexported (golint)
    • Line 31: warning: exported method LagerLogr.V should have comment or be unexported (golint)
    • Line 35: warning: exported method LagerLogr.WithValues should have comment or be unexported (golint)
    • Line 41: warning: exported method LagerLogr.WithName should have comment or be unexported (golint)
    • eirini/tests/integration/eirini_bins.go
    • Line 16: warning: should not use dot imports (golint)
    • Line 19: warning: should not use dot imports (golint)
    • Line 24: warning: exported type EiriniBinaries should have comment or be unexported (golint)
    • Line 37: warning: exported function NewEiriniBinaries should have comment or be unexported (golint)
    • Line 54: warning: exported method EiriniBinaries.TearDown should have comment or be unexported (golint)
    • Line 79: warning: exported type Binary should have comment or be unexported (golint)
    • Line 86: warning: exported function NewBinary should have comment or be unexported (golint)
    • Line 98: warning: exported method Binary.Run should have comment or be unexported (golint)
    • Line 116: warning: exported method Binary.RunWithConfig should have comment or be unexported (golint)
    • Line 132: warning: exported method Binary.Restart should have comment or be unexported (golint)
    • eirini/k8s/crclient/tasks.go
    • Line 11: warning: exported type Tasks should have comment or be unexported (golint)
    • Line 15: warning: exported function NewTasks should have comment or be unexported (golint)
    • Line 19: warning: exported method Tasks.GetTask should have comment or be unexported (golint)
    • Line 29: warning: exported method Tasks.UpdateTaskStatus should have comment or be unexported (golint)
    • eirini/k8s/informers/event/crash.go
    • Line 18: warning: exported const CrashLoopBackOff should have comment (or a comment on this block) or be unexported (golint)
    • Line 25: warning: exported type CrashEventGenerator should have comment or be unexported (golint)
    • Line 29: warning: exported type CrashEmitter should have comment or be unexported (golint)
    • Line 33: warning: exported type CrashReconciler should have comment or be unexported (golint)
    • Line 40: warning: exported function NewCrashReconciler should have comment or be unexported (golint)
    • Line 54: warning: exported method CrashReconciler.Reconcile should have comment or be unexported (golint)
    • eirini/k8s/client/job_client.go
    • Line 15: warning: exported type Job should have comment or be unexported (golint)
    • Line 22: warning: exported function NewJob should have comment or be unexported (golint)
    • Line 31: warning: exported method Job.Create should have comment or be unexported (golint)
    • Line 38: warning: exported method Job.Delete should have comment or be unexported (golint)
    • Line 50: warning: exported method Job.GetByGUID should have comment or be unexported (golint)
    • Line 66: warning: exported method Job.List should have comment or be unexported (golint)
    • Line 82: warning: exported method Job.SetAnnotation should have comment or be unexported (golint)
    • Line 97: warning: exported method Job.SetLabel should have comment or be unexported (golint)
    • eirini/k8s/webhook/diff/lrp.go
    • Line 11: warning: exported type Reporter should have comment or be unexported (golint)
    • Line 16: warning: exported method Reporter.PushStep should have comment or be unexported (golint)
    • Line 20: warning: exported method Reporter.Report should have comment or be unexported (golint)
    • Line 26: warning: exported method Reporter.PopStep should have comment or be unexported (golint)
    • Line 54: warning: exported function CompareLRPSpecs should have comment or be unexported (golint)
    • eirini/migrations/adopt_job_secret.go
    • Line 15: warning: exported type AdoptJobRegistrySecret should have comment or be unexported (golint)
    • Line 19: warning: exported function NewAdoptJobRegistrySecret should have comment or be unexported (golint)
    • Line 25: warning: exported method AdoptJobRegistrySecret.Apply should have comment or be unexported (golint)
    • Line 57: warning: exported method AdoptJobRegistrySecret.SequenceID should have comment or be unexported (golint)
    • Line 67: warning: exported method AdoptJobRegistrySecret.AppliesTo should have comment or be unexported (golint)
    • eirini/k8s/patching/cpu_request.go
    • Line 12: warning: exported type CPURequestPatch should have comment or be unexported (golint)
    • Line 17: warning: exported function NewCPURequestPatch should have comment or be unexported (golint)
    • Line 24: warning: exported method CPURequestPatch.Type should have comment or be unexported (golint)
    • Line 28: warning: exported method CPURequestPatch.GetPatchBytes should have comment or be unexported (golint)
    • eirini/k8s/patching/set_owner.go
    • Line 10: warning: exported type SetOwnerPatch should have comment or be unexported (golint)
    • Line 14: warning: exported function NewSetOwner should have comment or be unexported (golint)
    • Line 20: warning: exported method SetOwnerPatch.Type should have comment or be unexported (golint)
    • Line 24: warning: exported method SetOwnerPatch.GetPatchBytes should have comment or be unexported (golint)
    • eirini/migrations/adopt_stset_secret.go
    • Line 16: warning: exported type SecretsClient should have comment or be unexported (golint)
    • Line 21: warning: exported type AdoptStatefulsetRegistrySecret should have comment or be unexported (golint)
    • Line 25: warning: exported function NewAdoptStatefulsetRegistrySecret should have comment or be unexported (golint)
    • Line 31: warning: exported method AdoptStatefulsetRegistrySecret.Apply should have comment or be unexported (golint)
    • Line 57: warning: exported method AdoptStatefulsetRegistrySecret.SequenceID should have comment or be unexported (golint)
    • Line 65: warning: exported method AdoptStatefulsetRegistrySecret.AppliesTo should have comment or be unexported (golint)
    • eirini/handler/task_handler.go
    • Line 14: warning: exported type Task should have comment or be unexported (golint)
    • Line 19: warning: exported function NewTaskHandler should have comment or be unexported (golint)
    • Line 26: warning: exported method Task.Get should have comment or be unexported (golint)
    • Line 53: warning: exported method Task.Run should have comment or be unexported (golint)
    • Line 75: warning: exported method Task.Cancel should have comment or be unexported (golint)
    • Line 91: warning: exported method Task.List should have comment or be unexported (golint)
    • eirini/util/hash.go
    • Line 12: warning: exported const MaxHashLength should have comment or be unexported (golint)
    • Line 14: warning: exported function Hash should have comment or be unexported (golint)
    • eirini/util/retryable_json_client.go
    • Line 16: warning: exported type RetryableJSONClient should have comment or be unexported (golint)
    • Line 20: warning: exported function NewRetryableJSONClientWithConfig should have comment or be unexported (golint)
    • Line 29: warning: exported function NewRetryableJSONClient should have comment or be unexported (golint)
    • Line 38: warning: exported method RetryableJSONClient.Post should have comment or be unexported (golint)
    • eirini/tests/k8s.go
    • Line 14: warning: should not use dot imports (golint)
    • Line 17: warning: should not use dot imports (golint)
    • Line 25: warning: exported const DefaultApplicationServiceAccount should have comment or be unexported (golint)
    • Line 27: warning: exported function CreateRandomNamespace should have comment or be unexported (golint)
    • Line 50: warning: exported function CreatePodCreationPSP should have comment or be unexported (golint)
    • Line 132: warning: exported function DeleteNamespace should have comment or be unexported (golint)
    • Line 136: warning: exported function DeletePSP should have comment or be unexported (golint)
    • Line 140: warning: exported function GetApplicationServiceAccount should have comment or be unexported (golint)
    • Line 149: warning: exported function ExposeAsService should have comment or be unexported (golint)
    • Line 178: warning: exported function RequestServiceFn should have comment or be unexported (golint)
    • eirini/k8s/client/pod_disruption_budget_client.go
    • Line 16: warning: exported type PodDisruptionBudget should have comment or be unexported (golint)
    • Line 20: warning: exported function NewPodDisruptionBudget should have comment or be unexported (golint)
    • Line 24: warning: exported method PodDisruptionBudget.Get should have comment or be unexported (golint)
    • Line 31: warning: exported method PodDisruptionBudget.Create should have comment or be unexported (golint)
    • Line 38: warning: exported method PodDisruptionBudget.Delete should have comment or be unexported (golint)
    • Line 45: warning: exported method PodDisruptionBudget.SetOwner should have comment or be unexported (golint)
    • eirini/pkg/apis/eirini/v1/task.go
    • Line 23: warning: exported type TaskSpec should have comment or be unexported (golint)
    • Line 47: warning: exported type TaskList should have comment or be unexported (golint)
    • Line 54: warning: exported type ExecutionStatus should have comment or be unexported (golint)
    • Line 57: warning: exported const TaskStarting should have comment (or a comment on this block) or be unexported (golint)
    • Line 63: warning: exported type TaskStatus should have comment or be unexported (golint)
    • eirini/k8s/jobs/status.go
    • Line 13: warning: exported type StatusGetter should have comment or be unexported (golint)
    • Line 18: warning: exported function NewStatusGetter should have comment or be unexported (golint)
    • Line 28: warning: exported method StatusGetter.GetStatus should have comment or be unexported (golint)
    • eirini/k8s/utils/names.go
    • Line 13: warning: exported function SanitizeName should have comment or be unexported (golint)
    • Line 17: warning: exported function SanitizeNameWithMaxStringLen should have comment or be unexported (golint)
    • Line 36: warning: exported function GetStatefulsetName should have comment or be unexported (golint)
    • eirini/util/parse.go
    • Line 12: warning: exported const DockerHubHost should have comment or be unexported (golint)
    • Line 16: warning: exported function ParseAppIndex should have comment or be unexported (golint)
    • Line 31: warning: exported function ParseImageRegistryHost should have comment or be unexported (golint)
    • eirini/k8s/jobs/get.go
    • Line 14: warning: exported type JobGetter should have comment or be unexported (golint)
    • Line 18: warning: exported type Getter should have comment or be unexported (golint)
    • Line 22: warning: exported function NewGetter should have comment or be unexported (golint)
    • Line 30: warning: exported method Getter.Get should have comment or be unexported (golint)
    • eirini/migrations/executor.go
    • Line 21: warning: exported type StatefulsetsClient should have comment or be unexported (golint)
    • Line 28: warning: exported type JobsClient should have comment or be unexported (golint)
    • Line 33: warning: exported type AnnotationSetter should have comment or be unexported (golint)
    • Line 39: warning: exported type MigrationStep should have comment or be unexported (golint)
    • Line 47: warning: exported type MigrationProvider should have comment or be unexported (golint)
    • Line 52: warning: exported type Executor should have comment or be unexported (golint)
    • Line 58: warning: exported function NewExecutor should have comment or be unexported (golint)
    • Line 66: warning: exported method Executor.Migrate should have comment or be unexported (golint)
    • eirini/migrations/migrations.go
    • Line 9: warning: exported type ObjectType should have comment or be unexported (golint)
    • Line 12: warning: exported const StatefulSetObjectType should have comment (or a comment on this block) or be unexported (golint)
    • Line 16: warning: exported function CreateMigrationStepsProvider should have comment or be unexported (golint)
    • Line 27: warning: exported type MigrationStepsProvider should have comment or be unexported (golint)
    • Line 31: warning: exported function NewMigrationStepsProvider should have comment or be unexported (golint)
    • Line 39: warning: exported method MigrationStepsProvider.Provide should have comment or be unexported (golint)
    • Line 43: warning: exported method MigrationStepsProvider.GetLatestMigrationIndex should have comment or be unexported (golint)
    • eirini/util/http.go
    • Line 10: warning: exported type CertPaths should have comment or be unexported (golint)
    • Line 14: warning: exported function CreateTLSHTTPClient should have comment or be unexported (golint)
    • eirini/k8s/reconciler/lrp.go
    • Line 28: warning: exported type LRPWorkloadCLient should have comment or be unexported (golint)
    • Line 35: warning: exported type LRPsCrClient should have comment or be unexported (golint)
    • Line 40: warning: exported function NewLRP should have comment or be unexported (golint)
    • Line 49: warning: exported type LRP should have comment or be unexported (golint)
    • Line 56: warning: exported method LRP.Reconcile should have comment or be unexported (golint)
    • eirini/handler/handler.go
    • Line 17: warning: exported type LRPBifrost should have comment or be unexported (golint)
    • Line 27: warning: exported type TaskBifrost should have comment or be unexported (golint)
    • Line 34: warning: exported type StagingBifrost should have comment or be unexported (golint)
    • Line 39: warning: exported function New should have comment or be unexported (golint)
    • eirini/k8s/webhook/lrp_resource_validator.go
    • Line 16: warning: exported type LRPResourceValidator should have comment or be unexported (golint)
    • Line 22: warning: exported function NewLRPResourceValidator should have comment or be unexported (golint)
    • Line 33: warning: exported method LRPResourceValidator.Handle should have comment or be unexported (golint)
    • eirini/k8s/probe.go
    • Line 9: warning: exported function CreateLivenessProbe should have comment or be unexported (golint)
    • Line 21: warning: exported function CreateReadinessProbe should have comment or be unexported (golint)
    • eirini/k8s/crclient/lrps.go
    • Line 11: warning: exported type LRPs should have comment or be unexported (golint)
    • Line 15: warning: exported function NewLRPs should have comment or be unexported (golint)
    • Line 19: warning: exported method LRPs.GetLRP should have comment or be unexported (golint)
    • Line 29: warning: exported method LRPs.UpdateLRPStatus should have comment or be unexported (golint)
    • eirini/bifrost/task.go
    • Line 17: warning: exported type TaskConverter should have comment or be unexported (golint)
    • Line 21: warning: exported type TaskClient should have comment or be unexported (golint)
    • Line 28: warning: exported type JSONClient should have comment or be unexported (golint)
    • Line 32: warning: exported type TaskNamespacer should have comment or be unexported (golint)
    • Line 36: warning: exported type Task should have comment or be unexported (golint)
    • Line 43: warning: exported method Task.GetTask should have comment or be unexported (golint)
    • Line 52: warning: exported method Task.ListTasks should have comment or be unexported (golint)
    • Line 66: warning: exported method Task.TransferTask should have comment or be unexported (golint)
    • Line 77: warning: exported method Task.CancelTask should have comment or be unexported (golint)
    • eirini/k8s/utils/dockerutils/config.go
    • Line 11: warning: exported const DockerConfigKey should have comment or be unexported (golint)
    • Line 13: warning: exported type Config should have comment or be unexported (golint)
    • Line 17: warning: exported type DockerAuth should have comment or be unexported (golint)
    • Line 23: warning: exported function NewDockerConfig should have comment or be unexported (golint)
    • Line 37: warning: exported method Config.JSON should have comment or be unexported (golint)
    • eirini/pkg/apis/eirini/v1/lrp.go
    • Line 1: warning: package comment should be of the form "Package v1 ..." (golint)
    • Line 10: warning: comment on exported type LRP should be of the form "LRP ..." (with optional leading article) (golint)
    • Line 25: warning: exported type LRPSpec should have comment or be unexported (golint)
    • Line 57: warning: exported type LRPStatus should have comment or be unexported (golint)
    • Line 61: warning: exported type Route should have comment or be unexported (golint)
    • Line 66: warning: exported type Sidecar should have comment or be unexported (golint)
    • Line 75: warning: exported type PrivateRegistry should have comment or be unexported (golint)
    • Line 80: warning: exported type VolumeMount should have comment or be unexported (golint)
    • Line 85: warning: exported type Healthcheck should have comment or be unexported (golint)
    • Line 95: warning: exported type LRPList should have comment or be unexported (golint)
    • eirini/models/cf/models.go
    • Line 7: warning: exported type VolumeMount should have comment or be unexported (golint)
    • Line 12: warning: exported type DesiredLRP should have comment or be unexported (golint)
    • Line 20: warning: exported type DesiredLRPResponse should have comment or be unexported (golint)
    • Line 24: warning: exported type DesireLRPRequest should have comment or be unexported (golint)
    • Line 56: warning: exported type DesiredLRPSchedulingInfo should have comment or be unexported (golint)
    • Line 63: warning: exported type DesiredLRPKey should have comment or be unexported (golint)
    • Line 67: warning: exported type DesiredLRPSchedulingInfosResponse should have comment or be unexported (golint)
    • Line 71: warning: exported type DesiredLRPLifecycleResponse should have comment or be unexported (golint)
    • Line 75: warning: exported type Lifecycle should have comment or be unexported (golint)
    • Line 79: warning: exported type DockerLifecycle should have comment or be unexported (golint)
    • Line 86: warning: exported type TaskRequest should have comment or be unexported (golint)
    • Line 101: warning: exported type TaskResponse should have comment or be unexported (golint)
    • Line 105: warning: exported type TasksResponse should have comment or be unexported (golint)
    • Line 107: warning: exported type TaskCompletedRequest should have comment or be unexported (golint)
    • Line 113: warning: exported type StagingRequest should have comment or be unexported (golint)
    • Line 128: warning: exported type StagingCompletedRequest should have comment or be unexported (golint)
    • Line 136: warning: exported type StagingLifecycle should have comment or be unexported (golint)
    • Line 140: warning: exported type StagingDockerLifecycle should have comment or be unexported (golint)
    • Line 146: warning: exported type EnvironmentVariable should have comment or be unexported (golint)
    • Line 151: warning: exported type UpdateDesiredLRPRequest should have comment or be unexported (golint)
    • Line 157: warning: exported type DesiredLRPUpdate should have comment or be unexported (golint)
    • Line 163: warning: exported type GetInstancesResponse should have comment or be unexported (golint)
    • Line 169: warning: exported type Instance should have comment or be unexported (golint)
    • Line 176: warning: exported type Route should have comment or be unexported (golint)
    • Line 181: warning: exported type AppCrashedRequest should have comment or be unexported (golint)
    • Line 191: warning: exported type Error should have comment or be unexported (golint)
    • eirini/k8s/stset/stop.go
    • Line 18: warning: exported type StatefulSetDeleter should have comment or be unexported (golint)
    • Line 22: warning: exported type PodDeleter should have comment or be unexported (golint)
    • Line 26: warning: exported type Stopper should have comment or be unexported (golint)
    • Line 33: warning: exported function NewStopper should have comment or be unexported (golint)
    • Line 47: warning: exported method Stopper.Stop should have comment or be unexported (golint)
    • Line 80: warning: exported method Stopper.StopInstance should have comment or be unexported (golint)
    • eirini/k8s/informers/task/reconciler.go
    • Line 23: warning: exported type Reporter should have comment or be unexported (golint)
    • Line 27: warning: exported type JobsClient should have comment or be unexported (golint)
    • Line 32: warning: exported type Deleter should have comment or be unexported (golint)
    • Line 36: warning: exported type PodsClient should have comment or be unexported (golint)
    • Line 41: warning: exported type Reconciler should have comment or be unexported (golint)
    • Line 52: warning: exported function NewReconciler should have comment or be unexported (golint)
    • Line 74: warning: exported method Reconciler.Reconcile should have comment or be unexported (golint)
    • eirini/k8s/lrp_client.go
    • Line 14: warning: exported type PodClient should have comment or be unexported (golint)
    • Line 20: warning: exported type PodDisruptionBudgetClient should have comment or be unexported (golint)
    • Line 24: warning: exported type StatefulSetClient should have comment or be unexported (golint)
    • Line 32: warning: exported type SecretsClient should have comment or be unexported (golint)
    • Line 38: warning: exported type EventsClient should have comment or be unexported (golint)
    • Line 42: warning: exported type LRPClient should have comment or be unexported (golint)
    • Line 51: warning: exported function NewLRPClient should have comment or be unexported (golint)
    • eirini/bifrost/convert.go
    • Line 21: warning: exported type APIConverter should have comment or be unexported (golint)
    • Line 25: warning: exported function NewAPIConverter should have comment or be unexported (golint)
    • Line 31: warning: exported method APIConverter.ConvertLRP should have comment or be unexported (golint)
    • Line 92: warning: exported method APIConverter.ConvertTask should have comment or be unexported (golint)
    • eirini/prometheus/lrp_client.go
    • Line 16: warning: exported const LRPCreations should have comment (or a comment on this block) or be unexported (golint)
    • Line 24: warning: exported type LRPClient should have comment or be unexported (golint)
    • Line 31: warning: exported type LRPClientDecorator should have comment or be unexported (golint)
    • Line 39: warning: exported function NewLRPClientDecorator should have comment or be unexported (golint)
    • Line 64: warning: exported method LRPClientDecorator.Desire should have comment or be unexported (golint)
    • eirini/tests/integration/assets/notdora/main.go
    • Line 29: warning: exported function HelloHandler should have comment or be unexported (golint)
    • Line 33: warning: exported function EnvHandler should have comment or be unexported (golint)
    • Line 37: warning: exported function LsHandler should have comment or be unexported (golint)
    • Line 59: warning: exported function ExitHandler should have comment or be unexported (golint)
    • eirini/events/cc_crash_emitter.go
    • Line 10: warning: exported type CcClient should have comment or be unexported (golint)
    • Line 14: warning: exported type CrashEvent should have comment or be unexported (golint)
    • Line 19: warning: exported type CcCrashEmitter should have comment or be unexported (golint)
    • Line 24: warning: exported function NewCcCrashEmitter should have comment or be unexported (golint)
    • Line 31: warning: exported method CcCrashEmitter.Emit should have comment or be unexported (golint)
    • eirini/k8s/patching/testing_annotation.go
    • Line 10: warning: exported type TestingAnnotationPatch should have comment or be unexported (golint)
    • Line 16: warning: exported function NewTestingAnnotation should have comment or be unexported (golint)
    • Line 24: warning: exported method TestingAnnotationPatch.Type should have comment or be unexported (golint)
    • Line 28: warning: exported method TestingAnnotationPatch.GetPatchBytes should have comment or be unexported (golint)
    • eirini/k8s/shared/options.go
    • Line 8: warning: exported type Option should have comment or be unexported (golint)
    • Line 11: warning: exported function ApplyOpts should have comment or be unexported (golint)
    • eirini/k8s/stset/lrp_to_statefulset.go
    • Line 17: warning: exported const PodAffinityTermWeight should have comment or be unexported (golint)
    • Line 19: warning: exported type ProbeCreator should have comment or be unexported (golint)
    • Line 21: warning: exported type LRPToStatefulSet should have comment or be unexported (golint)
    • Line 31: warning: exported function NewLRPToStatefulSetConverter should have comment or be unexported (golint)
    • Line 51: warning: exported method LRPToStatefulSet.Convert should have comment or be unexported (golint)
    • Line 312: warning: exported function StatefulSetLabelSelector should have comment or be unexported (golint)
    • eirini/migrations/adopt_pdb.go
    • Line 15: warning: exported type PDBClient should have comment or be unexported (golint)
    • Line 20: warning: exported type AdoptPDB should have comment or be unexported (golint)
    • Line 24: warning: exported function NewAdoptPDB should have comment or be unexported (golint)
    • Line 30: warning: exported method AdoptPDB.Apply should have comment or be unexported (golint)
    • Line 52: warning: exported method AdoptPDB.SequenceID should have comment or be unexported (golint)
    • Line 56: warning: exported method AdoptPDB.AppliesTo should have comment or be unexported (golint)
    • eirini/tests/eats/wiremock/wiremock.go
    • Line 14: warning: exported type Wiremock should have comment or be unexported (golint)
    • Line 18: warning: exported function New should have comment or be unexported (golint)
    • Line 25: warning: exported method Wiremock.Reset should have comment or be unexported (golint)
    • Line 29: warning: exported type Stub should have comment or be unexported (golint)
    • Line 34: warning: exported type RequestMatcher should have comment or be unexported (golint)
    • Line 39: warning: exported type Response should have comment or be unexported (golint)
    • Line 43: warning: exported method Wiremock.Address should have comment or be unexported (golint)
    • Line 47: warning: exported method Wiremock.AddStub should have comment or be unexported (golint)
    • Line 51: warning: exported type Count should have comment or be unexported (golint)
    • Line 55: warning: exported type Requests should have comment or be unexported (golint)
    • Line 59: warning: exported type Request should have comment or be unexported (golint)
    • Line 63: warning: exported method Wiremock.GetRequestBody should have comment or be unexported (golint)
    • Line 85: warning: exported method Wiremock.GetCount should have comment or be unexported (golint)
    • Line 103: warning: exported method Wiremock.GetCountFn should have comment or be unexported (golint)
    • eirini/tests/uuid.go
    • Line 7: warning: should not use dot imports (golint)
    • Line 10: warning: exported function GenerateGUID should have comment or be unexported (golint)
    • eirini/k8s/task_client.go
    • Line 13: warning: exported type JobClient should have comment or be unexported (golint)
    • Line 20: warning: exported type TaskClient should have comment or be unexported (golint)
    • Line 28: warning: exported function NewTaskClient should have comment or be unexported (golint)
    • eirini/k8s/patching/annotation.go
    • Line 9: warning: exported type AnnotationPatch should have comment or be unexported (golint)
    • Line 14: warning: exported function NewAnnotation should have comment or be unexported (golint)
    • Line 21: warning: exported method AnnotationPatch.Type should have comment or be unexported (golint)
    • Line 25: warning: exported method AnnotationPatch.GetPatchBytes should have comment or be unexported (golint)
    • eirini/bifrost/namespacer.go
    • Line 3: warning: exported type Namespacer should have comment or be unexported (golint)
    • Line 7: warning: exported function NewNamespacer should have comment or be unexported (golint)
    • Line 13: warning: exported method Namespacer.GetNamespace should have comment or be unexported (golint)
    • eirini/k8s/client/pod_client.go
    • Line 17: warning: exported type Pod should have comment or be unexported (golint)
    • Line 22: warning: exported function NewPod should have comment or be unexported (golint)
    • Line 29: warning: exported method Pod.GetAll should have comment or be unexported (golint)
    • Line 46: warning: exported method Pod.GetByLRPIdentifier should have comment or be unexported (golint)
    • Line 64: warning: exported method Pod.Delete should have comment or be unexported (golint)
    • Line 71: warning: exported method Pod.SetAnnotation should have comment or be unexported (golint)
    • Line 86: warning: exported method Pod.SetAndTestAnnotation should have comment or be unexported (golint)
    • eirini/k8s/client/secret_client.go
    • Line 15: warning: exported type Secret should have comment or be unexported (golint)
    • Line 19: warning: exported function NewSecret should have comment or be unexported (golint)
    • Line 23: warning: exported method Secret.Get should have comment or be unexported (golint)
    • Line 30: warning: exported method Secret.Create should have comment or be unexported (golint)
    • Line 37: warning: exported method Secret.Update should have comment or be unexported (golint)
    • Line 44: warning: exported method Secret.Delete should have comment or be unexported (golint)
    • Line 51: warning: exported method Secret.SetOwner should have comment or be unexported (golint)
    • eirini/k8s/jobs/delete.go
    • Line 14: warning: exported type JobDeleter should have comment or be unexported (golint)
    • Line 18: warning: exported type Deleter should have comment or be unexported (golint)
    • Line 24: warning: exported function NewDeleter should have comment or be unexported (golint)
    • Line 36: warning: exported method Deleter.Delete should have comment or be unexported (golint)
    • eirini/k8s/jobs/desire.go
    • Line 21: warning: exported type TaskToJobConverter should have comment or be unexported (golint)
    • Line 25: warning: exported type JobCreator should have comment or be unexported (golint)
    • Line 29: warning: exported type SecretsClient should have comment or be unexported (golint)
    • Line 35: warning: exported type Desirer should have comment or be unexported (golint)
    • Line 42: warning: exported function NewDesirer should have comment or be unexported (golint)
    • Line 56: warning: exported method Desirer.Desire should have comment or be unexported (golint)
    • eirini/k8s/stset/desire.go
    • Line 24: warning: exported type LRPToStatefulSetConverter should have comment or be unexported (golint)
    • Line 28: warning: exported type SecretsClient should have comment or be unexported (golint)
    • Line 34: warning: exported type StatefulSetCreator should have comment or be unexported (golint)
    • Line 38: warning: exported type PodDisruptionBudgetUpdater should have comment or be unexported (golint)
    • Line 42: warning: exported type Desirer should have comment or be unexported (golint)
    • Line 50: warning: exported function NewDesirer should have comment or be unexported (golint)
    • Line 66: warning: exported method Desirer.Desire should have comment or be unexported (golint)
    • eirini/k8s/stset/status.go
    • Line 13: warning: exported type StatefulsetGetter should have comment or be unexported (golint)
    • Line 17: warning: exported type StatusGetter should have comment or be unexported (golint)
    • Line 22: warning: exported function NewStatusGetter should have comment or be unexported (golint)
    • Line 29: warning: exported method StatusGetter.GetStatus should have comment or be unexported (golint)
    • eirini/k8s/stset/update.go
    • Line 15: warning: exported type StatefulSetUpdater should have comment or be unexported (golint)
    • Line 19: warning: exported type Updater should have comment or be unexported (golint)
    • Line 26: warning: exported function NewUpdater should have comment or be unexported (golint)
    • Line 40: warning: exported method Updater.Update should have comment or be unexported (golint)
    • eirini/tests/fixture.go
    • Line 18: warning: should not use dot imports (golint)
    • Line 21: warning: should not use dot imports (golint)
    • Line 35: warning: exported type Fixture should have comment or be unexported (golint)
    • Line 70: warning: exported function NewFixture should have comment or be unexported (golint)
    • Line 95: warning: exported method Fixture.SetUp should have comment or be unexported (golint)
    • Line 99: warning: exported method Fixture.NextAvailablePort should have comment or be unexported (golint)
    • Line 117: warning: exported method Fixture.TearDown should have comment or be unexported (golint)
    • Line 125: warning: exported method Fixture.Destroy should have comment or be unexported (golint)
    • Line 129: warning: exported method Fixture.CreateExtraNamespace 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!