rdp_messages

package
v0.0.0-...-66c35ad Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2018 License: Apache-2.0 Imports: 3 Imported by: 1

Documentation

Overview

Package rdp_messages is a generated protocol buffer package.

It is generated from these files:

rdp.proto

It has these top-level messages:

Column
Row
Event
Transaction
KafkaPkg
KeyPair
VMSMessage
VIPProperties

Index

Constants

This section is empty.

Variables

View Source
var DDL_name = map[int32]string{
	0: "kDDLNoChage",
	1: "kDDLChanged",
}
View Source
var DDL_value = map[string]int32{
	"kDDLNoChage": 0,
	"kDDLChanged": 1,
}
View Source
var KafkaPkgFlag_name = map[int32]string{
	0: "kKfkPkgDefault",
	1: "kKfkPkgCompressData",
}
View Source
var KafkaPkgFlag_value = map[string]int32{
	"kKfkPkgDefault":      0,
	"kKfkPkgCompressData": 1,
}

Functions

This section is empty.

Types

type Column

type Column struct {
	// column 名称
	Name []byte `protobuf:"bytes,1,req,name=name" json:"name,omitempty"`
	// column 类型:int32 varcher blob等,参见:enum_field_types
	Type []byte `protobuf:"bytes,2,req,name=type" json:"type,omitempty"`
	// column 内容
	Value      []byte  `protobuf:"bytes,3,req,name=value" json:"value,omitempty"`
	BinlogType *uint32 `protobuf:"varint,4,opt,name=binlog_type" json:"binlog_type,omitempty"`
	// 索引类型
	Key              *string `protobuf:"bytes,5,opt,name=key" json:"key,omitempty"`
	IsNull           *uint32 `protobuf:"varint,6,opt,name=is_null" json:"is_null,omitempty"`
	XXX_unrecognized []byte  `json:"-"`
}

Column

func (*Column) Descriptor

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

func (*Column) GetBinlogType

func (m *Column) GetBinlogType() uint32

func (*Column) GetIsNull

func (m *Column) GetIsNull() uint32

func (*Column) GetKey

func (m *Column) GetKey() string

func (*Column) GetName

func (m *Column) GetName() []byte

func (*Column) GetType

func (m *Column) GetType() []byte

func (*Column) GetValue

func (m *Column) GetValue() []byte

func (*Column) ProtoMessage

func (*Column) ProtoMessage()

func (*Column) Reset

func (m *Column) Reset()

func (*Column) String

func (m *Column) String() string

type DDL

type DDL int32
const (
	DDL_kDDLNoChage DDL = 0
	DDL_kDDLChanged DDL = 1
)

func (DDL) Enum

func (x DDL) Enum() *DDL

func (DDL) EnumDescriptor

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

func (DDL) String

func (x DDL) String() string

func (*DDL) UnmarshalJSON

func (x *DDL) UnmarshalJSON(data []byte) error

type Event

type Event struct {
	DatabaseName []byte  `protobuf:"bytes,1,opt,name=database_name" json:"database_name,omitempty"`
	TableName    []byte  `protobuf:"bytes,2,opt,name=table_name" json:"table_name,omitempty"`
	EventType    *uint32 `protobuf:"varint,3,req,name=event_type" json:"event_type,omitempty"`
	SchemaId     *uint64 `protobuf:"varint,4,opt,name=schema_id" json:"schema_id,omitempty"`
	// 数据库的binlog时间
	Timestamp *uint64 `protobuf:"varint,5,req,name=timestamp" json:"timestamp,omitempty"`
	// rdp处理binlog的时间
	TimestampOfReceipt *uint64 `protobuf:"varint,6,req,name=timestamp_of_receipt" json:"timestamp_of_receipt,omitempty"`
	// 是否发生ddl变更
	Ddl *DDL `protobuf:"varint,7,opt,name=ddl,enum=rdp.messages.DDL" json:"ddl,omitempty"`
	// 在binlog文件中的位置
	Position *uint64 `protobuf:"varint,8,opt,name=position" json:"position,omitempty"`
	// 下一条binlog的位置
	NextPosition *uint64 `protobuf:"varint,9,opt,name=next_position" json:"next_position,omitempty"`
	// binlog文件名
	BinlogFileName []byte `protobuf:"bytes,10,opt,name=binlog_file_name" json:"binlog_file_name,omitempty"`
	// ServerId Long mysql 实例的唯一性ID
	ServerId *uint64 `protobuf:"varint,12,opt,name=server_id" json:"server_id,omitempty"`
	// sqlStatement String 表结构发生变化时的SQL
	SqlStatement []byte `protobuf:"bytes,13,opt,name=sql_statement" json:"sql_statement,omitempty"`
	Rows         []*Row `protobuf:"bytes,14,rep,name=rows" json:"rows,omitempty"`
	// Event原始的二进制流
	OrigBuff         []byte `protobuf:"bytes,15,opt,name=orig_buff" json:"orig_buff,omitempty"`
	XXX_unrecognized []byte `json:"-"`
}

