Preparing report...

Report for github.com/apache/rocketmq-client-go

A+    Excellent!    Found 59 issues across 110 files

Tweet

gofmt98%

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!


gocyclo93%

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.

    • rocketmq-client-go/consumer/push_consumer.go
    • Line 516: warning: cyclomatic complexity 40 of function (*pushConsumer).pullMessage() is high (> 15) (gocyclo)
    • Line 1055: warning: cyclomatic complexity 29 of function (*pushConsumer).consumeMessageOrderly() is high (> 15) (gocyclo)
    • Line 443: warning: cyclomatic complexity 26 of function (*pushConsumer).validate() is high (> 15) (gocyclo)
    • Line 954: warning: cyclomatic complexity 18 of function (*pushConsumer).consumeMessageCurrently() is high (> 15) (gocyclo)

golint49%

Golint is a linter for Go source code.

    • rocketmq-client-go/consumer/option.go
    • Line 126: warning: exported type Option should have comment or be unexported (golint)
    • Line 137: warning: exported function WithConsumerModel should have comment or be unexported (golint)
    • Line 143: warning: exported function WithConsumeFromWhere should have comment or be unexported (golint)
    • Line 149: warning: exported function WithConsumerOrder should have comment or be unexported (golint)
    • Line 155: warning: exported function WithConsumeMessageBatchMaxSize should have comment or be unexported (golint)
    • Line 161: warning: comment on exported function WithInterceptor should be of the form "WithInterceptor ..." (golint)
    • Line 180: warning: exported function WithInstance should have comment or be unexported (golint)
    • Line 193: warning: exported function WithVIPChannel should have comment or be unexported (golint)
    • Line 207: warning: exported function WithCredentials should have comment or be unexported (golint)
    • Line 221: warning: exported function WithStrategy should have comment or be unexported (golint)
    • Line 227: warning: exported function WithPullBatchSize should have comment or be unexported (golint)
    • Line 233: warning: exported function WithRebalanceLockInterval should have comment or be unexported (golint)
    • Line 239: warning: exported function WithAutoCommit should have comment or be unexported (golint)
    • Line 245: warning: exported function WithSuspendCurrentQueueTimeMillis should have comment or be unexported (golint)
    • Line 251: warning: exported function WithPullInterval should have comment or be unexported (golint)
    • rocketmq-client-go/consumer/strategy.go
    • Line 44: warning: exported type AllocateStrategy should have comment or be unexported (golint)
    • Line 46: warning: exported function AllocateByAveragely should have comment or be unexported (golint)
    • Line 102: warning: exported function AllocateByAveragelyCircle should have comment or be unexported (golint)
    • Line 137: warning: comment on exported function AllocateByMachineNearby should be of the form "AllocateByMachineNearby ..." (golint)
    • Line 143: warning: exported function AllocateByConfig should have comment or be unexported (golint)
    • Line 149: warning: exported function AllocateByMachineRoom should have comment or be unexported (golint)
    • Line 203: warning: exported function AllocateByConsistentHash should have comment or be unexported (golint)
    • rocketmq-client-go/primitive/base.go
    • Line 29: warning: exported type NamesrvAddr should have comment or be unexported (golint)
    • Line 31: warning: exported function NewNamesrvAddr should have comment or be unexported (golint)
    • Line 53: warning: exported method NamesrvAddr.Check should have comment or be unexported (golint)
    • Line 84: warning: exported var PanicHandler should have comment or be unexported (golint)
    • Line 86: warning: exported function WithRecover should have comment or be unexported (golint)
    • Line 99: warning: exported function Diff should have comment or be unexported (golint)
    • rocketmq-client-go/primitive/message.go
    • Line 35: warning: exported const PropertyKeySeparator should have comment (or a comment on this block) or be unexported (golint)
    • Line 65: warning: exported type Message should have comment or be unexported (golint)
    • Line 80: warning: exported method Message.WithProperties should have comment or be unexported (golint)
    • Line 86: warning: exported method Message.WithProperty should have comment or be unexported (golint)
    • Line 98: warning: exported method Message.GetProperty should have comment or be unexported (golint)
    • Line 105: warning: exported method Message.RemoveProperty should have comment or be unexported (golint)
    • Line 115: warning: exported method Message.MarshallProperties should have comment or be unexported (golint)
    • Line 128: warning: comment on exported method Message.UnmarshalProperties should be of the form "UnmarshalProperties ..." (golint)
    • Line 144: warning: exported method Message.GetProperties should have comment or be unexported (golint)
    • Line 154: warning: exported function NewMessage should have comment or be unexported (golint)
    • Line 172: warning: exported method Message.WithTag should have comment or be unexported (golint)
    • Line 177: warning: exported method Message.WithKeys should have comment or be unexported (golint)
    • Line 188: warning: exported method Message.WithShardingKey should have comment or be unexported (golint)
    • Line 193: warning: exported method Message.GetTags should have comment or be unexported (golint)
    • Line 197: warning: exported method Message.GetKeys should have comment or be unexported (golint)
    • Line 201: warning: exported method Message.GetShardingKey should have comment or be unexported (golint)
    • Line 210: warning: exported method Message.Marshal should have comment or be unexported (golint)
    • Line 239: warning: exported type MessageExt should have comment or be unexported (golint)
    • Line 256: warning: exported method MessageExt.GetTags should have comment or be unexported (golint)
    • Line 260: warning: exported method MessageExt.GetRegionID should have comment or be unexported (golint)
    • Line 264: warning: exported method MessageExt.IsTraceOn should have comment or be unexported (golint)
    • Line 277: warning: exported function DecodeMessage should have comment or be unexported (golint)
    • Line 398: warning: exported method MessageQueue.HashCode should have comment or be unexported (golint)
    • Line 407: warning: exported type AccessChannel should have comment or be unexported (golint)
    • Line 410: warning: comment on exported const Local should be of the form "Local ..." (golint)
    • Line 412: warning: comment on exported const Cloud should be of the form "Cloud ..." (golint)
    • Line 416: warning: exported type MessageType should have comment or be unexported (golint)
    • Line 419: warning: exported const NormalMsg should have comment (or a comment on this block) or be unexported (golint)
    • Line 425: warning: exported type LocalTransactionState should have comment or be unexported (golint)
    • Line 428: warning: exported const CommitMessageState should have comment (or a comment on this block) or be unexported (golint)
    • Line 433: warning: exported type TransactionListener should have comment or be unexported (golint)
    • Line 442: warning: exported type MessageID should have comment or be unexported (golint)
    • Line 448: warning: exported function CreateMessageId should have comment or be unexported (golint)
    • Line 457: warning: exported function UnmarshalMsgID should have comment or be unexported (golint)
    • Line 478: warning: exported var CompressedFlag should have comment or be unexported (golint)
    • Line 491: warning: exported function GetTransactionValue should have comment or be unexported (golint)
    • Line 495: warning: exported function ResetTransactionValue should have comment or be unexported (golint)
    • Line 499: warning: exported function ClearCompressedFlag should have comment or be unexported (golint)
    • Line 503: warning: exported function SetCompressedFlag should have comment or be unexported (golint)
    • Line 529: warning: exported function CreateUniqID should have comment or be unexported (golint)
    • Line 550: warning: exported function Pid should have comment or be unexported (golint)
    • rocketmq-client-go/rlog/log.go
    • Line 28: warning: exported const LogKeyConsumerGroup should have comment (or a comment on this block) or be unexported (golint)
    • Line 38: warning: exported type Logger should have comment or be unexported (golint)
    • Line 135: warning: exported function SetLogLevel should have comment or be unexported (golint)
    • Line 142: warning: exported function SetOutputPath should have comment or be unexported (golint)
    • Line 150: warning: exported function Debug should have comment or be unexported (golint)
    • Line 154: warning: exported function Info should have comment or be unexported (golint)
    • Line 161: warning: exported function Warning should have comment or be unexported (golint)
    • Line 168: warning: exported function Error should have comment or be unexported (golint)
    • Line 172: warning: exported function Fatal should have comment or be unexported (golint)
    • rocketmq-client-go/primitive/result.go
    • Line 28: warning: exported const SendOK should have comment (or a comment on this block) or be unexported (golint)
    • Line 53: warning: exported function NewSendResult should have comment or be unexported (golint)
    • Line 63: warning: comment on exported type TransactionSendResult should be of the form "TransactionSendResult ..." (with optional leading article) (golint)
    • Line 95: warning: exported method PullResult.GetMessageExts should have comment or be unexported (golint)
    • Line 99: warning: exported method PullResult.SetMessageExts should have comment or be unexported (golint)
    • Line 103: warning: exported method PullResult.GetMessages should have comment or be unexported (golint)
    • Line 110: warning: exported method PullResult.SetBody should have comment or be unexported (golint)
    • Line 114: warning: exported method PullResult.GetBody should have comment or be unexported (golint)
    • rocketmq-client-go/internal/route.go
    • Line 41: warning: exported const EnvNameServerAddr should have comment (or a comment on this block) or be unexported (golint)
    • Line 50: warning: exported var ErrTopicNotExist should have comment or be unexported (golint)
    • Line 93: warning: comment on exported type TopicPublishInfo should be of the form "TopicPublishInfo ..." (with optional leading article) (golint)
    • Line 569: warning: exported method QueueData.Equals should have comment or be unexported (golint)
    • Line 601: warning: exported method BrokerData.Equals should have comment or be unexported (golint)
    • rocketmq-client-go/admin/option.go
    • Line 33: warning: exported type TopicConfigCreate should have comment or be unexported (golint)
    • Line 45: warning: exported type OptionCreate should have comment or be unexported (golint)
    • Line 47: warning: exported function WithTopicCreate should have comment or be unexported (golint)
    • Line 53: warning: exported function WithBrokerAddrCreate should have comment or be unexported (golint)
    • Line 59: warning: exported function WithReadQueueNums should have comment or be unexported (golint)
    • Line 65: warning: exported function WithWriteQueueNums should have comment or be unexported (golint)
    • Line 71: warning: exported function WithPerm should have comment or be unexported (golint)
    • Line 77: warning: exported function WithTopicFilterType should have comment or be unexported (golint)
    • Line 83: warning: exported function WithTopicSysFlag should have comment or be unexported (golint)
    • Line 89: warning: exported function WithOrder should have comment or be unexported (golint)
    • Line 100: warning: exported type TopicConfigDelete should have comment or be unexported (golint)
    • Line 107: warning: exported type OptionDelete should have comment or be unexported (golint)
    • Line 109: warning: exported function WithTopicDelete should have comment or be unexported (golint)
    • Line 115: warning: exported function WithBrokerAddrDelete should have comment or be unexported (golint)
    • Line 121: warning: exported function WithClusterName should have comment or be unexported (golint)
    • Line 127: warning: exported function WithNameSrvAddr should have comment or be unexported (golint)
    • rocketmq-client-go/examples/producer/transaction/main.go
    • Line 34: warning: exported type DemoListener should have comment or be unexported (golint)
    • Line 39: warning: exported function NewDemoListener should have comment or be unexported (golint)
    • Line 45: warning: exported method DemoListener.ExecuteLocalTransaction should have comment or be unexported (golint)
    • Line 55: warning: exported method DemoListener.CheckLocalTransaction should have comment or be unexported (golint)
    • rocketmq-client-go/producer/option.go
    • Line 54: warning: exported type Option should have comment or be unexported (golint)
    • Line 66: warning: exported function WithInstanceName should have comment or be unexported (golint)
    • Line 79: warning: exported function WithSendMsgTimeout should have comment or be unexported (golint)
    • Line 85: warning: exported function WithVIPChannel should have comment or be unexported (golint)
    • Line 99: warning: exported function WithInterceptor should have comment or be unexported (golint)
    • Line 105: warning: exported function WithQueueSelector should have comment or be unexported (golint)
    • Line 111: warning: exported function WithCredentials should have comment or be unexported (golint)
    • Line 117: warning: exported function WithDefaultTopicQueueNums should have comment or be unexported (golint)
    • Line 123: warning: exported function WithCreateTopicKey should have comment or be unexported (golint)
    • rocketmq-client-go/consumer/offset_store.go
    • Line 55: warning: comment on exported type OffsetStore should be of the form "OffsetStore ..." (with optional leading article) (golint)
    • Line 63: warning: exported type OffsetSerializeWrapper should have comment or be unexported (golint)
    • Line 67: warning: exported type MessageQueueKey should have comment or be unexported (golint)
    • Line 69: warning: exported method MessageQueueKey.MarshalText should have comment or be unexported (golint)
    • Line 83: warning: exported method MessageQueueKey.UnmarshalText should have comment or be unexported (golint)
    • Line 108: warning: exported function NewLocalFileOffsetStore should have comment or be unexported (golint)
    • Line 232: warning: exported function NewRemoteOffsetStore should have comment or be unexported (golint)
    • rocketmq-client-go/primitive/ctx.go
    • Line 18: warning: package comment should be of the form "Package primitive ..." (golint)
    • Line 18: warning: package comment should not have leading space (golint)
    • Line 31: warning: exported type CtxKey should have comment or be unexported (golint)
    • Line 33: warning: exported type CommunicationMode should have comment or be unexported (golint)
    • Line 35: warning: exported type ConsumeReturnType should have comment or be unexported (golint)
    • Line 37: warning: exported method ConsumeReturnType.Ordinal should have comment or be unexported (golint)
    • Line 62: warning: comment on exported const SendSync should be of the form "SendSync ..." (golint)
    • Line 64: warning: exported const SendOneway should have comment (or a comment on this block) or be unexported (golint)
    • Line 66: warning: comment on exported const ConsumerPush should be of the form "ConsumerPush ..." (golint)
    • Line 78: warning: exported type ConsumeMessageContext should have comment or be unexported (golint)
    • Line 110: warning: exported type ConsumeOrderlyContext should have comment or be unexported (golint)
    • Line 116: warning: exported function NewConsumeOrderlyContext should have comment or be unexported (golint)
    • Line 123: warning: exported function WithOrderlyCtx should have comment or be unexported (golint)
    • Line 127: warning: exported function GetOrderlyCtx should have comment or be unexported (golint)
    • Line 132: warning: exported type ConsumeConcurrentlyContext should have comment or be unexported (golint)
    • Line 138: warning: exported function NewConsumeConcurrentlyContext should have comment or be unexported (golint)
    • Line 144: warning: exported function WithConcurrentlyCtx should have comment or be unexported (golint)
    • Line 148: warning: exported function GetConcurrentlyCtx should have comment or be unexported (golint)
    • Line 153: warning: exported type ProducerCtx should have comment or be unexported (golint)
    • Line 166: warning: exported function WithProducerCtx should have comment or be unexported (golint)
    • Line 170: warning: exported function GetProducerCtx should have comment or be unexported (golint)
    • rocketmq-client-go/internal/response.go
    • Line 21: warning: exported const ResSuccess should have comment (or a comment on this block) or be unexported (golint)
    • Line 32: warning: exported type SendMessageResponse should have comment or be unexported (golint)
    • Line 40: warning: exported method SendMessageResponse.Decode should have comment or be unexported (golint)
    • Line 44: warning: exported type PullMessageResponse should have comment or be unexported (golint)
    • rocketmq-client-go/internal/trace.go
    • Line 37: warning: exported type TraceBean should have comment or be unexported (golint)
    • Line 51: warning: exported type TraceTransferBean should have comment or be unexported (golint)
    • Line 57: warning: exported type TraceType should have comment or be unexported (golint)
    • Line 60: warning: exported const Pub should have comment (or a comment on this block) or be unexported (golint)
    • Line 68: warning: exported type TraceContext should have comment or be unexported (golint)
    • Line 190: warning: exported const RmqSysTraceTopic should have comment (or a comment on this block) or be unexported (golint)
    • Line 202: warning: exported type TraceDispatcher should have comment or be unexported (golint)
    • Line 231: warning: exported function NewTraceDispatcher should have comment or be unexported (golint)
    • Line 401: warning: exported type Keyset should have comment or be unexported (golint)
    • Line 405: warning: should omit 2nd value from range; this loop is equivalent to `for k := range ...` (golint)
    • rocketmq-client-go/primitive/nsresolver.go
    • Line 1: warning: package comment should be of the form "Package primitive ..." (golint)
    • Line 32: warning: comment on exported type NsResolver should be of the form "NsResolver ..." (with optional leading article) (golint)
    • Line 39: warning: exported type StaticResolver should have comment or be unexported (golint)
    • Line 44: warning: exported function NewEnvResolver should have comment or be unexported (golint)
    • Line 48: warning: exported type EnvResolver should have comment or be unexported (golint)
    • Line 51: warning: exported method EnvResolver.Resolve should have comment or be unexported (golint)
    • Line 58: warning: exported method EnvResolver.Description should have comment or be unexported (golint)
    • Line 67: warning: exported function NewPassthroughResolver should have comment or be unexported (golint)
    • Line 86: warning: exported const DEFAULT_NAMESRV_ADDR should have comment (or a comment on this block) or be unexported (golint)
    • Line 91: warning: exported type HttpResolver should have comment or be unexported (golint)
    • Line 98: warning: exported function NewHttpResolver should have comment or be unexported (golint)
    • Line 114: warning: exported method HttpResolver.Resolve should have comment or be unexported (golint)
    • Line 127: warning: exported method HttpResolver.Description should have comment or be unexported (golint)
    • rocketmq-client-go/internal/client.go
    • Line 58: warning: exported var ErrServiceState should have comment or be unexported (golint)
    • Line 72: warning: exported type InnerProducer should have comment or be unexported (golint)
    • Line 79: warning: exported type InnerConsumer should have comment or be unexported (golint)
    • Line 93: warning: exported function DefaultClientOptions should have comment or be unexported (golint)
    • Line 102: warning: exported type ClientOptions should have comment or be unexported (golint)
    • Line 118: warning: exported method ClientOptions.ChangeInstanceNameToPID should have comment or be unexported (golint)
    • Line 130: warning: comment on exported type RMQClient should be of the form "RMQClient ..." (with optional leading article) (golint)
    • Line 180: warning: exported function GetOrNewRocketMQClient should have comment or be unexported (golint)
    • rocketmq-client-go/internal/request.go
    • Line 27: warning: exported const ReqSendMessage should have comment (or a comment on this block) or be unexported (golint)
    • Line 56: warning: exported type SendMessageRequestHeader should have comment or be unexported (golint)
    • Line 72: warning: exported method SendMessageRequestHeader.Encode should have comment or be unexported (golint)
    • Line 91: warning: exported type EndTransactionRequestHeader should have comment or be unexported (golint)
    • Line 101: warning: exported type SendMessageRequestV2Header should have comment or be unexported (golint)
    • Line 105: warning: exported method SendMessageRequestV2Header.Encode should have comment or be unexported (golint)
    • Line 123: warning: exported method EndTransactionRequestHeader.Encode should have comment or be unexported (golint)
    • Line 135: warning: exported type CheckTransactionStateRequestHeader should have comment or be unexported (golint)
    • Line 143: warning: exported method CheckTransactionStateRequestHeader.Encode should have comment or be unexported (golint)
    • Line 154: warning: exported method CheckTransactionStateRequestHeader.Decode should have comment or be unexported (golint)
    • Line 175: warning: exported type ConsumerSendMsgBackRequestHeader should have comment or be unexported (golint)
    • Line 185: warning: exported method ConsumerSendMsgBackRequestHeader.Encode should have comment or be unexported (golint)
    • Line 198: warning: exported type PullMessageRequestHeader should have comment or be unexported (golint)
    • Line 212: warning: exported method PullMessageRequestHeader.Encode should have comment or be unexported (golint)
    • Line 229: warning: exported type GetConsumerListRequestHeader should have comment or be unexported (golint)
    • Line 233: warning: exported method GetConsumerListRequestHeader.Encode should have comment or be unexported (golint)
    • Line 239: warning: exported type GetMaxOffsetRequestHeader should have comment or be unexported (golint)
    • Line 244: warning: exported method GetMaxOffsetRequestHeader.Encode should have comment or be unexported (golint)
    • Line 251: warning: exported type QueryConsumerOffsetRequestHeader should have comment or be unexported (golint)
    • Line 257: warning: exported method QueryConsumerOffsetRequestHeader.Encode should have comment or be unexported (golint)
    • Line 265: warning: exported type SearchOffsetRequestHeader should have comment or be unexported (golint)
    • Line 271: warning: exported method SearchOffsetRequestHeader.Encode should have comment or be unexported (golint)
    • Line 279: warning: exported type UpdateConsumerOffsetRequestHeader should have comment or be unexported (golint)
    • Line 286: warning: exported method UpdateConsumerOffsetRequestHeader.Encode should have comment or be unexported (golint)
    • Line 295: warning: exported type GetRouteInfoRequestHeader should have comment or be unexported (golint)
    • Line 299: warning: exported method GetRouteInfoRequestHeader.Encode should have comment or be unexported (golint)
    • Line 305: warning: exported type GetConsumerRunningInfoHeader should have comment or be unexported (golint)
    • Line 310: warning: exported method GetConsumerRunningInfoHeader.Encode should have comment or be unexported (golint)
    • Line 317: warning: exported method GetConsumerRunningInfoHeader.Decode should have comment or be unexported (golint)
    • Line 330: warning: exported type QueryMessageRequestHeader should have comment or be unexported (golint)
    • Line 338: warning: exported method QueryMessageRequestHeader.Encode should have comment or be unexported (golint)
    • Line 349: warning: exported method QueryMessageRequestHeader.Decode should have comment or be unexported (golint)
    • Line 353: warning: exported type ViewMessageRequestHeader should have comment or be unexported (golint)
    • Line 357: warning: exported method ViewMessageRequestHeader.Encode should have comment or be unexported (golint)
    • Line 364: warning: exported type CreateTopicRequestHeader should have comment or be unexported (golint)
    • Line 375: warning: exported method CreateTopicRequestHeader.Encode should have comment or be unexported (golint)
    • Line 389: warning: exported type TopicListRequestHeader should have comment or be unexported (golint)
    • Line 393: warning: exported method TopicListRequestHeader.Encode should have comment or be unexported (golint)
    • Line 400: warning: exported type DeleteTopicRequestHeader should have comment or be unexported (golint)
    • Line 404: warning: exported method DeleteTopicRequestHeader.Encode should have comment or be unexported (golint)
    • Line 411: warning: exported type ConsumeMessageDirectlyHeader should have comment or be unexported (golint)
    • Line 418: warning: exported method ConsumeMessageDirectlyHeader.Encode should have comment or be unexported (golint)
    • Line 427: warning: exported method ConsumeMessageDirectlyHeader.Decode should have comment or be unexported (golint)
    • rocketmq-client-go/internal/utils/net.go
    • Line 30: warning: exported var LocalIP should have comment or be unexported (golint)
    • Line 42: warning: exported function ClientIP4 should have comment or be unexported (golint)
    • Line 57: warning: exported function FakeIP should have comment or be unexported (golint)
    • Line 63: warning: exported function GetAddressByBytes should have comment or be unexported (golint)
    • rocketmq-client-go/consumer/push_consumer.go
    • Line 49: warning: exported const Mb should have comment (or a comment on this block) or be unexported (golint)
    • Line 52: warning: exported type PushConsumerCallback should have comment or be unexported (golint)
    • Line 57: warning: exported method PushConsumerCallback.UniqueID should have comment or be unexported (golint)
    • Line 74: warning: exported function NewPushConsumer should have comment or be unexported (golint)
    • Line 917: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 1223: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 1231: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • rocketmq-client-go/internal/remote/codec.go
    • Line 1: warning: package comment should be of the form "Package remote ..." (golint)
    • Line 1: warning: package comment should not have leading space (golint)
    • Line 32: warning: comment on exported const RPCType should be of the form "RPCType ..." (golint)
    • Line 34: warning: comment on exported const RPCOneWay should be of the form "RPCOneWay ..." (golint)
    • Line 42: warning: exported type LanguageCode should have comment or be unexported (golint)
    • Line 50: warning: exported method LanguageCode.MarshalJSON should have comment or be unexported (golint)
    • Line 54: warning: exported method LanguageCode.UnmarshalJSON should have comment or be unexported (golint)
    • Line 77: warning: exported type RemotingCommand should have comment or be unexported (golint)
    • Line 88: warning: exported type CustomHeader should have comment or be unexported (golint)
    • Line 92: warning: exported function NewRemotingCommand should have comment or be unexported (golint)
    • Line 128: warning: comment on exported method RemotingCommand.WriteTo should be of the form "WriteTo ..." (golint)
    • Line 266: warning: exported const JsonCodecs should have comment (or a comment on this block) or be unexported (golint)
    • rocketmq-client-go/api.go
    • Line 30: warning: exported type Producer should have comment or be unexported (golint)
    • Line 39: warning: exported function NewProducer should have comment or be unexported (golint)
    • Line 43: warning: exported type TransactionProducer should have comment or be unexported (golint)
    • Line 49: warning: exported function NewTransactionProducer should have comment or be unexported (golint)
    • Line 53: warning: exported type PushConsumer should have comment or be unexported (golint)
    • Line 67: warning: exported function NewPushConsumer should have comment or be unexported (golint)
    • Line 71: warning: exported type PullConsumer should have comment or be unexported (golint)
    • Line 132: warning: comment on exported function NewPullConsumer should be of the form "NewPullConsumer ..." (golint)
    • rocketmq-client-go/producer/selector.go
    • Line 29: warning: exported type QueueSelector should have comment or be unexported (golint)
    • Line 36: warning: exported function NewManualQueueSelector should have comment or be unexported (golint)
    • Line 50: warning: exported function NewRandomQueueSelector should have comment or be unexported (golint)
    • Line 69: warning: exported function NewRoundRobinQueueSelector should have comment or be unexported (golint)
    • Line 99: warning: exported function NewHashQueueSelector should have comment or be unexported (golint)
    • rocketmq-client-go/internal/utils/set.go
    • Line 26: warning: exported type UniqueItem should have comment or be unexported (golint)
    • Line 30: warning: exported type StringUnique should have comment or be unexported (golint)
    • Line 32: warning: exported method StringUnique.UniqueID should have comment or be unexported (golint)
    • Line 36: warning: exported type Set should have comment or be unexported (golint)
    • Line 40: warning: exported function NewSet should have comment or be unexported (golint)
    • Line 46: warning: exported method Set.Add should have comment or be unexported (golint)
    • Line 50: warning: exported method Set.AddKV should have comment or be unexported (golint)
    • Line 54: warning: exported method Set.Contains should have comment or be unexported (golint)
    • Line 59: warning: exported method Set.Len should have comment or be unexported (golint)
    • Line 65: warning: exported method Set.MarshalJSON should have comment or be unexported (golint)
    • Line 101: warning: exported method Set.UnmarshalJSON should have comment or be unexported (golint)
    • rocketmq-client-go/consumer/consumer.go
    • Line 62: warning: exported type ConsumeType should have comment or be unexported (golint)
    • Line 72: warning: exported var ErrCreated should have comment or be unexported (golint)
    • Line 76: warning: comment on exported type MessageModel should be of the form "MessageModel ..." (with optional leading article) (golint)
    • Line 89: warning: exported const BroadCasting should have comment (or a comment on this block) or be unexported (golint)
    • Line 104: warning: comment on exported type ConsumeFromWhere should be of the form "ConsumeFromWhere ..." (with optional leading article) (golint)
    • Line 136: warning: exported const ConsumeFromLastOffset should have comment (or a comment on this block) or be unexported (golint)
    • Line 141: warning: exported type ExpressionType should have comment or be unexported (golint)
    • Line 144: warning: comment on exported const SQL92 should be of the form "SQL92 ..." (golint)
    • Line 176: warning: comment on exported const TAG should be of the form "TAG ..." (golint)
    • Line 184: warning: exported function IsTagType should have comment or be unexported (golint)
    • Line 191: warning: exported type MessageSelector should have comment or be unexported (golint)
    • Line 196: warning: exported type ConsumeResult should have comment or be unexported (golint)
    • Line 199: warning: exported const ConsumeSuccess should have comment (or a comment on this block) or be unexported (golint)
    • Line 206: warning: exported type ConsumeResultHolder should have comment or be unexported (golint)
    • Line 210: warning: exported type ConsumerReturn should have comment or be unexported (golint)
    • Line 213: warning: exported const SuccessReturn should have comment (or a comment on this block) or be unexported (golint)
    • Line 220: warning: exported type PullRequest should have comment or be unexported (golint)
    • rocketmq-client-go/primitive/errors.go
    • Line 26: warning: exported var ErrNoNameserver should have comment or be unexported (golint)
    • Line 31: warning: exported type MQBrokerErr should have comment or be unexported (golint)
    • Line 40: warning: exported function NewRemotingErr should have comment or be unexported (golint)
    • Line 44: warning: exported type RemotingErr should have comment or be unexported (golint)
    • Line 52: warning: exported function NewMQClientErr should have comment or be unexported (golint)
    • Line 56: warning: exported type MQClientErr should have comment or be unexported (golint)
    • Line 65: warning: exported function IsRemotingErr should have comment or be unexported (golint)
    • rocketmq-client-go/primitive/pool.go
    • Line 37: warning: exported function GetHeader should have comment or be unexported (golint)
    • Line 43: warning: exported function BackHeader should have comment or be unexported (golint)
    • Line 47: warning: exported function GetBuffer should have comment or be unexported (golint)
    • Line 53: warning: exported function BackBuffer should have comment or be unexported (golint)
    • rocketmq-client-go/internal/model.go
    • Line 33: warning: exported type FindBrokerResult should have comment or be unexported (golint)
    • Line 43: warning: exported type ServiceState should have comment or be unexported (golint)
    • Line 47: warning: exported const StateCreateJust should have comment (or a comment on this block) or be unexported (golint)
    • Line 53: warning: exported type SubscriptionData should have comment or be unexported (golint)
    • Line 90: warning: exported function NewHeartbeatData should have comment or be unexported (golint)
    • Line 111: warning: exported const PropNameServerAddr should have comment (or a comment on this block) or be unexported (golint)
    • Line 119: warning: exported type ProcessQueueInfo should have comment or be unexported (golint)
    • Line 136: warning: exported type ConsumeStatus should have comment or be unexported (golint)
    • Line 145: warning: exported type ConsumerRunningInfo should have comment or be unexported (golint)
    • Line 152: warning: exported method ConsumerRunningInfo.Encode should have comment or be unexported (golint)
    • Line 256: warning: exported function NewConsumerRunningInfo should have comment or be unexported (golint)
    • Line 265: warning: exported type ConsumeMessageDirectlyResult should have comment or be unexported (golint)
    • Line 273: warning: exported type ConsumeResult should have comment or be unexported (golint)
    • Line 276: warning: exported const ConsumeSuccess should have comment (or a comment on this block) or be unexported (golint)
    • Line 284: warning: exported method ConsumeMessageDirectlyResult.Encode should have comment or be unexported (golint)
    • rocketmq-client-go/internal/remote/remote_client.go
    • Line 1: warning: package comment should be of the form "Package remote ..." (golint)
    • Line 1: warning: package comment should not have leading space (golint)
    • Line 33: warning: exported type ClientRequestFunc should have comment or be unexported (golint)
    • Line 35: warning: exported type TcpOption should have comment or be unexported (golint)
    • Line 39: warning: comment on exported type RemotingClient should be of the form "RemotingClient ..." (with optional leading article) (golint)
    • Line 60: warning: exported function NewRemotingClient should have comment or be unexported (golint)
    • Line 290: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • rocketmq-client-go/consumer/statistics.go
    • Line 31: warning: exported type StatsManager should have comment or be unexported (golint)
    • Line 41: warning: exported function NewStatsManager should have comment or be unexported (golint)
    • Line 51: warning: exported type ConsumeStatus should have comment or be unexported (golint)
    • Line 80: warning: exported method StatsManager.GetConsumeStatus should have comment or be unexported (golint)
    • Line 103: warning: exported method StatsManager.ShutDownStat should have comment or be unexported (golint)
    • Line 315: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • rocketmq-client-go/producer/producer.go
    • Line 39: warning: exported var ErrTopicEmpty should have comment or be unexported (golint)
    • Line 55: warning: exported function NewDefaultProducer should have comment or be unexported (golint)
    • Line 132: warning: exported function MarshalMessageBatch should have comment or be unexported (golint)
    • Line 440: warning: comment on exported function NewTransactionProducer should be of the form "NewTransactionProducer ..." (golint)
    • rocketmq-client-go/internal/namesrv.go
    • Line 31: warning: exported const DEFAULT_NAMESRV_ADDR should have comment (or a comment on this block) or be unexported (golint)
    • Line 37: warning: exported var ErrNoNameserver should have comment or be unexported (golint)
    • Line 42: warning: comment on exported type Namesrvs should be of the form "Namesrvs ..." (with optional leading article) (golint)

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!


misspell98%

Misspell Finds commonly misspelled English words