redis source code analysis

Read about redis source code analysis, The latest news, videos, and discussion topics about redis source code analysis from alibabacloud.com

Redis source code analysis: dict. c and dict. h

Introduction Hash table is one of the core structures of redis. In redis source code, dict. c and dict. h defines the hash structure used by redis. In this article, we will. c and dict. h. Because dict. the implementation of the separate chaining hash table used in c can be

Redis source code analysis: Memory Management

Source code version: redis 2.4.4 Redis memory-related functions are stored in zmalloc. h zmalloc. C.Redis can use tcmalloc and jemallocMakefile: ifeq ($(USE_TCMALLOC),yes) ALLOC_DEP= ALLOC_LINK=-ltcmalloc ALLOC_FLAGS=-DUSE_TCMALLOCendififeq ($(USE_JEMALLOC),yes) ALLOC_DEP=../deps/jemalloc/lib/libjemalloc.a ALLOC_L

Redis source code analysis (18th) --- object creation and release of redisObject objects

larger strings, using the arbitrary value * of 32 bytes. this code was backported from the unstable branch * where this is already med when the object is too large to be * encoded as EMBSTR. */if (len> 32 o-> encoding = REDIS_ENCODING_RAW sdsavail (s)> len/10) {// call sdsRemoveFreeSpace to remove the spaces in the string 0-> ptr from o-> ptr = sdsRemoveFreeSpace (o-> ptr);}/* Return the original object. */return o ;}.....Removes the space occupied

Redis source code parsing (5): redis persistence, redis source code parsing

Redis source code parsing (5): redis persistence, redis source code parsing Redis is often called a memory database because it stores all d

Redis source code parsing (1): Introduction, redis source code parsing Introduction

Redis source code parsing (1): Introduction, redis source code parsing IntroductionZookeeper The author of Redis, Salvatore Sanfilippo, is from Sicily, Italy and now lives in Catania. H

Redis Source Profiling and annotations (20)---Network Connection library profiling (creation/release of client, command receive/reply, Redis Communication protocol analysis, etc.)

Anatomy of a Redis network connection library 1. Introduction to Redis Network Connection library The file that corresponds to the Redis network Connection library is networking.c. This file is primarily responsible for client creation and release commands receive and command reply REDIS Communication Protocol

Redis Source Analysis (32)---REDIS-CLI.C implementation of client command line interface (1)

Analysis of the Redis source code for nearly 1 months, but also to the most core, closest to the beginning of the system, I named him the main directory, which included 2 important documents, REDIS-CLI and Redis files, 1 represent

Redis Source Analysis (34)---The implementation analysis of REDIS.H service end (1)

The last time just analyzed the client structure analysis, thinking more simple, clear, and finally learning is the implementation of the service end, the service in Redis but the heavy, which basically contains the previous modules involved in all the points of knowledge, from the Redis of the head file can be seen, Redis.h The amount of

Redis Source Analysis (31)---Latency delay analysis and processing

Latencysample acquisition point structure definition: /* Representation of a latency sample:the sampling time and the latency * observed in milliseconds.//// Delay sample * * struct Latencysample { //Delay Sample creation time int32_t/* We don ' t use time_t to force 4 bytes Usage everywhe Re. * * //delay time, in milliseconds uint32_t latency/* latency in milliseconds. */ };The dictionary does not maintain a sample node, but rather a node list structure: /* The Latency Time ser

Redis Source code Parsing (iii): Redis data type string

converted into memory-mapped models using encoding). The former is used to hold the long type data, which is used to hold Sds/char*,long long,long double,double type data. The string type is basically implemented by the operation function of the SDS data structure, here is just a simple example, and nothing else to say./* Appends a string to the specified string and indicates an increased memory space */sds Sdscatlen (SDS s, const void *t, size_t len) {//Declaration string sh struct SDSHDR *

The cornerstone of Redis memory management ZMALLC.C Source code interpretation (appendix): Source Structure table

The cornerstone of Redis memory management ZMALLC.C Source code interpretation (a) The cornerstone of Redis memory management ZMALLC.C Source code interpretation (ii) The previous two posts, detailed introduction of the Z

Redis Source Analysis (25)---zmalloc memory allocation implementation

Time passed quickly, after 1 months of time to learn, I Redis source code analysis has been more than half of the previous study, I mainly for the Redis tool class code to learn. The next few days I'm going to learn about the impl

Tomcat source code analysis-component startup implementation analysis, tomcat source code analysis component

Tomcat source code analysis-component startup implementation analysis, tomcat source code analysis component Tomcat is composed of multiple components. How does Tomcat manage its lifecy

. Net Core Cache Component (Redis) source code parsing

, indicates a permanent cache return New string[] {"value1","value2" }; }}Third, source code analysis Source code in the Github.com/aspnet/caching,redis source is relatively simple, mai

Redis Source Analysis (7)--rdb

between different buckets). Take a look at the RDB-related content below.1. rdb file formatThe Rdb file format is relatively simple and can be seen as a sequence of instructions, consisting of each instruction:|-----------------------|----------------------------------|| OP Code:1byte | Instruction:nbytes ||-----------------------|----------------------------------|When an RDB is loaded, this sequence of instructions is parsed. All op

JDK source code-AQS source code analysis, jdk source code aqs

JDK source code-AQS source code analysis, jdk source code aqs Unless otherwise specified, all the articles on this site are original. For reprinted articles, enter the address. Abstrac

Redis Source Analysis (2)--Event loop

>= Te->when_ms)) {//In the callback handler, it is possible to add a new timer event, if you continue to join, there is a risk of a dead loop, so you need to avoid this situation, each cycle does not handle the newly added events, which is implemented by the following code. if (Te->id > Maxid) { te = te->next; Continue; }The event Loop section is analyzed to the end, feeling more intuitive, clear, comple

YII Source Code Analysis (2), yii Source Code Analysis _ PHP Tutorial

YII Source Code Analysis (2): yii source code analysis. YII Source Code Analysis (II): yii

YII Source Code Analysis (III), yii Source Code Analysis _ PHP Tutorial

YII Source Code Analysis (3): yii source code analysis. YII Source Code Analysis (3). yii

Compile the source code on CentOS5/Redhat5 to install Redis

Compile the source code on CentOS5Redhat5 and install Redis | InstallRedisonCentOS5Redhat5 Compile the source code on CentOS 5/Redhat 5 to Install Redis | Install Redis on CentOS 5/Redh

Total Pages: 15 1 .... 3 4 5 6 7 .... 15 Go to: Go

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.