<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Scalability on Brave New Geek</title><link>https://bravenewgeek.com/tag/scalability/</link><description>Recent content in Scalability on Brave New Geek</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Thu, 29 Oct 2020 15:05:18 -0500</lastBuildDate><atom:link href="https://bravenewgeek.com/tag/scalability/index.xml" rel="self" type="application/rss+xml"/><item><title>Introducing Liftbridge: Lightweight, Fault-Tolerant Message Streams</title><link>https://bravenewgeek.com/introducing-liftbridge-lightweight-fault-tolerant-message-streams/</link><pubDate>Fri, 27 Jul 2018 17:42:49 -0500</pubDate><guid>https://bravenewgeek.com/introducing-liftbridge-lightweight-fault-tolerant-message-streams/</guid><description>&lt;p&gt;&lt;a href="https://github.com/liftbridge-io/liftbridge"&gt;&lt;img loading="lazy" src="https://bravenewgeek.com/wp-content/uploads/2018/07/liftbridge.png"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://twitter.com/tyler_treat/status/1019281381493526529"&gt;Last week&lt;/a&gt; I open sourced &lt;a href="https://github.com/liftbridge-io/liftbridge"&gt;Liftbridge&lt;/a&gt;, my latest project and contribution to the &lt;a href="https://www.cncf.io/"&gt;Cloud Native Computing Foundation&lt;/a&gt; ecosystem. Liftbridge is a system for lightweight, fault-tolerant (LIFT) message streams built on &lt;a href="https://nats.io/"&gt;NATS&lt;/a&gt; and &lt;a href="https://grpc.io/"&gt;gRPC&lt;/a&gt;. Fundamentally, it extends NATS with a &lt;a href="https://kafka.apache.org/"&gt;Kafka&lt;/a&gt;-like publish-subscribe log API that is highly available and horizontally scalable.&lt;/p&gt;
&lt;p&gt;I’ve been working on Liftbridge for the past couple of months, but it’s something I’ve been thinking about for over a year. I sketched out the design for it last year and &lt;a href="https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-5-sketching-a-new-system/"&gt;wrote about it&lt;/a&gt; in January. It was largely inspired while I was working on &lt;a href="https://github.com/nats-io/nats-streaming-server"&gt;NATS Streaming&lt;/a&gt;, which I’m currently still the second top contributor to. My primary involvement with NATS Streaming was building out the early data replication and clustering solution for high availability, which has continued to evolve since I left the project. In many ways, Liftbridge is about applying a lot of the things I learned while working on NATS Streaming as well as my observations from being closely involved with the NATS community for some time. It’s also the product of scratching an itch I’ve had since these are the kinds of problems I enjoy working on, and I needed something to code.&lt;/p&gt;</description></item><item><title>Building a Distributed Log from Scratch, Part 5: Sketching a New System</title><link>https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-5-sketching-a-new-system/</link><pubDate>Tue, 23 Jan 2018 12:08:53 -0600</pubDate><guid>https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-5-sketching-a-new-system/</guid><description>&lt;p&gt;In &lt;a href="https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-4-trade-offs-and-lessons-learned/"&gt;part four&lt;/a&gt; of this series we looked at some key trade-offs involved with a distributed log implementation and discussed a few lessons learned while building NATS Streaming. In this fifth and final installment, we’ll conclude by outlining the design for a new log-based system that draws from the previous entries in the series.&lt;/p&gt;
&lt;h3 id="the-context"&gt;The Context&lt;/h3&gt;
&lt;p&gt;For context, &lt;a href="https://nats.io/"&gt;NATS&lt;/a&gt; and &lt;a href="https://nats.io/documentation/streaming/nats-streaming-intro/"&gt;NATS Streaming&lt;/a&gt; are two different things. NATS Streaming is a log-based streaming system built on top of NATS, and NATS is a lightweight pub/sub messaging system. NATS was originally built (and then open sourced) as the control plane for Cloud Foundry. NATS Streaming was built in response to the community’s ask for higher-level guarantees—durability, at-least-once delivery, and so forth—beyond what NATS provided. It was built as a separate layer on top of NATS. I tend to describe NATS as a dial tone—ubiquitous and always on—perfect for “online” communications. NATS Streaming is the voicemail—leave a message after the beep and someone will get to it later. There are, of course, more nuances than this, but that’s the gist.&lt;/p&gt;</description></item><item><title>Building a Distributed Log from Scratch, Part 4: Trade-Offs and Lessons Learned</title><link>https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-4-trade-offs-and-lessons-learned/</link><pubDate>Thu, 18 Jan 2018 16:01:13 -0600</pubDate><guid>https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-4-trade-offs-and-lessons-learned/</guid><description>&lt;p&gt;In &lt;a href="https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-3-scaling-message-delivery/"&gt;part three&lt;/a&gt; of this series we talked about scaling message delivery in a distributed log. In part four, we’ll look at some key trade-offs involved with such systems and discuss a few lessons learned while building NATS Streaming.&lt;/p&gt;
&lt;h3 id="competing-goals"&gt;Competing Goals&lt;/h3&gt;
&lt;p&gt;There are a number of competing goals when building a distributed log (these goals also extend to many other types of systems). Recall from &lt;a href="https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-1-storage-mechanics/"&gt;part one&lt;/a&gt; that our key priorities for this type of system are performance, high availability, and scalability. The preceding parts of this series described at various levels how we can accomplish these three goals, but astute readers likely noticed that some of these things conflict with one another.&lt;/p&gt;</description></item><item><title>Building a Distributed Log from Scratch, Part 3: Scaling Message Delivery</title><link>https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-3-scaling-message-delivery/</link><pubDate>Mon, 08 Jan 2018 16:10:40 -0600</pubDate><guid>https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-3-scaling-message-delivery/</guid><description>&lt;p&gt;In &lt;a href="https://bravenewgeek.com/building-a-distributed-log-from-scratch-part-2-data-replication/"&gt;part two&lt;/a&gt; of this series we discussed data replication within the context of a distributed log and how it relates to high availability. Next, we’ll look at what it takes to scale the log such that it can handle non-trivial workloads.&lt;/p&gt;
&lt;h3 id="data-scalability"&gt;Data Scalability&lt;/h3&gt;
&lt;p&gt;A key part of scaling any kind of data-intensive system is the ability to partition the data. Partitioning is how we can scale a system linearly, that is to say we can handle more load by adding more nodes. We make the system &lt;em&gt;horizontally&lt;/em&gt; scalable.&lt;/p&gt;</description></item><item><title>Thrift on Steroids: A Tale of Scale and Abstraction</title><link>https://bravenewgeek.com/thrift-on-steroids-a-tale-of-scale-and-abstraction/</link><pubDate>Thu, 30 Nov 2017 19:49:24 -0600</pubDate><guid>https://bravenewgeek.com/thrift-on-steroids-a-tale-of-scale-and-abstraction/</guid><description>&lt;p&gt;&lt;a href="https://thrift.apache.org/"&gt;Apache Thrift&lt;/a&gt; is an RPC framework developed at Facebook for building “scalable cross-language services.” It consists of an interface definition language (IDL), communication protocol, API libraries, and a code generator that allows you to build and evolve services independently and in a polyglot fashion across a wide range of languages. This is nothing new and has been around for over a decade now.&lt;/p&gt;
&lt;p&gt;There are a number of notable users of Thrift aside from Facebook, including Twitter (mainly by way of &lt;a href="https://twitter.github.io/finagle/"&gt;Finagle&lt;/a&gt;), Foursquare, Pinterest, Uber (via &lt;a href="https://uber.github.io/tchannel/"&gt;TChannel&lt;/a&gt;), and Evernote, among others—and for good reason, Thrift is mature and battle-tested.&lt;/p&gt;</description></item><item><title>If State Is Hell, SOA Is Satan</title><link>https://bravenewgeek.com/if-state-is-hell-soa-is-satan/</link><pubDate>Sun, 08 Mar 2015 12:33:18 -0600</pubDate><guid>https://bravenewgeek.com/if-state-is-hell-soa-is-satan/</guid><description>&lt;p&gt;More and more companies are describing their &lt;a href="http://nginx.com/blog/microservices-at-netflix-architectural-best-practices/"&gt;success stories&lt;/a&gt; regarding the switch to a service-oriented architecture. As with any technological upswing, there’s a clear and palpable hype factor involved (Big Data™ or The Cloud™ anyone?), but obviously it’s not just puff.&lt;/p&gt;
&lt;p&gt;While microservices and SOA have seen a staggering &lt;a href="http://www.enterprisecioforum.com/en/blogs/enadhan/secrets-behind-rapid-growth-soa"&gt;rate of adoption&lt;/a&gt; in recent years, the mindset of developers often seems to be stuck in the past. I think this is, at least in part, because we seek a mental model we can reason about. It’s why we build abstractions in the first place. In a sense, I would argue there’s a comparison to be made between the explosion of OOP in the early 90’s and today’s SOA trend. After all, &lt;strong&gt;SOA is as much about people scale as it is about workload scale&lt;/strong&gt;, so it makes sense from an organizational perspective.&lt;/p&gt;</description></item><item><title>Stream Processing and Probabilistic Methods: Data at Scale</title><link>https://bravenewgeek.com/stream-processing-and-probabilistic-methods/</link><pubDate>Fri, 13 Feb 2015 10:49:07 -0600</pubDate><guid>https://bravenewgeek.com/stream-processing-and-probabilistic-methods/</guid><description>&lt;p&gt;Stream processing and related abstractions have become all the rage following the rise of systems like Apache Kafka, Samza, and the &lt;a href="http://en.wikipedia.org/wiki/Lambda_architecture"&gt;Lambda architecture&lt;/a&gt;. Applying the idea of immutable, append-only &lt;a href="http://blog.confluent.io/2015/01/29/making-sense-of-stream-processing/"&gt;event sourcing&lt;/a&gt; means we’re storing more data than ever before. However, as the cost of storage continues to decline, it’s becoming more feasible to store more data for longer periods of time. With immutability, how the data &lt;em&gt;lives&lt;/em&gt; isn’t interesting anymore. It’s all about how it &lt;em&gt;moves&lt;/em&gt;.&lt;/p&gt;</description></item><item><title>Fast, Scalable Networking in Go with Mangos</title><link>https://bravenewgeek.com/fast-scalable-networking-in-go-with-mangos/</link><pubDate>Sat, 10 Jan 2015 17:21:19 -0600</pubDate><guid>https://bravenewgeek.com/fast-scalable-networking-in-go-with-mangos/</guid><description>&lt;p&gt;In the past, I’ve looked at nanomsg and why it’s a formidable alternative to the well-regarded &lt;a href="http://www.bravenewgeek.com/distributed-messaging-with-zeromq/"&gt;ZeroMQ&lt;/a&gt;. Like ZeroMQ, nanomsg is a native library which markets itself as a way to build fast and scalable networking layers. I won’t go into detail on how nanomsg accomplishes this since my analysis of it already covers that fairly extensively, but instead I want to talk about a Go implementation of the protocol called &lt;a href="https://github.com/gdamore/mangos"&gt;Mangos&lt;/a&gt;. ((Full disclosure: I am a contributor on the Mangos project, but only because I was a user first!)) If you’re not familiar with nanomsg or Scalability Protocols, I recommend reading my &lt;a href="http://www.bravenewgeek.com/a-look-at-nanomsg-and-scalability-protocols/"&gt;overview&lt;/a&gt; of those first.&lt;/p&gt;</description></item><item><title>From Mainframe to Microservice: An Introduction to Distributed Systems</title><link>https://bravenewgeek.com/from-mainframe-to-microservice-an-introduction-to-distributed-systems/</link><pubDate>Sat, 01 Nov 2014 18:12:38 -0600</pubDate><guid>https://bravenewgeek.com/from-mainframe-to-microservice-an-introduction-to-distributed-systems/</guid><description>&lt;p&gt;I gave a talk at &lt;a href="http://iowacodecamp.com/"&gt;Iowa Code Camp&lt;/a&gt; this weekend on distributed systems. It was primarily an introduction to them, so it explored some core concepts at a high level.  We looked at why distributed systems are difficult to build (right), the CAP theorem, consensus, scaling shared data and CRDTs.&lt;/p&gt;
&lt;p&gt;There was some interest in making the slides available online. I’m not sure how useful they are without narration, but here they are anyway for posterity.&lt;/p&gt;</description></item><item><title>Dissecting Message Queues</title><link>https://bravenewgeek.com/dissecting-message-queues/</link><pubDate>Mon, 07 Jul 2014 00:33:53 -0500</pubDate><guid>https://bravenewgeek.com/dissecting-message-queues/</guid><description>&lt;p&gt;&lt;em&gt;&lt;strong&gt;Disclaimer (10/29/20)&lt;/strong&gt; – The benchmarks and performance analysis presented in this post should not be relied on. This post was written roughly six years ago, and at the time, was just the result of my exploration of various messaging systems. The benchmarks are not implemented in a meaningful way, which I discussed in a &lt;a href="https://bravenewgeek.com/benchmark-responsibly/"&gt;follow-up post&lt;/a&gt;. This post will remain for posterity and learning purposes, but I do not claim that this information is accurate or useful.&lt;/em&gt;&lt;/p&gt;</description></item><item><title>A Look at Nanomsg and Scalability Protocols (Why ZeroMQ Shouldn’t Be Your First Choice)</title><link>https://bravenewgeek.com/a-look-at-nanomsg-and-scalability-protocols/</link><pubDate>Sun, 29 Jun 2014 20:44:34 -0600</pubDate><guid>https://bravenewgeek.com/a-look-at-nanomsg-and-scalability-protocols/</guid><description>&lt;p&gt;Earlier this month, I &lt;a href="http://www.bravenewgeek.com/distributed-messaging-with-zeromq/" title="Distributed Messaging with ZeroMQ"&gt;explored ZeroMQ&lt;/a&gt; and how it proves to be a promising solution for building fast, high-throughput, and scalable distributed systems. Despite lending itself quite well to these types of problems, ZeroMQ is not without its flaws. Its creators have attempted to rectify many of these shortcomings through spiritual successors &lt;a href="https://github.com/crossroads-io/libxs"&gt;Crossroads I/O&lt;/a&gt; and &lt;a href="http://nanomsg.org/"&gt;nanomsg&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The now-defunct Crossroads I/O is a proper fork of ZeroMQ with the true intention being to build a viable commercial ecosystem around it. Nanomsg, however, is a &lt;em&gt;reimagining&lt;/em&gt; of ZeroMQ—a complete rewrite in C ((The author &lt;a href="http://250bpm.com/blog:4"&gt;explains why&lt;/a&gt; he should have originally written ZeroMQ in C instead of C++.)). It builds upon ZeroMQ’s rock-solid performance characteristics while providing several vital improvements, both internal and external. It also attempts to address many of the strange behaviors that ZeroMQ can often exhibit. Today, I’ll take a look at what differentiates nanomsg from its predecessor and implement a use case for it in the form of service discovery.&lt;/p&gt;</description></item><item><title>Distributed Messaging with ZeroMQ</title><link>https://bravenewgeek.com/distributed-messaging-with-zeromq/</link><pubDate>Wed, 11 Jun 2014 16:56:03 -0600</pubDate><guid>https://bravenewgeek.com/distributed-messaging-with-zeromq/</guid><description>&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;“A distributed system is one in which the failure of a computer you didn’t even know existed can render your own computer unusable.” -Leslie Lamport&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;With the increased prevalence and accessibility of cloud computing, distributed systems architecture has largely supplanted more monolithic constructs. The implication of using a service-oriented architecture, of course, is that you now have to deal with a myriad of difficulties that previously never existed, such as fault tolerance, availability, and horizontal scaling. Another interesting layer of complexity is providing consistency across nodes, which itself is a problem surrounded with endless research. Algorithms like &lt;a href="http://en.wikipedia.org/wiki/Paxos_(computer_science)"&gt;Paxos&lt;/a&gt; and &lt;a href="https://ramcloud.stanford.edu/wiki/download/attachments/11370504/raft.pdf"&gt;Raft&lt;/a&gt; attempt to provide solutions for managing replicated data, while other solutions offer eventual consistency.&lt;/p&gt;</description></item></channel></rss>