package proto

import proto1 "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"

import io "io"

var _ = proto1.Marshal
var _ = fmt.Errorf
var _ = math.Inf

const _ = proto1.ProtoPackageIsVersion2 

type Op int32

const (
	Op_CREATE_PARTITION Op = 0
	Op_SHRINK_ISR       Op = 1
	Op_REPORT_LEADER    Op = 2
	Op_CHANGE_LEADER    Op = 3
	Op_EXPAND_ISR       Op = 4
)

var Op_name = map[int32]string{
	0: "CREATE_PARTITION",
	1: "SHRINK_ISR",
	2: "REPORT_LEADER",
	3: "CHANGE_LEADER",
	4: "EXPAND_ISR",
}
var Op_value = map[string]int32{
	"CREATE_PARTITION": 0,
	"SHRINK_ISR":       1,
	"REPORT_LEADER":    2,
	"CHANGE_LEADER":    3,
	"EXPAND_ISR":       4,
}

func (x Op) String() string {
	return proto1.EnumName(Op_name, int32(x))
}
func (Op) EnumDescriptor() ([]byte, []int) { return fileDescriptorInternal, []int{0} }

type ServerState struct {
	ServerID string `protobuf:"bytes,1,opt,name=serverID,proto3" json:"serverID,omitempty"`
}

func (m *ServerState) Reset()                    { *m = ServerState{} }
func (m *ServerState) String() string            { return proto1.CompactTextString(m) }
func (*ServerState) ProtoMessage()               {}
func (*ServerState) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{0} }

func (m *ServerState) GetServerID() string {
	if m != nil {
		return m.ServerID
	}
	return ""
}

type RaftLog struct {
	Op                Op                 `protobuf:"varint,1,opt,name=op,proto3,enum=proto.Op" json:"op,omitempty"`
	CreatePartitionOp *CreatePartitionOp `protobuf:"bytes,2,opt,name=createPartitionOp" json:"createPartitionOp,omitempty"`
	ShrinkISROp       *ShrinkISROp       `protobuf:"bytes,3,opt,name=shrinkISROp" json:"shrinkISROp,omitempty"`
	ChangeLeaderOp    *ChangeLeaderOp    `protobuf:"bytes,4,opt,name=changeLeaderOp" json:"changeLeaderOp,omitempty"`
	ExpandISROp       *ExpandISROp       `protobuf:"bytes,5,opt,name=expandISROp" json:"expandISROp,omitempty"`
}

func (m *RaftLog) Reset()                    { *m = RaftLog{} }
func (m *RaftLog) String() string            { return proto1.CompactTextString(m) }
func (*RaftLog) ProtoMessage()               {}
func (*RaftLog) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{1} }

func (m *RaftLog) GetOp() Op {
	if m != nil {
		return m.Op
	}
	return Op_CREATE_PARTITION
}

func (m *RaftLog) GetCreatePartitionOp() *CreatePartitionOp {
	if m != nil {
		return m.CreatePartitionOp
	}
	return nil
}

func (m *RaftLog) GetShrinkISROp() *ShrinkISROp {
	if m != nil {
		return m.ShrinkISROp
	}
	return nil
}

func (m *RaftLog) GetChangeLeaderOp() *ChangeLeaderOp {
	if m != nil {
		return m.ChangeLeaderOp
	}
	return nil
}

func (m *RaftLog) GetExpandISROp() *ExpandISROp {
	if m != nil {
		return m.ExpandISROp
	}
	return nil
}

type CreatePartitionOp struct {
	Partition *Partition `protobuf:"bytes,1,opt,name=partition" json:"partition,omitempty"`
}

func (m *CreatePartitionOp) Reset()                    { *m = CreatePartitionOp{} }
func (m *CreatePartitionOp) String() string            { return proto1.CompactTextString(m) }
func (*CreatePartitionOp) ProtoMessage()               {}
func (*CreatePartitionOp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{2} }

func (m *CreatePartitionOp) GetPartition() *Partition {
	if m != nil {
		return m.Partition
	}
	return nil
}

type ShrinkISROp struct {
	Stream          string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition       int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
	ReplicaToRemove string `protobuf:"bytes,3,opt,name=replicaToRemove,proto3" json:"replicaToRemove,omitempty"`
	Leader          string `protobuf:"bytes,4,opt,name=leader,proto3" json:"leader,omitempty"`
	LeaderEpoch     uint64 `protobuf:"varint,5,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
}

func (m *ShrinkISROp) Reset()                    { *m = ShrinkISROp{} }
func (m *ShrinkISROp) String() string            { return proto1.CompactTextString(m) }
func (*ShrinkISROp) ProtoMessage()               {}
func (*ShrinkISROp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{3} }

func (m *ShrinkISROp) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *ShrinkISROp) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

func (m *ShrinkISROp) GetReplicaToRemove() string {
	if m != nil {
		return m.ReplicaToRemove
	}
	return ""
}

func (m *ShrinkISROp) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

func (m *ShrinkISROp) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

type ExpandISROp struct {
	Stream       string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition    int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
	ReplicaToAdd string `protobuf:"bytes,3,opt,name=replicaToAdd,proto3" json:"replicaToAdd,omitempty"`
	Leader       string `protobuf:"bytes,4,opt,name=leader,proto3" json:"leader,omitempty"`
	LeaderEpoch  uint64 `protobuf:"varint,5,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
}

func (m *ExpandISROp) Reset()                    { *m = ExpandISROp{} }
func (m *ExpandISROp) String() string            { return proto1.CompactTextString(m) }
func (*ExpandISROp) ProtoMessage()               {}
func (*ExpandISROp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{4} }

func (m *ExpandISROp) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *ExpandISROp) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

func (m *ExpandISROp) GetReplicaToAdd() string {
	if m != nil {
		return m.ReplicaToAdd
	}
	return ""
}

func (m *ExpandISROp) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

func (m *ExpandISROp) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

type ReportLeaderOp struct {
	Stream      string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition   int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
	Replica     string `protobuf:"bytes,3,opt,name=replica,proto3" json:"replica,omitempty"`
	Leader      string `protobuf:"bytes,4,opt,name=leader,proto3" json:"leader,omitempty"`
	LeaderEpoch uint64 `protobuf:"varint,5,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
}

func (m *ReportLeaderOp) Reset()                    { *m = ReportLeaderOp{} }
func (m *ReportLeaderOp) String() string            { return proto1.CompactTextString(m) }
func (*ReportLeaderOp) ProtoMessage()               {}
func (*ReportLeaderOp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{5} }

func (m *ReportLeaderOp) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *ReportLeaderOp) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

func (m *ReportLeaderOp) GetReplica() string {
	if m != nil {
		return m.Replica
	}
	return ""
}

func (m *ReportLeaderOp) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

func (m *ReportLeaderOp) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

type ChangeLeaderOp struct {
	Stream    string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
	Leader    string `protobuf:"bytes,3,opt,name=leader,proto3" json:"leader,omitempty"`
}

func (m *ChangeLeaderOp) Reset()                    { *m = ChangeLeaderOp{} }
func (m *ChangeLeaderOp) String() string            { return proto1.CompactTextString(m) }
func (*ChangeLeaderOp) ProtoMessage()               {}
func (*ChangeLeaderOp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{6} }

func (m *ChangeLeaderOp) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *ChangeLeaderOp) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

func (m *ChangeLeaderOp) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

type Partition struct {
	Subject           string   `protobuf:"bytes,1,opt,name=subject,proto3" json:"subject,omitempty"`
	Stream            string   `protobuf:"bytes,2,opt,name=stream,proto3" json:"stream,omitempty"`
	Id                int32    `protobuf:"varint,3,opt,name=id,proto3" json:"id,omitempty"`
	Group             string   `protobuf:"bytes,4,opt,name=group,proto3" json:"group,omitempty"`
	ReplicationFactor int32    `protobuf:"varint,5,opt,name=replicationFactor,proto3" json:"replicationFactor,omitempty"`
	Replicas          []string `protobuf:"bytes,6,rep,name=replicas" json:"replicas,omitempty"`
	Leader            string   `protobuf:"bytes,7,opt,name=leader,proto3" json:"leader,omitempty"`
	Isr               []string `protobuf:"bytes,8,rep,name=isr" json:"isr,omitempty"`
	LeaderEpoch       uint64   `protobuf:"varint,9,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
	Epoch             uint64   `protobuf:"varint,10,opt,name=epoch,proto3" json:"epoch,omitempty"`
}

func (m *Partition) Reset()                    { *m = Partition{} }
func (m *Partition) String() string            { return proto1.CompactTextString(m) }
func (*Partition) ProtoMessage()               {}
func (*Partition) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{7} }

func (m *Partition) GetSubject() string {
	if m != nil {
		return m.Subject
	}
	return ""
}

func (m *Partition) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *Partition) GetId() int32 {
	if m != nil {
		return m.Id
	}
	return 0
}

func (m *Partition) GetGroup() string {
	if m != nil {
		return m.Group
	}
	return ""
}

func (m *Partition) GetReplicationFactor() int32 {
	if m != nil {
		return m.ReplicationFactor
	}
	return 0
}

func (m *Partition) GetReplicas() []string {
	if m != nil {
		return m.Replicas
	}
	return nil
}

func (m *Partition) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

func (m *Partition) GetIsr() []string {
	if m != nil {
		return m.Isr
	}
	return nil
}

func (m *Partition) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

func (m *Partition) GetEpoch() uint64 {
	if m != nil {
		return m.Epoch
	}
	return 0
}

type RaftJoinRequest struct {
	NodeID   string `protobuf:"bytes,1,opt,name=nodeID,proto3" json:"nodeID,omitempty"`
	NodeAddr string `protobuf:"bytes,2,opt,name=nodeAddr,proto3" json:"nodeAddr,omitempty"`
}

func (m *RaftJoinRequest) Reset()                    { *m = RaftJoinRequest{} }
func (m *RaftJoinRequest) String() string            { return proto1.CompactTextString(m) }
func (*RaftJoinRequest) ProtoMessage()               {}
func (*RaftJoinRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{8} }

func (m *RaftJoinRequest) GetNodeID() string {
	if m != nil {
		return m.NodeID
	}
	return ""
}

func (m *RaftJoinRequest) GetNodeAddr() string {
	if m != nil {
		return m.NodeAddr
	}
	return ""
}

type RaftJoinResponse struct {
	Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
}

func (m *RaftJoinResponse) Reset()                    { *m = RaftJoinResponse{} }
func (m *RaftJoinResponse) String() string            { return proto1.CompactTextString(m) }
func (*RaftJoinResponse) ProtoMessage()               {}
func (*RaftJoinResponse) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{9} }

func (m *RaftJoinResponse) GetError() string {
	if m != nil {
		return m.Error
	}
	return ""
}

type MetadataSnapshot struct {
	Partitions []*Partition `protobuf:"bytes,1,rep,name=partitions" json:"partitions,omitempty"`
}

func (m *MetadataSnapshot) Reset()                    { *m = MetadataSnapshot{} }
func (m *MetadataSnapshot) String() string            { return proto1.CompactTextString(m) }
func (*MetadataSnapshot) ProtoMessage()               {}
func (*MetadataSnapshot) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{10} }

func (m *MetadataSnapshot) GetPartitions() []*Partition {
	if m != nil {
		return m.Partitions
	}
	return nil
}

type ReplicationRequest struct {
	ReplicaID string `protobuf:"bytes,1,opt,name=replicaID,proto3" json:"replicaID,omitempty"`
	Offset    int64  `protobuf:"varint,2,opt,name=offset,proto3" json:"offset,omitempty"`
}

func (m *ReplicationRequest) Reset()                    { *m = ReplicationRequest{} }
func (m *ReplicationRequest) String() string            { return proto1.CompactTextString(m) }
func (*ReplicationRequest) ProtoMessage()               {}
func (*ReplicationRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{11} }

func (m *ReplicationRequest) GetReplicaID() string {
	if m != nil {
		return m.ReplicaID
	}
	return ""
}

func (m *ReplicationRequest) GetOffset() int64 {
	if m != nil {
		return m.Offset
	}
	return 0
}

