replication_modepb

package
v0.0.0-...-4fa2b26 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 17, 2024 License: Apache-2.0 Imports: 5 Imported by: 7

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthReplicationModepb        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowReplicationModepb          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupReplicationModepb = fmt.Errorf("proto: unexpected end of group")
)
View Source
var DRAutoSyncState_name = map[int32]string{
	0: "SYNC",
	1: "ASYNC_WAIT",
	2: "ASYNC",
	3: "SYNC_RECOVER",
}
View Source
var DRAutoSyncState_value = map[string]int32{
	"SYNC":         0,
	"ASYNC_WAIT":   1,
	"ASYNC":        2,
	"SYNC_RECOVER": 3,
}
View Source
var RegionReplicationState_name = map[int32]string{
	0: "UNKNOWN",
	1: "SIMPLE_MAJORITY",
	2: "INTEGRITY_OVER_LABEL",
}
View Source
var RegionReplicationState_value = map[string]int32{
	"UNKNOWN":              0,
	"SIMPLE_MAJORITY":      1,
	"INTEGRITY_OVER_LABEL": 2,
}
View Source
var ReplicationMode_name = map[int32]string{
	0: "MAJORITY",
	1: "DR_AUTO_SYNC",
}
View Source
var ReplicationMode_value = map[string]int32{
	"MAJORITY":     0,
	"DR_AUTO_SYNC": 1,
}

Functions

This section is empty.

Types

type DRAutoSync

type DRAutoSync struct {
	// The key of the label that used for distinguish different DC.
	LabelKey string          `protobuf:"bytes,1,opt,name=label_key,json=labelKey,proto3" json:"label_key,omitempty"`
	State    DRAutoSyncState `protobuf:"varint,2,opt,name=state,proto3,enum=replication_modepb.DRAutoSyncState" json:"state,omitempty"`
	// Unique ID of the state, it increases after each state transfer.
	StateId uint64 `protobuf:"varint,3,opt,name=state_id,json=stateId,proto3" json:"state_id,omitempty"`
	// Duration to wait before switching to SYNC by force (in seconds)
	WaitSyncTimeoutHint int32 `protobuf:"varint,4,opt,name=wait_sync_timeout_hint,json=waitSyncTimeoutHint,proto3" json:"wait_sync_timeout_hint,omitempty"`
	// Stores should only sync messages with available stores when state is ASYNC or ASYNC_WAIT.
	AvailableStores []uint64 `protobuf:"varint,5,rep,packed,name=available_stores,json=availableStores,proto3" json:"available_stores,omitempty"`
	// Stores should forbid region split.
	PauseRegionSplit     bool     `protobuf:"varint,6,opt,name=pause_region_split,json=pauseRegionSplit,proto3" json:"pause_region_split,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

The status of dr-autosync mode.

func (*DRAutoSync) Descriptor

func (*DRAutoSync) Descriptor() ([]byte, []int)

func (*DRAutoSync) GetAvailableStores

func (m *DRAutoSync) GetAvailableStores() []uint64

func (*DRAutoSync) GetLabelKey

func (m *DRAutoSync) GetLabelKey() string

func (*DRAutoSync) GetPauseRegionSplit

func (m *DRAutoSync) GetPauseRegionSplit() bool

func (*DRAutoSync) GetState

func (m *DRAutoSync) GetState() DRAutoSyncState

func (*DRAutoSync) GetStateId

func (m *DRAutoSync) GetStateId() uint64

func (*DRAutoSync) GetWaitSyncTimeoutHint

func (m *DRAutoSync) GetWaitSyncTimeoutHint() int32

func (*DRAutoSync) Marshal

func (m *DRAutoSync) Marshal() (dAtA []byte, err error)

func (*DRAutoSync) MarshalTo

func (m *DRAutoSync) MarshalTo(dAtA []byte) (int, error)

func (*DRAutoSync) MarshalToSizedBuffer

func (m *DRAutoSync) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*DRAutoSync) ProtoMessage

func (*DRAutoSync) ProtoMessage()

func (*DRAutoSync) Reset

func (m *DRAutoSync) Reset()

func (*DRAutoSync) Size

func (m *DRAutoSync) Size() (n int)

func (*DRAutoSync) String

func (m *DRAutoSync) String() string

func (*DRAutoSync) Unmarshal

func (m *DRAutoSync) Unmarshal(dAtA []byte) error

func (*DRAutoSync) XXX_DiscardUnknown

func (m *DRAutoSync) XXX_DiscardUnknown()

func (*DRAutoSync) XXX_Marshal

func (m *DRAutoSync) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DRAutoSync) XXX_Merge

func (m *DRAutoSync) XXX_Merge(src proto.Message)

func (*DRAutoSync) XXX_Size

func (m *DRAutoSync) XXX_Size() int

func (*DRAutoSync) XXX_Unmarshal

func (m *DRAutoSync) XXX_Unmarshal(b []byte) error

type DRAutoSyncState

type DRAutoSyncState int32
const (
	// Raft logs need to sync between different DCs
	DRAutoSyncState_SYNC DRAutoSyncState = 0
	// Wait for switching to ASYNC. Stop sync raft logs between DCs.
	DRAutoSyncState_ASYNC_WAIT DRAutoSyncState = 1
	// Raft logs need to sync to majority peers
	DRAutoSyncState_ASYNC DRAutoSyncState = 2
	// Switching from ASYNC to SYNC mode
	DRAutoSyncState_SYNC_RECOVER DRAutoSyncState = 3
)

func (DRAutoSyncState) EnumDescriptor

func (DRAutoSyncState) EnumDescriptor() ([]byte, []int)

func (DRAutoSyncState) String

func (x DRAutoSyncState) String() string

type RegionReplicationState

type RegionReplicationState int32
const (
	// The region's state is unknown
	RegionReplicationState_UNKNOWN RegionReplicationState = 0
	// Logs sync to majority peers
	RegionReplicationState_SIMPLE_MAJORITY RegionReplicationState = 1
	// Logs sync to different DCs
	RegionReplicationState_INTEGRITY_OVER_LABEL RegionReplicationState = 2
)

func (RegionReplicationState) EnumDescriptor

func (RegionReplicationState) EnumDescriptor() ([]byte, []int)

func (RegionReplicationState) String

func (x RegionReplicationState) String() string

type RegionReplicationStatus

type RegionReplicationStatus struct {
	State RegionReplicationState `protobuf:"varint,1,opt,name=state,proto3,enum=replication_modepb.RegionReplicationState" json:"state,omitempty"`
	// Unique ID of the state, it increases after each state transfer.
	StateId              uint64   `protobuf:"varint,2,opt,name=state_id,json=stateId,proto3" json:"state_id,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

The replication status sync from TiKV to PD.

func (*RegionReplicationStatus) Descriptor

func (*RegionReplicationStatus) Descriptor() ([]byte, []int)

func (*RegionReplicationStatus) GetState

func (*RegionReplicationStatus) GetStateId

func (m *RegionReplicationStatus) GetStateId() uint64

func (*RegionReplicationStatus) Marshal

func (m *RegionReplicationStatus) Marshal() (dAtA []byte, err error)

func (*RegionReplicationStatus) MarshalTo

func (m *RegionReplicationStatus) MarshalTo(dAtA []byte) (int, error)

func (*RegionReplicationStatus) MarshalToSizedBuffer

func (m *RegionReplicationStatus) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*RegionReplicationStatus) ProtoMessage

