Method and device for deadlock monitoring for application programming interface
An application program interface and deadlock technology, applied in the computer field, can solve problems such as low applicability and ineffective detection
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0108] refer to figure 1 , which shows a flow chart of the steps of an embodiment of an application program interface deadlock monitoring method of the present application, which may specifically include the following steps:
[0109] Step 110, receiving a call request from a client to an API.
[0110] During data encapsulation, each layer in the network layer interacts with each other and provides services through an interface, and the interface between the application layer and the client is called an application program interface. In practical applications, the client can request the system to provide services by calling an application program interface.
[0111] Step 120, creating a deadlock detection node for the call request.
[0112] In the embodiment of the present application, the deadlock detection node is used to save the deadlock detection information of each call request. Among them, API deadlock refers to a phenomenon that in a distributed system, a user calls ...
Embodiment 2
[0128] refer to figure 2 , which shows a flow chart of the steps of an embodiment of an application program interface deadlock monitoring method of the present application, which may specifically include the following steps:
[0129] Step 210, receiving a call request from a client to an API.
[0130] Step 220, when calling the application program interface, create a deadlock detection node in the application program interface context environment data structure.
[0131] In the embodiment of this application, the deadlock detection node will be created in the context data structure of the corresponding API, so that the life cycle of the deadlock detection node is the same as the corresponding API context data structure, and the deadlock detection node The memory space can be allocated in the context environment, so as to avoid frequently calling functions to separately allocate and release memory space for the deadlock detection node. In addition, the deadlock detection node...
Embodiment 3
[0198] refer to image 3 , which shows a flow chart of the steps of an embodiment of an application program interface deadlock monitoring method of the present application, which may specifically include the following steps:
[0199] Step 310, receiving a call request from a client to an API.
[0200] Step 320, creating a deadlock detection node for the call request.
[0201] Step 330, calculating the priority of the deadlock detection node; the priority of the deadlock detection node is the deadline; the deadline is the sum of the creation time of the detection node and the deadlock time threshold.
[0202] In the embodiment of the present application, the first queue for storing deadlock detection nodes is a priority queue. Among them, the priority queue (priority queue) is a collection of 0 or more elements, each element has a priority, and elements with the same priority can be processed in first-in first-out order or according to any priority. For the priority queue, e...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