type LeaderEpochOffsetRequest struct {
	LeaderEpoch uint64 `protobuf:"varint,1,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
}

func (m *LeaderEpochOffsetRequest) Reset()         { *m = LeaderEpochOffsetRequest{} }
func (m *LeaderEpochOffsetRequest) String() string { return proto1.CompactTextString(m) }
func (*LeaderEpochOffsetRequest) ProtoMessage()    {}
func (*LeaderEpochOffsetRequest) Descriptor() ([]byte, []int) {
	return fileDescriptorInternal, []int{12}
}

func (m *LeaderEpochOffsetRequest) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

type LeaderEpochOffsetResponse struct {
	EndOffset int64 `protobuf:"varint,1,opt,name=endOffset,proto3" json:"endOffset,omitempty"`
}

func (m *LeaderEpochOffsetResponse) Reset()         { *m = LeaderEpochOffsetResponse{} }
func (m *LeaderEpochOffsetResponse) String() string { return proto1.CompactTextString(m) }
func (*LeaderEpochOffsetResponse) ProtoMessage()    {}
func (*LeaderEpochOffsetResponse) Descriptor() ([]byte, []int) {
	return fileDescriptorInternal, []int{13}
}

func (m *LeaderEpochOffsetResponse) GetEndOffset() int64 {
	if m != nil {
		return m.EndOffset
	}
	return 0
}

type PropagatedRequest struct {
	Op                Op                 `protobuf:"varint,1,opt,name=op,proto3,enum=proto.Op" json:"op,omitempty"`
	CreatePartitionOp *CreatePartitionOp `protobuf:"bytes,2,opt,name=createPartitionOp" json:"createPartitionOp,omitempty"`
	ShrinkISROp       *ShrinkISROp       `protobuf:"bytes,3,opt,name=shrinkISROp" json:"shrinkISROp,omitempty"`
	ReportLeaderOp    *ReportLeaderOp    `protobuf:"bytes,4,opt,name=reportLeaderOp" json:"reportLeaderOp,omitempty"`
	ExpandISROp       *ExpandISROp       `protobuf:"bytes,5,opt,name=expandISROp" json:"expandISROp,omitempty"`
}

func (m *PropagatedRequest) Reset()                    { *m = PropagatedRequest{} }
func (m *PropagatedRequest) String() string            { return proto1.CompactTextString(m) }
func (*PropagatedRequest) ProtoMessage()               {}
func (*PropagatedRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{14} }

func (m *PropagatedRequest) GetOp() Op {
	if m != nil {
		return m.Op
	}
	return Op_CREATE_PARTITION
}

func (m *PropagatedRequest) GetCreatePartitionOp() *CreatePartitionOp {
	if m != nil {
		return m.CreatePartitionOp
	}
	return nil
}

func (m *PropagatedRequest) GetShrinkISROp() *ShrinkISROp {
	if m != nil {
		return m.ShrinkISROp
	}
	return nil
}

func (m *PropagatedRequest) GetReportLeaderOp() *ReportLeaderOp {
	if m != nil {
		return m.ReportLeaderOp
	}
	return nil
}

func (m *PropagatedRequest) GetExpandISROp() *ExpandISROp {
	if m != nil {
		return m.ExpandISROp
	}
	return nil
}

type Error struct {
	Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
	Msg  string `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"`
}

func (m *Error) Reset()                    { *m = Error{} }
func (m *Error) String() string            { return proto1.CompactTextString(m) }
func (*Error) ProtoMessage()               {}
func (*Error) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{15} }

func (m *Error) GetCode() uint32 {
	if m != nil {
		return m.Code
	}
	return 0
}

func (m *Error) GetMsg() string {
	if m != nil {
		return m.Msg
	}
	return ""
}

type PropagatedResponse struct {
	Op    Op     `protobuf:"varint,1,opt,name=op,proto3,enum=proto.Op" json:"op,omitempty"`
	Error *Error `protobuf:"bytes,2,opt,name=error" json:"error,omitempty"`
}

func (m *PropagatedResponse) Reset()                    { *m = PropagatedResponse{} }
func (m *PropagatedResponse) String() string            { return proto1.CompactTextString(m) }
func (*PropagatedResponse) ProtoMessage()               {}
func (*PropagatedResponse) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{16} }

func (m *PropagatedResponse) GetOp() Op {
	if m != nil {
		return m.Op
	}
	return Op_CREATE_PARTITION
}

func (m *PropagatedResponse) GetError() *Error {
	if m != nil {
		return m.Error
	}
	return nil
}

type ServerInfoRequest struct {
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
}

func (m *ServerInfoRequest) Reset()                    { *m = ServerInfoRequest{} }
func (m *ServerInfoRequest) String() string            { return proto1.CompactTextString(m) }
func (*ServerInfoRequest) ProtoMessage()               {}
func (*ServerInfoRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{17} }

func (m *ServerInfoRequest) GetId() string {
	if m != nil {
		return m.Id
	}
	return ""
}

type ServerInfoResponse struct {
	Id   string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Host string `protobuf:"bytes,2,opt,name=host,proto3" json:"host,omitempty"`
	Port int32  `protobuf:"varint,3,opt,name=port,proto3" json:"port,omitempty"`
}

func (m *ServerInfoResponse) Reset()                    { *m = ServerInfoResponse{} }
func (m *ServerInfoResponse) String() string            { return proto1.CompactTextString(m) }
func (*ServerInfoResponse) ProtoMessage()               {}
func (*ServerInfoResponse) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{18} }

func (m *ServerInfoResponse) GetId() string {
	if m != nil {
		return m.Id
	}
	return ""
}

func (m *ServerInfoResponse) GetHost() string {
	if m != nil {
		return m.Host
	}
	return ""
}

func (m *ServerInfoResponse) GetPort() int32 {
	if m != nil {
		return m.Port
	}
	return 0
}

type PartitionStatusRequest struct {
	Stream    string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
}

func (m *PartitionStatusRequest) Reset()                    { *m = PartitionStatusRequest{} }
func (m *PartitionStatusRequest) String() string            { return proto1.CompactTextString(m) }
func (*PartitionStatusRequest) ProtoMessage()               {}
func (*PartitionStatusRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{19} }

func (m *PartitionStatusRequest) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *PartitionStatusRequest) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

type PartitionStatusResponse struct {
	Exists   bool `protobuf:"varint,1,opt,name=exists,proto3" json:"exists,omitempty"`
	IsLeader bool `protobuf:"varint,2,opt,name=isLeader,proto3" json:"isLeader,omitempty"`
}

func (m *PartitionStatusResponse) Reset()                    { *m = PartitionStatusResponse{} }
func (m *PartitionStatusResponse) String() string            { return proto1.CompactTextString(m) }
func (*PartitionStatusResponse) ProtoMessage()               {}
func (*PartitionStatusResponse) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{20} }

func (m *PartitionStatusResponse) GetExists() bool {
	if m != nil {
		return m.Exists
	}
	return false
}

func (m *PartitionStatusResponse) GetIsLeader() bool {
	if m != nil {
		return m.IsLeader
	}
	return false
}

func init() {
	proto1.RegisterType((*ServerState)(nil), "proto.ServerState")
	proto1.RegisterType((*RaftLog)(nil), "proto.RaftLog")
	proto1.RegisterType((*CreatePartitionOp)(nil), "proto.CreatePartitionOp")
	proto1.RegisterType((*ShrinkISROp)(nil), "proto.ShrinkISROp")
	proto1.RegisterType((*ExpandISROp)(nil), "proto.ExpandISROp")
	proto1.RegisterType((*ReportLeaderOp)(nil), "proto.ReportLeaderOp")
	proto1.RegisterType((*ChangeLeaderOp)(nil), "proto.ChangeLeaderOp")
	proto1.RegisterType((*Partition)(nil), "proto.Partition")
	proto1.RegisterType((*RaftJoinRequest)(nil), "proto.RaftJoinRequest")
	proto1.RegisterType((*RaftJoinResponse)(nil), "proto.RaftJoinResponse")
	proto1.RegisterType((*MetadataSnapshot)(nil), "proto.MetadataSnapshot")
	proto1.RegisterType((*ReplicationRequest)(nil), "proto.ReplicationRequest")
	proto1.RegisterType((*LeaderEpochOffsetRequest)(nil), "proto.LeaderEpochOffsetRequest")
	proto1.RegisterType((*LeaderEpochOffsetResponse)(nil), "proto.LeaderEpochOffsetResponse")
	proto1.RegisterType((*PropagatedRequest)(nil), "proto.PropagatedRequest")
	proto1.RegisterType((*Error)(nil), "proto.Error")
	proto1.RegisterType((*PropagatedResponse)(nil), "proto.PropagatedResponse")
	proto1.RegisterType((*ServerInfoRequest)(nil), "proto.ServerInfoRequest")
	proto1.RegisterType((*ServerInfoResponse)(nil), "proto.ServerInfoResponse")
	proto1.RegisterType((*PartitionStatusRequest)(nil), "proto.PartitionStatusRequest")
	proto1.RegisterType((*PartitionStatusResponse)(nil), "proto.PartitionStatusResponse")
	proto1.RegisterEnum("proto.Op", Op_name, Op_value)
}
func (m *ServerState) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ServerState) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.ServerID) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.ServerID)))
		i += copy(dAtA[i:], m.ServerID)
	}
	return i, nil
}

func (m *RaftLog) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *RaftLog) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Op != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Op))
	}
	if m.CreatePartitionOp != nil {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.CreatePartitionOp.Size()))
		n1, err := m.CreatePartitionOp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n1
	}
	if m.ShrinkISROp != nil {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ShrinkISROp.Size()))
		n2, err := m.ShrinkISROp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n2
	}
	if m.ChangeLeaderOp != nil {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ChangeLeaderOp.Size()))
		n3, err := m.ChangeLeaderOp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n3
	}
	if m.ExpandISROp != nil {
		dAtA[i] = 0x2a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ExpandISROp.Size()))
		n4, err := m.ExpandISROp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n4
	}
	return i, nil
}

func (m *CreatePartitionOp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *CreatePartitionOp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Partition != nil {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition.Size()))
		n5, err := m.Partition.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n5
	}
	return i, nil
}

func (m *ShrinkISROp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ShrinkISROp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	if len(m.ReplicaToRemove) > 0 {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.ReplicaToRemove)))
		i += copy(dAtA[i:], m.ReplicaToRemove)
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x28
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	return i, nil
}

func (m *ExpandISROp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ExpandISROp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	if len(m.ReplicaToAdd) > 0 {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.ReplicaToAdd)))
		i += copy(dAtA[i:], m.ReplicaToAdd)
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x28
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	return i, nil
}

func (m *ReportLeaderOp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ReportLeaderOp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	if len(m.Replica) > 0 {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Replica)))
		i += copy(dAtA[i:], m.Replica)
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x28
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	return i, nil
}

func (m *ChangeLeaderOp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ChangeLeaderOp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	return i, nil
}

func (m *Partition) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Partition) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Subject) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Subject)))
		i += copy(dAtA[i:], m.Subject)
	}
	if len(m.Stream) > 0 {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Id != 0 {
		dAtA[i] = 0x18
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Id))
	}
	if len(m.Group) > 0 {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Group)))
		i += copy(dAtA[i:], m.Group)
	}
	if m.ReplicationFactor != 0 {
		dAtA[i] = 0x28
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ReplicationFactor))
	}
	if len(m.Replicas) > 0 {
		for _, s := range m.Replicas {
			dAtA[i] = 0x32
			i++
			l = len(s)
			for l >= 1<<7 {
				dAtA[i] = uint8(uint64(l)&0x7f | 0x80)
				l >>= 7
				i++
			}
			dAtA[i] = uint8(l)
			i++
			i += copy(dAtA[i:], s)
		}
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x3a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	if len(m.Isr) > 0 {
		for _, s := range m.Isr {
			dAtA[i] = 0x42
			i++
			l = len(s)
			for l >= 1<<7 {
				dAtA[i] = uint8(uint64(l)&0x7f | 0x80)
				l >>= 7
				i++
			}
			dAtA[i] = uint8(l)
			i++
			i += copy(dAtA[i:], s)
		}
	}
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x48
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	if m.Epoch != 0 {
		dAtA[i] = 0x50
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Epoch))
	}
	return i, nil
}

func (m *RaftJoinRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *RaftJoinRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.NodeID) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.NodeID)))
		i += copy(dAtA[i:], m.NodeID)
	}
	if len(m.NodeAddr) > 0 {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.NodeAddr)))
		i += copy(dAtA[i:], m.NodeAddr)
	}
	return i, nil
}

func (m *RaftJoinResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *RaftJoinResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Error) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Error)))
		i += copy(dAtA[i:], m.Error)
	}
	return i, nil
}

func (m *MetadataSnapshot) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *MetadataSnapshot) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Partitions) > 0 {
		for _, msg := range m.Partitions {
			dAtA[i] = 0xa
			i++
			i = encodeVarintInternal(dAtA, i, uint64(msg.Size()))
			n, err := msg.MarshalTo(dAtA[i:])
			if err != nil {
				return 0, err
			}
			i += n
		}
	}
	return i, nil
}

func (m *ReplicationRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ReplicationRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.ReplicaID) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.ReplicaID)))
		i += copy(dAtA[i:], m.ReplicaID)
	}
	if m.Offset != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Offset))
	}
	return i, nil
}

func (m *LeaderEpochOffsetRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *LeaderEpochOffsetRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	return i, nil
}

func (m *LeaderEpochOffsetResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *LeaderEpochOffsetResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.EndOffset != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.EndOffset))
	}
	return i, nil
}

func (m *PropagatedRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *PropagatedRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Op != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Op))
	}
	if m.CreatePartitionOp != nil {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.CreatePartitionOp.Size()))
		n6, err := m.CreatePartitionOp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n6
	}
	if m.ShrinkISROp != nil {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ShrinkISROp.Size()))
		n7, err := m.ShrinkISROp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n7
	}
	if m.ReportLeaderOp != nil {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ReportLeaderOp.Size()))
		n8, err := m.ReportLeaderOp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n8
	}
	if m.ExpandISROp != nil {
		dAtA[i] = 0x2a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ExpandISROp.Size()))
		n9, err := m.ExpandISROp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n9
	}
	return i, nil
}

