Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Method and system for realizing redis automatic master-slave switching

A master-slave, automatic technology, applied in the direction of transmission system, electrical components, input/output to record carrier, etc., can solve problems such as error-prone, inability to implant business logic, and inability to record the cause of business logic monitoring problems.

Active Publication Date: 2018-02-16
BEIJING JINGDONG SHANGKE INFORMATION TECH CO LTD +1
View PDF5 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

In this solution, the Keepalived software needs to be installed separately, and the scripts and configuration files described in the configuration solution need to be configured, which increases the learning cost and is prone to errors; the localization strategy must be enabled on both the master and the slave, otherwise it will not be enabled during the automatic switching process. The localized party will clear the data of the other party, resulting in complete data loss; it cannot implant the business logic of its own system, and can only perform stateless monitoring and master-slave switching, for example, monitoring with specific business logic cannot be achieved And the record of the cause of the problem when the master-slave is switched; it is inconvenient to add a new Redis machine later, and the configuration file needs to be changed

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and system for realizing redis automatic master-slave switching
  • Method and system for realizing redis automatic master-slave switching

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0027] The following description with reference to the accompanying drawings is provided to assist in a comprehensive understanding of exemplary embodiments of the present invention. It includes various details to facilitate understanding and they should be regarded as exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted for clarity and conciseness.

[0028] figure 1 It is an architecture diagram of a system for realizing Redis automatic master-slave switching according to an embodiment of the present invention.

[0029] The Redis cache control center 110 is used to store configuration information, register services with the broadcast service framework 120, monitor the Redis node 140, and change the master-slave configuration infor...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention provides a method and a device for achieving automatic Redis master-slave conversion. The device includes a Redis cache control center, a broadcasting service framework, subsystems and Redis nodes. The Redis cache control center is used for storing configuration information, providing registration service for the broadcasting service framework, monitoring the Redis nodes, changing master-slave configuration information in a memory when a Redis master server is not alive and sending master-slave conversion commands to the broadcasting service framework. The broadcasting service framework is used for obtaining the broadcasting conversion commands of each subsystem of Redis linkage information from the Redis cache control center after receiving the master-slave conversion commands from the Redis cache control center. The subsystems are used for conducting master-slave conversion after receiving broadcasting of the broadcasting service framework. The Redis nodes serve as a cache layer between the subsystems and a database.

Description

technical field [0001] The invention relates to a method and system for realizing Redis automatic master-slave switching. Background technique [0002] At present, in order to solve the performance problems caused by high concurrency, web application systems will adopt a cache layer between the web application system and the database. The most widely used is Redis (Redis is essentially a key-value type memory database). Due to its high performance and simple operation commands, Redis can be used as a buffer between software and traditional databases, ensuring high performance while ensuring data validity. [0003] At present, Redis only supports master-slave backup, but the released version does not support automatic master-slave switching after encountering problems. At present, there are mainly two solutions for this: [0004] The first solution uses Redis double writing, which is performed by writing two copies of the application server. In this solution, the consistenc...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Patents(China)
IPC IPC(8): H04L29/06H04L29/08G06F3/06
CPCG06F3/06H04L67/02
Inventor 罗炜杜维胡峰叶长根
Owner BEIJING JINGDONG SHANGKE INFORMATION TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products