Evolution based on session login

1. Send mobile phone verification code: Submit mobile phone number-check mobile phone number-generate verification code->save to session->send verification code public Result sendCode(String phone, HttpSession session) { // 1.Verify phone number Boolean phoneInvalid = RegexUtils.isPhoneInvalid(phone); // 2.If not, ...

Posted by ferpadro on Sat, 26 Nov 2022 17:52:21 +0300

[Redis] Redis basics of redis learning

This article is mainly to learn Dark horse programmer Redis entry to actual combat tutorial, in-depth analysis of the underlying principle of redis + redis distributed lock + enterprise solution + dark horse comment on the actual project income from 1 Introduction to Redis Redis is a key-value NoSql database. The key-value type means ...

Posted by Bulbe on Wed, 09 Nov 2022 20:22:25 +0300

redis protocol and asynchronous mode

The artic l e refers to the C/C++linux service period advanced architecture system tutorial of <Zero Voice Education> to learn: Server high-level architecture 1. redis network 1.1, redis network Micro: reactor Composition: IO multiplexing + non-blocking IOIO Responsibilities: IO Detection and IO OperationsEvent: Asynchronous event ...

Posted by depraved on Tue, 18 Oct 2022 18:17:04 +0300

Redis installation and startup (the latest nanny tutorial in 2022)

Redis installation and startup Redis official website address: https://redis.io/ 1. Install Redis on a single machine 1.1. Install Redis dependencies Redis is written based on the C language, so first you need to install the gcc dependencies required by Redis: yum install -y gcc tcl 1.2. Upload the installation package and extract it If ...

Posted by David Rech on Sun, 16 Oct 2022 01:32:58 +0300

Detailed explanation of Redis caching problems

cache penetrationCache penetration means that the data requested by the client does not exist in the cache and the database, so the cache will never take effect, and these requests will hit the databaseIf a malicious user uses countless threads to concurrently access non-existent data, these requests will all reach the database, which is likely ...

Posted by bliss322 on Sun, 25 Sep 2022 21:01:59 +0300

Redis advanced practice

Redis advanced practice transaction management Comparison between redis and mysql redis slow log queryredis high availability and cluster redis master-slave replication Synchronization mechanism**Master slave replication principle****Command propagation**SYNC and PSYNCConsistency of redis replication ...

Posted by ben2.0 on Sat, 27 Aug 2022 14:01:57 +0300

Cache elimination algorithms LRU and LFU

Caching is a computer thinking. For repeated calculations, cache the results. The next time you calculate this task, you don't go to the real calculation, but directly return the results, which can speed up the processing speed. Of course, for some things that will change over time, the cache will fail and have to be recalculated. For example, ...

Posted by fiztec on Wed, 25 May 2022 21:58:16 +0300

spring boot: use redis+lua to limit the frequency of sending SMS verification codes (spring boot 2.3.2)

1. Why limit the sending frequency of SMS verification codes? 1, SMS verification code Each SMS has cost constraints, Certainly can not be brushed the random hair of the interface And the interface is brushed will affect the user's experience, Affect the normal access of the server, So even with the protection of graphic verification codes, etc ...

Posted by shashiku on Wed, 25 May 2022 21:42:39 +0300

redis-cluster is built according to wiki learning records, adding and deleting nodes, and failover

Node planning Three masters and three slaves master slave node-1 192.168.0.142 6379 192.168.0.142 26379 node-2 192.168.0.143 6379 192.168.0.143 26379 node-3 192.168.0.144 6379 192.168.0.144 26379 16379 Messaging port 36379 Messaging port Directory Planning installation manual /usr/local/redis4 config file directory /u ...

Posted by RTT on Wed, 25 May 2022 09:21:28 +0300

Cluster node management of Redis service

The previous blog mainly talked about the deployment configuration of redis cluster, the construction of the ruby ​​environment required by the redis.trib.rb tool, the creation of the redis.trib.rb tool, and the viewing of cluster-related information. For a review, please refer to https://www.cnblogs.com/qiuhom-1874/p/13442458.html ; Today we w ...

Posted by GB_001 on Mon, 23 May 2022 22:14:20 +0300