sqldb

package
v0.5.4 Latest Latest
Warning

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

Go to latest
Published: Mar 8, 2019 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ActivityInfoMapsFilter

type ActivityInfoMapsFilter struct {
	ShardID    int64
	DomainID   UUID
	WorkflowID string
	RunID      UUID
	ScheduleID *int64
}

ActivityInfoMapsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type ActivityInfoMapsRow

type ActivityInfoMapsRow struct {
	ShardID                  int64
	DomainID                 UUID
	WorkflowID               string
	RunID                    UUID
	ScheduleID               int64
	Version                  int64
	ScheduledEventBatchID    int64
	ScheduledEvent           []byte
	ScheduledEventEncoding   string
	ScheduledTime            time.Time
	StartedID                int64
	StartedEvent             *[]byte
	StartedEventEncoding     string
	StartedTime              time.Time
	ActivityID               string
	RequestID                string
	Details                  *[]byte
	ScheduleToStartTimeout   int64
	ScheduleToCloseTimeout   int64
	StartToCloseTimeout      int64
	HeartbeatTimeout         int64
	CancelRequested          int64
	CancelRequestID          int64
	LastHeartbeatUpdatedTime time.Time
	TimerTaskStatus          int64
	Attempt                  int64
	TaskList                 string
	StartedIdentity          string
	HasRetryPolicy           int64
	InitInterval             int64
	BackoffCoefficient       float64
	MaxInterval              int64
	ExpirationTime           time.Time
	MaxAttempts              int64
	NonRetriableErrors       *[]byte
}

ActivityInfoMapsRow represents a row in activity_info_maps table

type BufferedEventsFilter

type BufferedEventsFilter struct {
	ShardID    int
	DomainID   UUID
	WorkflowID string
	RunID      UUID
}

BufferedEventsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type BufferedEventsRow

type BufferedEventsRow struct {
	ShardID      int
	DomainID     UUID
	WorkflowID   string
	RunID        UUID
	Data         []byte
	DataEncoding string
}

BufferedEventsRow represents a row in buffered_events table

type BufferedReplicationTaskMapsFilter

type BufferedReplicationTaskMapsFilter struct {
	ShardID      int64
	DomainID     UUID
	WorkflowID   string
	RunID        UUID
	FirstEventID *int64
}

BufferedReplicationTaskMapsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type BufferedReplicationTaskMapsRow

type BufferedReplicationTaskMapsRow struct {
	ShardID               int64
	DomainID              UUID
	WorkflowID            string
	RunID                 UUID
	FirstEventID          int64
	NextEventID           int64
	Version               int64
	History               *[]byte
	HistoryEncoding       string
	NewRunHistory         *[]byte
	NewRunHistoryEncoding string
}

BufferedReplicationTaskMapsRow represents a row in buffered_replication_task_maps table

type ChildExecutionInfoMapsFilter

type ChildExecutionInfoMapsFilter struct {
	ShardID     int64
	DomainID    UUID
	WorkflowID  string
	RunID       UUID
	InitiatedID *int64
}

ChildExecutionInfoMapsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type ChildExecutionInfoMapsRow

type ChildExecutionInfoMapsRow struct {
	ShardID                int64
	DomainID               UUID
	WorkflowID             string
	RunID                  UUID
	InitiatedID            int64
	Version                int64
	InitiatedEventBatchID  int64
	InitiatedEvent         *[]byte
	InitiatedEventEncoding string
	StartedID              int64
	StartedWorkflowID      string
	StartedRunID           string
	StartedEvent           *[]byte
	StartedEventEncoding   string
	CreateRequestID        string
	DomainName             string
	WorkflowTypeName       string
}

ChildExecutionInfoMapsRow represents a row in child_execution_info_maps table

type Conn

type Conn interface {
	Exec(query string, args ...interface{}) (sql.Result, error)
	NamedExec(query string, arg interface{}) (sql.Result, error)
	Get(dest interface{}, query string, args ...interface{}) error
	Select(dest interface{}, query string, args ...interface{}) error
}

Conn defines the API for a single database connection

type CurrentExecutionsFilter

