...

Text file src/github.com/twmb/franz-go/generate/definitions/09_offset_fetch

Documentation: github.com/twmb/franz-go/generate/definitions

     1// OffsetFetchRequest requests the most recent committed offsets for topic
     2// partitions in a group.
     3OffsetFetchRequest => key 9, max version 8, flexible v6+, group coordinator
     4  // Group is the group to fetch offsets for.
     5  Group: string // v0-v7
     6  // Topics contains topics to fetch offets for. Version 2+ allows this to be
     7  // null to return all topics the client is authorized to describe in the group.
     8  Topics: nullable-v2+[=>] // v0-v7
     9    // Topic is a topic to fetch offsets for.
    10    Topic: string
    11    // Partitions in a list of partitions in a group to fetch offsets for.
    12    Partitions: [int32]
    13  // Groups, introduced in v8 (Kafka 3.0), allows for fetching offsets for
    14  // multiple groups at a time.
    15  //
    16  // The fields here mirror the old top level fields on the request, thus they
    17  // are left undocumented. Refer to the top level documentation if necessary.
    18  Groups: [=>] // v8+
    19    Group: string
    20    Topics: nullable[=>]
    21      Topic: string
    22      Partitions: [int32]
    23  // RequireStable signifies whether the broker should wait on returning
    24  // unstable offsets, instead setting a retryable error on the relevant
    25  // unstable partitions (UNSTABLE_OFFSET_COMMIT). See KIP-447 for more
    26  // details.
    27  RequireStable: bool // v7+
    28
    29// OffsetFetchResponse is returned from an OffsetFetchRequest.
    30OffsetFetchResponse =>
    31  ThrottleMillis(4) // v3+
    32  // Topics contains responses for each requested topic/partition.
    33  Topics: [=>] // v0-v7
    34    // Topic is the topic this offset fetch response corresponds to.
    35    Topic: string
    36    // Partitions contains responses for each requested partition in
    37    // a topic.
    38    Partitions: [=>]
    39      // Partition is the partition in a topic this array slot corresponds to.
    40      Partition: int32
    41      // Offset is the most recently committed offset for this topic partition
    42      // in a group.
    43      Offset: int64
    44      // LeaderEpoch is the leader epoch of the last consumed record.
    45      //
    46      // This was proposed in KIP-320 and introduced in Kafka 2.1.0 and allows
    47      // clients to detect log truncation. See the KIP for more details.
    48      LeaderEpoch: int32(-1) // v5+
    49      // Metadata is client provided metadata corresponding to the offset commit.
    50      // This can be useful for adding who made the commit, etc.
    51      Metadata: nullable-string
    52      // ErrorCode is the error for this partition response.
    53      //
    54      // GROUP_AUTHORIZATION_FAILED is returned if the client is not authorized
    55      // to the group.
    56      //
    57      // INVALID_GROUP_ID is returned in the requested group ID is invalid.
    58      //
    59      // COORDINATOR_NOT_AVAILABLE is returned if the coordinator is not available
    60      // (due to the requested broker shutting down or it has not completed startup).
    61      //
    62      // COORDINATOR_LOAD_IN_PROGRESS is returned if the group is loading.
    63      //
    64      // NOT_COORDINATOR is returned if the requested broker is not the coordinator
    65      // for the requested group.
    66      //
    67      // UNKNOWN_TOPIC_OR_PARTITION is returned if the requested topic or partition
    68      // is unknown.
    69      //
    70      // UNSTABLE_OFFSET_COMMIT is returned for v7+ if the request set RequireStable.
    71      // See KIP-447 for more details.
    72      ErrorCode: int16
    73  // ErrorCode is a top level error code that applies to all topic/partitions.
    74  // This will be any group error.
    75  ErrorCode: int16 // v2-v7
    76  // Groups is the response for all groups. Each field mirrors the fields in the
    77  // top level request, thus they are left undocumented. Refer to the top level
    78  // documentation if necessary.
    79  Groups: [=>] // v8+
    80    Group: string
    81    Topics: [=>]
    82      Topic: string
    83      Partitions: [=>]
    84        Partition: int32
    85        Offset: int64
    86        LeaderEpoch: int32(-1)
    87        Metadata: nullable-string
    88        ErrorCode: int16
    89    ErrorCode: int16

View as plain text