Guava VS Disruptor

Compare Guava vs Disruptor and see what are their differences.

Guava

Google core libraries for Java (by google)
Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
Guava Disruptor
58 30
49,364 16,999
0.5% 0.8%
9.6 5.4
5 days ago 4 months ago
Java Java
Apache License 2.0 Apache License 2.0
The number of mentions indicates the total number of mentions that we've tracked plus the number of user suggested alternatives.
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.

Guava

Posts with mentions or reviews of Guava. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2023-11-23.
  • Lists: do you know the nature of yours? The strange story of a data container in Java
    2 projects | dev.to | 23 Nov 2023
    The first problem is at the level of Type System, given that a situation more correct would allow us to distinguish through the Collection Type which abstraction we are operating with, species if definable as mutable or immutable. The JCF was born at a time when great care was taken to offer immediate operational data structures, and with attention to performance, but with less attention to constructs or uses that are now seen as common. These concepts have been taken up by other infrastructures from which we certainly cannot fail to mention: Eclipse Collection, Guava Collections, and VAVR.
  • Google/guava: Google core libraries for Java
    3 projects | news.ycombinator.com | 8 Nov 2023
    Even better is getting Gradle/Maven to correctly pull "plain" vs "Android" versions of the package instead of them just publishing the diverging code base as two repository packages.

    https://github.com/google/guava/issues/2914

  • Guava 32.0 (released today) and the @Beta annotation
    5 projects | /r/java | 30 May 2023
    I'll admit I'm surprised to see that BOMs have been documented on maven.apache.org since mid-2008. It looks like Spring, for example, didn't adopt them until mid-2014. I don't know how widely they caught on in other areas. The first discussion of them in the context of Guava may have been in 2018, as I don't see mention of them in the various issues from 2011-2015 (#605, #1329, #1471, #1954.
  • Best Practice of Guava ImmutableList
    1 project | /r/learnjava | 8 May 2023
    And a quick peek at the source code for ImmutableList seems to confirm this (https://github.com/google/guava/blob/master/guava/src/com/google/common/collect/ImmutableList.java - it goes via a bunch of methods, but ends up using Arrays.copyOf(), which creates a fixed-size array).
  • Genuine question: how do you all use Haskell IRL?
    7 projects | /r/haskell | 22 Apr 2023
    The guava library of Java has some of these data structures implemented: https://github.com/google/guava/wiki/ImmutableCollectionsExplained , but implementations of the above book in many languages can be found on github (say, this one for Haskell: https://github.com/aistrate/Okasaki )
  • Murmurhash -criando um rollout progressivo via backend
    3 projects | dev.to | 21 Apr 2023
  • Один из примеров почему ChatGPT еще очень далеко до замены программистов, та и остальных профессий тоже.
    7 projects | /r/tjournal_refugees | 13 Apr 2023
    Java Mask: Java Mask is a library that offers various string masking techniques for sensitive data such as credit card numbers, email addresses, and more. You can find the library at: https://github.com/miguelfreitas93/java-mask DataMasker: DataMasker is a Java library specifically designed for masking sensitive data, including credit card numbers, using customizable masking patterns. Visit the GitHub repository for more information and usage examples: https://github.com/GDSSecurity/DataMasker Maskify: Maskify is a simple Java library that can be used to mask credit card numbers, Social Security numbers, and other sensitive information. You can find the library at: https://github.com/jonathancarvalhoalves/maskify CreditCardUtils: This is a lightweight Java library that provides utility methods for validating, formatting, and masking credit card numbers. Visit the GitHub repository for more information: https://github.com/malkusch/creditcardutils Google Guava: Google Guava is a popular set of Java libraries containing a wealth of utilities for working with strings, collections, and more. While not specifically designed for masking credit card information, you can use Guava's string manipulation methods to mask sensitive data: https://github.com/google/guava
  • Twitter makes some of its source code public
    3 projects | /r/Twitter | 2 Apr 2023
    I mean, I guess, technically? If you define it like that, then Microsoft has people working for them for free, as does Google, as does Apple, etc. It's not that weird, and you can try to twist it to be weird, but those of us in the software industry largely regard this as a good thing.
  • Managing unfixable CVEs
    1 project | /r/ExperiencedDevs | 11 Mar 2023
    So we have https://github.com/google/guava/issues/4011
  • Java 17 migration: bias locks regression
    1 project | dev.to | 16 Feb 2023
    Ok, so let's implement our lazy initialization more smartly to avoid acquiring the lock every time and use old fashion but still working double-checked locking. I've found it implemented by Suppliers.memoize in guava library.

Disruptor

Posts with mentions or reviews of Disruptor. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2024-03-14.
  • Gnet is the fastest networking framework in Go
    2 projects | news.ycombinator.com | 14 Mar 2024
    https://lmax-exchange.github.io/disruptor/#_what_is_the_disr.... Unfortunately IIUC writing this in Go still prevents the spin-locked acceptor thread from achieving the kind of performance you could get in a non-GC language, unless you chose to disable GC, so I'd guess Envoy is still faster.

    https://gnet.host/docs/quickstart/ it's nice that you can use this simply though. Envoy is kind of tricky to setup with custom filters, so most of the time it's just a standalone binary.

    [0] https://blog.envoyproxy.io/envoy-threading-model-a8d44b92231...

    [1] https://lmax-exchange.github.io/disruptor/#_what_is_the_disr...

  • A lock-free ring-buffer with contiguous reservations (2019)
    9 projects | news.ycombinator.com | 29 Feb 2024
    See also the Java LMAX Disruptor https://github.com/LMAX-Exchange/disruptor

    I've built a similar lock-free ring buffer in C++11 https://github.com/posterior/loom/blob/master/doc/adapting.m...

  • JEP Draft: Deprecate Memory-Access Methods in Sun.misc.Unsafe for Removal
    3 projects | news.ycombinator.com | 16 Jan 2024
    "Why we chose Java for our High-Frequency Trading application"

    https://medium.com/@jadsarmo/why-we-chose-java-for-our-high-...

    LMAX Disruptor customers

    https://lmax-exchange.github.io/disruptor/

    Among many other examples.

  • LMAX Disruptor – High Performance Inter-Thread Messaging Library
    1 project | /r/hackernews | 20 Nov 2023
    4 projects | news.ycombinator.com | 17 Nov 2023
    Current documentation

    https://lmax-exchange.github.io/disruptor/

  • Progress on No-GIL CPython
    5 projects | news.ycombinator.com | 20 Oct 2023
    LMAX Disruptor has on their wiki that average latency to send a message from one thread to another at 53 nanoseconds. For comparison a mutex is like 25 nanoseconds and more if Contended but a mutex is point to point synchronization.

    The great thing about it is that multiple threads can receive the same message without much more effort.

    https://github.com/LMAX-Exchange/disruptor/wiki/Performance-...

    https://gist.github.com/rmacy/2879257

    I am dreaming of language that is similar to Smalltalk that stays single threaded until it makes sense to parallise.

    I am looking for problems to parallelism that are not big data. Parallelism is like adding more cars to the road rather than increasing the speed of the car. But what does a desktop or mobile user need to do locally that could take advantage of the mathematical power of a computer? I'm still searching.

  • Disruptor 4.0.0 Released
    1 project | news.ycombinator.com | 29 Sep 2023
  • Anything can be a message queue if you use it wrongly enough
    6 projects | news.ycombinator.com | 4 Jun 2023
    Database config should be two connection strings, 1 for the admin user that creates the tables and anther for the queue user. Everything else should be stored in the database itself. Each queue should be in its own set of tables. Large blobs may or may not be referenced to an external file.

    Shouldn't a message send be worst case a CAS. It really seems like all the work around garbage collection would have some use for in-memory high speed queues.

    Are you familiar with the LMAX Disruptor? Is is a Java based cross thread messaging library used for day trading applications.

    https://lmax-exchange.github.io/disruptor/

  • Any library you would like to recommend to others as it helps you a lot? For me, mapstruct is one of them. Hopefully I would hear some other nice libraries I never try.
    21 projects | /r/java | 27 May 2023
    Disruptor for inter-thread messaging
  • Measuring how much Rust's bounds checking actually costs
    3 projects | /r/rust | 30 Nov 2022
    I have never worked in any industries where a perf margin was that small. It is funny, in HFT there are folks using Lmax (Java) and then you have folks writing their own TCP/IP stacks on FPGAs to do trading.

What are some alternatives?

When comparing Guava and Disruptor you can also consider the following projects:

JGit - JGit project repository (jgit)

JCTools

javatuples - Typesafe representation of tuples in Java.

Agrona - High Performance data structures and utility methods for Java

Caffeine - A high performance caching library for Java

fastutil - fastutil extends the Java™ Collections Framework by providing type-specific maps, sets, lists and queues.

Eclipse Collections - Eclipse Collections is a collections framework for Java with optimized data structures and a rich, functional and fluent API.

MPMCQueue.h - A bounded multi-producer multi-consumer concurrent queue written in C++11

Hashids.java - Hashids algorithm v1.0.0 implementation in Java

Gephi - Gephi - The Open Graph Viz Platform

Javolution