Skip to content

Instantly share code, notes, and snippets.

@subintp
Created March 19, 2020 13:34
Show Gist options
  • Save subintp/173a773003c883db388895c0a2ed7e46 to your computer and use it in GitHub Desktop.
Save subintp/173a773003c883db388895c0a2ed7e46 to your computer and use it in GitHub Desktop.
Redis vs Aerospike
**********Redis***************
Single threaded
No need to worry about locks
Cannot explore multiple cores.Need to run multiple instance in multiple coress.
Both master and slave in the same machine. Master goes down there is high change for data loss
Data structures
Rich data structures. Lot of operation on data structures is supported natively.
Nested data structures is not supported.
Performance
Tuned for in memory
LRU cache
Persistance
Optional snapshot to appendonly file.
Will take to lot of time to reconstruct data after restart of redis.
Replication
Manually configure and master and slave
Not rackaware
Asynchornous replication.
Sharding
Need to handle at application level
Auto rebalancing of keys when node goes down is not supported. They have plan to add in future.
Auto Clustering => Redis 3.0 or above
Some manual step involved.
Supports PubSub
********Aerospike**************
Multi threaded
Data structures
Basic data structures
Nested data structures is supported. Less operations on DS is natively supported
Performance
Tuned for in memory/SSD
Aerospike can run with data in-memory or directly off SSDs (using its own file system), usually within 1 millisecond. Using SSDs saves money and increases the amount of storage per node.This use of SSD enables enormous vertical scaleup at a 5x lower total cost of ownership (TCO) than pure RAM.
LRU cache
Persitance
SSD, Inmemory, Inmemory + incremental snapshot in harddisk.
Warm restart capability=> Indexes are stored in memory even the process goes down.
This will reduce restart time significantly
Replication
Auto assignment of master and slave
Synchronous replication
Rackawareness in replication (Wont keep same master and slave in same machine).
Sharding
Auto sharding
Auto rebalancing of keys when node goes down
Auto Clustering
No need to handle clustering logic in application
Known limitations = https://www.aerospike.com/docs/guide/limitations.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment