Analysis of Redis source code -- implementation of SDS
Implementation of SDS
SDS is a simple dynamic string. It is one of the basic data structures of Redis and has a wide range of uses
Overview of basic functions
function
function
Complexity
sdsnewlen
Create SDS from given string
O(N)
sdslen
Return string length
O(1)
sdsdup
Copy an SDS
O(N)
sdsfree ...
Posted by Fantast on Wed, 01 Apr 2020 16:19:05 -0700
Integrating Spring Session with Redis
There are so many specific features of Spring Session. The specific content can be learned from the document. The author makes a summary. The features of Spring Session include but are not limited to the following:
Use GemFire to build httpSession of C/S architecture (not concerned)
Use the third-party warehouse to realize the cluster sessi ...
Posted by ron814 on Wed, 01 Apr 2020 06:13:29 -0700
Under Ubuntu 14.04, install redis-3.2.0 and start up
Download it on the official website Redis -3.2.0.tar.gz, put redis-3.2.0.tar.gz in the / opt directory
Unzip redis-3.2.0.tar.gz
xiaoyao@xiaoyao-virtual-machine:/opt$ sudo tar -zxvf redis-3.2.0.tar.gz
Compile redis
xiaoyao@xiaoyao-virtual-machine:/opt$ cd redis-3.2.0/
xiaoyao@xiaoyao-virtual-machine:/opt/redis-3.2.0$ sudo m ...
Posted by hoopplaya4 on Tue, 31 Mar 2020 13:28:41 -0700
Installing jdk1.7 under Linux
1. Download jdk7 (download it on the official website)
Download address: http://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-javase7-521261.html
1.1 before downloading, check whether the system is 32-bit or 64 bit
[root@redis ~]# getconf LONG_BIT
64
I am 64 bit here, so I choose to downloa ...
Posted by fr600 on Tue, 31 Mar 2020 12:36:03 -0700
Netflix Zuul service gateway of Spring Cloud series
What is Zuul
Zuul is the front door for all requests from devices and websites to the back end of the application. As an edge service application, zuul aims to realize dynamic routing, monitoring, flexibility and security. Zuul includes two main functions of request routing and filtering.
Zuul is the open-source microservice gateway of Ne ...
Posted by doucie on Mon, 30 Mar 2020 21:01:30 -0700
redis master-slave configuration (one master-many slave)
Introduction of Master and Subordinate
redis installation
1. Master-Subordinate-Usage
Like MySQL, redis support master-slave synchronization, as well as a master-slave and multilevel slave structure.
The primary-slave architecture is designed for purely redundant backups, and for improved read perf ...
Posted by SpaceLincoln on Sat, 28 Mar 2020 10:36:48 -0700
Java integrated Alibaba big fish platform SMS service sending verification code -- supplement registration part
It's still the previous chart
1, back end
Server verification needs to be performed again before registration
Is the user name registered
Is the mobile number registered
Whether the verification code is wrong
Whether the verification code is implemented
Password is encrypted with BCrypt
Controller layer
The method of user name verificatio ...
Posted by nexgen_x on Fri, 27 Mar 2020 08:14:08 -0700
One click online installation of redis database by shell script (implemented by function)
The previous article gives the process of manual compilation and installation of redis, and gives the process of online installation of redis when simulating the establishment of redis cluster, so I want to write a redis script for online installation. In this paper, I mainly use shell functions to realize and verify the process of online ins ...
Posted by m!tCh on Wed, 25 Mar 2020 07:48:09 -0700
Laravel6 for third-party WeChat login
At present, many websites will have a lot of interactive functions, which reduces the user's operational difficulty, thus bringing the third-party login of WeChat to the project real-world function development.For the development content in this example, instead of using native content, use the encapsulated class libraries written by others dir ...
Posted by johnoc on Tue, 24 Mar 2020 19:58:08 -0700
Spring Cloud Micro Service Architecture From Getting Started to Getting Used - Service Gateway Authentication
In the previous article, we integrated a service gateway, Spring Cloud Gateway, where all service requests can be accessed through Gateway.We can then authenticate the user's request at the service gateway level to determine whether the routed API interface can be accessed.
So let's start with more authentication, and here we're using jwt
1. Cr ...
Posted by Zero20two on Tue, 24 Mar 2020 10:07:39 -0700