func (m *Error) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Error) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Code != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Code))
	}
	if len(m.Msg) > 0 {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Msg)))
		i += copy(dAtA[i:], m.Msg)
	}
	return i, nil
}

func (m *PropagatedResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *PropagatedResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Op != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Op))
	}
	if m.Error != nil {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Error.Size()))
		n10, err := m.Error.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n10
	}
	return i, nil
}

func (m *ServerInfoRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ServerInfoRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Id) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Id)))
		i += copy(dAtA[i:], m.Id)
	}
	return i, nil
}

func (m *ServerInfoResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ServerInfoResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Id) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Id)))
		i += copy(dAtA[i:], m.Id)
	}
	if len(m.Host) > 0 {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Host)))
		i += copy(dAtA[i:], m.Host)
	}
	if m.Port != 0 {
		dAtA[i] = 0x18
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Port))
	}
	return i, nil
}

func (m *PartitionStatusRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *PartitionStatusRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	return i, nil
}

func (m *PartitionStatusResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *PartitionStatusResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Exists {
		dAtA[i] = 0x8
		i++
		if m.Exists {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i++
	}
	if m.IsLeader {
		dAtA[i] = 0x10
		i++
		if m.IsLeader {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i++
	}
	return i, nil
}

func encodeVarintInternal(dAtA []byte, offset int, v uint64) int {
	for v >= 1<<7 {
		dAtA[offset] = uint8(v&0x7f | 0x80)
		v >>= 7
		offset++
	}
	dAtA[offset] = uint8(v)
	return offset + 1
}
func (m *ServerState) Size() (n int) {
	var l int
	_ = l
	l = len(m.ServerID)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *RaftLog) Size() (n int) {
	var l int
	_ = l
	if m.Op != 0 {
		n += 1 + sovInternal(uint64(m.Op))
	}
	if m.CreatePartitionOp != nil {
		l = m.CreatePartitionOp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ShrinkISROp != nil {
		l = m.ShrinkISROp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ChangeLeaderOp != nil {
		l = m.ChangeLeaderOp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ExpandISROp != nil {
		l = m.ExpandISROp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *CreatePartitionOp) Size() (n int) {
	var l int
	_ = l
	if m.Partition != nil {
		l = m.Partition.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *ShrinkISROp) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	l = len(m.ReplicaToRemove)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	return n
}

func (m *ExpandISROp) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	l = len(m.ReplicaToAdd)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	return n
}

func (m *ReportLeaderOp) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	l = len(m.Replica)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	return n
}

func (m *ChangeLeaderOp) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *Partition) Size() (n int) {
	var l int
	_ = l
	l = len(m.Subject)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Id != 0 {
		n += 1 + sovInternal(uint64(m.Id))
	}
	l = len(m.Group)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ReplicationFactor != 0 {
		n += 1 + sovInternal(uint64(m.ReplicationFactor))
	}
	if len(m.Replicas) > 0 {
		for _, s := range m.Replicas {
			l = len(s)
			n += 1 + l + sovInternal(uint64(l))
		}
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if len(m.Isr) > 0 {
		for _, s := range m.Isr {
			l = len(s)
			n += 1 + l + sovInternal(uint64(l))
		}
	}
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	if m.Epoch != 0 {
		n += 1 + sovInternal(uint64(m.Epoch))
	}
	return n
}

func (m *RaftJoinRequest) Size() (n int) {
	var l int
	_ = l
	l = len(m.NodeID)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.NodeAddr)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *RaftJoinResponse) Size() (n int) {
	var l int
	_ = l
	l = len(m.Error)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *MetadataSnapshot) Size() (n int) {
	var l int
	_ = l
	if len(m.Partitions) > 0 {
		for _, e := range m.Partitions {
			l = e.Size()
			n += 1 + l + sovInternal(uint64(l))
		}
	}
	return n
}

func (m *ReplicationRequest) Size() (n int) {
	var l int
	_ = l
	l = len(m.ReplicaID)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Offset != 0 {
		n += 1 + sovInternal(uint64(m.Offset))
	}
	return n
}

func (m *LeaderEpochOffsetRequest) Size() (n int) {
	var l int
	_ = l
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	return n
}

func (m *LeaderEpochOffsetResponse) Size() (n int) {
	var l int
	_ = l
	if m.EndOffset != 0 {
		n += 1 + sovInternal(uint64(m.EndOffset))
	}
	return n
}

func (m *PropagatedRequest) Size() (n int) {
	var l int
	_ = l
	if m.Op != 0 {
		n += 1 + sovInternal(uint64(m.Op))
	}
	if m.CreatePartitionOp != nil {
		l = m.CreatePartitionOp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ShrinkISROp != nil {
		l = m.ShrinkISROp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ReportLeaderOp != nil {
		l = m.ReportLeaderOp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ExpandISROp != nil {
		l = m.ExpandISROp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *Error) Size() (n int) {
	var l int
	_ = l
	if m.Code != 0 {
		n += 1 + sovInternal(uint64(m.Code))
	}
	l = len(m.Msg)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *PropagatedResponse) Size() (n int) {
	var l int
	_ = l
	if m.Op != 0 {
		n += 1 + sovInternal(uint64(m.Op))
	}
	if m.Error != nil {
		l = m.Error.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *ServerInfoRequest) Size() (n int) {
	var l int
	_ = l
	l = len(m.Id)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *ServerInfoResponse) Size() (n int) {
	var l int
	_ = l
	l = len(m.Id)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Host)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Port != 0 {
		n += 1 + sovInternal(uint64(m.Port))
	}
	return n
}

func (m *PartitionStatusRequest) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	return n
}

func (m *PartitionStatusResponse) Size() (n int) {
	var l int
	_ = l
	if m.Exists {
		n += 2
	}
	if m.IsLeader {
		n += 2
	}
	return n
}

func sovInternal(x uint64) (n int) {
	for {
		n++
		x >>= 7
		if x == 0 {
			break
		}
	}
	return n
}
func sozInternal(x uint64) (n int) {
	return sovInternal(uint64((x << 1) ^ uint64((int64(x) >> 63))))
}
func (m *ServerState) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ServerState: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ServerState: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ServerID", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ServerID = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *RaftLog) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: RaftLog: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: RaftLog: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Op", wireType)
			}
			m.Op = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Op |= (Op(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field CreatePartitionOp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.CreatePartitionOp == nil {
				m.CreatePartitionOp = &CreatePartitionOp{}
			}
			if err := m.CreatePartitionOp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ShrinkISROp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ShrinkISROp == nil {
				m.ShrinkISROp = &ShrinkISROp{}
			}
			if err := m.ShrinkISROp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ChangeLeaderOp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ChangeLeaderOp == nil {
				m.ChangeLeaderOp = &ChangeLeaderOp{}
			}
			if err := m.ChangeLeaderOp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 5:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ExpandISROp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ExpandISROp == nil {
				m.ExpandISROp = &ExpandISROp{}
			}
			if err := m.ExpandISROp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *CreatePartitionOp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: CreatePartitionOp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: CreatePartitionOp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Partition == nil {
				m.Partition = &Partition{}
			}
			if err := m.Partition.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ShrinkISROp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ShrinkISROp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ShrinkISROp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReplicaToRemove", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ReplicaToRemove = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ExpandISROp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ExpandISROp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ExpandISROp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReplicaToAdd", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ReplicaToAdd = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ReportLeaderOp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ReportLeaderOp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ReportLeaderOp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Replica", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Replica = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ChangeLeaderOp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ChangeLeaderOp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ChangeLeaderOp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Partition) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Partition: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Partition: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Subject", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Subject = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 3:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			m.Id = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Id |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Group = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReplicationFactor", wireType)
			}
			m.ReplicationFactor = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.ReplicationFactor |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 6:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Replicas = append(m.Replicas, string(dAtA[iNdEx:postIndex]))
			iNdEx = postIndex
		case 7:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 8:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Isr", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Isr = append(m.Isr, string(dAtA[iNdEx:postIndex]))
			iNdEx = postIndex
		case 9:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 10:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Epoch", wireType)
			}
			m.Epoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Epoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *RaftJoinRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: RaftJoinRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: RaftJoinRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field NodeID", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.NodeID = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field NodeAddr", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.NodeAddr = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *RaftJoinResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: RaftJoinResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: RaftJoinResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Error = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *MetadataSnapshot) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: MetadataSnapshot: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: MetadataSnapshot: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partitions", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Partitions = append(m.Partitions, &Partition{})
			if err := m.Partitions[len(m.Partitions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ReplicationRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ReplicationRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ReplicationRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReplicaID", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ReplicaID = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Offset", wireType)
			}
			m.Offset = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Offset |= (int64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *LeaderEpochOffsetRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: LeaderEpochOffsetRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: LeaderEpochOffsetRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *LeaderEpochOffsetResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: LeaderEpochOffsetResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: LeaderEpochOffsetResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field EndOffset", wireType)
			}
			m.EndOffset = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.EndOffset |= (int64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *PropagatedRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: PropagatedRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: PropagatedRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Op", wireType)
			}
			m.Op = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Op |= (Op(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field CreatePartitionOp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.CreatePartitionOp == nil {
				m.CreatePartitionOp = &CreatePartitionOp{}
			}
			if err := m.CreatePartitionOp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ShrinkISROp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ShrinkISROp == nil {
				m.ShrinkISROp = &ShrinkISROp{}
			}
			if err := m.ShrinkISROp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReportLeaderOp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ReportLeaderOp == nil {
				m.ReportLeaderOp = &ReportLeaderOp{}
			}
			if err := m.ReportLeaderOp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 5:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ExpandISROp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ExpandISROp == nil {
				m.ExpandISROp = &ExpandISROp{}
			}
			if err := m.ExpandISROp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Error) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Error: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Error: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType)
			}
			m.Code = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Code |= (uint32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Msg = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *PropagatedResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: PropagatedResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: PropagatedResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Op", wireType)
			}
			m.Op = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Op |= (Op(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Error == nil {
				m.Error = &Error{}
			}
			if err := m.Error.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ServerInfoRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ServerInfoRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ServerInfoRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Id = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ServerInfoResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ServerInfoResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ServerInfoResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Id = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Host", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Host = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 3:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType)
			}
			m.Port = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Port |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *PartitionStatusRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: PartitionStatusRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: PartitionStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *PartitionStatusResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: PartitionStatusResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: PartitionStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Exists", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				v |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			m.Exists = bool(v != 0)
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field IsLeader", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				v |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			m.IsLeader = bool(v != 0)
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func skipInternal(dAtA []byte) (n int, err error) {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return 0, ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return 0, io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		wireType := int(wire & 0x7)
		switch wireType {
		case 0:
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				iNdEx++
				if dAtA[iNdEx-1] < 0x80 {
					break
				}
			}
			return iNdEx, nil
		case 1:
			iNdEx += 8
			return iNdEx, nil
		case 2:
			var length int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				length |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			iNdEx += length
			if length < 0 {
				return 0, ErrInvalidLengthInternal
			}
			return iNdEx, nil
		case 3:
			for {
				var innerWire uint64
				var start int = iNdEx
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return 0, ErrIntOverflowInternal
					}
					if iNdEx >= l {
						return 0, io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
					innerWire |= (uint64(b) & 0x7F) << shift
					if b < 0x80 {
						break
					}
				}
				innerWireType := int(innerWire & 0x7)
				if innerWireType == 4 {
					break
				}
				next, err := skipInternal(dAtA[start:])
				if err != nil {
					return 0, err
				}
				iNdEx = start + next
			}
			return iNdEx, nil
		case 4:
			return iNdEx, nil
		case 5:
			iNdEx += 4
			return iNdEx, nil
		default:
			return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
		}
	}
	panic("unreachable")
}

var (
	ErrInvalidLengthInternal = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowInternal   = fmt.Errorf("proto: integer overflow")
)

func init() { proto1.RegisterFile("server/proto/internal.proto", fileDescriptorInternal) }

var fileDescriptorInternal = []byte{

	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x56, 0x4f, 0x73, 0x1b, 0x35,
	0x14, 0xef, 0xae, 0xe3, 0x24, 0xfb, 0xdc, 0xba, 0x6b, 0x4d, 0x09, 0x5b, 0xc8, 0x64, 0x3c, 0xe2,
	0x12, 0x18, 0x48, 0x99, 0xc0, 0x85, 0x19, 0x38, 0x98, 0x64, 0x4b, 0x5d, 0x5c, 0xdb, 0x23, 0xfb,
	0xc0, 0x89, 0xa0, 0x7a, 0x15, 0x7b, 0x21, 0x59, 0x09, 0x49, 0xe9, 0xf4, 0x5b, 0x70, 0x84, 0xe1,
	0xd6, 0x13, 0x5f, 0x85, 0x23, 0x1f, 0x81, 0x09, 0x5f, 0x84, 0x91, 0x56, 0xfb, 0xc7, 0xeb, 0x0e,
	0x33, 0xb8, 0x97, 0x9e, 0xac, 0xdf, 0xd3, 0xd3, 0x7b, 0xbf, 0xf7, 0x7b, 0xda, 0x27, 0xc3, 0xfb,
	0x8a, 0xc9, 0x17, 0x4c, 0x3e, 0x12, 0x92, 0x6b, 0xfe, 0x28, 0xcd, 0x34, 0x93, 0x19, 0xbd, 0x3a,
	0xb1, 0x10, 0xb5, 0xed, 0x0f, 0xfe, 0x10, 0x3a, 0x33, 0xeb, 0x35, 0xd3, 0x54, 0x33, 0xf4, 0x1e,
	0xec, 0xe7, 0x87, 0x86, 0xe7, 0x91, 0xd7, 0xf7, 0x8e, 0x03, 0x52, 0x62, 0xfc, 0xab, 0x0f, 0x7b,
	0x84, 0x5e, 0xea, 0x11, 0x5f, 0xa2, 0x87, 0xe0, 0x73, 0x61, 0x3d, 0xba, 0xa7, 0x41, 0x1e, 0xf1,
	0x64, 0x22, 0x88, 0xcf, 0x05, 0x7a, 0x0c, 0xbd, 0x85, 0x64, 0x54, 0xb3, 0x29, 0x95, 0x3a, 0xd5,
	0x29, 0xcf, 0x26, 0x22, 0xf2, 0xfb, 0xde, 0x71, 0xe7, 0x34, 0x72, 0x9e, 0x67, 0xcd, 0x7d, 0xb2,
	0x79, 0x04, 0x7d, 0x0e, 0x1d, 0xb5, 0x92, 0x69, 0xf6, 0xd3, 0x70, 0x46, 0x26, 0x22, 0x6a, 0xd9,
	0x08, 0xc8, 0x45, 0x98, 0x55, 0x3b, 0xa4, 0xee, 0x86, 0xbe, 0x82, 0xee, 0x62, 0x45, 0xb3, 0x25,
	0x1b, 0x31, 0x9a, 0x30, 0x39, 0x11, 0xd1, 0x8e, 0x3d, 0xf8, 0x4e, 0x91, 0x7a, 0x6d, 0x93, 0x34,
	0x9c, 0x4d, 0x52, 0xf6, 0x52, 0xd0, 0x2c, 0xc9, 0x93, 0xb6, 0xd7, 0x92, 0xc6, 0xd5, 0x0e, 0xa9,
	0xbb, 0xe1, 0x33, 0xe8, 0x6d, 0x94, 0x84, 0x4e, 0x20, 0x10, 0x05, 0xb4, 0x4a, 0x75, 0x4e, 0x43,
	0x17, 0xa8, 0x74, 0x23, 0x95, 0x0b, 0xfe, 0xc3, 0x83, 0x4e, 0xad, 0x2c, 0x74, 0x00, 0xbb, 0x4a,
	0x4b, 0x46, 0xaf, 0x5d, 0x23, 0x1c, 0x42, 0x87, 0xf5, 0xb8, 0x46, 0xd7, 0x76, 0x2d, 0x0a, 0x3a,
	0x86, 0xfb, 0x92, 0x89, 0xab, 0x74, 0x41, 0xe7, 0x9c, 0xb0, 0x6b, 0xfe, 0x82, 0x59, 0xe5, 0x02,
	0xd2, 0x34, 0x9b, 0xf8, 0x57, 0xb6, 0x6c, 0xab, 0x50, 0x40, 0x1c, 0x42, 0x7d, 0xe8, 0xe4, 0xab,
	0x58, 0xf0, 0xc5, 0xca, 0x4a, 0xb0, 0x43, 0xea, 0x26, 0xfc, 0xca, 0x83, 0x4e, 0x4d, 0x8b, 0x2d,
	0x99, 0x62, 0xb8, 0x5b, 0x52, 0x1a, 0x24, 0x89, 0xa3, 0xb9, 0x66, 0x7b, 0x03, 0x8e, 0xbf, 0x7b,
	0xd0, 0x25, 0x4c, 0x70, 0xa9, 0xcb, 0xde, 0x6e, 0x47, 0x33, 0x82, 0x3d, 0x47, 0xc9, 0x31, 0x2c,
	0xe0, 0x1b, 0x90, 0xfb, 0x1e, 0xba, 0xeb, 0xf7, 0x70, 0x4b, 0x6e, 0x15, 0x83, 0x56, 0x9d, 0x01,
	0xfe, 0xc5, 0x87, 0x60, 0x5a, 0xaf, 0x40, 0xdd, 0x3c, 0xff, 0x91, 0x2d, 0xb4, 0x0b, 0x5e, 0xc0,
	0x5a, 0x56, 0x7f, 0x2d, 0x6b, 0x17, 0xfc, 0x34, 0x6f, 0x48, 0x9b, 0xf8, 0x69, 0x82, 0x1e, 0x40,
	0x7b, 0x29, 0xf9, 0x8d, 0x70, 0x85, 0xe6, 0x00, 0x7d, 0x0c, 0x3d, 0x27, 0x85, 0x49, 0xf3, 0x98,
	0x2e, 0x34, 0x97, 0xb6, 0xda, 0x36, 0xd9, 0xdc, 0x30, 0x93, 0xc5, 0x19, 0x55, 0xb4, 0xdb, 0x6f,
	0x99, 0xc9, 0x52, 0xe0, 0x5a, 0x1d, 0x7b, 0x6b, 0x4a, 0x86, 0xd0, 0x4a, 0x95, 0x8c, 0xf6, 0xad,
	0xbb, 0x59, 0x36, 0xb5, 0x0d, 0x36, 0xb4, 0x35, 0x5c, 0x99, 0xdd, 0x03, 0xbb, 0x97, 0x03, 0x1c,
	0xc3, 0x7d, 0x33, 0xba, 0x9e, 0xf2, 0x34, 0x23, 0xec, 0xe7, 0x1b, 0xa6, 0x6c, 0xf1, 0x19, 0x4f,
	0x58, 0x39, 0xe8, 0x1c, 0x32, 0x44, 0xcd, 0x6a, 0x90, 0x24, 0xd2, 0xc9, 0x52, 0x62, 0x7c, 0x0c,
	0x61, 0x15, 0x46, 0x09, 0x9e, 0x29, 0x66, 0x13, 0x4a, 0xc9, 0xa5, 0x0b, 0x93, 0x03, 0x7c, 0x0e,
	0xe1, 0x33, 0xa6, 0x69, 0x42, 0x35, 0x9d, 0x65, 0x54, 0xa8, 0x15, 0xd7, 0xe8, 0x53, 0x80, 0xb2,
	0x77, 0x2a, 0xf2, 0xfa, 0xad, 0xd7, 0x8e, 0x84, 0x9a, 0x0f, 0x7e, 0x0a, 0x88, 0x54, 0x4a, 0x16,
	0xcc, 0x0f, 0x21, 0x70, 0xd2, 0x95, 0xe4, 0x2b, 0x83, 0xa9, 0x8b, 0x5f, 0x5e, 0x2a, 0xa6, 0x2d,
	0xfb, 0x16, 0x71, 0x08, 0x7f, 0x09, 0xd1, 0xa8, 0xd2, 0x69, 0x62, 0x8d, 0x45, 0xc4, 0x86, 0xac,
	0xde, 0xe6, 0x95, 0xfd, 0x02, 0x1e, 0xbe, 0xe6, 0xb4, 0x93, 0xe0, 0x10, 0x02, 0x96, 0x25, 0xb9,
	0xd1, 0x1e, 0x6e, 0x91, 0xca, 0x80, 0x5f, 0xf9, 0xd0, 0x9b, 0x4a, 0x2e, 0xe8, 0x92, 0x6a, 0x96,
	0x14, 0x29, 0xdf, 0xe6, 0x17, 0x44, 0xae, 0x0d, 0x8e, 0xc6, 0x0b, 0xb2, 0x3e, 0x55, 0x48, 0xc3,
	0x79, 0xcb, 0x17, 0xe4, 0x13, 0x68, 0xc7, 0xe6, 0xde, 0x20, 0x04, 0x3b, 0x0b, 0x9e, 0x30, 0x2b,
	0xcc, 0x3d, 0x62, 0xd7, 0xe6, 0x33, 0xb8, 0x56, 0x4b, 0x77, 0x19, 0xcd, 0x12, 0xcf, 0x00, 0xd5,
	0x15, 0x75, 0x6d, 0xf8, 0x0f, 0x49, 0x71, 0x71, 0x49, 0x73, 0x19, 0xef, 0x16, 0x7c, 0x8c, 0xad,
	0xb8, 0xb2, 0x1f, 0x40, 0x2f, 0xff, 0x2b, 0x30, 0xcc, 0x2e, 0x79, 0xd1, 0xa6, 0x7c, 0x14, 0xe4,
	0x97, 0xcc, 0x4f, 0x13, 0x3c, 0x02, 0x54, 0x77, 0x72, 0x99, 0x1b, 0x5e, 0xa6, 0x8a, 0x15, 0x57,
	0xda, 0x51, 0xb6, 0x6b, 0x63, 0x33, 0x42, 0xb9, 0xb1, 0x62, 0xd7, 0x78, 0x0c, 0x07, 0x65, 0xc3,
	0xcc, 0x1f, 0x90, 0x1b, 0x55, 0xfb, 0x3a, 0xff, 0xff, 0x40, 0xc4, 0xcf, 0xe0, 0xdd, 0x8d, 0x78,
	0x8e, 0xe2, 0x01, 0xec, 0xb2, 0x97, 0xa9, 0xd2, 0xca, 0x06, 0xdc, 0x27, 0x0e, 0x99, 0xcf, 0x3d,
	0x55, 0x79, 0xf7, 0x6c, 0xbc, 0x7d, 0x52, 0xe2, 0x8f, 0x7e, 0x00, 0x7f, 0x22, 0xd0, 0x03, 0x08,
	0xcf, 0x48, 0x3c, 0x98, 0xc7, 0x17, 0xd3, 0x01, 0x99, 0x0f, 0xe7, 0xc3, 0xc9, 0x38, 0xbc, 0x83,
	0xba, 0x00, 0xb3, 0x27, 0x64, 0x38, 0xfe, 0xf6, 0x62, 0x38, 0x23, 0xa1, 0x87, 0x7a, 0x70, 0x8f,
	0xc4, 0xd3, 0x09, 0x99, 0x5f, 0x8c, 0xe2, 0xc1, 0x79, 0x4c, 0x42, 0xdf, 0x98, 0xce, 0x9e, 0x0c,
	0xc6, 0xdf, 0xc4, 0x85, 0xa9, 0x65, 0x4e, 0xc5, 0xdf, 0x4d, 0x07, 0xe3, 0x73, 0x7b, 0x6a, 0xe7,
	0xeb, 0xf0, 0xcf, 0xdb, 0x23, 0xef, 0xaf, 0xdb, 0x23, 0xef, 0xef, 0xdb, 0x23, 0xef, 0xb7, 0x7f,
	0x8e, 0xee, 0x3c, 0xdf, 0xb5, 0x9d, 0xf9, 0xec, 0xdf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x2c, 0x53,
	0x25, 0x44, 0xbd, 0x09, 0x00, 0x00,
}
// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: server/proto/internal.proto

/*
	Package proto is a generated protocol buffer package.

	It is generated from these files:
		server/proto/internal.proto

	It has these top-level messages:
		ServerState
		RaftLog
		CreatePartitionOp
		ShrinkISROp
		ExpandISROp
		ReportLeaderOp
		ChangeLeaderOp
		Partition
		RaftJoinRequest
		RaftJoinResponse
		MetadataSnapshot
		ReplicationRequest
		LeaderEpochOffsetRequest
		LeaderEpochOffsetResponse
		PropagatedRequest
		Error
		PropagatedResponse
		ServerInfoRequest
		ServerInfoResponse
		PartitionStatusRequest
		PartitionStatusResponse
*/
package proto

import proto1 "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"

import io "io"

// Reference imports to suppress errors if they are not otherwise used.
var _ = proto1.Marshal
var _ = fmt.Errorf
var _ = math.Inf

// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto1.ProtoPackageIsVersion2 // please upgrade the proto package

type Op int32

const (
	Op_CREATE_PARTITION Op = 0
	Op_SHRINK_ISR       Op = 1
	Op_REPORT_LEADER    Op = 2
	Op_CHANGE_LEADER    Op = 3
	Op_EXPAND_ISR       Op = 4
)

var Op_name = map[int32]string{
	0: "CREATE_PARTITION",
	1: "SHRINK_ISR",
	2: "REPORT_LEADER",
	3: "CHANGE_LEADER",
	4: "EXPAND_ISR",
}
var Op_value = map[string]int32{
	"CREATE_PARTITION": 0,
	"SHRINK_ISR":       1,
	"REPORT_LEADER":    2,
	"CHANGE_LEADER":    3,
	"EXPAND_ISR":       4,
}

func (x Op) String() string {
	return proto1.EnumName(Op_name, int32(x))
}
func (Op) EnumDescriptor() ([]byte, []int) { return fileDescriptorInternal, []int{0} }

