Redis and Redis Sentinel Crash Course – Redis Commands and High Availability tutorial



Redis and Redis Sentinel Crash Course – Redis Commands and High Availability tutorial

Redis and Redis Sentinel Crash Course - Redis Commands and High Availability tutorial

In This tutorial we will talk about Redis and Sentinel high availability. you will have it in 2 parts. Part 1 will all theoretical and the second will have our hands dirty with the code 😀 have fun!.

Github repository: https://github.com/bloodymind/redis-master-slave-sentiel-failover

Part 1
– 00:52: What is Redis?
– 01:42: Redis use cases
– 02:02: Who using Redis in Production?
– 02:50: Redis Sentinel
Part 2
– 04:25: Redis Installation
– 09:30: Redis Important Comands / Strings
– INFO: Return informations and statistics about the server in a format that is simple to parse by computers and easy to read by humans
– KEYS: Returns all keys matching pattern
– SET: Add/update a record
– GET: Gets a single record
– EXISTS: Returns if a record exists or not (0 or 1)
– EXPIRE: Set a timeout on a key. After the timeout has expired, the key will automatically be deleted
– TTL: Returns the remaining time to live of a key that has a timeout
– SETEX: Equivalent to executing SET and EXPIRE
– SETNX: Set a single record if not exists
– INCR: Increment a number by 1
– INCRBY: Increment by a different number
– DECR: Decrement by 1
– DECRBY: Decrement by a different number
– APPEND: Appends the value at the end of a string
– MGET: Gets multiple records
– MSET: Sets multiple record
– DEL: Delete one or multiple records
– 19:15: Redis Important Comands / Hashes
– HSET: Sets field in the hash stored at key to value
– HGET: Returns the value associated with field in the hash stored at key.
– HMGET: Returns the multiple values associated with field in the hash stored at key.
– HMSET: Sets multiple values associated with field in the hash stored at key.
– HGETALL: Returns all fields and values of the hash stored at key
– HINCRBY: Increment by a different number
– HDECRBY: Decrement by a different number
– 24:05: Redis Important Comands / Sets
– SADD: Add the specified members to the set stored at key. Specified members that are already a member of this set are ignored
– SMEMBERS: Returns all the members of the set
– SCARD: Returns the set cardinality (number of elements)
– SISMEMBER: Returns if member is a member of the set stored at key.
– SREM: Remove the specified members from the set stored at key
– 25:58: Redis Important Comands / Sorted Sets
– ZADD: Adds specified members with the specified scores to the sorted set
– ZRANGE: Returns the specified range of elements in the sorted set stored at key. The elements are considered to be ordered from the lowest to the highest score
– ZREM: Removes the specified members from the sorted set stored at key. Non existing members are ignored.
– ZSCORE: Returns the score of member in the sorted set at key.
– 27:54: Redis Important Comands / Pub-Sub
– PUBLISH: Posts a message to the given channel.
– SUBSCRIBE: Subscribes the client to the specified channels.
– 30:06: Redis Important Comands / Transactions
– MULTI: Marks the start of a transaction block. Subsequent commands will be queued for atomic execution using EXEC.
– EXEC: Executes all previously queued commands in a transaction.
– DISCARD: Flushes all previously queued commands in a transaction.
– 31:50: Redis Important Comands / Connection
– AUTH: Request for authentication in a password-protected Redis server.
– PING: used to test if a connection is still alive, or to measure latency. Returns PONG if no argument is provided, otherwise return a copy of the argument as a bulk.
– SELECT: Selectable Redis databases are a form of namespacing.
– 34:46: Slave Master configuration
– 39:49: Sentinel Configuration and Failover test

Comments are closed.