Request timeout processing method and device, terminal and storage medium
A timeout processing and processor technology, applied in multi-programming devices, electrical digital data processing, program startup/switching, etc., can solve problems such as slow requests, increased back-end system load, avalanche effects, etc., to reduce additional burdens, The effect of improving processing density and reducing trigger frequency
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0037] Such as figure 1 As shown, this embodiment provides a request timeout processing method, including the following steps:
[0038] S1, when a front-end request is received, determine whether there is a task with the same request being processed;
[0039] S2, if not, create task information and perform task processing;
[0040] S3, if there is, save the request response, and feed back the processing result to the front end after the task corresponding to the same request is processed.
[0041] Through the above method, when a request takes a long time to process, when the request generated by the retry mechanism is sent to the backend again, since the same request is already being processed at the backend, the backend will respond to the new request (referring to the request generated by the retry mechanism) ) will only save the request response and will not trigger a new task. After the task processing of the first request is completed, the processing result will be fed...
Embodiment 2
[0053] Such as image 3 As shown, in combination with Embodiment 1, this embodiment provides a request timeout processing device, including the following functional modules.
[0054] Request receiving processing module 101: receiving the request sent by the front end, and judging whether there is a task with the same request being processed;
[0055] Task information establishment module 102: establish task information;
[0056] Processing control module 103: perform task processing;
[0057] Response saving module 104: when the same request task is being processed, save the request response to the newly received request;
[0058] Response control module 105: Feedback the processing result to the front end after the processing of the request task is completed.
[0059] In this embodiment, the task information establishment module 102 also sets the processing callback and response callback of the task information; wherein the processing callback defines the specific process ...
Embodiment 3
[0065] This embodiment provides a terminal, and the terminal includes a processor and a memory.
[0066] The memory is used to store instructions for the processor to execute. Memory can be implemented by any type of volatile or non-volatile storage terminals or a combination of them, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Read Only Memory (PROM), Read Only Memory (ROM), Magnetic Memory, Flash Memory, Magnetic Disk or Optical Disk. When the execution instructions in the memory are executed by the processor, the terminal is enabled to execute some or all of the steps in the foregoing method embodiments.
[0067] The processor is the control center of the storage terminal, using various interfaces and lines to connect various parts of the entire electronic terminal, by running or executing software programs and / or modules stored in the memory, and call...
PUM
Abstract
Description
Claims
Application Information
- R&D Engineer
- R&D Manager
- IP Professional
- Industry Leading Data Capabilities
- Powerful AI technology
- Patent DNA Extraction
Browse by: Latest US Patents, China's latest patents, Technical Efficacy Thesaurus, Application Domain, Technology Topic, Popular Technical Reports.
© 2024 PatSnap. All rights reserved.Legal|Privacy policy|Modern Slavery Act Transparency Statement|Sitemap|About US| Contact US: help@patsnap.com