Distributed complex lock realization method, terminal, server and computer readable storage medium

An implementation method and distributed technology, applied in the field of communication, can solve problems such as the inability of existing solutions to meet business requirements

Inactive Publication Date: 2017-09-05
NUBIA TECHNOLOGY CO LTD
View PDF3 Cites 3 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] In the process of realizing the present invention, the inventors found that the existing technology has the following problems: the existing technology is a solution for locking a single competing resource, and when an operation needs to operate multiple competing resources at the same time, the existing solution cannot satisfy the business need

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
  • Distributed complex lock realization method, terminal, server and computer readable storage medium
  • Distributed complex lock realization method, terminal, server and computer readable storage medium
  • Distributed complex lock realization method, terminal, server and computer readable storage medium

Examples

Experimental program
Comparison scheme
Effect test

no. 1 example

[0069] Such as image 3 As shown, a method for implementing a distributed complex lock provided in the first embodiment of the present invention, the method includes steps:

[0070] 30. The terminal sends a complex lock acquisition request containing multiple competing resources to the server.

[0071] 31. The server receives the complex lock acquisition request sent by the terminal, and splits the complex lock acquisition request containing multiple competing resources into multiple lock obtaining requests containing a single competing resource.

[0072] In this embodiment, by splitting the complex lock into multiple single locks, the synchronization operation on multiple competing resources can be satisfied.

[0073] 32. The server sends all lock acquisition success responses containing a single competing resource to the terminal.

[0074] Please refer to Figure 4 As shown, in this embodiment, step 32 specifically includes:

[0075] 320. Attempt to acquire one of multip...

no. 2 example

[0093] refer to Figure 6 , Figure 6 A terminal provided by the second embodiment of the present invention, the terminal 40 includes a memory 41, a processor 42, and an implementation program of a distributed complex lock stored in the memory 41 and operable on the processor 42. When the implementation program of the distributed complex lock is executed by the processor, the following steps are realized:

[0094] Send a complex lock acquisition request to the server with multiple competing resources;

[0095] Receive all locks containing a single competing resource from the server and acquire a successful response, and acquire all locks containing a single competing resource;

[0096] Wherein, the server receives the complex lock acquisition request sent by the terminal, splits the complex lock acquisition request containing multiple competing resources into multiple lock acquisition requests containing a single competing resource; sends all the lock acquiring requests cont...

no. 3 example

[0115] Such as Figure 7 as shown, Figure 7A server provided by the third embodiment of the present invention, the server 50 includes a memory 51, a processor 52, and an implementation program of a distributed complex lock stored on the memory 51 and running on the processor 52 , when the implementation program of the distributed complex lock is executed by the processor 52, the following steps are implemented:

[0116] Receive a complex lock acquisition request sent by the terminal that contains multiple competing resources;

[0117] Split the received complex lock acquisition request containing multiple competing resources into multiple lock acquisition requests containing a single competing resource;

[0118] In this embodiment, by splitting the complex lock into multiple single locks, the synchronization operation on multiple competing resources can be satisfied.

[0119] All lock acquisition success responses containing a single competing resource are sent to the term...

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 discloses a distributed complex lock realization method, a terminal, a server and a computer readable storage medium. The method includes the following steps that the terminal sends a complex lock acquisition request containing a plurality of competitive resources to the server; the server splits the complex lock acquisition request containing the competitive resources into multiple lock acquisition requests containing a single competitive resource, and sends all responses succeeding in acquiring locks including the single competitive resource to the terminal; the terminal receives all the responses succeeding in acquiring the locks including the single competitive resource from the server, so as to acquire all locks containing the single competitive resource. Synchronous operation of a plurality of competitive resources is realized by dividing the complex lock into a plurality of single locks; each competitive resource corresponds to only one lock, and simultaneous operation of different types of competitive resources can be supported; with a lock monitoring mode, efficiency of trying to acquire locks again is improved, and system resources are saved.

Description

technical field [0001] The present invention relates to the field of communication technology, in particular to a method for realizing a distributed complex lock, a terminal, a server and a computer-readable storage medium. Background technique [0002] With the rapid development of mobile communications and the mobile Internet, a large number of users use the mobile Internet to access and process Internet services. In this way, massive concurrent processing load pressure is generated on the server of the mobile Internet services. In order to meet the high concurrency performance requirements, the architecture of the server side of the Internet business adopts a distributed cluster, and at the same time, the server side has the ability to expand horizontally. In a distributed server-side architecture, how to ensure the lock processing of resource competition among multiple servers has become the primary problem. [0003] In the process of realizing the present invention, th...

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
IPC IPC(8): G06F9/52H04L29/08
CPCG06F9/526H04L67/10
Inventor 黄萍峰
Owner NUBIA TECHNOLOGY CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products