internal

package
v0.0.0-...-06b4540 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Empty converterParseMode = iota
	CreateTable
	CreateTableExcludeSuffix
	CreateView
)
View Source
const (
	ObjectTypeNone objectType = iota
	ObjectTypeTable
	ObjectTypeView
)

Variables

This section is empty.

Functions

func GetSortedKeys

func GetSortedKeys[K cmp.Ordered, V any](m map[K]V) []K

func GetYdbCredentials

func GetYdbCredentials() ydb.Option

Types

type PgSchema

type PgSchema struct {
	CommentExcluded bool
	ConvertSchema   bool
	// contains filtered or unexported fields
}

func NewPgSchema

func NewPgSchema() *PgSchema

func (*PgSchema) GetSchemas

func (c *PgSchema) GetSchemas() []string

func (*PgSchema) Read

func (c *PgSchema) Read(reader io.Reader)

func (*PgSchema) Write

func (c *PgSchema) Write(writer io.Writer) error

type Query

type Query struct {
	Number int
	Text   string
}

type Session

type Session struct {
	ID           string
	Success      bool
	Transactions []Transaction
}

type SessionLogRecord

type SessionLogRecord struct {
	ProcessID          int    `json:"pid"`
	SessionID          int    `json:"sess_id"`
	QueryCount         int    `json:"query_count"`
	Query              string `json:"query"`
	TransactionCount   int    `json:"transaction_count"`
	TransactionSuccess bool   `json:"transaction_success"`
}

type Transaction

type Transaction struct {
	Number  int
	Success bool
	Queries []Query
}

type YdbIssue

type YdbIssue struct {
	Message  string                   `yaml:"message"`
	Code     Ydb.StatusIds_StatusCode `yaml:"code"`
	Severity uint32                   `yaml:"severity"`
}

func ExtractIssues

func ExtractIssues(err error) []YdbIssue

type YdbPool

type YdbPool struct {
	// contains filtered or unexported fields
}

func NewYdbPool

func NewYdbPool(drivers []*ydb.Driver) *YdbPool

func OpenYdbPool

func OpenYdbPool(ctx context.Context, connectionStrings []string, options []ydb.Option) *YdbPool

func (*YdbPool) Get

func (p *YdbPool) Get() *ydb.Driver

Get return driver with minimal current inflight

func (*YdbPool) Release

func (p *YdbPool) Release(driver *ydb.Driver)

Jump to

Keyboard shortcuts

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