Documentation
¶
Index ¶
- func Run(stx sessionContext, log timber.Logger, terminateChannel chan bool) error
- type DistributedPlanType
- type ExpandedPlan
- type ExpandedPlanTask
- type InitialPlan
- type InitialPlanTask
- type NoahQueryPlanner
- type PlanTarget
- type PlanType
- type PreparedPortal
- type PreparedStatement
- type QueryMode
- type QueryPlanner
- type Session
- type TransactionQueryPlanner
- type TransactionState
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DistributedPlanType ¶
type DistributedPlanType int
const (
DistributedPlanType_NONE DistributedPlanType = 0
DistributedPlanType_COMMIT DistributedPlanType = 1
DistributedPlanType_ROLLBACK DistributedPlanType = 2
)
type ExpandedPlan ¶
type ExpandedPlan struct {
Tasks []ExpandedPlanTask
Target PlanTarget
OutFormats []pgwirebase.FormatCode
DistPlanType DistributedPlanType
}
type ExpandedPlanTask ¶
type ExpandedPlanTask struct {
Query string
ReadOnly bool
DataNodeShardID uint64
Type ast.StmtType
}
type InitialPlan ¶
type InitialPlan struct {
Types map[PlanType]InitialPlanTask
ShardID uint64
Target PlanTarget
DistPlanType DistributedPlanType
}
type InitialPlanTask ¶
type InitialPlanTask struct {
Query string
Type ast.StmtType
}
type NoahQueryPlanner ¶
type NoahQueryPlanner interface {
// contains filtered or unexported methods
}
type PlanTarget ¶
type PlanTarget string
const (
PlanTarget_STANDARD PlanTarget = "STANDARD"
PlanTarget_INTERNAL PlanTarget = "INTERNAL"
)
type PlanType ¶
type PlanType string
const (
PlanType_READ PlanType = "READ"
PlanType_WRITE PlanType = "WRITE"
PlanType_READWRITE PlanType = "READWRITE"
)
type PreparedPortal ¶
type PreparedPortal struct {
Stmt *PreparedStatement
Qargs queryutil.QueryArguments
// OutFormats contains the requested formats for the output columns.
OutFormats []pgwirebase.FormatCode
}
PreparedPortal is a PreparedStatement that has been bound with query arguments.
type PreparedStatement ¶
type PreparedStatement struct {
// Str is the statement string prior to parsing, used to generate
// error messages. This may be used in
// the future to present a contextual error message based on location
// information.
Str string
// TypeHints contains the types of the placeholders set by the client. It
// dictates how input parameters for those placeholders will be parsed. If a
// placeholder has no type hint, it will be populated during type checking.
TypeHints queryutil.PlaceholderTypes
// Statement is the parse tree from pg_query.
// This is used later to modify the query on the fly.
Statement ast.Stmt
Types queryutil.PlaceholderTypes
Columns []pgproto.FieldDescription
InferredTypes []types.Type
}
PreparedStatement is a SQL statement that has been parsed and the types of arguments and results have been determined.
type QueryPlanner ¶
type QueryPlanner interface {
GetQueryPlan(s *session) (InitialPlan, bool, error)
}
type TransactionQueryPlanner ¶
type TransactionQueryPlanner interface {
// contains filtered or unexported methods
}
type TransactionState ¶
type TransactionState int
const (
TransactionState_None TransactionState = 0
TransactionState_Active = 1
)
Click to show internal directories.
Click to hide internal directories.