type CurrentExecutionsFilter struct {
	ShardID    int64
	DomainID   UUID
	WorkflowID string
	RunID      UUID
}

CurrentExecutionsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type CurrentExecutionsRow

type CurrentExecutionsRow struct {
	ShardID          int64
	DomainID         UUID
	WorkflowID       string
	RunID            UUID
	CreateRequestID  string
	State            int
	CloseStatus      int
	LastWriteVersion int64
	StartVersion     int64
}

CurrentExecutionsRow represents a row in current_executions table

type DomainFilter

type DomainFilter struct {
	ID   *UUID
	Name *string
}

DomainFilter contains the column names within domain table that can be used to filter results through a WHERE clause. When ID is not nil, it will be used for WHERE condition. If ID is nil and Name is non-nil, Name will be used for WHERE condition. When both ID and Name are nil, no WHERE clause will be used

type DomainMetadataRow

type DomainMetadataRow struct {
	NotificationVersion int64
}

DomainMetadataRow represents a row in domain_metadata table

type DomainRow

type DomainRow struct {
	ID                          UUID
	Name                        string
	Status                      int
	Description                 string
	OwnerEmail                  string
	Data                        []byte
	Retention                   int
	EmitMetric                  bool
	ArchivalBucket              string
	ArchivalStatus              int
	ConfigVersion               int64
	NotificationVersion         int64
	FailoverNotificationVersion int64
	FailoverVersion             int64
	IsGlobalDomain              bool
	ActiveClusterName           string
	Clusters                    []byte
}

DomainRow represents a row in domain table

type EventsFilter

type EventsFilter struct {
	DomainID     UUID
	WorkflowID   string
	RunID        UUID
	FirstEventID *int64
	NextEventID  *int64
	PageSize     *int
}

EventsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type EventsRow

type EventsRow struct {
	DomainID     UUID
	WorkflowID   string
	RunID        UUID
	FirstEventID int64
	BatchVersion int64
	RangeID      int64
	TxID         int64
	Data         []byte
	DataEncoding string
}

EventsRow represents a row in events table

type ExecutionsFilter

type ExecutionsFilter struct {
	ShardID    int
	DomainID   UUID
	WorkflowID string
	RunID      UUID
}

ExecutionsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type ExecutionsRow

type ExecutionsRow struct {
	ShardID                      int
	DomainID                     UUID
	WorkflowID                   string
	RunID                        UUID
	ParentDomainID               *UUID
	ParentWorkflowID             *string
	ParentRunID                  *UUID
	InitiatedID                  *int64
	CompletionEventBatchID       *int64
	CompletionEvent              *[]byte
	CompletionEventEncoding      *string
	TaskList                     string
	WorkflowTypeName             string
	WorkflowTimeoutSeconds       int64
	DecisionTaskTimeoutMinutes   int64
	ExecutionContext             *[]byte
	State                        int64
	CloseStatus                  int64
	StartVersion                 int64
	CurrentVersion               int64
	LastWriteVersion             int64
	LastWriteEventID             *int64
	LastReplicationInfo          *[]byte
	LastFirstEventID             int64
	LastEventTaskID              int64
	NextEventID                  int64
	LastProcessedEvent           int64
	StartTime                    time.Time
	LastUpdatedTime              time.Time
	CreateRequestID              string
	DecisionVersion              int64
	DecisionScheduleID           int64
	DecisionStartedID            int64
	DecisionRequestID            string
	DecisionTimeout              int64
	DecisionAttempt              int64
	DecisionTimestamp            int64
	CancelRequested              *int64
	CancelRequestID              *string
	StickyTaskList               string
	StickyScheduleToStartTimeout int64
	ClientLibraryVersion         string
	ClientFeatureVersion         string
	ClientImpl                   string
	SignalCount                  int
	HistorySize                  int64
	CronSchedule                 string
	HasRetryPolicy               bool
	Attempt                      int
	InitialInterval              int
	BackoffCoefficient           float64
	MaximumInterval              int
	MaximumAttempts              int
	ExpirationSeconds            int
	ExpirationTime               time.Time
	NonRetryableErrors           []byte
}

ExecutionsRow represents a row in executions table

type Interface

