the general method to realize the cross-service ranking
In order to stimulate the players in the game of comparison psychology, often have a variety of rankings. The list can also be divided into the list of this service and cross-service rankings.
The PHP project needs a message queue, and finally to simply select the Redis List.
Redis Documents in Chinesehttp://redisdoc.com/On the premise that the Redis server has been started. 1. Connection Redis
$redis = new Redis ();
$redis->connect ("127.
In the case of running, Redis saves data in memory as a structure, and in order for data to be available after Redis restarts, Redis provides two ways to persist the RDB and aof, this article explains how RDB persistence works
At run time, Redis
Redis Command Reference»
Sentinel
This document is translated from: Http://redis.io/topics/sentinel.
The Redis Sentinel system is used to manage multiple Redis servers (instance) that perform the following three tasks: monitoring (monitoring):
The Spring-data-redis Project (SDR) provides a higher level of abstraction for Redis's Key-value data store operations, similar to the spring framework for JDBC support.
Project home: http://projects.spring.io/spring-data-redis/
Project Document:
[+] Overview
The power of Redis is largely due to the fact that all data is stored in memory, but when Redis restarts, all data stored in memory is lost and in many cases it is intolerable. So, we need to persist the in-memory data. The typical
1. Demand Analysis
The author's project has a check-in function: A user can only sign in once a day, but in the case of concurrency, a user may be able to check in several times a day, in this case, the first thing I think of is the use of Redis
One, install the JDK1.rpm-qa | grep JDK detects if JDK is installed2.rpm-e--nodeps The name of the existing JDK to uninstall3.TAR-ZXVF jdk-7u71-linux-i586.tar.gz Decompression JDK4.MV jdk-7u71-linux-i58//usr/local/src/java/jdk1.7 moved
Master-Slave concept
A master can have multiple slave, a slave? can have multiple slave, so go on, form a strong? Multi-level server cluster architecture
Master used to write data, slave used to read data, statistics: the website read
1. Installing homebrew
What is homebrew?Official explanation:Homebrew is the simplest and most flexible way to install UNIX tools that Apple does not include in MacOS.Official website: PortalGit repository Address: Portal
How do I install the
Import RedisR=redis. Redis (host= ' 192.168.56.102 ', port=6379,db=0,password= ' Jinxfredis ')R.set (' name ', ' Jin ')Print (R.get (' name '))Python remote connection Redis times the following error:DENIED Redis is running in protected mode because
Hiredisis a simple C client library of the Redis database. It is minimalist because it only adds minimal support for the Protocol, but at the same time it uses a high-level printf-like API, so it is very easy to use for C programming users
Installation of 1.redis: http://www.runoob.com/redis/redis-install.html2. Test if you can log in remotelyUse the Windows Command window to enter the Redis installation directory and use the command to remotely connect Centos7 Redis:Redis-cli-h 192.16
Project from a single-node environment to a clustered environment, this time to ensure that the project's scheduled tasks at the same time can only be run in one of the servers in the cluster, but can not write dead on which server to run, how to
Collection as a non-repeating listUnordered collectionSadd (name,values): Add an element to the collection that corresponds to nameSmembers (name): Gets all members of the collection that the name corresponds to127.0.0.1:6379> Sadd name John Jack
These two days in the company intranet home, the information is obtained from other systems, the product originally intended to directly on the static page, JSONP asynchronous fetch data. But one jsonp comparison pit (has not liked), and secondly,
Exception: Sending command to Master in replication handshake:-writing to Master:unknown error;Solution to the conclusion:The IP address written from the slaveof of the database is the same as the bind first parameter of the primary
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.