Blog
Engineering
Distributed SQL (NewSQL) made easy: How CockroachDB automates operations
A modern distributed database should do more than just split data amongst a number of servers; it should correctly manage partitions (or shards). Moreso, it should automatically detect failures, fix itself without any operator intervention, and completely abstract this management from the end user. This post is the first in a series on how CockroachDB handles its data and discusses the mechanisms it uses to rebalance and repair. These systems make managing a CockroachDB cluster significantly easier than managing other databases.
Bram Gruneir
October 5, 2017
System
Avoid vendor lock-in risk with multi-cloud deployments
As businesses outsource their infrastructure to public cloud providers they are in turn taking on major risks. In a recent piece by Financial News (gated), senior executives at Goldman Sachs and Standard Chartered warned that an overreliance on a small band of cloud service providers could result in a major hack or outage wreaking havoc on the global banking system. Lock-in is a global issue: Bain’s Cloud Computing Survey noted that the share of respondents citing vendor lock-in as a “top three concern” grew from 7% to 23% from 2012 to 2015. Of course, cloud vendor lock-in issues extend beyond uptime risk; they also include the regulatory risk of changes in data sovereignty policies or the financial risk of having to endure price hikes without any negotiating power; Dropbox went so far as to migrate off of AWS and onto their own system to get control of their costs.
Nate Stewart
October 3, 2017
Engineering
CockroachDB on DC/OS: Resilient and hassle-free operations for global services
CockroachDB makes data easier to manage by providing a strongly-consistent, highly-scalable, SQL interface that you can trust to be there when you need it. We’ve designed it to be a truly cloud-native, distributed SQL database that’s easy to operate in any environment you throw at it. One such computing environment that has grown in popularity over the previous few years is Mesosphere’s DC/OS, a datacenter operating system built on top of Apache Mesos. DC/OS is an orchestration system for deploying and managing distributed applications across a cluster of machines as if they were a single pool of resources. DC/OS has both an open source and an enterprise version that gives you the ability to elastically scale your infrastructure on prem or in the cloud. It provides scheduling, resource allocation, service discovery, automatic recovery from failure, load balancing, and more, all with the goal of making it easier to manage your applications.
Alex Robinson
September 28, 2017
Engineering
Real transactions are serializable
Most databases offer a choice of several transaction isolation levels, offering a tradeoff between correctness and performance. However, that performance comes at a price, as developers must study their transactional interactions carefully or risk introducing subtle bugs. CockroachDB provides strong (“SERIALIZABLE”) isolation by default to ensure that your application always sees the data it expects. In this post I'll explain what this means and how insufficient isolation impacts real-world applications.
Ben Darnell
September 21, 2017
Culture
Exercise-based interviewing at Cockroach Labs
When I first started at Cockroach Labs, the founders and I had a candid conversation about diversity. Studies have shown that diverse companies have a greater likelihood of success through higher employee performance and financial returns [2015 McKinsey report]. We agreed that it was important for us to attract a diverse workforce and concluded that the best way to do so was through creating an inclusive environment. In addition to internal initiatives, we set out on a mission to remove bias from our interview process or more realistically, challenge the bias that our interviewers face when assessing candidates.
Lindsay Grenawalt
September 7, 2017
Product
The cross-cloud migration
As a CockroachDB Tech Writer, when I document a new feature, generally, I first try to learn the business value behind it, then I test the feature thoroughly, and then I try to write up concise, informative guidance for users. Sometimes, the business value and usage aren’t unique to CockroachDB (it’s a SQL database, after all, and SQL has been around for a while). Other times, I get to document capabilities so novel and powerful that straight-up user documentation just doesn’t seem enough.
System
How CockroachDB implemented consistent, distributed, incremental backup
Consistent, Distributed, Incremental Backup: Pick Three Almost all widely used database systems include the ability to backup and restore a snapshot of their data. The replicated nature of CockroachDB’s distributed architecture means that the cluster survives the loss of disks or nodes, and yet many users still want to make regular backups. This led us to develop distributed backup and restore, the first feature available in our CockroachDB Self-hosted offering.
Daniel Harrison
August 9, 2017
Design
Product design is a work in progress
The design team at Cockroach Labs recently doubled in size (Hooray!). During the hiring process, I got many questions about the company culture, specific projects that a new product designer would be working on, and of course, personal growth. The most common question, however, was surprisingly about what exactly a product designer does. Product design encompasses a wide range of responsibilities. Depending on the person and their company, the typical day of a product designer can vary quite a bit. Some write thorough code for their mockups, while others write clear, witty copy. Some craft pixel-perfect icons, while others excel at prototyping animations and user flows. If you're attracted to working at startups like me, then you're probably drawn to wearing many hats. Since resources are scarce, product designers sometimes manage projects, conduct interviews, create mockups, and take on prototyping. And if you're working on a product for which you aren't the primary the user (like a database), one skill that's crucial to success is the ability to leverage knowledge from your fellow coworkers so they can help you arrive at great solutions. A product designer at Cockroach Labs has three main responsibilities: research, translation and facilitation.
Kuan Luo
July 20, 2017
System
Survey of rounding implementations in Go
Rounding in Go is hard to do correctly. That is, given a float64, truncate the fractional part (anything right of the decimal point), and add one to the truncated value if the fractional part was >= 0.5. This problem doesn't come up often, but it does enough that as of this writing, the second hit on Google for golang round is a closed issue from the Go project, which declined to add a Round function to the math package. That issue also includes many community contributions about ways to round.
Matt Jibson
July 6, 2017