type ServerState struct {
	ServerID string `protobuf:"bytes,1,opt,name=serverID,proto3" json:"serverID,omitempty"`
}

func (m *ServerState) Reset()                    { *m = ServerState{} }
func (m *ServerState) String() string            { return proto1.CompactTextString(m) }
func (*ServerState) ProtoMessage()               {}
func (*ServerState) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{0} }

func (m *ServerState) GetServerID() string {
	if m != nil {
		return m.ServerID
	}
	return ""
}

type RaftLog struct {
	Op                Op                 `protobuf:"varint,1,opt,name=op,proto3,enum=proto.Op" json:"op,omitempty"`
	CreatePartitionOp *CreatePartitionOp `protobuf:"bytes,2,opt,name=createPartitionOp" json:"createPartitionOp,omitempty"`
	ShrinkISROp       *ShrinkISROp       `protobuf:"bytes,3,opt,name=shrinkISROp" json:"shrinkISROp,omitempty"`
	ChangeLeaderOp    *ChangeLeaderOp    `protobuf:"bytes,4,opt,name=changeLeaderOp" json:"changeLeaderOp,omitempty"`
	ExpandISROp       *ExpandISROp       `protobuf:"bytes,5,opt,name=expandISROp" json:"expandISROp,omitempty"`
}

func (m *RaftLog) Reset()                    { *m = RaftLog{} }
func (m *RaftLog) String() string            { return proto1.CompactTextString(m) }
func (*RaftLog) ProtoMessage()               {}
func (*RaftLog) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{1} }

func (m *RaftLog) GetOp() Op {
	if m != nil {
		return m.Op
	}
	return Op_CREATE_PARTITION
}

func (m *RaftLog) GetCreatePartitionOp() *CreatePartitionOp {
	if m != nil {
		return m.CreatePartitionOp
	}
	return nil
}

func (m *RaftLog) GetShrinkISROp() *ShrinkISROp {
	if m != nil {
		return m.ShrinkISROp
	}
	return nil
}

func (m *RaftLog) GetChangeLeaderOp() *ChangeLeaderOp {
	if m != nil {
		return m.ChangeLeaderOp
	}
	return nil
}

func (m *RaftLog) GetExpandISROp() *ExpandISROp {
	if m != nil {
		return m.ExpandISROp
	}
	return nil
}

type CreatePartitionOp struct {
	Partition *Partition `protobuf:"bytes,1,opt,name=partition" json:"partition,omitempty"`
}

func (m *CreatePartitionOp) Reset()                    { *m = CreatePartitionOp{} }
func (m *CreatePartitionOp) String() string            { return proto1.CompactTextString(m) }
func (*CreatePartitionOp) ProtoMessage()               {}
func (*CreatePartitionOp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{2} }

func (m *CreatePartitionOp) GetPartition() *Partition {
	if m != nil {
		return m.Partition
	}
	return nil
}

type ShrinkISROp struct {
	Stream          string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition       int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
	ReplicaToRemove string `protobuf:"bytes,3,opt,name=replicaToRemove,proto3" json:"replicaToRemove,omitempty"`
	Leader          string `protobuf:"bytes,4,opt,name=leader,proto3" json:"leader,omitempty"`
	LeaderEpoch     uint64 `protobuf:"varint,5,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
}

func (m *ShrinkISROp) Reset()                    { *m = ShrinkISROp{} }
func (m *ShrinkISROp) String() string            { return proto1.CompactTextString(m) }
func (*ShrinkISROp) ProtoMessage()               {}
func (*ShrinkISROp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{3} }

func (m *ShrinkISROp) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *ShrinkISROp) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

func (m *ShrinkISROp) GetReplicaToRemove() string {
	if m != nil {
		return m.ReplicaToRemove
	}
	return ""
}

func (m *ShrinkISROp) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

func (m *ShrinkISROp) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

type ExpandISROp struct {
	Stream       string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition    int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
	ReplicaToAdd string `protobuf:"bytes,3,opt,name=replicaToAdd,proto3" json:"replicaToAdd,omitempty"`
	Leader       string `protobuf:"bytes,4,opt,name=leader,proto3" json:"leader,omitempty"`
	LeaderEpoch  uint64 `protobuf:"varint,5,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
}

func (m *ExpandISROp) Reset()                    { *m = ExpandISROp{} }
func (m *ExpandISROp) String() string            { return proto1.CompactTextString(m) }
func (*ExpandISROp) ProtoMessage()               {}
func (*ExpandISROp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{4} }

func (m *ExpandISROp) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *ExpandISROp) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

func (m *ExpandISROp) GetReplicaToAdd() string {
	if m != nil {
		return m.ReplicaToAdd
	}
	return ""
}

func (m *ExpandISROp) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

func (m *ExpandISROp) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

type ReportLeaderOp struct {
	Stream      string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition   int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
	Replica     string `protobuf:"bytes,3,opt,name=replica,proto3" json:"replica,omitempty"`
	Leader      string `protobuf:"bytes,4,opt,name=leader,proto3" json:"leader,omitempty"`
	LeaderEpoch uint64 `protobuf:"varint,5,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
}

func (m *ReportLeaderOp) Reset()                    { *m = ReportLeaderOp{} }
func (m *ReportLeaderOp) String() string            { return proto1.CompactTextString(m) }
func (*ReportLeaderOp) ProtoMessage()               {}
func (*ReportLeaderOp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{5} }

func (m *ReportLeaderOp) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *ReportLeaderOp) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

func (m *ReportLeaderOp) GetReplica() string {
	if m != nil {
		return m.Replica
	}
	return ""
}

func (m *ReportLeaderOp) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

func (m *ReportLeaderOp) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

type ChangeLeaderOp struct {
	Stream    string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
	Leader    string `protobuf:"bytes,3,opt,name=leader,proto3" json:"leader,omitempty"`
}

func (m *ChangeLeaderOp) Reset()                    { *m = ChangeLeaderOp{} }
func (m *ChangeLeaderOp) String() string            { return proto1.CompactTextString(m) }
func (*ChangeLeaderOp) ProtoMessage()               {}
func (*ChangeLeaderOp) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{6} }

func (m *ChangeLeaderOp) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *ChangeLeaderOp) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

func (m *ChangeLeaderOp) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

type Partition struct {
	Subject           string   `protobuf:"bytes,1,opt,name=subject,proto3" json:"subject,omitempty"`
	Stream            string   `protobuf:"bytes,2,opt,name=stream,proto3" json:"stream,omitempty"`
	Id                int32    `protobuf:"varint,3,opt,name=id,proto3" json:"id,omitempty"`
	Group             string   `protobuf:"bytes,4,opt,name=group,proto3" json:"group,omitempty"`
	ReplicationFactor int32    `protobuf:"varint,5,opt,name=replicationFactor,proto3" json:"replicationFactor,omitempty"`
	Replicas          []string `protobuf:"bytes,6,rep,name=replicas" json:"replicas,omitempty"`
	Leader            string   `protobuf:"bytes,7,opt,name=leader,proto3" json:"leader,omitempty"`
	Isr               []string `protobuf:"bytes,8,rep,name=isr" json:"isr,omitempty"`
	LeaderEpoch       uint64   `protobuf:"varint,9,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
	Epoch             uint64   `protobuf:"varint,10,opt,name=epoch,proto3" json:"epoch,omitempty"`
}

func (m *Partition) Reset()                    { *m = Partition{} }
func (m *Partition) String() string            { return proto1.CompactTextString(m) }
func (*Partition) ProtoMessage()               {}
func (*Partition) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{7} }

func (m *Partition) GetSubject() string {
	if m != nil {
		return m.Subject
	}
	return ""
}

func (m *Partition) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *Partition) GetId() int32 {
	if m != nil {
		return m.Id
	}
	return 0
}

func (m *Partition) GetGroup() string {
	if m != nil {
		return m.Group
	}
	return ""
}

func (m *Partition) GetReplicationFactor() int32 {
	if m != nil {
		return m.ReplicationFactor
	}
	return 0
}

func (m *Partition) GetReplicas() []string {
	if m != nil {
		return m.Replicas
	}
	return nil
}

func (m *Partition) GetLeader() string {
	if m != nil {
		return m.Leader
	}
	return ""
}

func (m *Partition) GetIsr() []string {
	if m != nil {
		return m.Isr
	}
	return nil
}

func (m *Partition) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

func (m *Partition) GetEpoch() uint64 {
	if m != nil {
		return m.Epoch
	}
	return 0
}

// RaftJoinRequest is a request to join a Raft group.
type RaftJoinRequest struct {
	NodeID   string `protobuf:"bytes,1,opt,name=nodeID,proto3" json:"nodeID,omitempty"`
	NodeAddr string `protobuf:"bytes,2,opt,name=nodeAddr,proto3" json:"nodeAddr,omitempty"`
}

func (m *RaftJoinRequest) Reset()                    { *m = RaftJoinRequest{} }
func (m *RaftJoinRequest) String() string            { return proto1.CompactTextString(m) }
func (*RaftJoinRequest) ProtoMessage()               {}
func (*RaftJoinRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{8} }

func (m *RaftJoinRequest) GetNodeID() string {
	if m != nil {
		return m.NodeID
	}
	return ""
}

func (m *RaftJoinRequest) GetNodeAddr() string {
	if m != nil {
		return m.NodeAddr
	}
	return ""
}

// RaftJoinResponse is a response to a RaftJoinRequest.
type RaftJoinResponse struct {
	Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
}

func (m *RaftJoinResponse) Reset()                    { *m = RaftJoinResponse{} }
func (m *RaftJoinResponse) String() string            { return proto1.CompactTextString(m) }
func (*RaftJoinResponse) ProtoMessage()               {}
func (*RaftJoinResponse) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{9} }

func (m *RaftJoinResponse) GetError() string {
	if m != nil {
		return m.Error
	}
	return ""
}

type MetadataSnapshot struct {
	Partitions []*Partition `protobuf:"bytes,1,rep,name=partitions" json:"partitions,omitempty"`
}

func (m *MetadataSnapshot) Reset()                    { *m = MetadataSnapshot{} }
func (m *MetadataSnapshot) String() string            { return proto1.CompactTextString(m) }
func (*MetadataSnapshot) ProtoMessage()               {}
func (*MetadataSnapshot) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{10} }

func (m *MetadataSnapshot) GetPartitions() []*Partition {
	if m != nil {
		return m.Partitions
	}
	return nil
}

type ReplicationRequest struct {
	ReplicaID string `protobuf:"bytes,1,opt,name=replicaID,proto3" json:"replicaID,omitempty"`
	Offset    int64  `protobuf:"varint,2,opt,name=offset,proto3" json:"offset,omitempty"`
}

func (m *ReplicationRequest) Reset()                    { *m = ReplicationRequest{} }
func (m *ReplicationRequest) String() string            { return proto1.CompactTextString(m) }
func (*ReplicationRequest) ProtoMessage()               {}
func (*ReplicationRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{11} }

func (m *ReplicationRequest) GetReplicaID() string {
	if m != nil {
		return m.ReplicaID
	}
	return ""
}

func (m *ReplicationRequest) GetOffset() int64 {
	if m != nil {
		return m.Offset
	}
	return 0
}

type LeaderEpochOffsetRequest struct {
	LeaderEpoch uint64 `protobuf:"varint,1,opt,name=leaderEpoch,proto3" json:"leaderEpoch,omitempty"`
}

func (m *LeaderEpochOffsetRequest) Reset()         { *m = LeaderEpochOffsetRequest{} }
func (m *LeaderEpochOffsetRequest) String() string { return proto1.CompactTextString(m) }
func (*LeaderEpochOffsetRequest) ProtoMessage()    {}
func (*LeaderEpochOffsetRequest) Descriptor() ([]byte, []int) {
	return fileDescriptorInternal, []int{12}
}

func (m *LeaderEpochOffsetRequest) GetLeaderEpoch() uint64 {
	if m != nil {
		return m.LeaderEpoch
	}
	return 0
}

type LeaderEpochOffsetResponse struct {
	EndOffset int64 `protobuf:"varint,1,opt,name=endOffset,proto3" json:"endOffset,omitempty"`
}

func (m *LeaderEpochOffsetResponse) Reset()         { *m = LeaderEpochOffsetResponse{} }
func (m *LeaderEpochOffsetResponse) String() string { return proto1.CompactTextString(m) }
func (*LeaderEpochOffsetResponse) ProtoMessage()    {}
func (*LeaderEpochOffsetResponse) Descriptor() ([]byte, []int) {
	return fileDescriptorInternal, []int{13}
}

func (m *LeaderEpochOffsetResponse) GetEndOffset() int64 {
	if m != nil {
		return m.EndOffset
	}
	return 0
}

type PropagatedRequest struct {
	Op                Op                 `protobuf:"varint,1,opt,name=op,proto3,enum=proto.Op" json:"op,omitempty"`
	CreatePartitionOp *CreatePartitionOp `protobuf:"bytes,2,opt,name=createPartitionOp" json:"createPartitionOp,omitempty"`
	ShrinkISROp       *ShrinkISROp       `protobuf:"bytes,3,opt,name=shrinkISROp" json:"shrinkISROp,omitempty"`
	ReportLeaderOp    *ReportLeaderOp    `protobuf:"bytes,4,opt,name=reportLeaderOp" json:"reportLeaderOp,omitempty"`
	ExpandISROp       *ExpandISROp       `protobuf:"bytes,5,opt,name=expandISROp" json:"expandISROp,omitempty"`
}

