package
25.1.0+incompatible
Repository: https://github.com/cockroachdb/cockroach.git
Documentation: pkg.go.dev

# Functions

AsZoneConfigHydrationHelper returns the collection as a catalog.ZoneConfigHydrationHelper.
CheckObjectNameCollision returns an error if the object name is already used.
CheckSpanCountLimit checks whether committing the set of uncommitted tables would exceed the span count limit we're allowed (applicable only to secondary tenants).
CheckTwoVersionInvariant checks whether any new schema being modified written at a version V has only valid leases at version = V - 1.
DecorateDescriptorError will ensure that if we have an error we will wrap additional context about the descriptor to aid in debugging.
FromTxn is a convenience function to extract a descs.Collection which is being interface-smuggled through an isql.Txn.
GetDescriptorCollidingWithObjectName returns the descriptor which collides with the desired name if it exists.
GetObjectName fetches the full name for the given table or type descriptor.
HydrateCatalog installs type metadata in the type.T objects present for all objects referencing them in the catalog.
IsTwoVersionInvariantViolationError is true if the error is the special error returned from CheckTwoVersionInvariant.
MakeSystemTableIDResolver creates an object that implements catalog.SystemTableIDResolver.
MakeTestCollection makes a Collection that can be used for tests.
NewBareBonesCollectionFactory constructs a new CollectionFactory which holds onto a minimum of dependencies needed to construct an operable Collection.
NewCollectionFactory constructs a new CollectionFactory which holds onto the node-level dependencies needed to construct a Collection.
NewDistSQLFunctionResolver returns a new DistSQLFunctionResolver.
NewDistSQLTypeResolver creates a new DistSQLTypeResolver.
NewHistoricalInternalExecTxnRunner constructs a new historical internal executor.
PrefixAndMutableTable looks up a mutable table descriptor by its full name.
PrefixAndMutableType looks up a mutable type descriptor by its full name.
PrefixAndTable looks up an immutable table descriptor by its full name.
PrefixAndType looks up an immutable type descriptor by its full name.
ValidateSelf validates that the descriptor is internally consistent.
WithDescriptorSessionDataProvider supplies a DescriptorSessionDataProvider instance to the Collection constructor.
WithMonitor supplies a mon.BytesMonitor instance to the Collection constructor.

# Variables

ErrMutableTableImplicitType indicates that a table implicit type was fetched as a mutable, which is not allowed.

# Structs

Collection is a collection of descriptors held by a single session that serves SQL requests, or a background job using descriptors.
CollectionFactory is used to construct a new Collection.
DistSQLFunctionResolver is a tree.FunctionReferenceResolver that resolves builtin function by name while resolves user defined function by oid.
DistSQLTypeResolver is a TypeResolver that accesses TypeDescriptors through a given descs.Collection and transaction.

# Interfaces

DB is used to enable running multiple queries with an internal executor in a transactional manner.
DescriptorSessionDataProvider is the union of various interfaces which expose descriptor-related state from session data.
HistoricalInternalExecTxnRunner is like historicalTxnRunner except it only passes the fn the exported Executor instead of the whole unexported extendedEvalContext, so it can be implemented outside pkg/sql.
RegionProvider abstracts the lookup of regions.
TemporarySchemaProvider encapsulates the temporary schema information in the current session data.
VirtualCatalogHolder holds a catalog of all virtual descriptors.
ZoneConfigValidator is used to validate zone configs.

# Type aliases

ByIDGetter looks up immutable descriptors by ID.
ByIDGetterBuilder is a builder object for ByIDGetter and MutableByIDGetter.
ByNameGetter looks up immutable descriptors by name.
ByNameGetterBuilder is a builder object for ByNameGetter and MutableByNameGetter.
DescriptorValidationModeProvider exports the same interface in catkv.
HistoricalInternalExecTxnRunnerFn callback for executing with the internal executor at a fixed timestamp.
InternalExecFn is the type of functions that operates using an internalExecutor.
MutableByIDGetter looks up mutable descriptors by ID.
MutableByNameGetter looks up mutable descriptors by name.
Option is how optional construction parameters are provided to the CollectionFactory construction method.