func (*RegionReplicationStatus) ProtoMessage()

func (*RegionReplicationStatus) Reset

func (m *RegionReplicationStatus) Reset()

func (*RegionReplicationStatus) Size

func (m *RegionReplicationStatus) Size() (n int)

func (*RegionReplicationStatus) String

func (m *RegionReplicationStatus) String() string

func (*RegionReplicationStatus) Unmarshal

func (m *RegionReplicationStatus) Unmarshal(dAtA []byte) error

func (*RegionReplicationStatus) XXX_DiscardUnknown

func (m *RegionReplicationStatus) XXX_DiscardUnknown()

func (*RegionReplicationStatus) XXX_Marshal

func (m *RegionReplicationStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*RegionReplicationStatus) XXX_Merge

func (m *RegionReplicationStatus) XXX_Merge(src proto.Message)

func (*RegionReplicationStatus) XXX_Size

func (m *RegionReplicationStatus) XXX_Size() int

func (*RegionReplicationStatus) XXX_Unmarshal

func (m *RegionReplicationStatus) XXX_Unmarshal(b []byte) error

type ReplicationMode

type ReplicationMode int32
const (
	// The standard mode. Replicate logs to majority peer.
	ReplicationMode_MAJORITY ReplicationMode = 0
	// DR mode. Replicate logs among 2 DCs.
	ReplicationMode_DR_AUTO_SYNC ReplicationMode = 1
)

func (ReplicationMode) EnumDescriptor

func (ReplicationMode) EnumDescriptor() ([]byte, []int)

func (ReplicationMode) String

func (x ReplicationMode) String() string

type ReplicationStatus

type ReplicationStatus struct {
	Mode                 ReplicationMode `protobuf:"varint,1,opt,name=mode,proto3,enum=replication_modepb.ReplicationMode" json:"mode,omitempty"`
	DrAutoSync           *DRAutoSync     `protobuf:"bytes,2,opt,name=dr_auto_sync,json=drAutoSync,proto3" json:"dr_auto_sync,omitempty"`
	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
	XXX_unrecognized     []byte          `json:"-"`
	XXX_sizecache        int32           `json:"-"`
}