func (m *PropagatedRequest) Reset()                    { *m = PropagatedRequest{} }
func (m *PropagatedRequest) String() string            { return proto1.CompactTextString(m) }
func (*PropagatedRequest) ProtoMessage()               {}
func (*PropagatedRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{14} }

func (m *PropagatedRequest) GetOp() Op {
	if m != nil {
		return m.Op
	}
	return Op_CREATE_PARTITION
}

func (m *PropagatedRequest) GetCreatePartitionOp() *CreatePartitionOp {
	if m != nil {
		return m.CreatePartitionOp
	}
	return nil
}

func (m *PropagatedRequest) GetShrinkISROp() *ShrinkISROp {
	if m != nil {
		return m.ShrinkISROp
	}
	return nil
}

func (m *PropagatedRequest) GetReportLeaderOp() *ReportLeaderOp {
	if m != nil {
		return m.ReportLeaderOp
	}
	return nil
}

func (m *PropagatedRequest) GetExpandISROp() *ExpandISROp {
	if m != nil {
		return m.ExpandISROp
	}
	return nil
}

type Error struct {
	Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
	Msg  string `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"`
}

func (m *Error) Reset()                    { *m = Error{} }
func (m *Error) String() string            { return proto1.CompactTextString(m) }
func (*Error) ProtoMessage()               {}
func (*Error) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{15} }

func (m *Error) GetCode() uint32 {
	if m != nil {
		return m.Code
	}
	return 0
}

func (m *Error) GetMsg() string {
	if m != nil {
		return m.Msg
	}
	return ""
}

type PropagatedResponse struct {
	Op    Op     `protobuf:"varint,1,opt,name=op,proto3,enum=proto.Op" json:"op,omitempty"`
	Error *Error `protobuf:"bytes,2,opt,name=error" json:"error,omitempty"`
}

func (m *PropagatedResponse) Reset()                    { *m = PropagatedResponse{} }
func (m *PropagatedResponse) String() string            { return proto1.CompactTextString(m) }
func (*PropagatedResponse) ProtoMessage()               {}
func (*PropagatedResponse) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{16} }

func (m *PropagatedResponse) GetOp() Op {
	if m != nil {
		return m.Op
	}
	return Op_CREATE_PARTITION
}

func (m *PropagatedResponse) GetError() *Error {
	if m != nil {
		return m.Error
	}
	return nil
}

type ServerInfoRequest struct {
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
}

func (m *ServerInfoRequest) Reset()                    { *m = ServerInfoRequest{} }
func (m *ServerInfoRequest) String() string            { return proto1.CompactTextString(m) }
func (*ServerInfoRequest) ProtoMessage()               {}
func (*ServerInfoRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{17} }

func (m *ServerInfoRequest) GetId() string {
	if m != nil {
		return m.Id
	}
	return ""
}

type ServerInfoResponse struct {
	Id   string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Host string `protobuf:"bytes,2,opt,name=host,proto3" json:"host,omitempty"`
	Port int32  `protobuf:"varint,3,opt,name=port,proto3" json:"port,omitempty"`
}

func (m *ServerInfoResponse) Reset()                    { *m = ServerInfoResponse{} }
func (m *ServerInfoResponse) String() string            { return proto1.CompactTextString(m) }
func (*ServerInfoResponse) ProtoMessage()               {}
func (*ServerInfoResponse) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{18} }

func (m *ServerInfoResponse) GetId() string {
	if m != nil {
		return m.Id
	}
	return ""
}

func (m *ServerInfoResponse) GetHost() string {
	if m != nil {
		return m.Host
	}
	return ""
}

func (m *ServerInfoResponse) GetPort() int32 {
	if m != nil {
		return m.Port
	}
	return 0
}

type PartitionStatusRequest struct {
	Stream    string `protobuf:"bytes,1,opt,name=stream,proto3" json:"stream,omitempty"`
	Partition int32  `protobuf:"varint,2,opt,name=partition,proto3" json:"partition,omitempty"`
}

func (m *PartitionStatusRequest) Reset()                    { *m = PartitionStatusRequest{} }
func (m *PartitionStatusRequest) String() string            { return proto1.CompactTextString(m) }
func (*PartitionStatusRequest) ProtoMessage()               {}
func (*PartitionStatusRequest) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{19} }

func (m *PartitionStatusRequest) GetStream() string {
	if m != nil {
		return m.Stream
	}
	return ""
}

func (m *PartitionStatusRequest) GetPartition() int32 {
	if m != nil {
		return m.Partition
	}
	return 0
}

type PartitionStatusResponse struct {
	Exists   bool `protobuf:"varint,1,opt,name=exists,proto3" json:"exists,omitempty"`
	IsLeader bool `protobuf:"varint,2,opt,name=isLeader,proto3" json:"isLeader,omitempty"`
}

func (m *PartitionStatusResponse) Reset()                    { *m = PartitionStatusResponse{} }
func (m *PartitionStatusResponse) String() string            { return proto1.CompactTextString(m) }
func (*PartitionStatusResponse) ProtoMessage()               {}
func (*PartitionStatusResponse) Descriptor() ([]byte, []int) { return fileDescriptorInternal, []int{20} }

func (m *PartitionStatusResponse) GetExists() bool {
	if m != nil {
		return m.Exists
	}
	return false
}

func (m *PartitionStatusResponse) GetIsLeader() bool {
	if m != nil {
		return m.IsLeader
	}
	return false
}

func init() {
	proto1.RegisterType((*ServerState)(nil), "proto.ServerState")
	proto1.RegisterType((*RaftLog)(nil), "proto.RaftLog")
	proto1.RegisterType((*CreatePartitionOp)(nil), "proto.CreatePartitionOp")
	proto1.RegisterType((*ShrinkISROp)(nil), "proto.ShrinkISROp")
	proto1.RegisterType((*ExpandISROp)(nil), "proto.ExpandISROp")
	proto1.RegisterType((*ReportLeaderOp)(nil), "proto.ReportLeaderOp")
	proto1.RegisterType((*ChangeLeaderOp)(nil), "proto.ChangeLeaderOp")
	proto1.RegisterType((*Partition)(nil), "proto.Partition")
	proto1.RegisterType((*RaftJoinRequest)(nil), "proto.RaftJoinRequest")
	proto1.RegisterType((*RaftJoinResponse)(nil), "proto.RaftJoinResponse")
	proto1.RegisterType((*MetadataSnapshot)(nil), "proto.MetadataSnapshot")
	proto1.RegisterType((*ReplicationRequest)(nil), "proto.ReplicationRequest")
	proto1.RegisterType((*LeaderEpochOffsetRequest)(nil), "proto.LeaderEpochOffsetRequest")
	proto1.RegisterType((*LeaderEpochOffsetResponse)(nil), "proto.LeaderEpochOffsetResponse")
	proto1.RegisterType((*PropagatedRequest)(nil), "proto.PropagatedRequest")
	proto1.RegisterType((*Error)(nil), "proto.Error")
	proto1.RegisterType((*PropagatedResponse)(nil), "proto.PropagatedResponse")
	proto1.RegisterType((*ServerInfoRequest)(nil), "proto.ServerInfoRequest")
	proto1.RegisterType((*ServerInfoResponse)(nil), "proto.ServerInfoResponse")
	proto1.RegisterType((*PartitionStatusRequest)(nil), "proto.PartitionStatusRequest")
	proto1.RegisterType((*PartitionStatusResponse)(nil), "proto.PartitionStatusResponse")
	proto1.RegisterEnum("proto.Op", Op_name, Op_value)
}
func (m *ServerState) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ServerState) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.ServerID) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.ServerID)))
		i += copy(dAtA[i:], m.ServerID)
	}
	return i, nil
}

func (m *RaftLog) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *RaftLog) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Op != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Op))
	}
	if m.CreatePartitionOp != nil {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.CreatePartitionOp.Size()))
		n1, err := m.CreatePartitionOp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n1
	}
	if m.ShrinkISROp != nil {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ShrinkISROp.Size()))
		n2, err := m.ShrinkISROp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n2
	}
	if m.ChangeLeaderOp != nil {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ChangeLeaderOp.Size()))
		n3, err := m.ChangeLeaderOp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n3
	}
	if m.ExpandISROp != nil {
		dAtA[i] = 0x2a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ExpandISROp.Size()))
		n4, err := m.ExpandISROp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n4
	}
	return i, nil
}

func (m *CreatePartitionOp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *CreatePartitionOp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Partition != nil {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition.Size()))
		n5, err := m.Partition.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n5
	}
	return i, nil
}

func (m *ShrinkISROp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ShrinkISROp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	if len(m.ReplicaToRemove) > 0 {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.ReplicaToRemove)))
		i += copy(dAtA[i:], m.ReplicaToRemove)
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x28
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	return i, nil
}

func (m *ExpandISROp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ExpandISROp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	if len(m.ReplicaToAdd) > 0 {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.ReplicaToAdd)))
		i += copy(dAtA[i:], m.ReplicaToAdd)
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x28
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	return i, nil
}

func (m *ReportLeaderOp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ReportLeaderOp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	if len(m.Replica) > 0 {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Replica)))
		i += copy(dAtA[i:], m.Replica)
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x28
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	return i, nil
}

func (m *ChangeLeaderOp) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ChangeLeaderOp) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	return i, nil
}

func (m *Partition) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Partition) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Subject) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Subject)))
		i += copy(dAtA[i:], m.Subject)
	}
	if len(m.Stream) > 0 {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Id != 0 {
		dAtA[i] = 0x18
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Id))
	}
	if len(m.Group) > 0 {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Group)))
		i += copy(dAtA[i:], m.Group)
	}
	if m.ReplicationFactor != 0 {
		dAtA[i] = 0x28
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ReplicationFactor))
	}
	if len(m.Replicas) > 0 {
		for _, s := range m.Replicas {
			dAtA[i] = 0x32
			i++
			l = len(s)
			for l >= 1<<7 {
				dAtA[i] = uint8(uint64(l)&0x7f | 0x80)
				l >>= 7
				i++
			}
			dAtA[i] = uint8(l)
			i++
			i += copy(dAtA[i:], s)
		}
	}
	if len(m.Leader) > 0 {
		dAtA[i] = 0x3a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Leader)))
		i += copy(dAtA[i:], m.Leader)
	}
	if len(m.Isr) > 0 {
		for _, s := range m.Isr {
			dAtA[i] = 0x42
			i++
			l = len(s)
			for l >= 1<<7 {
				dAtA[i] = uint8(uint64(l)&0x7f | 0x80)
				l >>= 7
				i++
			}
			dAtA[i] = uint8(l)
			i++
			i += copy(dAtA[i:], s)
		}
	}
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x48
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	if m.Epoch != 0 {
		dAtA[i] = 0x50
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Epoch))
	}
	return i, nil
}

func (m *RaftJoinRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *RaftJoinRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.NodeID) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.NodeID)))
		i += copy(dAtA[i:], m.NodeID)
	}
	if len(m.NodeAddr) > 0 {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.NodeAddr)))
		i += copy(dAtA[i:], m.NodeAddr)
	}
	return i, nil
}

func (m *RaftJoinResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *RaftJoinResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Error) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Error)))
		i += copy(dAtA[i:], m.Error)
	}
	return i, nil
}

func (m *MetadataSnapshot) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *MetadataSnapshot) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Partitions) > 0 {
		for _, msg := range m.Partitions {
			dAtA[i] = 0xa
			i++
			i = encodeVarintInternal(dAtA, i, uint64(msg.Size()))
			n, err := msg.MarshalTo(dAtA[i:])
			if err != nil {
				return 0, err
			}
			i += n
		}
	}
	return i, nil
}

func (m *ReplicationRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ReplicationRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.ReplicaID) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.ReplicaID)))
		i += copy(dAtA[i:], m.ReplicaID)
	}
	if m.Offset != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Offset))
	}
	return i, nil
}

func (m *LeaderEpochOffsetRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *LeaderEpochOffsetRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.LeaderEpoch != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.LeaderEpoch))
	}
	return i, nil
}

func (m *LeaderEpochOffsetResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *LeaderEpochOffsetResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.EndOffset != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.EndOffset))
	}
	return i, nil
}

func (m *PropagatedRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *PropagatedRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Op != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Op))
	}
	if m.CreatePartitionOp != nil {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.CreatePartitionOp.Size()))
		n6, err := m.CreatePartitionOp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n6
	}
	if m.ShrinkISROp != nil {
		dAtA[i] = 0x1a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ShrinkISROp.Size()))
		n7, err := m.ShrinkISROp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n7
	}
	if m.ReportLeaderOp != nil {
		dAtA[i] = 0x22
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ReportLeaderOp.Size()))
		n8, err := m.ReportLeaderOp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n8
	}
	if m.ExpandISROp != nil {
		dAtA[i] = 0x2a
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.ExpandISROp.Size()))
		n9, err := m.ExpandISROp.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n9
	}
	return i, nil
}

