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

# Packages

# Functions

DefaultHistogramWindowInterval returns the default rotation window for histograms.
DefaultRetryOptions should be used for retrying most network-dependent operations.
DefaultTestTempStorageConfig is the associated temp storage for DefaultTestStoreSpec that is in-memory.
DefaultTestTempStorageConfigWithSize is the associated temp storage for DefaultTestStoreSpec that is in-memory with the customized maximum size.
EmergencyBallastFile returns the path (relative to a data directory) used for an emergency ballast file.
GetAbsoluteFSPath takes a (possibly relative) and returns the absolute path.
InheritTempStorageConfig creates a new TempStorageConfig using the configuration of the given TempStorageConfig.
InternalNonDefaultDecision builds a sentinel value used inside a mechanism in serverutils.
LookupAddr resolves the given address/host to an IP address.
NewSizeSpec parses the string passed into a --size flag and returns a SizeSpec if it is correctly parsed.
NewSQLIDContainerForNode sets up a SQLIDContainer which serves the underlying NodeID as the SQL instance ID.
NewStoreSpec parses the string passed into a --store flag and returns a StoreSpec if it is correctly parsed.
PreventedStartupFile is the filename (relative to 'dir') used for files that can block server startup.
SubzoneIDFromIndex turns a subzone's index within its parent zone into its SubzoneID.
TempStorageConfigFromEnv creates a TempStorageConfig.
TestDoesNotWorkWithSecondaryTenantsButWeDontKnowWhyYet can be used to disable virtualization because the test doesn't appear to be compatible with it, and we don't understand it yet.
TestDoesNotWorkWithSharedProcessModeButWeDontKnowWhyYet can be used to disable selecting a shared process test virtual cluster probabilistically because the test doesn't appear to be compatible with it, and we don't understand it yet.
TestIsForStuffThatShouldWorkWithSecondaryTenantsButDoesntYet can be used to disable virtualization because the test exercises a feature known not to work with virtualization enabled yet, but we wish it to eventually.
TestIsForStuffThatShouldWorkWithSharedProcessModeButDoesntYet can be used to disable selecting a shared process test virtual cluster probabilistically because the test exercises a feature known not to work with a shared process virtual cluster, but we wish it to eventually.

# Constants

AuxiliaryDir is the path of the auxiliary dir relative to an engine.Engine's root directory.
ChunkRaftCommandThresholdBytes is the threshold in bytes at which to chunk or otherwise limit commands being sent to Raft.
CPUProfileDir is the directory name where the CPU profile dumper stores profiles when the periodic CPU profile dump is enabled.
DefaultDescriptorLeaseDuration is the default mean duration a lease will be acquired for.
DefaultDescriptorLeaseJitterFraction is the default factor that we use to randomly jitter the lease duration when acquiring a new lease and the lease renewal timeout.
DefaultDescriptorLeaseRenewalTimeout is the default time before a lease expires when acquisition to renew the lease begins.
The default port for HTTP-for-humans.
100MB */.
DefaultLeaseRenewalCrossValidate is the default setting for if we should validate descriptors on lease renewals.
DefaultMaxClockOffset is the default maximum acceptable clock offset value.
NB: this can't easily become a variable as the UI hard-codes it to 10s.
From IANA Service Name and Transport Protocol Port Number Registry.
32GB */.
DefaultTxnHeartbeatInterval is how often heartbeats are sent from the transaction coordinator to a live transaction.
GoroutineDumpDir is the directory name where the goroutine dumper stores dump when one of the dump heuristics is triggered.
HeapProfileDir is the directory name where the heap profiler stores profiles when there is a potential OOM situation.
InflightTraceDir is the directory name where the job trace dumper stores traces when a job opts in to dumping its execution traces.
MinimumStoreSize is the smallest size in bytes that a store can have.
ReplicationAuto means that ranges are replicated according to the production default zone config.
ReplicationManual means that the lease, split, merge and replication queues of all servers are stopped, and the test must manually control splitting, merging and replication through the TestServer.
SlowRequestThreshold is the amount of time to wait before considering a request to be "slow".
TempStoreID is used as the store id for a temp pebble engine's log.
WALFailoverAmongStores enables WAL failover among multiple stores within a node.
WALFailoverDefault leaves the WAL failover configuration unspecified.
WALFailoverDisabled leaves WAL failover disabled.
WALFailoverExplicitPath enables WAL failover for a single-store node to an explicitly specified path.

# Variables

CCLDistributionAndEnterpriseEnabled is a simpler version of CheckEnterpriseEnabled which doesn't take in feature-related info and doesn't return an error with a nice message.
CheckEnterpriseEnabled returns a non-nil error if the requested enterprise feature is not enabled, including information or a link explaining how to enable it.
DefaultCertsDirectory is the default value for the cert directory flag.
DefaultRPCHeartbeatTimeout is the default RPC heartbeat timeout.
DefaultTestStoreSpec is just a single in memory store of 512 MiB with no special attributes.
DialTimeout is the timeout used when dialing a node.
ExternalTestTenantAlwaysEnabled will always redirect the test workload to an external process virtual cluster.
GetLicenseTTL is a function which returns the TTL for the active cluster.
LicenseType returns what type of license the cluster is running with, or "OSS" if it is an OSS build.
NetworkTimeout is the timeout used for network operations that require a single network round trip.
PingInterval is the interval between RPC heartbeat pings.
SharedTestTenantAlwaysEnabled will always redirect the test workload to a shared process virtual cluster.
TestControlsTenantsExplicitly is used when the test wants to manage its own secondary tenants and tenant servers.
TestingIDContainer is an SQLIDContainer with hard-coded SQLInstanceID of 10.
TestIsSpecificToStorageLayerAndNeedsASystemTenant is used when the test needs to be given access to a SQL conn to a tenant with sufficient capabilities to access all the storage layer.
TestNeedsTightIntegrationBetweenAPIsAndTestingKnobs is used when a test wants to use a single set of testing knobs for both the storage layer and the SQL layer and for simplicity of the test code we want to give that test a simplified environment.
TestRequiresExplicitSQLConnection is used when the test is unable to pass the cluster as an option in the connection URL.
TestTenantAlwaysEnabled will always redirect the test workload to a virtual cluster.
TestTenantProbabilistic starts the test under a virtual cluster on a probabilistic basis.
TestTenantProbabilisticOnly starts the test under a virtual cluster on a probabilistic basis.
TODOTestTenantDisabled should not be used anymore.

# Structs

AdvertiseAddr is the type of the AdvertiseAddr field in Config.
ClusterIDContainer is used to share a single Cluster ID instance between multiple layers.
Config is embedded by server.Config.
DefaultTestTenantOptions specifies the conditions under which a virtual cluster (secondary tenant) will be automatically started to bear load for a unit test.
ExternalIODirConfig describes various configuration options pertaining to external storage implementations.
ExternalPath represents a non-store path and associated encryption-at-rest configuration.
HTTPAdvertiseAddr is the type of the HTTPAdvertiseAddr field in Config.
NodeIDContainer is used to share a single roachpb.NodeID or SQLInstanceID instance between multiple layers.
ProvisionedRateSpec is an optional part of the StoreSpec.
RaftConfig holds raft tuning parameters.
SizeSpec contains size in different kinds of formats supported by CLI(%age, bytes).
SQLAdvertiseAddr is the type of the SQLAdvertiseAddr field in Config.
StoreIDContainer is added as a logtag in the pebbleLogger's context.
StoreSpec contains the details that can be specified in the cli pertaining to the --store flag.
StoreSpecList contains a slice of StoreSpecs that implements pflag's value interface.
TempStorageConfig contains the details that can be specified in the cli pertaining to temp storage flags, specifically --temp-dir and --max-disk-temp-storage.
TestClusterArgs contains the parameters one can set when creating a test cluster.
TestingKnobs contains facilities for controlling various parts of the system for testing.
TestServerArgs contains the parameters one can set when creating a test server.
TestSharedProcessTenantArgs are the arguments to TestServer.StartSharedProcessTenant.
TestTenantArgs are the arguments to TestServer.StartTenant.
WALFailoverConfig configures a node's stores behavior under high write latency to their write-ahead logs.

# Interfaces

ModuleTestingKnobs is an interface for testing knobs for a submodule.

# Type aliases

JoinListType is a slice of strings that implements pflag's value interface.
SQLIDContainer is a variant of NodeIDContainer that contains SQL instance IDs.
A SQLInstanceID is an ephemeral ID assigned to a running instance of the SQL server.
SubzoneID represents a subzone within a zone.
TestClusterReplicationMode represents the replication settings for a TestCluster.
WALFailoverMode specifies the mode of WAL failover.