package
19.2.12+incompatible
Repository: https://github.com/cockroachdb/cockroach.git
Documentation: pkg.go.dev
# Functions
DrainAndClose is a version of DrainAndForwardMetadata that drains multiple sources.
DrainAndForwardMetadata calls src.ConsumerDone() (thus asking src for draining metadata) and then forwards all the metadata to dst.
GenerateValuesSpec generates a ValuesCoreSpec that encodes the given rows.
GetFetcherInputStats is a utilitty function to check whether the given input is collecting row fetcher stats, returning true and the stats if so.
GetInputStats is a utility function to check whether the given input is collecting stats, returning true and the stats if so.
GetTraceData returns the trace data.
GetTxnCoordMeta returns the txn metadata from a transaction if it is present and the transaction is a leaf transaction, otherwise nil.
InitRowFetcher initializes the fetcher.
LimitHint returns the limit hint to set for a KVFetcher based on the spec's limit hint and the PostProcessSpec.
MakeDistSQLMetrics instantiates the metrics holder for DistSQL monitoring.
MakeNoMetadataRowSource builds a NoMetadataRowSource.
MakeTestDiskMonitor creates a new disk monitor to be used in tests.
MisplannedRanges filters out the misplanned ranges and their RangeInfo for a given node.
NewIndexJoiner returns a new IndexJoiner.
NewInputStatCollector creates a new InputStatCollector that wraps the given input.
NewJoinReader returns a new JoinReader.
NewLimitedMonitor is a utility function used by processors to create a new limited memory monitor with the given name and start it.
NewMetadataTestReceiver creates a new MetadataTestReceiver.
NewMetadataTestSender creates a new MetadataTestSender.
NewMonitor is a utility function used by processors to create a new memory monitor with the given name and start it.
NewRepeatableRowSource creates a RepeatableRowSource with the given schema and rows.
NewRowFetcherStatCollector returns a new RowFetcherStatCollector.
OtherSide returns the opposite to s side.
ProcessorSpan creates a child span for a processor (if we are doing any tracing).
Run reads records from the source and outputs them to the receiver, properly draining the source of metadata and closing both the source and receiver.
ScanShouldLimitBatches returns whether the scan should pace itself.
SendTraceData collects the tracing information from the ctx and pushes it to dst.
ShouldEmitUnmatchedRow determines if we should emit am ummatched row (with NULLs for the columns of the other stream).
# Constants
BytesReadQueryPlanSuffix is the tag suffix for the bytes read.
BytesReadTagSuffix is the tag suffix for the bytes read stat.
ConsumerClosed indicates that the consumer will not process any more data rows or metadata.
DrainRequested indicates that the consumer will not process any more data rows, but will accept trailing metadata from the producer.
LeftSide indicates the left side of the join.
MaxDiskQueryPlanSuffix is the tag suffix for the max disk used.
MaxDiskTagSuffix is the tag suffix for the max disk used stat.
MaxMemoryQueryPlanSuffix is the tag suffix for the max memory used.
MaxMemoryTagSuffix is the tag suffix for the max memory used stat.
MinAcceptedVersion is the oldest version that the server is compatible with; see above.
NeedMoreRows indicates that the consumer is still expecting more rows.
NoExplain represents that metadata test processors are planned for all queries except EXPLAIN (DISTSQL) statements.
Off represents that no metadata test processors are planned.
On represents that metadata test processors are planned for all queries.
ParallelScanResultThreshold is the number of results up to which, if the maximum number of results returned by a scan is known, the table reader disables batch limits in the dist sender.
RightSide indicates the right side of the join.
RowChannelBufSize is the default buffer size of a RowChannel.
StateDraining is the state in which the processor is forwarding metadata from its input and otherwise ignoring all rows.
StateExhausted is the state of a processor that has no more rows or metadata to produce.
StateRunning is the common state of a processor: it's producing rows for its consumer and forwarding metadata from its input.
StateTrailingMeta is the state in which the processor is outputting final metadata such as the tracing information or the TxnCoordMeta.
StaticNodeID is the default Node ID to be used in tests.
Version identifies the distsql protocol version.
# Variables
No description provided by the author
No description provided by the author
SettingUseTempStorageJoins is a cluster setting that configures whether joins are allowed to spill to disk.
SettingUseTempStorageSorts is a cluster setting that configures whether sorts are allowed to spill to disk.
SettingWorkMemBytes is a cluster setting that determines the maximum amount of RAM that a processor can use.
# Structs
DistSQLMetrics contains pointers to the metrics for monitoring DistSQL processing.
ExprHelper implements the common logic around evaluating an expression that depends on a set of values.
FlowCtx encompasses the configuration parameters needed for various flow components.
IndexJoiner performs a join between a secondary index, the `input`, and the primary index of the same table, `desc`, to retrieve columns which are not stored in the secondary index.
InputStatCollector wraps a RowSource and collects stats from it.
InputStats represents the stats collected from an input.
JoinerBase is the common core of all joiners.
JoinReader performs a lookup join between `input` and the specified `index`.
JoinReaderStats are the stats collected during a JoinReader run.
MetadataTestReceiver is a Processors that is complimentary to MetadataTestSender which checks that all metadata emitted by latter is received.
MetadataTestSender intersperses a metadata record after every row.
NoMetadataRowSource is a wrapper on top of a RowSource that automatically forwards metadata to a RowReceiver.
ProcessorBase is supposed to be embedded by Processors.
ProcOutputHelper is a helper type that performs filtering and projection on the output of a processor.
ProcStateOpts contains fields used by the ProcessorBase's family of functions that deal with draining and trailing metadata: the ProcessorBase implements generic useful functionality that needs to call back into the Processor.
RepeatableRowSource is a RowSource used in benchmarks to avoid having to reinitialize a new RowSource every time during multiple passes of the input.
RowChannel is a thin layer over a RowChannelMsg channel, which can be used to transfer rows between goroutines.
RowChannelMsg is the message used in the channels that implement local physical streams (i.e.
RowDisposer is a RowReceiver that discards any rows Push()ed.
RowFetcherStatCollector is a RowFetcherWrapper that collects stats.
RowFetcherWrapper is used only by processors that need to wrap calls to Fetcher.NextRow() in a RowSource implementation.
ServerConfig encompasses the configuration required to create a DistSQLServer.
TestingKnobs are the testing knobs.
# Interfaces
LocalProcessor is a RowSourcedProcessor that needs to be initialized with its post processing spec and output row receiver.
OpNode is an interface to operator-like structures with children.
Processor is a common interface implemented by all processors, used by the higher-level flow orchestration code.
RowFetcher is an interface used to abstract a row fetcher so that a stat collector wrapper can be plugged in.
RowReceiver is any component of a flow that receives rows from another component.
RowSource is any component of a flow that produces rows that can be consumed by another component.
RowSourcedProcessor is the union of RowSource and Processor.
RuntimeStats is an interface through which the rowexec layer can get information about runtime statistics.
# Type aliases
ConsumerStatus is the type returned by RowReceiver.Push(), informing a producer of a consumer's state.
JoinSide is the utility type to dinstinguish between two sides of the join.
MetadataTestLevel represents the types of queries where metadata test processors are planned.