Preface
I was involved in a redis project last year, but I was involved in other projects due to temporary decisions. The heart has been on redis can be said to do not forget, the most impressive is when the first day to hear redis, said it is the database AK-47. The authorSalvatore
Sanfilippo is fully written in accordance with standard C when implementing redis. All required data structures andAlgorithmAll are self-implemented. The encoding style will be compiled.CodeAs beautiful as poetry.
Redis Introduction
As a preface, here we will mainly talk about What redis is doing. Here we will talk about the official redis Website: the original article here is redis introduction:
Redis is a completely open-source, free, and advanced key-value persistence product. it is usually called a Data Structure server, because keys can contain strings, maps, lists, sets, and sorted sets ).
You can perform atomic operations on these data types, such as string extension, adding values in the hash, adding elements to the List, and calculating the intersection, union, and difference sets of the set, or obtain the highest value in an ordered set.
To achieve excellent performance, redis is a database fully working in the memory. Based on your needs, you can regularly dump the database to a disk or incremental logs to achieve database persistence.
Redis supports trivial-to-setup master-slave replication and uses features such as fast first non-blocking synchronization and automatic reconnection of network fragments.
With the check-and-Set Mechanism, the pub/sub function and other configuration settings make redis just like a cache.
We can use other major languages to write redis clients.
Materials
The redis version used for learning the redis source code of this series is 2.9.7.
Redis source code: Click to open the link
Apsaradb for redis source code: Click to open the link
Redis Data Summary topic: Click to open the link