func (*Event) Descriptor

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

func (*Event) GetBinlogFileName

func (m *Event) GetBinlogFileName() []byte

func (*Event) GetDatabaseName

func (m *Event) GetDatabaseName() []byte

func (*Event) GetDdl

func (m *Event) GetDdl() DDL

func (*Event) GetEventType

func (m *Event) GetEventType() uint32

func (*Event) GetNextPosition

func (m *Event) GetNextPosition() uint64

func (*Event) GetOrigBuff

func (m *Event) GetOrigBuff() []byte

func (*Event) GetPosition

func (m *Event) GetPosition() uint64

func (*Event) GetRows

func (m *Event) GetRows() []*Row

func (*Event) GetSchemaId

func (m *Event) GetSchemaId() uint64

func (*Event) GetServerId

func (m *Event) GetServerId() uint64

func (*Event) GetSqlStatement

func (m *Event) GetSqlStatement() []byte

func (*Event) GetTableName

func (m *Event) GetTableName() []byte

func (*Event) GetTimestamp

func (m *Event) GetTimestamp() uint64

func (*Event) GetTimestampOfReceipt

func (m *Event) GetTimestampOfReceipt() uint64

func (*Event) ProtoMessage

func (*Event) ProtoMessage()

func (*Event) Reset

func (m *Event) Reset()

func (*Event) String

func (m *Event) String() string

type KafkaPkg

type KafkaPkg struct {
	// kafka 数据版本号
	Epoch *uint64 `protobuf:"varint,1,req,name=epoch" json:"epoch,omitempty"`
	// 事务序号
	TransSeqNo *uint64 `protobuf:"varint,2,req,name=trans_seq_no" json:"trans_seq_no,omitempty"`
	// 事务GTID
	Gtid []byte `protobuf:"bytes,3,req,name=gtid" json:"gtid,omitempty"`
	// 分包标识
	// 0: 独立数据,没有分包操作
	// 1: 分包数据,非最后分包
	// 2: 分包数据,最后分包
	SplitFlag *int32 `protobuf:"varint,4,req,name=split_flag" json:"split_flag,omitempty"`
	// 分包序号
	SeqNo *uint64 `protobuf:"varint,5,req,name=seq_no" json:"seq_no,omitempty"`
	// 数据
	Data []byte `protobuf:"bytes,6,req,name=data" json:"data,omitempty"`
	// Transaction数据校验值
	// 在分包标识为0或者2的时候才存在
	Checksum *int64 `protobuf:"varint,7,opt,name=checksum" json:"checksum,omitempty"`
	// 标识字段
	Flag *uint32 `protobuf:"varint,8,opt,name=flag" json:"flag,omitempty"`
	// 序列后后,压缩前Transaction的长度
	SourceDataLen    *uint64 `protobuf:"varint,9,opt,name=source_data_len" json:"source_data_len,omitempty"`
	XXX_unrecognized []byte  `json:"-"`
}

写入kafka数据

func (*KafkaPkg) Descriptor

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

func (*KafkaPkg) GetChecksum

func (m *KafkaPkg) GetChecksum() int64

func (*KafkaPkg) GetData

