Gofmt formats Go programs. We run gofmt -s
on your code, where -s
is for the "simplify" command
No problems detected. Good job!
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!
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.
Golint is a linter for Go source code.
-
grpc-connection-library/pool/connection_pool.go
- Line 50: warning: comment on exported const UnaryServer should be of the form "UnaryServer ..." (golint)
- Line 52: warning: exported const UnaryClient should have comment (or a comment on this block) or be unexported (golint)
- Line 74: warning: exported var ConnIndex should have comment or be unexported (golint)
-
grpc-connection-library/pool/pool_options.go
- Line 9: warning: exported type PoolConnOptions should have comment or be unexported (golint)
- Line 21: warning: exported type PoolOptions should have comment or be unexported (golint)
- Line 23: warning: exported function WithAddress should have comment or be unexported (golint)
- Line 29: warning: exported function WithAuthority should have comment or be unexported (golint)
- Line 35: warning: exported function WithInsecure should have comment or be unexported (golint)
- Line 41: warning: exported function WithScheme should have comment or be unexported (golint)
- Line 47: warning: exported function WithConnectionInterceptor should have comment or be unexported (golint)
- Line 53: warning: exported function WithRetry should have comment or be unexported (golint)
- Line 59: warning: exported function WithCodes should have comment or be unexported (golint)
- Line 65: warning: exported function WithCredentials should have comment or be unexported (golint)
-
grpc-connection-library/pool/semaphore.go
- Line 5: warning: exported type Semaphore should have comment or be unexported (golint)
- Line 10: warning: exported function NewSemaphore should have comment or be unexported (golint)
- Line 17: warning: exported method Semaphore.Acquire should have comment or be unexported (golint)
- Line 25: warning: exported method Semaphore.Release should have comment or be unexported (golint)
- Line 32: warning: exported method Semaphore.Lock should have comment or be unexported (golint)
- Line 36: warning: exported method Semaphore.Unlock should have comment or be unexported (golint)
- Line 41: warning: exported method Semaphore.RLock should have comment or be unexported (golint)
- Line 45: warning: exported method Semaphore.RUnlock should have comment or be unexported (golint)
-
grpc-connection-library/grpc/options.go
- Line 7: warning: exported type Options should have comment or be unexported (golint)
- Line 9: warning: exported function WithConnectionType should have comment or be unexported (golint)
- Line 15: warning: exported function WithAddress should have comment or be unexported (golint)
- Line 21: warning: exported function WithPort should have comment or be unexported (golint)
- Line 27: warning: exported function WithServerOptions should have comment or be unexported (golint)
Checks whether your project has a LICENSE file.
No problems detected. Good job!
IneffAssign detects ineffectual assignments in Go code.
-
grpc-connection-library/grpc/grpc.go
- Line 5: warning: cannot find package "." in: (ineffassign)
- Line 6: warning: cannot find package "." in: (ineffassign)
- Line 12: warning: cannot find package "." in: (ineffassign)
- Line 13: warning: cannot find package "." in: (ineffassign)
- Line 14: warning: cannot find package "." in: (ineffassign)
- Line 5: warning: could not import github.com/Deeptiman/grpc-connection-library/ping (invalid package name: "") (ineffassign)
- Line 6: warning: could not import github.com/Deeptiman/grpc-connection-library/pool (invalid package name: "") (ineffassign)
- Line 12: warning: could not import google.golang.org/grpc (invalid package name: "") (ineffassign)
- Line 13: warning: could not import google.golang.org/grpc/connectivity (invalid package name: "") (ineffassign)
- Line 14: warning: could not import google.golang.org/grpc/grpclog (invalid package name: "") (ineffassign)
-
grpc-connection-library/interceptor/interceptor.go
- Line 5: warning: cannot find package "." in: (ineffassign)
- Line 6: warning: cannot find package "." in: (ineffassign)
- Line 5: warning: could not import github.com/Deeptiman/grpc-connection-library/retry (invalid package name: "") (ineffassign)
- Line 6: warning: could not import google.golang.org/grpc (invalid package name: "") (ineffassign)
-
grpc-connection-library/ping/ping.go
- Line 6: warning: cannot find package "." in: (ineffassign)
- Line 6: warning: could not import github.com/golang/protobuf/ptypes (invalid package name: "") (ineffassign)
- Line 14: warning: undeclared name: UnimplementedPingServiceServer (ineffassign)
- Line 18: warning: undeclared name: PingServiceClient (ineffassign)
- Line 42: warning: undeclared name: Request (ineffassign)
- Line 42: warning: undeclared name: Response (ineffassign)
- Line 23: warning: undeclared name: Response (ineffassign)
- Line 27: warning: undeclared name: Request (ineffassign)
- Line 47: warning: undeclared name: Response (ineffassign)
- Line 48: warning: undeclared name: Pong (ineffassign)
-
grpc-connection-library/pool/connection_pool.go
- Line 12: warning: cannot find package "." in: (ineffassign)
- Line 4: warning: cannot find package "." in: (ineffassign)
- Line 5: warning: cannot find package "." in: (ineffassign)
- Line 6: warning: cannot find package "." in: (ineffassign)
- Line 13: warning: cannot find package "." in: (ineffassign)
- Line 14: warning: cannot find package "." in: (ineffassign)
- Line 15: warning: cannot find package "." in: (ineffassign)
- Line 4: warning: could not import github.com/Deeptiman/grpc-connection-library/interceptor (invalid package name: "") (ineffassign)
- Line 5: warning: could not import github.com/Deeptiman/grpc-connection-library/ping (invalid package name: "") (ineffassign)
- Line 6: warning: could not import github.com/Deeptiman/grpc-connection-library/retry (invalid package name: "") (ineffassign)
- Line 12: warning: could not import github.com/Deeptiman/go-batch (invalid package name: "") (ineffassign)
- Line 13: warning: could not import google.golang.org/grpc (invalid package name: "") (ineffassign)
- Line 14: warning: could not import google.golang.org/grpc/codes (invalid package name: "") (ineffassign)
- Line 15: warning: could not import google.golang.org/grpc/grpclog (invalid package name: "") (ineffassign)
- Line 39: warning: undeclared name: batch (ineffassign)
- Line 294: warning: undeclared name: batch (ineffassign)
- Line 299: warning: undeclared name: batch (ineffassign)
- Line 107: warning: undeclared name: batch (ineffassign)
- Line 107: warning: undeclared name: batch (ineffassign)
- Line 214: warning: undeclared name: batch (ineffassign)
- Line 231: warning: undeclared name: batch (ineffassign)
- Line 231: warning: undeclared name: batch (ineffassign)
- Line 232: warning: undeclared name: batch (ineffassign)
- Line 266: warning: undeclared name: batch (ineffassign)
- Line 275: warning: undeclared name: batch (ineffassign)
- Line 301: warning: undeclared name: batch (ineffassign)
- Line 12: warning: "github.com/Deeptiman/go-batch" imported but not used (ineffassign)
-
grpc-connection-library/pool/connection_queue.go
- Line 5: warning: cannot find package "." in: (ineffassign)
- Line 5: warning: could not import github.com/Deeptiman/grpc-connection-library/logger (invalid package name: "") (ineffassign)
- Line 23: warning: undeclared name: batch (ineffassign)
- Line 43: warning: undeclared name: batch (ineffassign)
- Line 43: warning: undeclared name: batch (ineffassign)
- Line 50: warning: undeclared name: batch (ineffassign)
- Line 65: warning: undeclared name: batch (ineffassign)
- Line 84: warning: undeclared name: batch (ineffassign)
- Line 34: warning: undeclared name: batch (ineffassign)
- Line 55: warning: undeclared name: batch (ineffassign)
- Line 79: warning: undeclared name: batch (ineffassign)
- Line 4: warning: "github.com/Deeptiman/go-batch" imported but not used (ineffassign)
-
grpc-connection-library/retry/retry.go
- Line 5: warning: cannot find package "." in: (ineffassign)
- Line 6: warning: cannot find package "." in: (ineffassign)
- Line 7: warning: cannot find package "." in: (ineffassign)
- Line 8: warning: cannot find package "." in: (ineffassign)
- Line 9: warning: cannot find package "." in: (ineffassign)
- Line 5: warning: could not import google.golang.org/grpc (invalid package name: "") (ineffassign)
- Line 6: warning: could not import google.golang.org/grpc/codes (invalid package name: "") (ineffassign)
- Line 7: warning: could not import google.golang.org/grpc/connectivity (invalid package name: "") (ineffassign)
- Line 8: warning: could not import google.golang.org/grpc/grpclog (invalid package name: "") (ineffassign)
- Line 9: warning: could not import google.golang.org/grpc/status (invalid package name: "") (ineffassign)
Misspell Finds commonly misspelled English words
No problems detected. Good job!