StackShareStackShare
Follow on
StackShare

Discover and share technology stacks from companies around the world.

Follow on

© 2025 StackShare. All rights reserved.

Product

  • Stacks
  • Tools
  • Feed

Company

  • About
  • Contact

Legal

  • Privacy Policy
  • Terms of Service
  1. Stackups
  2. Application & Data
  3. Databases
  4. Databases
  5. Memcached vs RabbitMQ

Memcached vs RabbitMQ

OverviewDecisionsComparisonAlternatives

Overview

Memcached
Memcached
Stacks7.9K
Followers5.7K
Votes473
GitHub Stars14.0K
Forks3.3K
RabbitMQ
RabbitMQ
Stacks21.8K
Followers18.9K
Votes558
GitHub Stars13.2K
Forks4.0K

Memcached vs RabbitMQ: What are the differences?

  1. Key Difference 1: Scalability

    • Memcached is horizontally scalable, which means that it can be easily scaled by adding more nodes to the cluster. This allows it to handle high traffic and large data sets efficiently.
    • On the other hand, RabbitMQ is vertically scalable. It can be scaled by increasing the resources of a single node, such as CPU or memory. This makes it suitable for handling a large number of messages within a single node.
  2. Key Difference 2: Data Storage

    • Memcached is primarily used for caching data in memory. It is designed to provide fast access to frequently accessed data. However, it does not provide durable storage, as the data is lost when the server restarts or when the cache reaches its memory limit.
    • In contrast, RabbitMQ is a message broker that provides durable storage for messages. It stores messages on disk, ensuring that they are not lost even if the server restarts. This makes it suitable for reliable message delivery in distributed systems.
  3. Key Difference 3: Data Distribution

    • Memcached uses a distributed hash table (DHT) to distribute data across multiple nodes in the cluster. The data is divided into key-value pairs and assigned to different nodes based on the hash value of the key. This allows for efficient load balancing and high availability.
    • RabbitMQ uses a message queueing system to distribute messages among consumers. Messages are sent to an exchange, which then routes them to the appropriate queues. Consumers can subscribe to these queues to receive and process messages. This allows for flexible message routing and handling of complex workflows.
  4. Key Difference 4: Communication Protocol

    • Memcached uses a simple text-based protocol for communication. Clients send commands to the server in a human-readable format, such as "get" or "set" followed by the key and value. This makes it easy to interact with Memcached using any programming language.
    • RabbitMQ uses the Advanced Message Queuing Protocol (AMQP) for communication. It is a binary protocol that allows for efficient and reliable message exchange between clients and the RabbitMQ server. The protocol supports features like message acknowledgments, transactions, and various messaging patterns.
  5. Key Difference 5: Message Ordering

    • Memcached does not guarantee the order in which data is stored or retrieved. It is designed for fast access to data and does not prioritize ordering.
    • RabbitMQ, on the other hand, maintains the order of messages within a queue. Consumers can process messages in the order they are received, ensuring that the message ordering is preserved.
  6. Key Difference 6: Message Persistence

    • Memcached does not persist data to disk by default. It relies on the cache's memory for data storage. However, some configurations allow Memcached to store data on disk, but it affects performance.
    • RabbitMQ, by default, persists messages to disk to ensure durability. This means that messages are stored even if the server crashes or restarts. It provides options to control message durability and allows for long-term message storage.

In Summary, Memcached is a scalable in-memory caching system primarily used for fast data access, while RabbitMQ is a durable message broker for reliable message delivery with support for various messaging patterns.

Share your Stack

Help developers discover the tools you use. Get visibility for your team's tech choices and contribute to the community's knowledge.

View Docs
CLI (Node.js)
or
Manual

Advice on Memcached, RabbitMQ

viradiya
viradiya

Apr 12, 2020

Needs adviceonAngularJSAngularJSASP.NET CoreASP.NET CoreMSSQLMSSQL

We are going to develop a microservices-based application. It consists of AngularJS, ASP.NET Core, and MSSQL.

We have 3 types of microservices. Emailservice, Filemanagementservice, Filevalidationservice

I am a beginner in microservices. But I have read about RabbitMQ, but come to know that there are Redis and Kafka also in the market. So, I want to know which is best.

933k views933k
Comments
Meili
Meili

Software engineer at Digital Science

Sep 24, 2020

Needs adviceonZeroMQZeroMQRabbitMQRabbitMQAmazon SQSAmazon SQS

Hi, we are in a ZMQ set up in a push/pull pattern, and we currently start to have more traffic and cases that the service is unavailable or stuck. We want to:

  • Not loose messages in services outages
  • Safely restart service without losing messages (@{ZeroMQ}|tool:1064| seems to need to close the socket in the receiver before restart manually)