type Interface interface {
	BeginTx() (Tx, error)
	DriverName() string
	Close() error
	// contains filtered or unexported methods
}

Interface defines the API for a SQL database

type ReplicationTasksFilter

type ReplicationTasksFilter struct {
	ShardID   int
	TaskID    *int64
	MinTaskID *int64
	MaxTaskID *int64
	PageSize  *int
}

ReplicationTasksFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type ReplicationTasksRow

type ReplicationTasksRow struct {
	ShardID             int
	TaskID              int64
	DomainID            UUID
	WorkflowID          string
	RunID               UUID
	TaskType            int
	FirstEventID        int64
	NextEventID         int64
	Version             int64
	LastReplicationInfo []byte
	ScheduledID         int64
}

ReplicationTasksRow represents a row in replication_tasks table

type RequestCancelInfoMapsFilter

type RequestCancelInfoMapsFilter struct {
	ShardID     int64
	DomainID    UUID
	WorkflowID  string
	RunID       UUID
	InitiatedID *int64
}

RequestCancelInfoMapsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type RequestCancelInfoMapsRow

type RequestCancelInfoMapsRow struct {
	ShardID         int64
	DomainID        UUID
	WorkflowID      string
	RunID           UUID
	InitiatedID     int64
	Version         int64
	CancelRequestID string
}

RequestCancelInfoMapsRow represents a row in request_cancel_info_maps table

type ShardsFilter

type ShardsFilter struct {
	ShardID int64
}

ShardsFilter contains the column names within shards table that can be used to filter results through a WHERE clause

type ShardsRow

type ShardsRow struct {
	ShardID                   int64
	Owner                     string
	RangeID                   int64
	StolenSinceRenew          int64
	UpdatedAt                 time.Time
	ReplicationAckLevel       int64
	TransferAckLevel          int64
	TimerAckLevel             time.Time
	ClusterTransferAckLevel   []byte
	ClusterTimerAckLevel      []byte
	DomainNotificationVersion int64
}

ShardsRow represents a row in shards table

type SignalInfoMapsFilter

type SignalInfoMapsFilter struct {
	ShardID     int64
	DomainID    UUID
	WorkflowID  string
	RunID       UUID
	InitiatedID *int64
}

SignalInfoMapsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type SignalInfoMapsRow

type SignalInfoMapsRow struct {
	ShardID         int64
	DomainID        UUID
	WorkflowID      string
	RunID           UUID
	InitiatedID     int64
	Version         int64
	SignalRequestID string
	SignalName      string
	Input           *[]byte
	Control         *[]byte
}

SignalInfoMapsRow represents a row in signal_info_maps table

type SignalsRequestedSetsFilter

type SignalsRequestedSetsFilter struct {
	ShardID    int64
	DomainID   UUID
	WorkflowID string
	RunID      UUID
	SignalID   *string
}

SignalsRequestedSetsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type SignalsRequestedSetsRow

type SignalsRequestedSetsRow struct {
	ShardID    int64
	DomainID   UUID
	WorkflowID string
	RunID      UUID
	SignalID   string
}

SignalsRequestedSetsRow represents a row in signals_requested_sets table

type TaskListsFilter

type TaskListsFilter struct {
	ShardID             int
	DomainID            *UUID
	Name                *string
	TaskType            *int64
	DomainIDGreaterThan *UUID
	NameGreaterThan     *string
	TaskTypeGreaterThan *int64
	RangeID             *int64
	PageSize            *int
}

TaskListsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type TaskListsRow

type TaskListsRow struct {
	ShardID     int
	DomainID    UUID
	Name        string
	TaskType    int64
	RangeID     int64
	AckLevel    int64
	Kind        int64
	LastUpdated time.Time
	ExpiryTs    time.Time
}

TaskListsRow represents a row in task_lists table

type TasksFilter

type TasksFilter struct {
	DomainID             UUID
	TaskListName         string
	TaskType             int64
	TaskID               *int64
	MinTaskID            *int64
	MaxTaskID            *int64
	TaskIDLessThanEquals *int64
	Limit                *int
	PageSize             *int
}

TasksFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type TasksRow

