What's Redis?
Redis is an open-source, Key-value database that is written in C, that supports network interaction, and can be based on memory and persistence.
Redis's official website address, very good remember, is Redis.io. (specially checked,
ways to implement transactionsmulti (Open transaction) +exec (commit) +discard (Discard transaction) +watch (CAS optimistic lock) Lua script
the characteristics of Redis affairsAll methods in a transaction are executed serially, the execution is not
Message Notification
Task Queues
Benefits of using task queuesLoose coupling. Producers and consumers do not need to know each other's implementation details, just agree to a good description of the task format. This allows producers and consumers
Redis-cluster Research and use
Blog Categories:Redis Redis Cluster Distributed storage Recent research Redis-cluster, just set up an environment, encountered a lot of pits, the system's summary, wait until REDIS3 release, replace Memcache cluster.
#最近在研究NOSQL中的Redis的安装以及连接服务器
Preparation: Windows working platform, redis database, please download the website and extract it to the local disk to install the Redis process I do not detail: The following two pictures
let's go to the second
Overview
In the actual development process will often encounter some time-sensitive data, such as limited time discount activities, caching or verification code, and so on. After a while, you need to delete this data. In a relational database, you
one: About Redis cluster
the present situation of 1:redis cluster
Reids-cluster plans to launch in redis3.0, can be regarded as a Antirez statement: HTTP://ANTIREZ.COM/NEWS/49 (PS: Skip the ticket for a long time, this year seems to speed up), the
dear friends, long time no see. Has not been updated recently, because the company's project has been catching progress, but also table structure replacement, and refactoring, but also iterative requirements. Feel the project is going to be rotten ..
Affairs
Ømulti,exec action: Start and end tag of transaction
N executes the multi command, Redis feedback OK indicates the start of the transaction, executes the EXEC command, ends the transaction, and begins the sequential execution of the
Redis Cluster Add node
1: Start the node that needs to be added first
cd/usr/local/cluster/mkdir 7006cp/usr/local/cluster/redis.conf/usr/local/cluster/7006/cd/usr/local/cluster/7006/VI redis.conf# The value of the port parameter in
Redis Implement distributed lock
In the cluster and other multiple servers often used to synchronize the business, then the ordinary transaction is to meet the needs of the business, the need for distributed locks. Distributed locks are implemented
Redis Data backup and recovery
Persistence of
RDB Mode (default)
The persistence of the RDB approach is accomplished through snapshots (snapshotting), and Redis automatically snaps and stores all data in memory to the hard disk when certain
Before you say Redis persistence, you need to figure out what the concept of database state is, because the persistence is to save the state of the database in memory to disk. So what is the database state? Redis is a key-value database server,
Although Redis has excellent performance, we can still master/slave this simple architecture, read and write separation, further mining redis performance, improve system availability.
Redis How to do master and slave copy. Redis replication is
Redis is a distributed NoSQL database system oriented to "Key-value" type data, which has the advantages of high performance, persistent storage, and adapting to the highly concurrent application scenarios. Although it started late, but the
First, NoSQL introduction
1, NoSQL (NoSQL =not only sql), meaning that "not only SQL", is a new database revolutionary movement, it was suggested in the early days, the trend of development to 2009 has become increasingly high.
2, NoSQL, refers to
# Redis configuration file
# When you need to configure the memory size in the configuration, you can use similar formats such as 1k, 5GB, 4M, which are converted as follows (case-insensitive)
#
# 1k =>
1000 bytes
# 1kb => 1024 bytes
# 1m => 100000
Http://www.cnblogs.com/stephen-liu74/archive/2012/02/23/2364717.html
first, the replication of Redis:The first thing to note here is that it's so easy to configure the Master-slave mode in Redis. Believe that after reading this blog you can also
Exception content:
Redis.clients.jedis.exceptions.JedisConnectionException:java.net.SocketTimeoutException:Read timed out at Redis.clients.jedis.Protocol.process (protocol.java:79) ~[jedis-2.1.0.jar:na] at Redis.clients.jedis.Protocol.read
installing Redis under Linux systemsFirst step: Download Way 1:http://www.redis.cn/Download from official website Click to download the following screen appears.--------------------------------------------------------------------------------
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.