func (m *Error) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Error) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Code != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Code))
	}
	if len(m.Msg) > 0 {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Msg)))
		i += copy(dAtA[i:], m.Msg)
	}
	return i, nil
}

func (m *PropagatedResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *PropagatedResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Op != 0 {
		dAtA[i] = 0x8
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Op))
	}
	if m.Error != nil {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Error.Size()))
		n10, err := m.Error.MarshalTo(dAtA[i:])
		if err != nil {
			return 0, err
		}
		i += n10
	}
	return i, nil
}

func (m *ServerInfoRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ServerInfoRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Id) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Id)))
		i += copy(dAtA[i:], m.Id)
	}
	return i, nil
}

func (m *ServerInfoResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *ServerInfoResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Id) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Id)))
		i += copy(dAtA[i:], m.Id)
	}
	if len(m.Host) > 0 {
		dAtA[i] = 0x12
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Host)))
		i += copy(dAtA[i:], m.Host)
	}
	if m.Port != 0 {
		dAtA[i] = 0x18
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Port))
	}
	return i, nil
}

func (m *PartitionStatusRequest) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *PartitionStatusRequest) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if len(m.Stream) > 0 {
		dAtA[i] = 0xa
		i++
		i = encodeVarintInternal(dAtA, i, uint64(len(m.Stream)))
		i += copy(dAtA[i:], m.Stream)
	}
	if m.Partition != 0 {
		dAtA[i] = 0x10
		i++
		i = encodeVarintInternal(dAtA, i, uint64(m.Partition))
	}
	return i, nil
}

