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

Communication system distributed method based on Redis

A communication system and distributed technology, applied in transmission systems, digital transmission systems, electrical components, etc., can solve problems such as high risk of loss, poor reliability of message processing, etc., and achieve the effect of excellent fault handling and guaranteed availability

Active Publication Date: 2020-08-21
CHUANGSHENG SHILIAN DIGITAL TECH BEIJING CO LTD
View PDF10 Cites 10 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0011] The present invention provides a distributed method for a communication system based on Redis, which solves the problems of poor message processing reliability and high risk of loss in the existing RedisPub / Sub topic subscription mode, and its technical solution is as follows:

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
  • Communication system distributed method based on Redis
  • Communication system distributed method based on Redis
  • Communication system distributed method based on Redis

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0031] The present invention provides a distributed method of communication system based on Redis, such as figure 2 As shown, the following architecture is used:

[0032] Including the Nginx cluster connected with the client, the load of the Nginx cluster adopts keepalived, the Nginx cluster is connected with the Gateway gateway cluster, the Gateway gateway cluster is connected with the message processor cluster and the Eureka registration center cluster, and the message processing The server cluster is connected to the Redis cluster and the Sentinel cluster respectively. The following is a detailed description of each cluster:

[0033] 1. Client: Based on the Websocket layer, the full-duplex communication between the client and the server (the message processor service that builds the Websocket service) is realized; by establishing a Websocket long connection, the client can actively send messages to the sending server through the gateway. Message, the server can also acti...

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 communication system distributed method based on Redis. The method comprises the following steps that a client establishes Websocket long connection with a gateway layer of aGateway gateway cluster through an Nginx cluster; the Gateway gateway cluster acquires a message processor cluster acquisition node list and requests a message processor to establish connection; the client sends a message and forwards the message request to a message processor, and the message processor publishes the message to the Redis; for a subscribed client, a publisher Redis Stream structurecan create a corresponding Consumer Group through xadd, and then other clients ensure that a message is reliably consumed through the xadd Group and an ack mechanism. Message pushing and subscriptionservices are integrated to independently form a message processor cluster, and the health state of each node is monitored and subjected to cluster deployment through an Eureka registration center cluster, so an efficient service mode of high availability and distributed cluster deployment is achieved.

Description

technical field [0001] The invention relates to a message system based on a Redis topic subscription mode, in particular to a distributed method of a Redis-based communication system. Background technique [0002] Such as figure 1 As shown, the existing chat system server architecture has largely solved the shortcomings of traditional chat system stand-alone deployment, achieving high availability and dynamic expansion. Using layered thinking, by separating the message flow processor separately, it is used to process the push-pull message flow, forming a separate middleware processor cluster, pushing and subscribing messages to the corresponding channel of the Redis cluster, and then forwarding the message to all other The corresponding client connected to this server. [0003] The deficiencies of prior art solutions: [0004] The existing chat system based on the Redis Pub / Sub topic subscription model still has some shortcomings, which will be analyzed below. [0005] 1...

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 Applications(China)
IPC IPC(8): H04L29/08H04L12/24
CPCH04L67/141H04L67/1023H04L67/1034H04L41/0663H04L67/145H04L67/56
Inventor 王云龙董世永
Owner CHUANGSHENG SHILIAN DIGITAL TECH BEIJING 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