Do you have experience with this setup with ZeroMQ? Would you suggest RabbitMQ or Amazon SQS (we are in AWS setup) instead? Something else?

Thank you for your time

500k views500k
Comments
André
André

Technology Manager at GS1 Portugal - Codipor

Jul 30, 2020

Needs adviceon.NET Core.NET Core

Hello dear developers, our company is starting a new project for a new Web App, and we are currently designing the Architecture (we will be using .NET Core). We want to embark on something new, so we are thinking about migrating from a monolithic perspective to a microservices perspective. We wish to containerize those microservices and make them independent from each other. Is it the best way for microservices to communicate with each other via ESB, or is there a new way of doing this? Maybe complementing with an API Gateway? Can you recommend something else different than the two tools I provided?

We want something good for Cost/Benefit; performance should be high too (but not the primary constraint).

Thank you very much in advance :)

461k views461k
Comments

Detailed Comparison

Memcached
Memcached
RabbitMQ
RabbitMQ

Memcached is an in-memory key-value store for small chunks of arbitrary data (strings, objects) from results of database calls, API calls, or page rendering.

RabbitMQ gives your applications a common platform to send and receive messages, and your messages a safe place to live until received.

-
Robust messaging for applications;Easy to use;Runs on all major operating systems;Supports a huge number of developer platforms;Open source and commercially supported
Statistics
GitHub Stars
14.0K
GitHub Stars
13.2K
GitHub Forks
3.3K
GitHub Forks
4.0K
Stacks
7.9K
Stacks
21.8K
Followers
5.7K
Followers
18.9K
Votes
473
Votes
558
Pros & Cons
Pros
  • 139
    Fast object cache
  • 129
    High-performance
  • 91
    Stable
  • 65
    Mature
  • 33
    Distributed caching system
Cons
  • 2
    Only caches simple types
Pros
  • 235
    It's fast and it works with good metrics/monitoring
  • 80
    Ease of configuration
  • 60
    I like the admin interface
  • 52
    Easy to set-up and start with
  • 22
    Durable
Cons
  • 9
    Too complicated cluster/HA config and management
  • 6
    Needs Erlang runtime. Need ops good with Erlang runtime
  • 5
    Configuration must be done first, not by your code
  • 4
    Slow

What are some alternatives to Memcached, RabbitMQ?

MongoDB

MongoDB

MongoDB stores data in JSON-like documents that can vary in structure, offering a dynamic, flexible schema. MongoDB was also designed for high availability and scalability, with built-in replication and auto-sharding.

MySQL

MySQL

The MySQL software delivers a very fast, multi-threaded, multi-user, and robust SQL (Structured Query Language) database server. MySQL Server is intended for mission-critical, heavy-load production systems as well as for embedding into mass-deployed software.

PostgreSQL

PostgreSQL

PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, user-defined types and functions.

Kafka

Kafka

Kafka is a distributed, partitioned, replicated commit log service. It provides the functionality of a messaging system, but with a unique design.

Microsoft SQL Server

Microsoft SQL Server

Microsoft® SQL Server is a database management and analysis system for e-commerce, line-of-business, and data warehousing solutions.

SQLite

SQLite

SQLite is an embedded SQL database engine. Unlike most other SQL databases, SQLite does not have a separate server process. SQLite reads and writes directly to ordinary disk files. A complete SQL database with multiple tables, indices, triggers, and views, is contained in a single disk file.

Cassandra

Cassandra

Partitioning means that Cassandra can distribute your data across multiple machines in an application-transparent matter. Cassandra will automatically repartition as machines are added and removed from the cluster. Row store means that like relational databases, Cassandra organizes data by rows and columns. The Cassandra Query Language (CQL) is a close relative of SQL.

MariaDB

MariaDB

Started by core members of the original MySQL team, MariaDB actively works with outside developers to deliver the most featureful, stable, and sanely licensed open SQL server in the industry. MariaDB is designed as a drop-in replacement of MySQL(R) with more features, new storage engines, fewer bugs, and better performance.

RethinkDB

RethinkDB

RethinkDB is built to store JSON documents, and scale to multiple machines with very little effort. It has a pleasant query language that supports really useful queries like table joins and group by, and is easy to setup and learn.

Celery

Celery

Celery is an asynchronous task queue/job queue based on distributed message passing. It is focused on real-time operation, but supports scheduling as well.

Related Comparisons

Bootstrap
Materialize

Bootstrap vs Materialize

Laravel
Django

Django vs Laravel vs Node.js

Bootstrap
Foundation

Bootstrap vs Foundation vs Material UI

Node.js
Spring Boot

Node.js vs Spring-Boot

Liquibase
Flyway

Flyway vs Liquibase