In Jedis development, we often want to put an object directly into the Redis and then take it out when needed. Redis key and value both support binary secure strings, storing Java objects is not a problem, let's look at how to implement it.
1
Someone asked me, Redis multiple databases, is not the start of multiple Redis processes, listening to different ports. At some level, this can be considered, but not recommended.
1,redis Database
The number of Redis databases is set dead in the
0. What is Redis
Redis is an open source, with the ANSI C language, support network, can be based on memory can also be persistent log-type, Key-value database, and provide a variety of language APIs
1. Compare with other user state save scheme
As an application of NoSQL database, Redis is more efficient in response and hit rate. The project needs to use a centralized scalable caching framework, do a little research, even if redis, memcached existing efficiency differences (specific
Example
Objective: To copy the Redis data on the server CentOS to the Mac
Steps:
Find the dump file location on the CentOS
vi/etc/redis.conf
dbfilename Dump.rdb
Dir/var/lib/redis
Description file in
/var/lib/redis/dump.rdb
This article mainly introduces the use of Redis to achieve SQL scaling, including the lock and time series to improve the performance of traditional databases, the need for friends can refer to.
Ease of line Competition
We used the sentry.buffers
Redis version
Copy Code code as follows:
[Root@localhost ~]# Redis-server--version
Redis server v=2.8.19 sha=00000000:0 malloc=jemalloc-3.6.0 bits=32 build=e2559761bd460ca0
List is a list structure, the main function is
First, overview:
In Redis, we can look at a set type as an unordered character set, and like the list type, we can also perform actions such as adding, deleting, or determining whether an element exists on that type of data value. It should be
Session information into Redis
Session Introduction
session, Chinese often translated as a conversation, its original meaning is the beginning and end of a series of actions/messages , such as phone calls from the pick up the phone to hang up the
This article describes the method of compiling Redis and Phpredis under Linux. Share to everyone for your reference, specific as follows:
1. Preparation work
Download software: This site download the address.Operating system: CentOS 5.5Redis
2.MONGODB installation Configuration Simple LearningConfiguring the database path allows the MONGO command to perform an interactive operation: Start the server first, and perform an interactive operation with a CMD1) Increase and deletion
Redis supports five types of data: string (String), hash (hash), list, set (set), and Zset (sorted set: Ordered set)I: String (String)The string is the most basic type of redis, and you can understand it as a type that is identical to memcached, a
Not much nonsense.Project structurePom.xml configurations such as the following4.0.0testspringmvc_ Spring_jpa0.0.1-snapshotjarspringmvc_spring_jpahttp://maven.apache.orgutf-84.0.0.release1.8.0.release1.2.25.1.21 1.6.110.9.5 -pre31.7.21.2.164.11
1. Build the cluster, shut down the virtual machine firewall, or iptables parameters to allow the Redis cluster port to passService iptables stop or Vim/etc/sysconfig/iptables2. Test cluster (does not integrate spring)@Test Public
First, install a software called composer.Install the process has a choice button called Browe Choose your phpstudy inside the PHP inside of the php5.6.27 inside ext php.exe (like), (version preference php5.6),Then the idiot installs open cmd,
REDIS all the commands.>Lpop key: Delete and get a list header elementRpop key: Deletes and obtains an element of the list tailBlpop key [key ...] timeout: delete and get the list header an element, if not on the blockBrpop key [key ...] timeout:
Create a new Folder "Redis" on the D drive, unzip the Redis Zip package and unzip all the files into the Redis folder. (Other drive characters can also drip ^_^)File Description:Redis-benchmark.exe #基准测试Redis-check-aof.exe # AOFRedischeck-dump.exe #
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