Home / Companies / Cockroach Labs / Blog / September 2021

September 2021 Summaries

6 posts from Cockroach Labs

Filter
Month: Year:
Post Summaries Back to Blog
Crain's has ranked Cockroach Labs as the #1 large company on its 2021 Best Places to Work list for New York City. This is the second consecutive year that Cockroach Labs has received this ranking, having also ranked first in the mid-sized category in 2019. The company's founders named it after resilience and survival, with a focus on building a human-forward business where employees can balance their careers with personal lives. They have implemented programs for better recruiting, flexibility, support, opportunities both in and out of the office, and fostered an environment that celebrates diversity of thought. Despite rapid growth, maintaining a human-centered culture remains a top priority for Cockroach Labs.
Sep 27, 2021 979 words in the original blog post.
Wells Fargo has announced an ambitious digital infrastructure initiative that aims to have all of its workloads running on public clouds within the next ten years. The company plans to decommission its data centers and move services to two different public cloud providers, Microsoft Azure and Google Cloud Services. This move is part of a wider trend towards multi-cloud adoption, with 85% of US companies surveyed reporting having an active multi-cloud strategy. Financial firms have been slower to adopt multi-cloud due to security concerns and regulatory barriers, but Wells Fargo's decision to embrace the technology shows that even conservative industries are starting to recognize its benefits.
Sep 22, 2021 937 words in the original blog post.
CockroachDB is a distributed SQL database that provides strong consistency, survivability, and high availability. One of the key features of CockroachDB is its ability to serve stale reads from follower replicas, which can significantly improve read performance in multi-region deployments. In this post, we'll discuss how CockroachDB enables follower reads and some of the trade-offs involved. Closed Timestamps: CockroachDB uses closed timestamps to enable follower reads. A closed timestamp is a point in time after which no writes can occur on a range (a contiguous set of keys). Once a timestamp is closed, it's guaranteed that all subsequent reads at or below the closed timestamp will see a consistent view of the data. To close a timestamp, CockroachDB uses a side-transport mechanism to propagate closed timestamp information between nodes in the cluster. Each node maintains a sender-side state and a receiver-side state for each connection with another node. The sender updates its state when it sends closed timestamp information, and the receiver updates its state when it receives this information. When a follower replica wants to determine whether it's up to date enough to serve a read at a particular timestamp, it checks its own state against the closed timestamp information received from other nodes. If the timestamp is below or equal to the range's closed timestamp, the follower can safely serve the read without blocking on any locks. Optimizations: To minimize access to the side-transport's state and improve performance, CockroachDB uses a per-replica cache in front of the side-transport and queries the closed timestamp information in conjunction with a timestamp that's "sufficient". The sufficient threshold is the timestamp of the read which we suspect we might be able to serve locally as a follower-read. Transaction commit and closed timestamps vs resolved timestamps: CockroachDB allows transactions to commit at timestamps below the closed timestamp, but it doesn't count transaction commits as writes for the purpose of updating closed timestamps. This is because transaction commits are not tied to any particular range and can only ratchet up the timestamps of the committed keys - so they cannot cause keys to float down from >ct to <ct. Request routing: CockroachDB uses a component called the DistSender to route read/write requests to the right place. The DistSender tries to route requests to leaseholders, but if the request is read-only with a timestamp that's old enough, it chooses the closest replica instead. A read timestamp is considered "old enough" if it's likely that every follower has been informed of a closed timestamp higher than the read timestamp. Comparing CockroachDB with Spanner: CockroachDB and Google's Spanner have some similarities in how they handle stale reads, but there are also some differences. In Spanner, every replica serves both strongly-consistent and stale reads, while in CockroachDB, the DistSender tries to route requests to leaseholders for strong reads and to followers for stale reads. Additionally, Spanner requires a follower to have caught up to a resolved timestamp rather than a closed timestamp before serving a read at that timestamp. In conclusion, CockroachDB's ability to serve follower reads is an important feature that can significantly improve read performance in multi-region deployments. By using closed timestamps and optimizing the request routing process, CockroachDB enables efficient and consistent stale reads while maintaining strong consistency guarantees.
Sep 16, 2021 8,679 words in the original blog post.
The article discusses the combination of TypeORM and CockroachDB as a powerful database solution for TypeScript applications. It explains that TypeORM is an ORM library that supports various databases, including CockroachDB, which is a cloud-native distributed SQL database with features like online schema changes, automated data replication, and elastic scaling. The article provides a step-by-step guide on how to connect a TypeScript application to CockroachDB, emphasizing its ease of use and performance benefits.
Sep 14, 2021 524 words in the original blog post.
Game developers require databases that can handle automated scaling, low latency, consistency, and high availability. Automated scaling allows for instant adjustment when demand spikes, ensuring a smooth player experience without additional operational complexity. Low latency is crucial as gamers are distributed globally and expect quick responses from the database. Consistency is vital for accurate transactional workloads and metadata storage in games with leaderboards or player profiles. High availability ensures that players can access the game at all times, especially important for free-to-play games where a negative first experience could lead to loss of users. CockroachDB offers these features and has been used by successful games like Cookie Run: Kingdom.
Sep 07, 2021 1,447 words in the original blog post.
This article presents eight popular third-party GUI tools for Postgres-compliant databases. These include DBeaver, DBmarlin, DataGrip, Beekeeper Studio, Pgweb, TablePlus, Postico, and Navicat. Each tool offers unique features such as compatibility with various database technologies, performance visualization and monitoring, SQL code completion, and more. While only DBeaver is officially supported by Cockroach Labs, the other tools have been tested by the community and are known to work well. The article also mentions additional tools that can be used with CockroachDB, which can be found in their documentation pages.
Sep 01, 2021 666 words in the original blog post.