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

# Packages

No description provided by the author
No description provided by the author
Package application_api pertains to the RPC and HTTP APIs exposed by the application layers, including SQL and tenant-scoped HTTP.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Package settingswatcher provides utilities to update cluster settings using a range feed.
No description provided by the author
No description provided by the author
No description provided by the author
Package storage_api pertains to the RPC and HTTP APIs exposed by the storage and KV layers.
No description provided by the author
No description provided by the author
Package telemetry contains helpers for capturing diagnostics information.
Package tenantsettingswatcher implements an in-memory view of the tenant_settings table (containing overrides for tenant settings) using a rangefeed.
No description provided by the author

# Functions

BuildJobQueryFromRequest builds the SQL query for the given JobsRequest.
CallDrainServerSide is a reference implementation for a server-side function that wishes to shut down a server gracefully via the Drain interface.
ExpectedInitialRangeCount returns the expected number of ranges that should be on the server after bootstrap.
GetBootstrapSchema returns the schema which will be used to bootstrap a new server.
ListenAndUpdateAddrs starts a TCP listener on the specified address then updates the address and advertised address fields based on the actual interface address resolved by the OS during the Listen() call.
ListenerFactoryForConfig return an RPCListenerFactory for the given configuration.
MakeBaseConfig returns a BaseConfig with default values.
MakeConfig returns a Config for the system tenant with default values.
MakeKVConfig returns a KVConfig with default values.
MakeServerOptionsForURL creates the input for MakeURLForServer().
MakeSQLConfig returns a SQLConfig with default values.
NewNode returns a new instance of Node.
NewNoopTenantSideCostController returns a noop cost controller.
NewSeparateProcessTenantServer creates a tenant-specific, SQL-only server against a KV backend, with defaults appropriate for a SQLServer that is not located in the same process as a KVServer.
NewServer creates a Server from a server.Config.
No description provided by the author
NewWaitingForInitError creates an error indicating that the server cannot run the specified method until the node has been initialized.
SetOpenFileLimitForOneStore sets the soft limit for open file descriptors when there is only one store.
TestingMakeLoggingContexts is exposed for use in tests.
UpdateAddrs updates the listen and advertise port numbers with those found during the call to net.Listen().

# Constants

AcceptHeader is the canonical header name for accept.
ClusterNameParamInQueryURL is the HTTP query URL parameter used to select a particular virtual cluster.
ContentTypeHeader is the canonical header name for content type.
No description provided by the author
Table sources.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
128 MiB.
Context defaults.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
JSONContentType is the JSON content type.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
RaftStateDormant is used when there is no known raft state.
RemoteNodeID is used to look up remote nodeID values to route requests to from a request's query params or a Cookie.
No description provided by the author
No description provided by the author
TempDirPrefix is the filename prefix of any temporary subdirectory created.
TempDirsRecordFilename is the filename for the record file that keeps track of the paths of the temporary directories created.
TenantSelectHeader is the HTTP header used to select a particular tenant.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Variables

ApplyTenantLicense is a hook for CCL code which enables enterprise features for the tenant process if the COCKROACH_TENANT_LICENSE environment variable is set.
ConnectionShutdownTimeout is the max amount of time waiting for clients to disconnect.
DebugZipRedactAddressesEnabled guards whether hostname / ip address and other sensitive fields should be redacted in the debug zip.
DrainWait is the initial wait time before a drain effectively starts.
ErrClusterInitialized is reported when the Bootstrap RPC is run on a node that is already part of an initialized cluster.
ErrIncompatibleBinaryVersion is returned when a CRDB node with a binary version X attempts to join a cluster with an active version that's higher.
ErrInvalidTenant is reported as one of the error marks on the error result of newServerFn, i.e.
ErrNoNodeID is returned by getNodeIDFromRequest if the request contains no nodeID to proxy to.
HotRangesRequestNodeTimeout controls the timeout of a serverpb.HotRangesRequest.
HSTSEnabled is a boolean that enables HSTS headers on the HTTP server.
JobShutdownTimeout is the max amount of time waiting for jobs to stop executing.
No description provided by the author
No description provided by the author
NewTenantSideCostController is a hook for CCL code which implements the controller.
NewTenantUsageServer is a hook for CCL code which implements the tenant usage server.
PersistedInsightsUIEnabled controls if the insights endpoint uses the persisted statement_execution_insights and transaction_execution_insights tables.
QueryShutdownTimeout is the max amount of time waiting for queries to stop execution.
RangeDescPageSize controls the page size when iterating through range descriptors.
RangeStatsBatchLimit registers the maximum number of ranges to be batched when fetching range stats for a span.
Cluster settings.
ServerHTTPBasePath is a cluster setting that contains the path to route the user to after successful login.
No description provided by the author
SQLAPIClock is exposed for override by tests.
SQLStatsResponseMax controls the maximum number of statements and transactions returned by the CombinedStatements endpoint.
SQLStatsShowInternal controls if statistics for internal executions should be returned in sql stats APIs, including: CombinedStatementStats, ListSessions, and ListLocalSessions.
StatsActivityUIEnabled controls if the combined statement stats uses the system.statement_activity and system.transaction_activity which acts as a cache storing the top queries from system.statement_statistics and system.transaction_statistics tables.
TestServerFactory can be passed to serverutils.InitTestServerFactory and rangetestutils.InitTestServerFactory.

# Structs

BaseConfig holds parameters that are needed to setup either a KV or a SQL server.
Config holds the parameters needed to set up a combined KV and SQL server.
No description provided by the author
KeyVisualizerServer is a concrete implementation of the keyvispb.KeyVisualizerServer interface.
KVConfig holds the parameters that (together with a BaseConfig) allow setting up a KV server.
ListenError is returned from Start when we fail to start listening on either the main Cockroach port or the HTTP port, so that the CLI can instruct the user on what might have gone wrong.
LocalKVServerInfo is used to group information about the local KV server necessary for creating the internalClientAdapter for an in-process tenant talking to that server.
A Node manages a map of stores (by store ID) for which it serves traffic.
No description provided by the author
SQLConfig holds the parameters that (together with a BaseConfig) allow setting up a SQL server.
SQLServer encapsulates the part of a CRDB server that is dedicated to SQL processing.
SQLServerWrapper is a utility struct that encapsulates a SQLServer and its helpers that make it a networked service.
TenantMigrationServer is an implementation of the Migration service for tenants.
TestingKnobs groups testing knobs for the Server.

# Interfaces

No description provided by the author
ServerIterator is an interface that provides an abstraction around fanning out requests to different "servers" or "nodes".
StmtDiagnosticsRequester is the interface into *stmtdiagnostics.Registry used by AdminUI endpoints.

# Type aliases

Engines is a container of engines, allowing convenient closing.
GetNodeIDHTTPAddressFn is a callback to look up HTTP addresses for a given NodeID.
No description provided by the author
MaxOffsetType stores the configured MaxOffset.
ParseNodeIDFn is a callback to parse strings into `roachpb.NodeID` instances.
No description provided by the author
ServerSideDrainFn is the interface of the server-side handler for the Drain logic.