pgtypes

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MessageTypeLogicalDecodingMessage pglogrepl.MessageType = 'M'
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BeginMessage

type BeginMessage pglogrepl.BeginMessage

func (BeginMessage) String added in v0.0.12

func (m BeginMessage) String() string

type CommitMessage

type CommitMessage pglogrepl.CommitMessage

func (CommitMessage) String added in v0.0.12

func (m CommitMessage) String() string

type DeleteMessage

type DeleteMessage struct {
	*pglogrepl.DeleteMessage
	OldValues map[string]any
}

func (DeleteMessage) String added in v0.0.12

func (m DeleteMessage) String() string

type InsertMessage

type InsertMessage struct {
	*pglogrepl.InsertMessage
	NewValues map[string]any
}

func (InsertMessage) String added in v0.0.12

func (m InsertMessage) String() string

type LSN

type LSN pglogrepl.LSN

func (LSN) String

func (lsn LSN) String() string

type LogicalReplicationMessage

type LogicalReplicationMessage struct {

	// Flags is either 0 (non-transactional) or 1 (transactional)
	Flags uint8
	// Xid is the transaction id (if transactional logical replication message)
	Xid *uint32
	// LSN is the LSN of the logical replication message
	LSN pglogrepl.LSN
	// Prefix is the prefix of the logical replication message
	Prefix string
	// Content is the content of the logical replication message
	Content []byte
	// contains filtered or unexported fields
}

LogicalReplicationMessage is a logical replication message.

func (*LogicalReplicationMessage) Decode

func (m *LogicalReplicationMessage) Decode(src []byte) (err error)

func (*LogicalReplicationMessage) IsTransactional

func (m *LogicalReplicationMessage) IsTransactional() bool

func (*LogicalReplicationMessage) SetType

func (m *LogicalReplicationMessage) SetType(t pglogrepl.MessageType)

func (*LogicalReplicationMessage) String added in v0.0.12

func (m *LogicalReplicationMessage) String() string

func (*LogicalReplicationMessage) Type

func (m *LogicalReplicationMessage) Type() pglogrepl.MessageType

Type returns message type.

type OriginMessage

type OriginMessage pglogrepl.OriginMessage

func (OriginMessage) String added in v0.0.12

func (m OriginMessage) String() string

type RelationMessage

type RelationMessage pglogrepl.RelationMessage

func (RelationMessage) String added in v0.0.12

func (m RelationMessage) String() string

type ReplicaIdentity

type ReplicaIdentity string
const (
	NOTHING ReplicaIdentity = "n"
	FULL    ReplicaIdentity = "f"
	DEFAULT ReplicaIdentity = "d"
	INDEX   ReplicaIdentity = "i"
	UNKNOWN ReplicaIdentity = ""
)

func AsReplicaIdentity

func AsReplicaIdentity(val string) ReplicaIdentity

func (ReplicaIdentity) Description

func (ri ReplicaIdentity) Description() string

Description returns a description of this REPLICA IDENTITY Values are in sync with debezium project: https://github.com/debezium/debezium/blob/main/debezium-connector-postgres/src/main/java/io/debezium/connector/postgresql/connection/ServerInfo.java

func (*ReplicaIdentity) Scan

func (ri *ReplicaIdentity) Scan(src interface{}) error

type TruncateMessage

type TruncateMessage pglogrepl.TruncateMessage

func (TruncateMessage) String added in v0.0.12

func (m TruncateMessage) String() string

type TypeMessage

type TypeMessage pglogrepl.TypeMessage

func (TypeMessage) String added in v0.0.12

func (m TypeMessage) String() string

type UpdateMessage

type UpdateMessage struct {
	*pglogrepl.UpdateMessage
	OldValues map[string]any
	NewValues map[string]any
}

func (UpdateMessage) String added in v0.0.12

func (m UpdateMessage) String() string

type XLogData

type XLogData struct {
	pglogrepl.XLogData

	LastBegin  LSN
	LastCommit LSN
	Xid        uint32
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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