func (m *PartitionStatusResponse) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalTo(dAtA)
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *PartitionStatusResponse) MarshalTo(dAtA []byte) (int, error) {
	var i int
	_ = i
	var l int
	_ = l
	if m.Exists {
		dAtA[i] = 0x8
		i++
		if m.Exists {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i++
	}
	if m.IsLeader {
		dAtA[i] = 0x10
		i++
		if m.IsLeader {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i++
	}
	return i, nil
}

func encodeVarintInternal(dAtA []byte, offset int, v uint64) int {
	for v >= 1<<7 {
		dAtA[offset] = uint8(v&0x7f | 0x80)
		v >>= 7
		offset++
	}
	dAtA[offset] = uint8(v)
	return offset + 1
}
func (m *ServerState) Size() (n int) {
	var l int
	_ = l
	l = len(m.ServerID)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *RaftLog) Size() (n int) {
	var l int
	_ = l
	if m.Op != 0 {
		n += 1 + sovInternal(uint64(m.Op))
	}
	if m.CreatePartitionOp != nil {
		l = m.CreatePartitionOp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ShrinkISROp != nil {
		l = m.ShrinkISROp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ChangeLeaderOp != nil {
		l = m.ChangeLeaderOp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ExpandISROp != nil {
		l = m.ExpandISROp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *CreatePartitionOp) Size() (n int) {
	var l int
	_ = l
	if m.Partition != nil {
		l = m.Partition.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *ShrinkISROp) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	l = len(m.ReplicaToRemove)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	return n
}

func (m *ExpandISROp) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	l = len(m.ReplicaToAdd)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	return n
}

func (m *ReportLeaderOp) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	l = len(m.Replica)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	return n
}

func (m *ChangeLeaderOp) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *Partition) Size() (n int) {
	var l int
	_ = l
	l = len(m.Subject)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Id != 0 {
		n += 1 + sovInternal(uint64(m.Id))
	}
	l = len(m.Group)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ReplicationFactor != 0 {
		n += 1 + sovInternal(uint64(m.ReplicationFactor))
	}
	if len(m.Replicas) > 0 {
		for _, s := range m.Replicas {
			l = len(s)
			n += 1 + l + sovInternal(uint64(l))
		}
	}
	l = len(m.Leader)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if len(m.Isr) > 0 {
		for _, s := range m.Isr {
			l = len(s)
			n += 1 + l + sovInternal(uint64(l))
		}
	}
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	if m.Epoch != 0 {
		n += 1 + sovInternal(uint64(m.Epoch))
	}
	return n
}

func (m *RaftJoinRequest) Size() (n int) {
	var l int
	_ = l
	l = len(m.NodeID)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.NodeAddr)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *RaftJoinResponse) Size() (n int) {
	var l int
	_ = l
	l = len(m.Error)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *MetadataSnapshot) Size() (n int) {
	var l int
	_ = l
	if len(m.Partitions) > 0 {
		for _, e := range m.Partitions {
			l = e.Size()
			n += 1 + l + sovInternal(uint64(l))
		}
	}
	return n
}

func (m *ReplicationRequest) Size() (n int) {
	var l int
	_ = l
	l = len(m.ReplicaID)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Offset != 0 {
		n += 1 + sovInternal(uint64(m.Offset))
	}
	return n
}

func (m *LeaderEpochOffsetRequest) Size() (n int) {
	var l int
	_ = l
	if m.LeaderEpoch != 0 {
		n += 1 + sovInternal(uint64(m.LeaderEpoch))
	}
	return n
}

func (m *LeaderEpochOffsetResponse) Size() (n int) {
	var l int
	_ = l
	if m.EndOffset != 0 {
		n += 1 + sovInternal(uint64(m.EndOffset))
	}
	return n
}

func (m *PropagatedRequest) Size() (n int) {
	var l int
	_ = l
	if m.Op != 0 {
		n += 1 + sovInternal(uint64(m.Op))
	}
	if m.CreatePartitionOp != nil {
		l = m.CreatePartitionOp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ShrinkISROp != nil {
		l = m.ShrinkISROp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ReportLeaderOp != nil {
		l = m.ReportLeaderOp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.ExpandISROp != nil {
		l = m.ExpandISROp.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *Error) Size() (n int) {
	var l int
	_ = l
	if m.Code != 0 {
		n += 1 + sovInternal(uint64(m.Code))
	}
	l = len(m.Msg)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *PropagatedResponse) Size() (n int) {
	var l int
	_ = l
	if m.Op != 0 {
		n += 1 + sovInternal(uint64(m.Op))
	}
	if m.Error != nil {
		l = m.Error.Size()
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *ServerInfoRequest) Size() (n int) {
	var l int
	_ = l
	l = len(m.Id)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	return n
}

func (m *ServerInfoResponse) Size() (n int) {
	var l int
	_ = l
	l = len(m.Id)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	l = len(m.Host)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Port != 0 {
		n += 1 + sovInternal(uint64(m.Port))
	}
	return n
}

func (m *PartitionStatusRequest) Size() (n int) {
	var l int
	_ = l
	l = len(m.Stream)
	if l > 0 {
		n += 1 + l + sovInternal(uint64(l))
	}
	if m.Partition != 0 {
		n += 1 + sovInternal(uint64(m.Partition))
	}
	return n
}

func (m *PartitionStatusResponse) Size() (n int) {
	var l int
	_ = l
	if m.Exists {
		n += 2
	}
	if m.IsLeader {
		n += 2
	}
	return n
}

func sovInternal(x uint64) (n int) {
	for {
		n++
		x >>= 7
		if x == 0 {
			break
		}
	}
	return n
}
func sozInternal(x uint64) (n int) {
	return sovInternal(uint64((x << 1) ^ uint64((int64(x) >> 63))))
}
func (m *ServerState) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ServerState: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ServerState: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ServerID", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ServerID = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *RaftLog) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: RaftLog: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: RaftLog: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Op", wireType)
			}
			m.Op = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Op |= (Op(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field CreatePartitionOp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.CreatePartitionOp == nil {
				m.CreatePartitionOp = &CreatePartitionOp{}
			}
			if err := m.CreatePartitionOp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ShrinkISROp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ShrinkISROp == nil {
				m.ShrinkISROp = &ShrinkISROp{}
			}
			if err := m.ShrinkISROp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ChangeLeaderOp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ChangeLeaderOp == nil {
				m.ChangeLeaderOp = &ChangeLeaderOp{}
			}
			if err := m.ChangeLeaderOp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 5:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ExpandISROp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ExpandISROp == nil {
				m.ExpandISROp = &ExpandISROp{}
			}
			if err := m.ExpandISROp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *CreatePartitionOp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: CreatePartitionOp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: CreatePartitionOp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Partition == nil {
				m.Partition = &Partition{}
			}
			if err := m.Partition.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ShrinkISROp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ShrinkISROp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ShrinkISROp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReplicaToRemove", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ReplicaToRemove = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ExpandISROp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ExpandISROp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ExpandISROp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReplicaToAdd", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ReplicaToAdd = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ReportLeaderOp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ReportLeaderOp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ReportLeaderOp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Replica", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Replica = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ChangeLeaderOp) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ChangeLeaderOp: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ChangeLeaderOp: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Partition) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Partition: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Partition: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Subject", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Subject = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 3:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			m.Id = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Id |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Group = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReplicationFactor", wireType)
			}
			m.ReplicationFactor = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.ReplicationFactor |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 6:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Replicas = append(m.Replicas, string(dAtA[iNdEx:postIndex]))
			iNdEx = postIndex
		case 7:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Leader", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Leader = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 8:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Isr", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Isr = append(m.Isr, string(dAtA[iNdEx:postIndex]))
			iNdEx = postIndex
		case 9:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 10:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Epoch", wireType)
			}
			m.Epoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Epoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *RaftJoinRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: RaftJoinRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: RaftJoinRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field NodeID", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.NodeID = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field NodeAddr", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.NodeAddr = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *RaftJoinResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: RaftJoinResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: RaftJoinResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Error = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *MetadataSnapshot) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: MetadataSnapshot: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: MetadataSnapshot: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partitions", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Partitions = append(m.Partitions, &Partition{})
			if err := m.Partitions[len(m.Partitions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ReplicationRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ReplicationRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ReplicationRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReplicaID", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ReplicaID = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Offset", wireType)
			}
			m.Offset = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Offset |= (int64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *LeaderEpochOffsetRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: LeaderEpochOffsetRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: LeaderEpochOffsetRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field LeaderEpoch", wireType)
			}
			m.LeaderEpoch = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.LeaderEpoch |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *LeaderEpochOffsetResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: LeaderEpochOffsetResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: LeaderEpochOffsetResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field EndOffset", wireType)
			}
			m.EndOffset = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.EndOffset |= (int64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *PropagatedRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: PropagatedRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: PropagatedRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Op", wireType)
			}
			m.Op = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Op |= (Op(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field CreatePartitionOp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.CreatePartitionOp == nil {
				m.CreatePartitionOp = &CreatePartitionOp{}
			}
			if err := m.CreatePartitionOp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ShrinkISROp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ShrinkISROp == nil {
				m.ShrinkISROp = &ShrinkISROp{}
			}
			if err := m.ShrinkISROp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ReportLeaderOp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ReportLeaderOp == nil {
				m.ReportLeaderOp = &ReportLeaderOp{}
			}
			if err := m.ReportLeaderOp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 5:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ExpandISROp", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.ExpandISROp == nil {
				m.ExpandISROp = &ExpandISROp{}
			}
			if err := m.ExpandISROp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Error) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Error: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Error: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType)
			}
			m.Code = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Code |= (uint32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Msg = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *PropagatedResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: PropagatedResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: PropagatedResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Op", wireType)
			}
			m.Op = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Op |= (Op(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + msglen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Error == nil {
				m.Error = &Error{}
			}
			if err := m.Error.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ServerInfoRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ServerInfoRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ServerInfoRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Id = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *ServerInfoResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: ServerInfoResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: ServerInfoResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Id = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Host", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Host = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 3:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType)
			}
			m.Port = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Port |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *PartitionStatusRequest) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: PartitionStatusRequest: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: PartitionStatusRequest: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Stream", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= (uint64(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthInternal
			}
			postIndex := iNdEx + intStringLen
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Stream = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType)
			}
			m.Partition = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Partition |= (int32(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *PartitionStatusResponse) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: PartitionStatusResponse: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: PartitionStatusResponse: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Exists", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				v |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			m.Exists = bool(v != 0)
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field IsLeader", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				v |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			m.IsLeader = bool(v != 0)
		default:
			iNdEx = preIndex
			skippy, err := skipInternal(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if skippy < 0 {
				return ErrInvalidLengthInternal
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func skipInternal(dAtA []byte) (n int, err error) {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return 0, ErrIntOverflowInternal
			}
			if iNdEx >= l {
				return 0, io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		wireType := int(wire & 0x7)
		switch wireType {
		case 0:
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				iNdEx++
				if dAtA[iNdEx-1] < 0x80 {
					break
				}
			}
			return iNdEx, nil
		case 1:
			iNdEx += 8
			return iNdEx, nil
		case 2:
			var length int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowInternal
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				length |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			iNdEx += length
			if length < 0 {
				return 0, ErrInvalidLengthInternal
			}
			return iNdEx, nil
		case 3:
			for {
				var innerWire uint64
				var start int = iNdEx
				for shift := uint(0); ; shift += 7 {
					if shift >= 64 {
						return 0, ErrIntOverflowInternal
					}
					if iNdEx >= l {
						return 0, io.ErrUnexpectedEOF
					}
					b := dAtA[iNdEx]
					iNdEx++
					innerWire |= (uint64(b) & 0x7F) << shift
					if b < 0x80 {
						break
					}
				}
				innerWireType := int(innerWire & 0x7)
				if innerWireType == 4 {
					break
				}
				next, err := skipInternal(dAtA[start:])
				if err != nil {
					return 0, err
				}
				iNdEx = start + next
			}
			return iNdEx, nil
		case 4:
			return iNdEx, nil
		case 5:
			iNdEx += 4
			return iNdEx, nil
		default:
			return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
		}
	}
	panic("unreachable")
}

var (
	ErrInvalidLengthInternal = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowInternal   = fmt.Errorf("proto: integer overflow")
)

func init() { proto1.RegisterFile("server/proto/internal.proto", fileDescriptorInternal) }

var fileDescriptorInternal = []byte{
	// 902 bytes of a gzipped FileDescriptorProto
	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x56, 0x4f, 0x73, 0x1b, 0x35,
	0x14, 0xef, 0xae, 0xe3, 0x24, 0xfb, 0xdc, 0xba, 0x6b, 0x4d, 0x09, 0x5b, 0xc8, 0x64, 0x3c, 0xe2,
	0x12, 0x18, 0x48, 0x99, 0xc0, 0x85, 0x19, 0x38, 0x98, 0x64, 0x4b, 0x5d, 0x5c, 0xdb, 0x23, 0xfb,
	0xc0, 0x89, 0xa0, 0x7a, 0x15, 0x7b, 0x21, 0x59, 0x09, 0x49, 0xe9, 0xf4, 0x5b, 0x70, 0x84, 0xe1,
	0xd6, 0x13, 0x5f, 0x85, 0x23, 0x1f, 0x81, 0x09, 0x5f, 0x84, 0x91, 0x56, 0xfb, 0xc7, 0xeb, 0x0e,
	0x33, 0xb8, 0x97, 0x9e, 0xac, 0xdf, 0xd3, 0xd3, 0x7b, 0xbf, 0xf7, 0x7b, 0xda, 0x27, 0xc3, 0xfb,
	0x8a, 0xc9, 0x17, 0x4c, 0x3e, 0x12, 0x92, 0x6b, 0xfe, 0x28, 0xcd, 0x34, 0x93, 0x19, 0xbd, 0x3a,
	0xb1, 0x10, 0xb5, 0xed, 0x0f, 0xfe, 0x10, 0x3a, 0x33, 0xeb, 0x35, 0xd3, 0x54, 0x33, 0xf4, 0x1e,
	0xec, 0xe7, 0x87, 0x86, 0xe7, 0x91, 0xd7, 0xf7, 0x8e, 0x03, 0x52, 0x62, 0xfc, 0xab, 0x0f, 0x7b,
	0x84, 0x5e, 0xea, 0x11, 0x5f, 0xa2, 0x87, 0xe0, 0x73, 0x61, 0x3d, 0xba, 0xa7, 0x41, 0x1e, 0xf1,
	0x64, 0x22, 0x88, 0xcf, 0x05, 0x7a, 0x0c, 0xbd, 0x85, 0x64, 0x54, 0xb3, 0x29, 0x95, 0x3a, 0xd5,
	0x29, 0xcf, 0x26, 0x22, 0xf2, 0xfb, 0xde, 0x71, 0xe7, 0x34, 0x72, 0x9e, 0x67, 0xcd, 0x7d, 0xb2,
	0x79, 0x04, 0x7d, 0x0e, 0x1d, 0xb5, 0x92, 0x69, 0xf6, 0xd3, 0x70, 0x46, 0x26, 0x22, 0x6a, 0xd9,
	0x08, 0xc8, 0x45, 0x98, 0x55, 0x3b, 0xa4, 0xee, 0x86, 0xbe, 0x82, 0xee, 0x62, 0x45, 0xb3, 0x25,
	0x1b, 0x31, 0x9a, 0x30, 0x39, 0x11, 0xd1, 0x8e, 0x3d, 0xf8, 0x4e, 0x91, 0x7a, 0x6d, 0x93, 0x34,
	0x9c, 0x4d, 0x52, 0xf6, 0x52, 0xd0, 0x2c, 0xc9, 0x93, 0xb6, 0xd7, 0x92, 0xc6, 0xd5, 0x0e, 0xa9,
	0xbb, 0xe1, 0x33, 0xe8, 0x6d, 0x94, 0x84, 0x4e, 0x20, 0x10, 0x05, 0xb4, 0x4a, 0x75, 0x4e, 0x43,
	0x17, 0xa8, 0x74, 0x23, 0x95, 0x0b, 0xfe, 0xc3, 0x83, 0x4e, 0xad, 0x2c, 0x74, 0x00, 0xbb, 0x4a,
	0x4b, 0x46, 0xaf, 0x5d, 0x23, 0x1c, 0x42, 0x87, 0xf5, 0xb8, 0x46, 0xd7, 0x76, 0x2d, 0x0a, 0x3a,
	0x86, 0xfb, 0x92, 0x89, 0xab, 0x74, 0x41, 0xe7, 0x9c, 0xb0, 0x6b, 0xfe, 0x82, 0x59, 0xe5, 0x02,
	0xd2, 0x34, 0x9b, 0xf8, 0x57, 0xb6, 0x6c, 0xab, 0x50, 0x40, 0x1c, 0x42, 0x7d, 0xe8, 0xe4, 0xab,
	0x58, 0xf0, 0xc5, 0xca, 0x4a, 0xb0, 0x43, 0xea, 0x26, 0xfc, 0xca, 0x83, 0x4e, 0x4d, 0x8b, 0x2d,
	0x99, 0x62, 0xb8, 0x5b, 0x52, 0x1a, 0x24, 0x89, 0xa3, 0xb9, 0x66, 0x7b, 0x03, 0x8e, 0xbf, 0x7b,
	0xd0, 0x25, 0x4c, 0x70, 0xa9, 0xcb, 0xde, 0x6e, 0x47, 0x33, 0x82, 0x3d, 0x47, 0xc9, 0x31, 0x2c,
	0xe0, 0x1b, 0x90, 0xfb, 0x1e, 0xba, 0xeb, 0xf7, 0x70, 0x4b, 0x6e, 0x15, 0x83, 0x56, 0x9d, 0x01,
	0xfe, 0xc5, 0x87, 0x60, 0x5a, 0xaf, 0x40, 0xdd, 0x3c, 0xff, 0x91, 0x2d, 0xb4, 0x0b, 0x5e, 0xc0,
	0x5a, 0x56, 0x7f, 0x2d, 0x6b, 0x17, 0xfc, 0x34, 0x6f, 0x48, 0x9b, 0xf8, 0x69, 0x82, 0x1e, 0x40,
	0x7b, 0x29, 0xf9, 0x8d, 0x70, 0x85, 0xe6, 0x00, 0x7d, 0x0c, 0x3d, 0x27, 0x85, 0x49, 0xf3, 0x98,
	0x2e, 0x34, 0x97, 0xb6, 0xda, 0x36, 0xd9, 0xdc, 0x30, 0x93, 0xc5, 0x19, 0x55, 0xb4, 0xdb, 0x6f,
	0x99, 0xc9, 0x52, 0xe0, 0x5a, 0x1d, 0x7b, 0x6b, 0x4a, 0x86, 0xd0, 0x4a, 0x95, 0x8c, 0xf6, 0xad,
	0xbb, 0x59, 0x36, 0xb5, 0x0d, 0x36, 0xb4, 0x35, 0x5c, 0x99, 0xdd, 0x03, 0xbb, 0x97, 0x03, 0x1c,
	0xc3, 0x7d, 0x33, 0xba, 0x9e, 0xf2, 0x34, 0x23, 0xec, 0xe7, 0x1b, 0xa6, 0x6c, 0xf1, 0x19, 0x4f,
	0x58, 0x39, 0xe8, 0x1c, 0x32, 0x44, 0xcd, 0x6a, 0x90, 0x24, 0xd2, 0xc9, 0x52, 0x62, 0x7c, 0x0c,
	0x61, 0x15, 0x46, 0x09, 0x9e, 0x29, 0x66, 0x13, 0x4a, 0xc9, 0xa5, 0x0b, 0x93, 0x03, 0x7c, 0x0e,
	0xe1, 0x33, 0xa6, 0x69, 0x42, 0x35, 0x9d, 0x65, 0x54, 0xa8, 0x15, 0xd7, 0xe8, 0x53, 0x80, 0xb2,
	0x77, 0x2a, 0xf2, 0xfa, 0xad, 0xd7, 0x8e, 0x84, 0x9a, 0x0f, 0x7e, 0x0a, 0x88, 0x54, 0x4a, 0x16,
	0xcc, 0x0f, 0x21, 0x70, 0xd2, 0x95, 0xe4, 0x2b, 0x83, 0xa9, 0x8b, 0x5f, 0x5e, 0x2a, 0xa6, 0x2d,
	0xfb, 0x16, 0x71, 0x08, 0x7f, 0x09, 0xd1, 0xa8, 0xd2, 0x69, 0x62, 0x8d, 0x45, 0xc4, 0x86, 0xac,
	0xde, 0xe6, 0x95, 0xfd, 0x02, 0x1e, 0xbe, 0xe6, 0xb4, 0x93, 0xe0, 0x10, 0x02, 0x96, 0x25, 0xb9,
	0xd1, 0x1e, 0x6e, 0x91, 0xca, 0x80, 0x5f, 0xf9, 0xd0, 0x9b, 0x4a, 0x2e, 0xe8, 0x92, 0x6a, 0x96,
	0x14, 0x29, 0xdf, 0xe6, 0x17, 0x44, 0xae, 0x0d, 0x8e, 0xc6, 0x0b, 0xb2, 0x3e, 0x55, 0x48, 0xc3,
	0x79, 0xcb, 0x17, 0xe4, 0x13, 0x68, 0xc7, 0xe6, 0xde, 0x20, 0x04, 0x3b, 0x0b, 0x9e, 0x30, 0x2b,
	0xcc, 0x3d, 0x62, 0xd7, 0xe6, 0x33, 0xb8, 0x56, 0x4b, 0x77, 0x19, 0xcd, 0x12, 0xcf, 0x00, 0xd5,
	0x15, 0x75, 0x6d, 0xf8, 0x0f, 0x49, 0x71, 0x71, 0x49, 0x73, 0x19, 0xef, 0x16, 0x7c, 0x8c, 0xad,
	0xb8, 0xb2, 0x1f, 0x40, 0x2f, 0xff, 0x2b, 0x30, 0xcc, 0x2e, 0x79, 0xd1, 0xa6, 0x7c, 0x14, 0xe4,
	0x97, 0xcc, 0x4f, 0x13, 0x3c, 0x02, 0x54, 0x77, 0x72, 0x99, 0x1b, 0x5e, 0xa6, 0x8a, 0x15, 0x57,
	0xda, 0x51, 0xb6, 0x6b, 0x63, 0x33, 0x42, 0xb9, 0xb1, 0x62, 0xd7, 0x78, 0x0c, 0x07, 0x65, 0xc3,
	0xcc, 0x1f, 0x90, 0x1b, 0x55, 0xfb, 0x3a, 0xff, 0xff, 0x40, 0xc4, 0xcf, 0xe0, 0xdd, 0x8d, 0x78,
	0x8e, 0xe2, 0x01, 0xec, 0xb2, 0x97, 0xa9, 0xd2, 0xca, 0x06, 0xdc, 0x27, 0x0e, 0x99, 0xcf, 0x3d,
	0x55, 0x79, 0xf7, 0x6c, 0xbc, 0x7d, 0x52, 0xe2, 0x8f, 0x7e, 0x00, 0x7f, 0x22, 0xd0, 0x03, 0x08,
	0xcf, 0x48, 0x3c, 0x98, 0xc7, 0x17, 0xd3, 0x01, 0x99, 0x0f, 0xe7, 0xc3, 0xc9, 0x38, 0xbc, 0x83,
	0xba, 0x00, 0xb3, 0x27, 0x64, 0x38, 0xfe, 0xf6, 0x62, 0x38, 0x23, 0xa1, 0x87, 0x7a, 0x70, 0x8f,
	0xc4, 0xd3, 0x09, 0x99, 0x5f, 0x8c, 0xe2, 0xc1, 0x79, 0x4c, 0x42, 0xdf, 0x98, 0xce, 0x9e, 0x0c,
	0xc6, 0xdf, 0xc4, 0x85, 0xa9, 0x65, 0x4e, 0xc5, 0xdf, 0x4d, 0x07, 0xe3, 0x73, 0x7b, 0x6a, 0xe7,
	0xeb, 0xf0, 0xcf, 0xdb, 0x23, 0xef, 0xaf, 0xdb, 0x23, 0xef, 0xef, 0xdb, 0x23, 0xef, 0xb7, 0x7f,
	0x8e, 0xee, 0x3c, 0xdf, 0xb5, 0x9d, 0xf9, 0xec, 0xdf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x2c, 0x53,
	0x25, 0x44, 0xbd, 0x09, 0x00, 0x00,
}
