MCPcopy
hub / github.com/segmentio/kafka-go / makeError

Function makeError

error.go:667–675  ·  view source on GitHub ↗
(code int16, message string)

Source from the content-addressed store, hash-verified

665}
666
667func makeError(code int16, message string) error {
668 if code == 0 {
669 return nil
670 }
671 if message == "" {
672 return Error(code)
673 }
674 return fmt.Errorf("%w: %s", Error(code), message)
675}
676
677// WriteError is returned by kafka.(*Writer).WriteMessages when the writer is
678// not configured to write messages asynchronously. WriteError values contain

Callers 15

LeaveGroupMethod · 0.85
OffsetDeleteMethod · 0.85
CreatePartitionsMethod · 0.85
CreateACLsMethod · 0.85
AlterClientQuotasMethod · 0.85
AddOffsetsToTxnMethod · 0.85
ListGroupsMethod · 0.85
DescribeGroupsMethod · 0.85
RawProduceMethod · 0.85
ElectLeadersMethod · 0.85

Calls 1

ErrorTypeAlias · 0.70

Tested by 4

TestClientDeleteACLsFunction · 0.68
TestClientDescribeACLsFunction · 0.68