Blog
Product
How we built a vectorized execution engine
CockroachDB is an OLTP database, specialized for serving high-throughput queries that read or write a small number of rows. As we gained more usage, we found that customers weren’t getting the performance they expected from analytic queries that read a lot of rows, like large scans, joins, or aggregations. In April 2018, we started to seriously investigate how to improve the performance of these types of queries in CockroachDB, and began working on a new SQL execution engine. In this blog post, we use example code to discuss how we built the new engine and why it results in up to a 4x speed improvement on an industry-standard benchmark.
Alfonso Subiotto Marques
October 31, 2019
Product
Announcing CockroachDB Dedicated: CockroachDB-as-a-service
Today we announced the beta program for CockroachDB Dedicated, a self-service, fully managed cloud offering of CockroachDB. CockroachDB Dedicated delivers simple and easy to onboard distributed SQL, while also offering a secure and flexible experience. Whether you’re building a small application on a single node, a resilient application across multiple nodes or a multi-region application serving users all over the world, CockroachDB Dedicated is the distributed SQL database for modern application developers. “As-a-service” has become the norm for how developers consume software. A year ago, we announced a limited availability of Managed CockroachDB, which was the first step in our cloud journey, and an important milestone in our mission of Making Data Easy. Since then, we’ve learned a lot from our earliest users. CockroachDB Dedicated is the culmination of all those learnings, and we’re excited to now open up the offering to a broader audience.
Lakshmi Kannan
October 16, 2019
Product
Get started geo-partitioning data with our command-line CockroachDB demo
CockroachDB offers a number of powerful enterprise features, most notably those related to geo-partitioning tables. Geo-partitioning allows users to control where their data lives geographically, at the row-level. To make geo-partitioning easier for users to try out, we made some updates to cockroach demo that enable you to check out enterprise features without the need for a full deployment. Note that all of the features discussed in this blog will be available in CockroachDB version 19.2. When you run cockroach demo in a terminal, CockroachDB starts a temporary, in-memory cluster, and then opens a SQL shell to that cluster. The in-memory cluster persists only as long as the shell is open, and the data is lost once the shell is closed. cockroach demo also automatically acquires a temporary enterprise license for each demo session, so you can use enterprise CockroachDB features right now. After you install CockroachDB, no further set up is necessary. So let’s dive right into the new features available for use with cockroach demo!
Rohan Yadav
October 10, 2019
Product
Feature of the week: Core changefeeds in CockroachDB 19.1
Our latest CockroachDB Feature of the Week, core changefeeds, is an exciting new way for event-driven apps to consume data from CockroachDB. With the CHANGEFEED FOR statement, a SQL client can tell the database to monitor a table and tell it when writes take place. CockroachDB will then hold the connection open until the client closes it and stream records to the client for all writes. You can use changefeeds to build event-driven applications, perform data integration, and do all kinds of other tasks that depend on watching the state of a table.
Roland Crosby
July 30, 2019
Product
Query plan caching in CockroachDB
Since the 2.1 release, CockroachDB has had a cost-based optimizer. Rewriting a big component of an existing system is always challenging. In particular, we really wanted to avoid regressing on any workloads, including simple transactional queries where the existing planner was already generating the best plan. A cost-based optimizer inherently does more work and thus involves longer planning times. To mitigate this, we worked on caching and reusing optimizer state across multiple instances of the same query. For now, we chose a conservative path: only cache state from which we can still generate the best plan (the one we would have generated without caching), making caching invisible to the user. We’ll start with an overview of the stages of the query planning process; then we’ll go over the methods clients can use to issue queries against CockroachDB, and finally we’ll discuss the caching work we have done to speed up query planning.
Radu Berinde
June 20, 2019
Product
Vectorizing the merge joiner in CockroachDB
Everybody loves a fast query. So how can we make the best use of the existing information to make joins on sorted data faster? The answer is lies in vectorizing the merge join operator. Today we’ll be looking into what a merge joiner is (or what it used to be), followed by what vectorization means and how it changes the problem, and ending with how we decided to make the merge join operator faster and what this means for your queries.
George Utsin
June 18, 2019
Product
Introducing CockroachDB 19.1
It’s been a little over four years since we started our mission to deliver an enterprise-ready distributed SQL database. Today, we’re excited to release CockroachDB 19.1. With this release, we enhanced distributed SQL capabilities, and expanded upon enterprise-grade features for security and data integrations. 19.1 continues to solve the challenge of complex, distributed SQL while meeting all the “enterprise” requirements that are expected of a database. Here’s Nate Stewart, our VP of Product, with a quick intro on what you can expect in CockroachDB 19.1. And for a deeper tutorial with Nate, register for our CockroachDB 19.1 webinar.
Product
Why we're switching to calendar versioning
One small step for Cockroach Labs, one giant leap for our release numbering. Since our initial launch, Cockroach Labs has used semantic versioning in our release cycle guidelines. Two years, one major release, and n-patch fixes later, we're making the switch to Calendar Versioning. This means subscribers to our release notes will see quite the jump in today's version numbering, from last week's 2.1.5 to today's 19.1 beta.
Peter Mattis
February 25, 2019
Product
CockroachDB 2.1: Easier migrations and a 5x scalability improvement
CockroachDB was built to help teams scale their applications across the globe without sacrificing SQL’s convenience, power, and data-integrity guarantees. In CockroachDB 2.1, we’ve made it easier than ever to migrate from MySQL and Postgres, improved our scalability on transactional workloads by 5x, and launched a managed offering to help teams deploy low-latency, multi-region clusters with minimal operator overhead.
Nate Stewart
November 1, 2018