func (m *KafkaPkg) GetData() []byte

func (*KafkaPkg) GetEpoch

func (m *KafkaPkg) GetEpoch() uint64

func (*KafkaPkg) GetFlag

func (m *KafkaPkg) GetFlag() uint32

func (*KafkaPkg) GetGtid

func (m *KafkaPkg) GetGtid() []byte

func (*KafkaPkg) GetSeqNo

func (m *KafkaPkg) GetSeqNo() uint64

func (*KafkaPkg) GetSourceDataLen

func (m *KafkaPkg) GetSourceDataLen() uint64

func (*KafkaPkg) GetSplitFlag

func (m *KafkaPkg) GetSplitFlag() int32

func (*KafkaPkg) GetTransSeqNo

func (m *KafkaPkg) GetTransSeqNo() uint64

func (*KafkaPkg) ProtoMessage

func (*KafkaPkg) ProtoMessage()

func (*KafkaPkg) Reset

func (m *KafkaPkg) Reset()

func (*KafkaPkg) String

func (m *KafkaPkg) String() string

type KafkaPkgFlag

type KafkaPkgFlag int32
const (
	KafkaPkgFlag_kKfkPkgDefault      KafkaPkgFlag = 0
	KafkaPkgFlag_kKfkPkgCompressData KafkaPkgFlag = 1
)

func (KafkaPkgFlag) Enum

func (x KafkaPkgFlag) Enum() *KafkaPkgFlag

func (KafkaPkgFlag) EnumDescriptor

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

func (KafkaPkgFlag) String

func (x KafkaPkgFlag) String() string

func (*KafkaPkgFlag) UnmarshalJSON

func (x *KafkaPkgFlag) UnmarshalJSON(data []byte) error

type KeyPair

type KeyPair struct {
	Key              *string `protobuf:"bytes,1,req,name=key" json:"key,omitempty"`
	Value            *string `protobuf:"bytes,2,req,name=value" json:"value,omitempty"`
	XXX_unrecognized []byte  `json:"-"`
}

**************VMS Protobuf********************

func (*KeyPair) Descriptor

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

func (*KeyPair) GetKey

func (m *KeyPair) GetKey() string

func (*KeyPair) GetValue

func (m *KeyPair) GetValue() string

func (*KeyPair) ProtoMessage

func (*KeyPair) ProtoMessage()

func (*KeyPair) Reset

func (m *KeyPair) Reset()

func (*KeyPair) String

func (m *KeyPair) String() string

type Row

type Row struct {
	// Insert、Delete情况下,只有before
	Before []*Column `protobuf:"bytes,14,rep,name=before" json:"before,omitempty"`
	// Update情况下,before和after成对出现
	After            []*Column `protobuf:"bytes,15,rep,name=after" json:"after,omitempty"`
	XXX_unrecognized []byte    `json:"-"`
}

func (*Row) Descriptor

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

func (*Row) GetAfter

func (m *Row) GetAfter() []*Column

func (*Row) GetBefore

func (m *Row) GetBefore() []*Column

func (*Row) ProtoMessage

func (*Row) ProtoMessage()

func (*Row) Reset

func (m *Row) Reset()

func (*Row) String

func (m *Row) String() string

type Transaction

type Transaction struct {
	Gtid   []byte   `protobuf:"bytes,1,req,name=gtid" json:"gtid,omitempty"`
	Seq    *uint32  `protobuf:"varint,2,req,name=seq" json:"seq,omitempty"`
	Events []*Event `protobuf:"bytes,3,rep,name=events" json:"events,omitempty"`
	// 在binlog文件中的位置
	Position *uint64 `protobuf:"varint,4,req,name=position" json:"position,omitempty"`
	// binlog文件名
	BinlogFileName []byte `protobuf:"bytes,5,req,name=binlog_file_name" json:"binlog_file_name,omitempty"`
	// 下一条binlog的位置
	NextPosition *uint64 `protobuf:"varint,6,req,name=next_position" json:"next_position,omitempty"`
	// binlog文件名
	NextBinlogFileName []byte `protobuf:"bytes,7,req,name=next_binlog_file_name" json:"next_binlog_file_name,omitempty"`
	// group commit id
	LastCommitted *int64 `protobuf:"varint,8,opt,name=last_committed" json:"last_committed,omitempty"`
	// group commit sequence number
	SequenceNumber   *int64 `protobuf:"varint,9,opt,name=sequence_number" json:"sequence_number,omitempty"`
	XXX_unrecognized []byte `json:"-"`
}

