Repository Analysis

IBM/sarama

Sarama is a Go library for Apache Kafka.

1.1 Likely human-written View on GitHub
1.1
Adjusted Score
1.1
Raw Score
100%
Time Factor
2026-05-30
Last Push
12,486
Stars
Go
Language
81,843
Lines of Code
347
Files
76
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 1HIGH 0MEDIUM 0LOW 75

Pattern Findings

76 matches across 3 categories. Click a row to expand file-level details.

Over-Commented Block74 hits · 73 pts
SeverityFileLineSnippet
LOWpartitioner.go21 // partitions (even ones known to be unavailable), and its choice must be
LOWconfig.go41 // Net is the namespace for network-level properties used by the Broker, and
LOWconfig.go61 // original address list. Similar to the `client.dns.lookup` option in
LOWconfig.go81 Enable bool
LOWconfig.go141 // cluster is in the middle of a leader election (default 3).
LOWconfig.go161
LOWconfig.go181 }
LOWconfig.go201 Compression CompressionCodec
LOWconfig.go221
LOWconfig.go241 // this internally.
LOWconfig.go261 // `MaxMessages` to set a hard upper limit.
LOWconfig.go281 // more sophisticated backoff strategies. This takes precedence over
LOWconfig.go301 // message for the first time. Interceptors allows to intercept and
LOWconfig.go321 Timeout time.Duration
LOWconfig.go341 // strategy that all group members support will be chosen by the leader.
LOWconfig.go381 // How long to wait after a failing to read from a partition before
LOWconfig.go401 // as 0 causes the consumer to spin when no messages are available.
LOWconfig.go421 // one extra RecordBatch beyond it to guarantee progress when a single
LOWconfig.go441 // of the expiryTicker then a timeout is detected.
LOWconfig.go461 // Offsets specifies configuration for how and when to commit consumed
LOWconfig.go481 // Should be OffsetNewest or OffsetOldest. Defaults to OffsetNewest.
LOWconfig.go501 // - use `ReadCommitted` to hide messages that are part of an aborted transaction
LOWconfig.go521 // The number of events to buffer in internal and external channels. This
LOWmetadata.go241 for {
LOWsync_producer.go21type SyncProducer interface {
LOWasync_producer.go21 // minFunctionalRetryBufferLength defines the minimum number of messages the retry buffer must support.
LOWasync_producer.go41 // drain the results of any messages in flight.
LOWasync_producer.go341
LOWasync_producer.go361 // Timestamp can vary in behavior depending on broker configuration, being
LOWCHANGELOG.md1301#1817 - reverts #1785 - Add private method to Client interface to prevent implementation
LOWCHANGELOG.md1321### Improvements
LOWrequest_test.go421 apiKeyMetadata: 10, // up from 9
LOWrequest_test.go501 {
LOWrequest.go221 return &DescribeClusterRequest{Version: version}
LOWfetch_response.go41
LOWoffset_manager.go501 if om.sessionCanceler != nil {
LOWoffset_manager.go521 // metadata string can be used by another consumer to restore that state, so it
LOWoffset_manager.go541 // Errors returns a read channel of errors that occur during offset management, if
LOWclient.go21// automatically when it passes out of scope. It is safe to share a client amongst many
LOWclient.go81 // available metadata for those topics. If no topics are provided, it will refresh
LOWclient.go121 // to call this function before a client object passes out of scope, as it will
LOWclient.go1081 if client.Closed() {
LOWinterceptors.go1package sarama
LOWproduce_response.go1package sarama
LOWadmin.go21 // It may take several seconds after CreateTopic returns success for all the brokers
LOWadmin.go41 // If partitions are increased for a topic that has a key, the partition logic or ordering of
LOWadmin.go61 // The returned configuration includes default values and the Default is true
LOWadmin.go81
LOWadmin.go121 //
LOWconsumer.go61 // This method is the same as Client.Partitions(), and is provided for convenience.
LOWconsumer.go341
LOWconsumer.go361 // should continue to service the 'Messages' and 'Errors' channels until they are empty. It is required to call this
LOWconsumer.go381 Errors() <-chan *ConsumerError
LOWfetch_request.go61 // is from a consumer.
LOWdescribe_client_quotas_response.go1package sarama
LOWconfig_test.go601 metrics.WriteOnce(appMetricRegistry, os.Stdout)
LOWjoin_group_request.go41 SessionTimeout int32
LOWbalance_strategy.go61// BalanceStrategy that lets a strategy inject per-cycle metadata into the
LOWbalance_strategy.go121// Example with topic T with six partitions (0..5) and two members (M1, M2):
LOWconsumer_group.go21var ErrSessionPartitionCountChanged = errors.New("kafka: partition count changed for subscribed topic")
14 more matches not shown…
Hallucination Indicators1 hit · 15 pts
SeverityFileLineSnippet
CRITICALpartitioner_test.go324 // org.apache.kafka.common.utils.Utils.murmur2() implementation
Example Usage Blocks1 hit · 2 pts
SeverityFileLineSnippet
LOWutils.go359// Example usage: