cockroach: github.com/cockroachdb/cockroach/pkg

Directories

PathSynopsis
acceptance
acceptance/cluster
acceptance/localcluster
acceptance/localcluster/tcPackage tc contains utility methods for using the Linux tc (traffic control) command to mess with the network links between cockroach nodes running on the local machine.
base
bench
blobsPackage blobs contains a gRPC service to be used for remote file access.
blobs/blobspb
build
ccl
ccl/backupccl
ccl/baseccl
ccl/buildccl
ccl/changefeedccl
ccl/changefeedccl/cdctest
ccl/changefeedccl/changefeedbase
ccl/changefeedccl/kvfeedPackage kvfeed provides an abstraction to stream kvs to a buffer.
ccl/changefeedccl/schemafeed
ccl/changefeedccl/schemafeed/schematestutilsPackage schematestutils is a utility package for constructing schema objects in the context of cdc.
ccl/cliccl
ccl/cliccl/cliflagsccl
ccl/cmdccl/enc_utils
ccl/followerreadscclPackage followerreadsccl implements and injects the functionality needed to expose follower reads to clients.
ccl/gssapiccl
ccl/importccl
ccl/logictestcclPackage logictestccl houses the SQL logic tests that test CCL features.
ccl/partitionccl
ccl/roleccl
ccl/servercclPackage serverccl houses tests that verify CCL behavior of a running CockroachDB server.
ccl/storageccl
ccl/storageccl/engineccl
ccl/storageccl/engineccl/enginepbccl
ccl/utilccl
ccl/utilccl/licenseccl
ccl/utilccl/sampledataccl
ccl/workloadccl
ccl/workloadccl/allccl
ccl/workloadccl/cliccl
ccl/workloadccl/format
ccl/workloadccl/roachmartccl
cli
cli/cliflags
cli/syncbench
cli/systembench
cli/systembench/systembenchpb
clusterversionPackage clusterversion defines the interfaces to interact with cluster/binary versions in order accommodate backward incompatible behaviors.
cmd/allocsim
cmd/cmdutil
cmd/cmp-protocolcmp-protocol connects to postgres and cockroach servers and compares the binary and text pgwire encodings of SQL statements.
cmd/cmp-protocol/pgconnectPackage pgconnect provides a way to get byte encodings from a simple query.
cmd/cmp-sqlcmp-sql connects to postgres and cockroach servers and compares the results of SQL statements.
cmd/cockroachThis is the default entry point for a CockroachDB binary.
cmd/cockroach-osscockroach-oss is an entry point for a CockroachDB binary that excludes all CCL-licensed code.
cmd/cockroach-shortcockroach-short is an entry point for a CockroachDB binary that excludes certain components that are slow to build or have heavyweight dependencies.
cmd/cr2pgcr2pg is a program that reads CockroachDB-formatted SQL files on stdin, modifies them to be Postgres compatible, and outputs them to stdout.
cmd/cr2pg/sqlstreamPackage sqlstream streams an io.Reader into SQL statements.
cmd/docgen
cmd/docgen/extract
cmd/fuzzfuzz builds and executes fuzz tests.
cmd/generate-binaryThis connects to a postgres server and crafts postgres-protocol message to encode its arguments into postgres' text and binary encodings.
cmd/github-postCommand github-post parses the JSON-formatted output from a Go test session, as generated by either 'go test -json' or './pkg.test | go tool test2json -t', and posts issues for any failed tests to GitHub.
cmd/github-pull-request-makeThis utility detects new tests added in a given pull request, and runs them under stress in our CI infrastructure.
cmd/gossipsimPackage simulation provides tools meant to visualize or test aspects of a Cockroach cluster on a single host.
cmd/internal/issues
cmd/prereqsprereqs generates Make prerequisites for Go binaries.
cmd/protoc-gen-gogoroach
cmd/publish-artifacts
cmd/publish-provisional-artifacts
cmd/reducereduce reduces SQL passed over stdin using cockroach demo.
cmd/returncheck
cmd/roachprod
cmd/roachprod/cloud
cmd/roachprod/config
cmd/roachprod/errors
cmd/roachprod/install
cmd/roachprod/ssh
cmd/roachprod-stress
cmd/roachprod/ui
cmd/roachprod/vm
cmd/roachprod/vm/aws
cmd/roachprod/vm/aws/terraformgenCommand terraformgen generate the terraform file used to configure AWS for multiregion support.
cmd/roachprod/vm/azurePackage azure allows roachprod to create instances within the Microsoft Azure cloud.
cmd/roachprod/vm/flagstub
cmd/roachprod/vm/gce
cmd/roachprod/vm/local
cmd/roachtest
cmd/roachvetCommand roachvet is a vettool which includes all of the standard analysis passes included in go vet as well as the `shadow` pass and some first-party passes.
cmd/skiperrsskiperrs connects to a postgres-compatible server with its URL specified as the first argument.
cmd/smithcmpsmithcmp is a tool to execute random queries on a database.
cmd/smithcmp/cmpconnPackage cmpconn assits in comparing results from DB connections.
cmd/smithtestsmithtest is a tool to execute sqlsmith tests on cockroach demo instances.
cmd/teamcity-triggerteamcity-trigger launches a variety of nightly build jobs on TeamCity using its REST API.
cmd/testfiltertestfilter is a utility to manipulate JSON streams in [test2json] format.
cmd/uptodateuptodate efficiently computes whether an output file is up-to-date with regard to its input files.
cmd/urlcheck
cmd/urlcheck/lib/urlcheck
cmd/workload
cmd/wraprules
cmd/zerosum
col/coldata
col/colserde
col/colserde/arrowserdePackage arrowserde contains the flatbuffer generated code used for Apache Arrow serialization (and some small helpers associated with the generated code).
col/coltypes
config
config/zonepb
gossipPackage gossip implements a protocol for sharing information between Cockroach nodes using an ad-hoc, peer-to-peer network.
gossip/resolver
gossip/simulation
internal/client/requestbatcherPackage requestbatcher is a library to enable easy batching of roachpb requests.
internal/rsg
internal/rsg/yaccPackage yacc parses .y files.
internal/sqlsmith
jobs
jobs/jobspb
jobs/jobsprotectedts
keysPackage keys manages the construction of keys for CockroachDB's key-value layer.
kvPackage kv and its KV API have been deprecated for external usage.
kv/bulk
kv/kvbasePackage kvbase exports kv level interfaces to avoid dependency cycles.
kv/kvclientPackage kvclient houses the implementation of the KV client.
kv/kvclient/kvcoordPackage kvcoord provides a key-value API to an underlying cockroach datastore.
kv/kvnemesesPackage kvnemeses exercises the KV api with random traffic and then validates that the observed behaviors are consistent with our guarantees.
kv/kvnemesisPackage kvnemesis exercises the KV api with random traffic and then validates that the observed behaviors are consistent with our guarantees.
kv/kvserverPackage kvserver provides access to the Store and Range abstractions.
kv/kvserver/abortspan
kv/kvserver/applyPackage apply provides abstractions and routines associated with the application of committed raft entries to a replicated state machine.
kv/kvserver/batcheval
kv/kvserver/batcheval/result
kv/kvserver/bulk
kv/kvserver/closedtsPackage closedts houses the interfaces and basic definitions used by the various components of the closed timestamp subsystems.
kv/kvserver/closedts/container
kv/kvserver/closedts/ctpb
kv/kvserver/closedts/minpropPackage minprop exports a main data structure, Tracker, which checkpoints closed timestamps and associated Raft Lease Applied indexes positions for which (under additional conditions) it is legal to serve follower reads.
kv/kvserver/closedts/provider
kv/kvserver/closedts/provider/testutils
kv/kvserver/closedts/storage
kv/kvserver/closedts/transport
kv/kvserver/closedts/transport/testutils
kv/kvserver/cloud
kv/kvserver/compactor
kv/kvserver/concurrencyPackage concurrency provides a concurrency manager structure that encapsulates the details of concurrency control and contention handling for serializable key-value transactions.
kv/kvserver/concurrency/lockPackage lock provides type definitions for locking-related concepts used by concurrency control in the key-value layer.
kv/kvserver/constraint
kv/kvserver/diskmap
kv/kvserver/gcPackage gc contains the logic to run scan a range for garbage and issue GC requests to remove that garbage.
kv/kvserver/idalloc
kv/kvserver/intentresolver
kv/kvserver/protectedtsPackage protectedts exports the interface to the protected timestamp subsystem which allows clients to prevent GC of expired data.
kv/kvserver/protectedts/ptcache
kv/kvserver/protectedts/ptpb
kv/kvserver/protectedts/ptproviderPackage ptprovider encapsulates the concrete implementation of the protectedts.Provider.
kv/kvserver/protectedts/ptreconcilePackage ptreconcile provides logic to reconcile protected timestamp records with state associated with their metadata.
kv/kvserver/protectedts/ptstoragePackage ptstorage implements protectedts.Storage.
kv/kvserver/protectedts/ptverifier
kv/kvserver/raftentryPackage raftentry provides a cache for entries to avoid extra deserializations.
kv/kvserver/rangefeed
kv/kvserver/rditer
kv/kvserver/reports
kv/kvserver/spanlatchPackage spanlatch provides a latch management structure for serializing access to keys and key ranges.
kv/kvserver/spanset
kv/kvserver/split
kv/kvserver/stateloader
kv/kvserver/storagebase
kv/kvserver/storagepb
kv/kvserver/tscachePackage tscache provides a timestamp cache structure that records the maximum timestamp that key ranges were read from and written to.
kv/kvserver/txnrecovery
kv/kvserver/txnwait
roachpb
rpc
rpc/nodedialer
security
security/securitytestPackage securitytest embeds the TLS test certificates.
serverPackage server implements the Cockroach storage node.
server/debug
server/debug/goroutineui
server/debug/pprofui
server/diagnosticspb
server/goroutinedumper
server/heapprofiler
server/serverpbPackage serverpb is a reverse proxy.
server/status
server/status/statuspb
server/telemetryPackage telemetry contains helpers for capturing diagnostics information.
settingsPackage settings provides a central registry of runtime editable settings and accompanying helper functions for retrieving their current values.
settings/cluster
sqlPackage sql provides the user-facing API for access to a Cockroach datastore.
sql/backfill
sql/colcontainer
sql/colencoding
sql/colexec
sql/colexec/execerror
sql/colexec/execgen
sql/colexec/execpb
sql/colexec/typeconv
sql/colflow
sql/colflow/colrpc
sql/covering
sql/delegate
sql/distsql
sql/execinfra
sql/execinfrapb
sql/flowinfra
sql/gcjob
sql/lex
sql/logictest
sqlmigrations
sqlmigrations/leasemanagerPackage leasemanager provides functionality for acquiring and managing leases via the kv api for use during sqlmigrations.
sql/mutations
sql/optPackage opt contains the Cockroach SQL optimizer.
sql/opt/benchPackage bench houses benchmarks for the SQL optimizer.
sql/opt/catPackage cat contains interfaces that are used by the query optimizer to avoid including specifics of sqlbase structures in the opt code.
sql/opt/constraint
sql/opt/exec
sql/opt/exec/execbuilder
sql/opt/idxconstraint
sql/opt/memo
sql/opt/norm
sql/opt/opbench
sql/opt/optbuilder
sql/opt/optgen/exprgen
sql/opt/optgen/langPackage lang implements a language called Optgen, short for "optimizer generator".
sql/opt/orderingPackage ordering contains operator-specific logic related to orderings - whether ops can provide Required orderings, what orderings do they need to require from their children, etc.
sql/opt/props
sql/opt/props/physical
sql/opt/testutils
sql/opt/testutils/opttester
sql/opt/testutils/testcat
sql/opt/testutils/testexpr
sql/opt/xform
sql/parser
sql/parser/fuzz
sql/pgwire
sql/pgwire/hbaPackage hba implements an hba.conf parser.
sql/pgwire/pgcodePackage pgcode defines the PostgreSQL 5-character support codes used throughout the CockroachDB source tree.
sql/pgwire/pgerror
sql/pgwire/pgwirebasePackage pgwirebase contains type definitions and very basic protocol structures to be used by both the pgwire package and by others (particularly by the sql package).
sql/physicalplan
sql/physicalplan/replicaoraclePackage replicaoracle provides functionality for physicalplan to choose a replica for a range.
sql/privilege
sql/querycache
sql/roleoption
sql/row
sql/rowcontainer
sql/rowexec
sql/rowflow
sql/schemaPackage schema is to avoid a circular dependency on pkg/sql/row and pkg/sql.
sql/schemachange
sql/scrub
sql/sem/builtins
sql/sem/transform
sql/sem/tree
sql/sessiondata
sql/span
sql/sqlbase
sql/sqltelemetryPackage sqltelemetry contains telemetry counter definitions for various SQL features.
sql/sqlutil
sql/stats
sql/stmtdiagnostics
sql/tests
sql/types
sql/vtable
storagePackage storage provides low-level storage.
storage/batcheval/result
storage/closedtsPackage closedts houses the interfaces and basic definitions used by the various components of the closed timestamp subsystems.
storage/closedts/container
storage/closedts/ctpb
storage/closedts/minpropPackage minprop exports a main data structure, Tracker, which checkpoints closed timestamps and associated Raft Lease Applied indexes positions for which (under additional conditions) it is legal to serve follower reads.
storage/closedts/provider/testutils
storage/closedts/transport
storage/cloud
storage/compactor
storage/concurrency
storage/concurrency/lockPackage lock provides type definitions for locking-related concepts used by concurrency control in the key-value layer.
storage/diskmap
storage/engine/fs
storage/engine/metamorphic
storage/enginepb
storage/fs
storage/gcPackage gc contains the logic to run scan a range for garbage and issue GC requests to remove that garbage.
storage/idalloc
storage/intentresolver
storage/metamorphic
storage/protectedtsPackage protectedts exports the interface to the protected timestamp subsystem which allows clients to prevent GC of expired data.
storage/protectedts/ptcache
storage/protectedts/ptproviderPackage ptprovider encapsulates the concrete implementation of the protectedts.Provider.
storage/protectedts/ptreconcilePackage ptreconcile provides logic to reconcile protected timestamp records with state associated with their metadata.
storage/protectedts/ptverifier
storage/raftentryPackage raftentry provides a cache for entries to avoid extra deserializations.
storage/rangefeed
storage/rditer
storage/reports
storage/stateloader
storage/storagepb
storage/tscachePackage tscache provides a timestamp cache structure that records the maximum timestamp that key ranges were read from and written to.
storage/txnrecovery
storage/txnwait
testutils
testutils/buildutil
testutils/colcontainerutils
testutils/distsqlutils
testutils/gossiputil
testutils/jobutils
testutils/keysutils
testutils/lintPackage lint tests Go code for policy and style violations, as well as detecting suspicious constructs that are typically bugs.
testutils/lint/passes/descriptormarshalPackage descriptormarshal defines an suite of Analyzers that detects correct setting of timestamps when unmarshaling table descriptors.
testutils/lint/passes/hashPackage hash defines an Analyzer that detects correct use of hash.Hash.
testutils/lint/passes/nocopyPackage nocopy defines an Analyzer that detects invalid uses of util.NoCopy.
testutils/lint/passes/returnerrcheckPackage returnerrcheck defines an suite of Analyzers that detects conditionals which check for a non-nil error and then proceed to return a nil error.
testutils/lint/passes/timerPackage timer defines an Analyzer that detects correct use of timeutil.Timer.
testutils/lint/passes/unconvertPackage unconvert defines an Analyzer that detects unnecessary type conversions.
testutils/localtestcluster
testutils/pgtest
testutils/physicalplanutils
testutils/reducePackage reduce implements a reducer core for reducing the size of test failure cases.
testutils/reduce/reducesql
testutils/serverutils
testutils/sqlutils
testutils/storageutils
testutils/testcluster
testutils/zerofields
tsPackage ts provides a basic time series database on top of the underlying CockroachDB key/value datastore.
ts/catalog
ts/testmodel
ts/tspbPackage tspb is a reverse proxy.
uiPackage ui embeds the assets for the web UI into the Cockroach binary.
ui/distcclPackage distccl embeds the assets for the CCL version of the web UI into the Cockroach binary.
ui/distossPackage distoss embeds the assets for the OSS version of the web UI into the Cockroach binary.
util
util/arith
util/binfetcher
util/bitarray
util/bufalloc
util/cache
util/caller
util/causer
util/cgroups
util/cloudinfo
util/contextutil
util/ctxgroupPackage ctxgroup wraps golang.org/x/sync/errgroup with a context func.
util/duration
util/encoding
util/encoding/csvPackage csv reads and writes comma-separated values (CSV) files.
util/envutil
util/errorutil
util/errorutil/unimplemented
util/fileutil
util/flagutilPackage flagutil facilitates creation of rich flag types.
util/fsmPackage fsm provides an interface for defining and working with finite-state machines.
util/growstack
util/grpcutil
util/hlcPackage hlc implements the Hybrid Logical Clock outlined in "Logical Physical Clocks and Consistent Snapshots in Globally Distributed Databases", available online at http://www.cse.buffalo.edu/tech-reports/2014-04.pdf.
util/httputil
util/humanizeutil
util/intervalPackage interval provides two implementations for an interval tree.
util/interval/genericPackage generic provides an implementation of a generic immutable interval B-Tree.
util/interval/generic/internal
util/ipaddr
util/json
util/keysutil
util/leaktestPackage leaktest provides tools to detect leaked goroutines in tests.
util/limit
util/logPackage log implements logging.
util/log/logflags
util/metricPackage metric provides server metrics (a.k.a.
util/mon
util/netutil
util/prettyPackage pretty prints documents based on a target line width.
util/protoutil
util/quotapoolPackage quotapool provides an abstract implementation of a pool of resources to be distributed among concurrent clients.
util/randutil
util/retry
util/ring
util/sdnotifyPackage sdnotify implements both sides of the systemd readiness protocol.
util/search
util/shuffle
util/span
util/stacktrace
util/stop
util/stringarena
util/stringencoding
util/syncutil
util/syncutil/singleflightPackage singleflight provides a duplicate function call suppression mechanism.
util/sysutilPackage sysutil is a cross-platform compatibility layer on top of package syscall.
util/timeofday
util/timetz
util/timeutil
util/timeutil/pgdatePackage pgdate contains parsing functions and types for dates and times in a manner that is compatible with PostgreSQL.
util/tracing
util/treeprinter
util/uint128
util/unique
util/uuid
util/version
workloadPackage workload provides an abstraction for generators of sql query loads (and requisite initial data) as well as tools for working with these generators.
workload/bank
workload/bulkingestPackage bulkingest defines a workload that is intended to stress some edge cases in our bulk-ingestion infrastructure.
workload/cli
workload/debugPackage debug provides a workload subcommand under which useful workload utilities live.
workload/examples
workload/faker
workload/histogram
workload/indexes
workload/interleavedpartitioned
workload/jsonload
workload/kv
workload/ledger
workload/movr
workload/querybench
workload/querylog
workload/queue
workload/rand
workload/sqlsmith
workload/tpcc
workload/tpccchecks
workload/tpcds
workload/tpch
workload/workloadimplPackage workloadimpl provides dependency-light helpers for implementing workload.Generators.
workload/workloadsql
workload/ycsbPackage ycsb is the workload specified by the Yahoo! Cloud Serving Benchmark.

Updated 2020-04-03. Refresh now. Tools for package owners.