1. 2.1 Redis BloomFilterhistorical

    A Redis-based BloomFilter implementation idea using BitMaps and automatic expansion.

  2. 2.2 Redis RateLimiterhistorical

    A Redis-based rate limiter using a counter algorithm and Lua scripts.

  3. 2.3 Redis Data Structureshistorical

    1. Redis DB - redisDb is the data structure used by Redis to represent a DB and contains a dict; dict is the K-V data structure in Redis and contains dictht; dictht is an array whose elements are dictEntry nodes; dictEntry.next uses chaining to resolve hash collisions

  4. 2.4 Redis Asynchronous Queuehistorical

    Simple Redis asynchronous-queue patterns with lists, blocking pop, Pub/Sub, and sorted sets.

  5. 2.5 Redis Distributed Lockshistorical

    1. What is a Redis distributed lock - A distributed lock implemented based on Redis 2. Redis distributed lock implementation 2.1. Single instance 2.1.1. Locking - Set a key when it does not exist - SET NX guarantees atomicity - The key guarantees mutual exclusion - The value guarantees that locking and unlocking are performed by the same client

  6. 2.6 Redis Key Design Tipshistorical

    1. MySQL -> Redis 1.1. Single table - Primary key column: set table-name:primary-key-name primary-key-value - Other columns: set table-name:primary-key-name:primary-key-value:column-name column-value 1.1.1. User table: query a record by primary key

  7. 2.7 Redis Commandshistorical

    1. Redis general commands - keys pattern queries matching keys - Redis supports fuzzy key matching with three wildcards: *, ?, [] - * matches any number of characters - ? matches one character - [] matches one character inside the brackets - redis-cli can only query data on the current node - SCAN cursor