type TasksRow struct {
	DomainID     UUID
	TaskType     int64
	TaskID       int64
	TaskListName string
	WorkflowID   string
	RunID        UUID
	ScheduleID   int64
	ExpiryTs     time.Time
}

TasksRow represents a row in tasks table

type TimerInfoMapsFilter

type TimerInfoMapsFilter struct {
	ShardID    int64
	DomainID   UUID
	WorkflowID string
	RunID      UUID
	TimerID    *string
}

TimerInfoMapsFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type TimerInfoMapsRow

type TimerInfoMapsRow struct {
	ShardID    int64
	DomainID   UUID
	WorkflowID string
	RunID      UUID
	TimerID    string
	Version    int64
	StartedID  int64
	ExpiryTime time.Time
	TaskID     int64
}

TimerInfoMapsRow represents a row in timer_info_maps table

type TimerTasksFilter

type TimerTasksFilter struct {
	ShardID                int
	TaskID                 int64
	VisibilityTimestamp    *time.Time
	MinVisibilityTimestamp *time.Time
	MaxVisibilityTimestamp *time.Time
	PageSize               *int
}

TimerTasksFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type TimerTasksRow

type TimerTasksRow struct {
	ShardID             int
	VisibilityTimestamp time.Time
	TaskID              int64
	DomainID            UUID
	WorkflowID          string
	RunID               UUID
	TaskType            int
	TimeoutType         int
	EventID             int64
	ScheduleAttempt     int64
	Version             int64
}

TimerTasksRow represents a row in timer_tasks table

type TransferTasksFilter

type TransferTasksFilter struct {
	ShardID   int
	TaskID    *int64
	MinTaskID *int64
	MaxTaskID *int64
}

TransferTasksFilter contains the column names within transfer_tasks table that can be used to filter results through a WHERE clause

type TransferTasksRow

type TransferTasksRow struct {
	ShardID                 int
	TaskID                  int64
	DomainID                UUID
	WorkflowID              string
	RunID                   UUID
	TaskType                int
	TargetDomainID          UUID
	TargetWorkflowID        string
	TargetRunID             UUID
	TargetChildWorkflowOnly bool
	TaskList                string
	ScheduleID              int64
	Version                 int64
	VisibilityTimestamp     time.Time
}

TransferTasksRow represents a row in transfer_tasks table

type Tx

type Tx interface {
	Commit() error
	Rollback() error
	// contains filtered or unexported methods
}

Tx defines the API for a SQL transaction

type UUID

type UUID []byte

UUID represents a 16-byte universally unique identifier this type is a wrapper around google/uuid with the following differences

  • type is a byte slice instead of [16]byte
  • db serialization converts uuid to bytes as opposed to string

func MustParseUUID

func MustParseUUID(s string) UUID

MustParseUUID returns a UUID parsed from the given string representation returns nil if the input is empty string panics if the given input is malformed

func UUIDPtr

func UUIDPtr(u UUID) *UUID

UUIDPtr simply returns a pointer for the given value type

func (*UUID) Scan

func (u *UUID) Scan(src interface{}) error

Scan implements sql.Scanner interface to allow this type to be parsed transparently by database drivers

func (UUID) String

func (u UUID) String() string

String returns the 36 byet hexstring representation of this uuid return empty string if this uuid is nil

func (UUID) Value

func (u UUID) Value() (driver.Value, error)

Value implements sql.Valuer so that UUIDs can be written to databases transparently. This method returns a byte slice representation of uuid

type VisibilityFilter

type VisibilityFilter struct {
	DomainID         string
	Closed           bool
	RunID            *string
	WorkflowID       *string
	WorkflowTypeName *string
	CloseStatus      *int32
	MinStartTime     *time.Time
	MaxStartTime     *time.Time
	PageSize         *int
}

VisibilityFilter contains the column names within domain table that can be used to filter results through a WHERE clause

type VisibilityRow

type VisibilityRow struct {
	DomainID         string
	RunID            string
	WorkflowTypeName string
	WorkflowID       string
	StartTime        time.Time
	CloseStatus      *int32
	CloseTime        *time.Time
	HistoryLength    *int64
}

VisibilityRow represents a row in executions_visibility table

Jump to

Keyboard shortcuts

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