mysql Transaction 数据

func (*Transaction) Descriptor

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

func (*Transaction) GetBinlogFileName

func (m *Transaction) GetBinlogFileName() []byte

func (*Transaction) GetEvents

func (m *Transaction) GetEvents() []*Event

func (*Transaction) GetGtid

func (m *Transaction) GetGtid() []byte

func (*Transaction) GetLastCommitted

func (m *Transaction) GetLastCommitted() int64

func (*Transaction) GetNextBinlogFileName

func (m *Transaction) GetNextBinlogFileName() []byte

func (*Transaction) GetNextPosition

func (m *Transaction) GetNextPosition() uint64

func (*Transaction) GetPosition

func (m *Transaction) GetPosition() uint64

func (*Transaction) GetSeq

func (m *Transaction) GetSeq() uint32

func (*Transaction) GetSequenceNumber

func (m *Transaction) GetSequenceNumber() int64

func (*Transaction) ProtoMessage

func (*Transaction) ProtoMessage()

func (*Transaction) Reset

func (m *Transaction) Reset()

func (*Transaction) String

func (m *Transaction) String() string

type VIPProperties

type VIPProperties struct {
	Version          *string    `protobuf:"bytes,1,req,name=version" json:"version,omitempty"`
	Properties       []*KeyPair `protobuf:"bytes,2,rep,name=properties" json:"properties,omitempty"`
	XXX_unrecognized []byte     `json:"-"`
}

func (*VIPProperties) Descriptor

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

func (*VIPProperties) GetProperties

func (m *VIPProperties) GetProperties() []*KeyPair

func (*VIPProperties) GetVersion

func (m *VIPProperties) GetVersion() string

func (*VIPProperties) ProtoMessage

func (*VIPProperties) ProtoMessage()

func (*VIPProperties) Reset

func (m *VIPProperties) Reset()

func (*VIPProperties) String

func (m *VIPProperties) String() string

type VMSMessage

type VMSMessage struct {
	MessageId        *string    `protobuf:"bytes,1,opt,name=messageId" json:"messageId,omitempty"`
	Weight           *uint64    `protobuf:"varint,2,opt,name=weight" json:"weight,omitempty"`
	Ttl              *uint64    `protobuf:"varint,3,opt,name=ttl" json:"ttl,omitempty"`
	RoutingKeys      []string   `protobuf:"bytes,4,rep,name=routingKeys" json:"routingKeys,omitempty"`
	Properties       []*KeyPair `protobuf:"bytes,5,rep,name=properties" json:"properties,omitempty"`
	Payload          []byte     `protobuf:"bytes,6,req,name=payload" json:"payload,omitempty"`
	XXX_unrecognized []byte     `json:"-"`
}

func (*VMSMessage) Descriptor

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

func (*VMSMessage) GetMessageId

func (m *VMSMessage) GetMessageId() string

func (*VMSMessage) GetPayload

func (m *VMSMessage) GetPayload() []byte

func (*VMSMessage) GetProperties

func (m *VMSMessage) GetProperties() []*KeyPair

func (*VMSMessage) GetRoutingKeys

func (m *VMSMessage) GetRoutingKeys() []string

func (*VMSMessage) GetTtl

func (m *VMSMessage) GetTtl() uint64

func (*VMSMessage) GetWeight

func (m *VMSMessage) GetWeight() uint64

func (*VMSMessage) ProtoMessage

func (*VMSMessage) ProtoMessage()

func (*VMSMessage) Reset

func (m *VMSMessage) Reset()

func (*VMSMessage) String

func (m *VMSMessage) String() string

Jump to

Keyboard shortcuts

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