cockroach: github.com/cockroachdb/cockroach/pkg/sql/colflow Index | Files | Directories

package colflow

import "github.com/cockroachdb/cockroach/pkg/sql/colflow"

Index

Package Files

vectorized_flow.go

Variables

var VectorizeTestingBatchSize = settings.RegisterValidatedIntSetting(
    "sql.testing.vectorize.batch_size",
    fmt.Sprintf("the size of a batch of rows in the vectorized engine (0=default, value must be less than %d)", coldata.MaxBatchSize),
    0,
    func(newBatchSize int64) error {
        if newBatchSize > coldata.MaxBatchSize {
            return pgerror.Newf(pgcode.InvalidParameterValue, "batch size %d may not be larger than %d", newBatchSize, coldata.MaxBatchSize)
        }
        return nil
    },
)

VectorizeTestingBatchSize is a testing cluster setting that sets the default batch size used by the vectorized execution engine. A low batch size is useful to test batch reuse.

func NewVectorizedFlow Uses

func NewVectorizedFlow(base *flowinfra.FlowBase) flowinfra.Flow

NewVectorizedFlow creates a new vectorized flow given the flow base.

func SupportsVectorized Uses

func SupportsVectorized(
    ctx context.Context,
    flowCtx *execinfra.FlowCtx,
    processorSpecs []execinfrapb.ProcessorSpec,
    isPlanLocal bool,
    output execinfra.RowReceiver,
    scheduledOnRemoteNode bool,
) (leaves []execinfra.OpNode, err error)

SupportsVectorized checks whether flow is supported by the vectorized engine and returns an error if it isn't. Note that it does so by setting up the full flow without running the components asynchronously. It returns a list of the leaf operators of all flows for the purposes of EXPLAIN output. Note that passed-in output can be nil, but if it is non-nil, only Types() method on it might be called (nothing will actually get Push()'ed into it). - scheduledOnRemoteNode indicates whether the flow that processorSpecs represent is scheduled to be run on a remote node (different from the one performing this check).

type VectorizeAlwaysException Uses

type VectorizeAlwaysException interface {
    // IsException returns whether this object should be an exception to the rule
    // that an inability to run this node in a vectorized flow should produce an
    // error.
    // TODO(asubiotto): This is the cleanest way I can think of to not error out
    // on SET statements when running with vectorize = experimental_always. If
    // there is a better way, we should get rid of this interface.
    IsException() bool
}

VectorizeAlwaysException is an object that returns whether or not execution should continue if vectorize=experimental_always and an error occurred when setting up the vectorized flow. Consider the case in which vectorize=experimental_always. The user must be able to unset this session variable without getting an error.

Directories

PathSynopsis
colrpc

Package colflow imports 39 packages (graph) and is imported by 4 packages. Updated 2020-08-12. Refresh now. Tools for package owners.