The replication status sync from PD to TiKV.

func (*ReplicationStatus) Descriptor

func (*ReplicationStatus) Descriptor() ([]byte, []int)

func (*ReplicationStatus) GetDrAutoSync

func (m *ReplicationStatus) GetDrAutoSync() *DRAutoSync

func (*ReplicationStatus) GetMode

func (m *ReplicationStatus) GetMode() ReplicationMode

func (*ReplicationStatus) Marshal

func (m *ReplicationStatus) Marshal() (dAtA []byte, err error)

func (*ReplicationStatus) MarshalTo

func (m *ReplicationStatus) MarshalTo(dAtA []byte) (int, error)

func (*ReplicationStatus) MarshalToSizedBuffer

func (m *ReplicationStatus) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ReplicationStatus) ProtoMessage

func (*ReplicationStatus) ProtoMessage()

func (*ReplicationStatus) Reset

func (m *ReplicationStatus) Reset()

func (*ReplicationStatus) Size

func (m *ReplicationStatus) Size() (n int)

func (*ReplicationStatus) String

func (m *ReplicationStatus) String() string

func (*ReplicationStatus) Unmarshal

func (m *ReplicationStatus) Unmarshal(dAtA []byte) error

func (*ReplicationStatus) XXX_DiscardUnknown

func (m *ReplicationStatus) XXX_DiscardUnknown()

func (*ReplicationStatus) XXX_Marshal

func (m *ReplicationStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ReplicationStatus) XXX_Merge

func (m *ReplicationStatus) XXX_Merge(src proto.Message)

func (*ReplicationStatus) XXX_Size

func (m *ReplicationStatus) XXX_Size() int

func (*ReplicationStatus) XXX_Unmarshal

func (m *ReplicationStatus) XXX_Unmarshal(b []byte) error

type StoreDRAutoSyncStatus

type StoreDRAutoSyncStatus struct {
	State                DRAutoSyncState `protobuf:"varint,1,opt,name=state,proto3,enum=replication_modepb.DRAutoSyncState" json:"state,omitempty"`
	StateId              uint64          `protobuf:"varint,2,opt,name=state_id,json=stateId,proto3" json:"state_id,omitempty"`
	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
	XXX_unrecognized     []byte          `json:"-"`
	XXX_sizecache        int32           `json:"-"`
}

func (*StoreDRAutoSyncStatus) Descriptor

func (*StoreDRAutoSyncStatus) Descriptor() ([]byte, []int)

func (*StoreDRAutoSyncStatus) GetState

func (m *StoreDRAutoSyncStatus) GetState() DRAutoSyncState

func (*StoreDRAutoSyncStatus) GetStateId

func (m *StoreDRAutoSyncStatus) GetStateId() uint64

func (*StoreDRAutoSyncStatus) Marshal

func (m *StoreDRAutoSyncStatus) Marshal() (dAtA []byte, err error)

func (*StoreDRAutoSyncStatus) MarshalTo

func (m *StoreDRAutoSyncStatus) MarshalTo(dAtA []byte) (int, error)

func (*StoreDRAutoSyncStatus) MarshalToSizedBuffer

func (m *StoreDRAutoSyncStatus) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*StoreDRAutoSyncStatus) ProtoMessage

func (*StoreDRAutoSyncStatus) ProtoMessage()

func (*StoreDRAutoSyncStatus) Reset

func (m *StoreDRAutoSyncStatus) Reset()

func (*StoreDRAutoSyncStatus) Size

func (m *StoreDRAutoSyncStatus) Size() (n int)

func (*StoreDRAutoSyncStatus) String

func (m *StoreDRAutoSyncStatus) String() string

func (*StoreDRAutoSyncStatus) Unmarshal

func (m *StoreDRAutoSyncStatus) Unmarshal(dAtA []byte) error

func (*StoreDRAutoSyncStatus) XXX_DiscardUnknown

func (m *StoreDRAutoSyncStatus) XXX_DiscardUnknown()

func (*StoreDRAutoSyncStatus) XXX_Marshal

func (m *StoreDRAutoSyncStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*StoreDRAutoSyncStatus) XXX_Merge

func (m *StoreDRAutoSyncStatus) XXX_Merge(src proto.Message)

func (*StoreDRAutoSyncStatus) XXX_Size

func (m *StoreDRAutoSyncStatus) XXX_Size() int

func (*StoreDRAutoSyncStatus) XXX_Unmarshal

func (m *StoreDRAutoSyncStatus) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL