First, set key, and get
172.16.9.24:6379> set name Tom
172.16.9.24:6379> gets name
Two, delete key, which is used to delete key when key exists
172.16.9.24:6379> del name
three, serialized key
172.16.9.24:6379> dump name
Four, checking for the
Redis is a key-value storage system. Like memcached, it supports a relatively larger number of stored value types, including string (string), list (linked list), set (set), and Zset (ordered set). These data types support Push/pop, Add/remove and
1.string
The string in Redis is a sequence of bytes. The strings in Redis are binary safe, meaning that their lengths are not determined by any particular terminating character. As a result, you can store anything up to 512 megabytes in a
Redis's excellent performance is because it stores all the data in memory, the same memcached do, but why Redis can stand out, largely because Redis has excellent persistence mechanism to ensure that the server restart, the data will not be lost.
This blog post mainly describes how to implement cache development using SPRINGAOP + Redis + annotations. First, term description 1, Springaop AOP (Aspect oriented programming), the technology of aspect-oriented programming. AOP is a useful
Redis is a commonly used database of non relational types.So we also need to know some of his common operating instructions.
Redis data types are mainly divided into strings, hashes, lists, sets, and so on.
String set--set name 1234//Set key
Through a brief introduction of the previous article "Redis simple Use", this article mainly elaborates the five types of operation of Jedis to Redis: string, list, hash, set, ordered set. Jedisutil
The test cases here are run using JUNIT4,
Redis Cache Server NotesRedis is a high-performance key-value storage system that can serve as a caching framework and queueBut since he is a memory memory system, the data is stored in the database
As a caching framework:create/updae/delete-at the
Overall Thinking
There have been previous Mybatis+redis integration in the Spring Environment (http://blog.csdn.net/xiadi934/article/details/50786293). Here we try the integration in spring boot, where some of the points of attention are different.
Redis Common Command set
1 Connection operation Command quit: Close the connection (connection) Auth: simple password Authentication help cmd: View cmd assistance, for example: helping quit
2 Persistent Save: Synchronize data to disk Bgsave:
Here is the configuration I used, using master-slave mode, turning off all persistence on master, and using aof persistence on slave:$cat/opt/redis/etc/redis.conf
##### #Master Config
# # #General Configuration
Daemonize Yes to run the program
Original address: Http://futeng.iteye.com/blog/2071867?utm_source=tuicool
Redis Source Download Address: http://download.csdn.net/detail/haitunxiaomo/8647255
Part I. Direct start
installation
Shell code:
The tar zxvf redis-2.8.9.tar.gz
Redis does not directly support indexing and needs to be maintained by itself.
For a range-only index, we can simply save the index as a kv pair, and V save the main key,
A range retrieval, or a Redis index, is implemented using the Zset of the
first, there are two ways of Redis persistence:
1.RDB: Snapshots of In-memory database state
2.AOF: Write every write command to the file, similar to the MySQL binlog log
RDB: Save the Redis in-memory database state to disk, RDB file is a
A
1, Twemproxy explore
When we have a large number of Redis or Memcached, it is usually only through some data allocation algorithms (such as a consistent hash) of the client that the characteristics of the cluster storage can be realized. Although
Redis capacity and usage planningIn the use of Redis process, we found that a lot of redis different from the memcached, but also different from the characteristics of MySQL.
(This article mainly discusses Redis is not enabled for VM support) 1.
Reference site: http://blog.nosqlfan.com/html/4077.html
This article comes from the gentle one knife sharing, introduced he in the actual work encounters some redis problems as well as the corresponding evasion and the solution, if you also use
At present, to enable the web to adapt to large-scale access, the application of the cluster deployment needs to be implemented. Cluster is the most effective solution is load balancing, and the implementation of load-balanced users are likely to be
Redis the operation of the String,list,hash,set,zset data type by the tool class. Add Dependencies
org.springframework.boot
Spring-boot-starter-data-redis
Redis Configuration
Import org.springframework.beans.factory.annotation.Autowired;
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.