CN109697113A - Request method, apparatus, equipment and the readable storage medium storing program for executing retried - Google Patents

Request method, apparatus, equipment and the readable storage medium storing program for executing retried Download PDF

Info

Publication number
CN109697113A
CN109697113A CN201811640170.0A CN201811640170A CN109697113A CN 109697113 A CN109697113 A CN 109697113A CN 201811640170 A CN201811640170 A CN 201811640170A CN 109697113 A CN109697113 A CN 109697113A
Authority
CN
China
Prior art keywords
request
retries
response
retried
requests
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201811640170.0A
Other languages
Chinese (zh)
Other versions
CN109697113B (en
Inventor
杨子国
周健兴
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Cubesili Information Technology Co Ltd
Original Assignee
Guangzhou Huaduo Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Huaduo Network Technology Co Ltd filed Critical Guangzhou Huaduo Network Technology Co Ltd
Priority to CN201811640170.0A priority Critical patent/CN109697113B/en
Publication of CN109697113A publication Critical patent/CN109697113A/en
Application granted granted Critical
Publication of CN109697113B publication Critical patent/CN109697113B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/465Distributed object oriented systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
    • G06F9/485Task life-cycle, e.g. stopping, restarting, resuming execution

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

This application discloses a kind of method, apparatus, equipment and readable storage medium storing program for executing for requesting to retry, and belong to application and development field.This method comprises: sending striding course request;If not receiving the corresponding response of request, the time offset that current request retries is obtained;It is made requests and is retried according to the time offset that current request retries;Wherein, the time offset that current request retries is the time interval of Twice requests, and time interval is dynamically determined according to business scenario.The application is after sending striding course request, if not receiving the corresponding response of request, obtain the time offset that current request retries, it makes requests and retries, since the time offset is dynamically determined according to business scenario, it thus avoids and requests to retry in batches within the set time, improve flexibility and success rate that request retries;And it avoids because service fault causes the load of called terminal to increase.

Description

Request method, apparatus, equipment and the readable storage medium storing program for executing retried
Technical field
This application involves application and development field, in particular to a kind of method, apparatus, equipment and readable storage for requesting to retry Medium.
Background technique
In Distributed Services development process, when the first service A striding course of client calls second service B, it can go out Therefore how the case where now request failure is designed and a kind of the method that retries is requested extremely to be paid close attention at application and development field people The problem of.
In the related technology, when the first service A striding course of client calls second service B, client is sending request When carry a unique sequence number, request failure after request is retried when, according to unique sequence number in fixation Request is retried with fixed number of retries at the same time in time, until client first service A at Function receives response or reaches the upper limit of number of retries.
The relevant technologies the prior art has at least the following problems:
The method that the request retries within the set time at the same time with fixed number of retries to request into Row retries, and requests the flexibility retried poor, success rate is low, thereby increases and it is possible to cause the load of called terminal to increase, and then cause to service Quality vicious circle.
Apply for content
The embodiment of the present application provides a kind of method, apparatus, equipment and readable storage medium storing program for executing for requesting to retry, to solve phase The flexibility that retries of pass technology request is poor, and success rate is low, thereby increases and it is possible to the problem of causing the load of called terminal to increase.The technology Scheme is as follows:
On the one hand, a kind of method for requesting to retry is provided, which comprises
Send striding course request;
If not receiving the corresponding response of the request, the time offset that current request retries is obtained;
It is made requests and is retried according to the time offset that the current request retries;
Wherein, the time offset that the current request retries is the time interval of Twice requests, the time interval root It is dynamically determined according to business scenario.
Optionally, the time offset retried according to the current request makes requests retry after, further includes:
If receiving the request retries corresponding response, ending request is retried.
Optionally, after the ending request retries, further includes:
The response retried is requested to store by described, the response that the request of storage retries is as subsequent same request Response.
Optionally, the method, further includes: obtain number of retries threshold value;
If number of retries reaches number of retries threshold value, ending request is retried.
Optionally, the method, further includes: according to business scenario, dynamically adjust the number of retries threshold value.
Optionally, after the transmission striding course request, further includes:
It receives the striding course and requests corresponding response;
Corresponding response is requested to store the striding course, the response that the request of storage retries is as subsequent phase With the response of request.
On the one hand, a kind of device for requesting to retry is provided, described device includes:
Sending module, for sending striding course request;
First obtains module, if it is inclined to obtain the time that current request retries for not receiving the corresponding response of the request Shifting amount;
Module is retried, the time offset for retrying according to the current request, which makes requests, to be retried;
Wherein, the time offset that the current request retries is the time interval of Twice requests, the time interval root It is dynamically determined according to business scenario.
Optionally, described to retry module, if being also used to receive the request retries corresponding response, ending request weight Examination.
Optionally, described device further include:
First memory module, for requesting the response retried to store for described, the sound that the request of storage retries It should be used as the response of subsequent same request.
Optionally, described device further include:
Second obtains module, for obtaining number of retries threshold value;
Described to retry module, if being also used to number of retries reaches number of retries threshold value, ending request is retried.
Optionally, described device further include:
Module is adjusted, for dynamically adjusting the number of retries threshold value according to business scenario.
Optionally, described device further include:
Second memory module requests corresponding response for receiving the striding course;The striding course is requested corresponding Response is stored, response of the response that the request of storage retries as subsequent same request.
On the one hand, a kind of equipment for requesting to retry is provided, the equipment includes processor and memory, the memory In be stored at least one instruction, described instruction is shown by the processor and is executed to realize what request as described above retried Method.
On the one hand, a kind of computer readable storage medium is provided, at least one instruction is stored in the storage medium, Described instruction is shown by processor and is executed to realize the method for requesting to retry as described above.
Technical solution bring beneficial effect provided by the present application includes at least:
After sending striding course request, if not receiving the corresponding response of request, by obtain that current request retries when Between offset, make requests and retry, since the time offset is dynamically determined according to business scenario, thus avoid request solid Interior batch of fixing time retries, and improves flexibility and success rate that request retries;And it avoids because service fault causes to be called The load at end increases.
Detailed description of the invention
In order to more clearly explain the technical solutions in the embodiments of the present application, make required in being described below to embodiment Attached drawing is briefly described, it should be apparent that, the drawings in the following description are only some examples of the present application, for For those of ordinary skill in the art, without creative efforts, it can also be obtained according to these attached drawings other Attached drawing.
Fig. 1 is implementation environment schematic diagram provided by the embodiments of the present application;
Fig. 2 is the method flow diagram provided by the embodiments of the present application for requesting to retry;
Fig. 3 is the method flow diagram provided by the embodiments of the present application for requesting to retry;
Fig. 4 is game display interface schematic diagram provided by the embodiments of the present application;
Fig. 5 is the apparatus structure schematic diagram provided by the embodiments of the present application for requesting to retry;
Fig. 6 is the apparatus structure schematic diagram provided by the embodiments of the present application for requesting to retry;
Fig. 7 is the apparatus structure schematic diagram provided by the embodiments of the present application for requesting to retry;
Fig. 8 is the apparatus structure schematic diagram provided by the embodiments of the present application for requesting to retry;
Fig. 9 is the apparatus structure schematic diagram provided by the embodiments of the present application for requesting to retry;
Figure 10 is the structural schematic diagram of terminal provided by the embodiments of the present application.
Specific embodiment
To keep the purposes, technical schemes and advantages of the application clearer, below in conjunction with attached drawing to the application embodiment party Formula is described in further detail.
The embodiment of the present application provides a kind of method for requesting to retry, and this method can be applied to implementation ring as shown in Figure 1 In border.In Fig. 1, including at least one terminal 11 and server 12, terminal 11 can be communicatively coupled with server 12, with from clothes The time offset that acquisition request retries on business device 12.
Wherein, terminal 11 can be any one and can be handed over user by keyboard, touch tablet, touch screen, remote controler, voice Mutually or one or more modes such as handwriting equipment carry out the electronic product of human-computer interaction, such as PC (Personal Computer, Personal computer), it is mobile phone, smart phone, PDA (Personal Digital Assistant, personal digital assistant), wearable Equipment, palm PC PPC (Pocket PC), tablet computer, intelligent vehicle device, smart television, intelligent sound box etc..
Server 12 can be a server, be also possible to the server cluster being made of multiple servers, either One cloud computing service center.
Those skilled in the art will be understood that above-mentioned terminal 11 and server 12 are only for example, other are existing or from now on may be used The terminal or server that can occur such as are applicable to the application, should also be included within the application protection scope, and herein to draw It is incorporated herein with mode.
Based on above-mentioned implementation environment shown in FIG. 1, referring to fig. 2, the embodiment of the present application provides a kind of side for requesting to retry Method, this method can be applied in terminal shown in FIG. 1.As shown in Fig. 2, this method comprises:
Step 201, striding course request is sent.
Distributed Services exploitation in, when client receive request after, can striding course send request, and wait request pair The response answered.Wherein, striding course is for carrying out data exchange between different application.
For sending request to second service striding course from first service in same client, when first service is to second When servicing striding course transmission request, i.e., when first service striding course calls second service, if calling is non-idempotent, i.e., repeatedly When the influence of repetitive operation and once-through operation is different, need to guarantee the service-conformance called.
Optionally, after sending striding course request, if receiving striding course requests corresponding response, striding course is asked It asks corresponding response to be stored, the striding course of the storage is requested into response of the corresponding response as subsequent same request.
That is, requesting corresponding sound when client receives striding course after client sends striding course request At once, which terminates, and requests corresponding response to be stored in the memory of client striding course.To work as client In subsequently received identical request, directly fed back the response in client's end memory as its corresponding response.
Wherein, it is contemplated that the limited storage space of memory, method provided by the embodiments of the present application can be to storing in memory Response be ranked up by storage time length or be ranked up by the frequency of use of response, every some cycles, will sort The response of reference quantity rearward is deleted, with the memory space of releasing memory.The period for deleting response can be rule of thumb Setting, or be arranged according to business scenario, the embodiment of the present application is not limited this.After the period for deleting response is set, this The method that application embodiment provides also is supported to be adjusted the deletion period.Once adjustment, then subsequent according to week adjusted Phase periodically deletes response stored in memory.
For example, store 3 responses in memory, it is small to respond when the storage of A a length of 20 by respectively response A, response B and response C When, it responds when the storage of B a length of 12 hours, responds when the storage of C a length of 1 hour, be 24 hours to be to delete the period of response Example deleted the response of sequence rearward every 24 hours, due to the storage time longest of response A, sorted rearward, thus After reaching the period, response A is deleted.
Optionally in addition, storage time in memory can also be reached certain after reaching the period for deleting response The response that length or frequency of use are less than frequency of use threshold value is deleted.
Still to store 3 responses, respectively response A, response B and response C in memory, and the period for deleting response is 24 small When for, if response A frequency of use be 20 times, respond B frequency of use be 2 times, respond C frequency of use be 0 time, use Frequency threshold is 2, then after the period of deletion response for reaching 24 hours, since the frequency of use of response C is not up to frequency of use Threshold value, thus response C is deleted.
Step 202, if not receiving the corresponding response of request, the time offset that current request retries is obtained.
When client do not receive request corresponding response when, from the memory of client obtain current request retry when Between offset.Wherein, the time offset that current request retries is the time interval of Twice requests, and time interval is according to business field Scape is dynamically determined.
It should be noted that illustrating to call serv-fail when client does not receive the corresponding response of request.Wherein, Malloc failure malloc has following three kinds of situations:
Situation one
When first service calls second service, since network cause request is not delivered to second service, request fails, i.e., Malloc failure malloc.
Situation two
When first service calls second service, request is sent to second service, but second service is when carrying out business processing It is abnormal in generation process, cause request to fail, i.e. malloc failure malloc.
Situation three
When first service calls second service, request is sent to second service, and business processing is being just in second service process Often, and successfully transmit response causes response not to be sent to first service due to network problem;Or first service due to Wait-for-response is overtime and disconnects, and does not receive response;Lead to malloc failure malloc.
No matter malloc failure malloc belongs to which kind of above-mentioned situation, after client, which does not receive, requests corresponding response, from client The time offset that current request retries is obtained in the memory at end.Wherein, the time offset that current request retries is to ask twice The time interval asked, i.e., sent the time interval of request apart from last time, and the request that last time sends can be asking for transmission for the first time It asks, is also possible to the request sent when last time request retries.For example, if it is that request retries for the first time that current request, which retries, it should Time interval is the time interval that distance sends request for the first time, should if it is that second of request retries that current request, which retries, Time interval is the time interval that distance requests to retry for the first time.
For example, obtaining the time offset that current request retries from the memory of client is 5s, if last time sends request Time be 10:10:08, then the time that current request retries be 10:10:13.
Further, according to business scenario, the time offset retried dynamic can also be requested to be adjusted to by next 10s, or according to current business scenario, request the time offset retried dynamic to be adjusted to 20s for next.It needs to illustrate , request the dynamic retried to adjust for next, can be adjusted according to business scenario, or carry out based on experience value Adjustment, the embodiment of the present application are not limited this.
Wherein business scenario include but is not limited to current client operation fluency or locating network state, example Such as, when client does not receive the corresponding response of request, and the time offset that current request retries is obtained from memory, according to Operation fluency, that is, payload size dynamic adjustment time offset size of client at present, the operating status of active client It is not smooth, current time offset dynamic can be tuned up;The operating status of active client is smoother, can be by current time Offset dynamic is turned down.Wherein.Judgement for the smooth degree of the operating status of active client, can be according to the hair of request The reaction time for sending or receiving response is determined, or is determined based on experience value, and the embodiment of the present application is not subject to this It limits.
Further, it is also possible to according to the size of current network state dynamic adjustment time offset, such as by network state Five grades are divided into difference from good, are level-one, second level, three-level, level Four and Pyatyi respectively;When current network state is second level When, current time offset dynamic can be adjusted to 10s;It, can be inclined by current time when current network state is level Four Shifting amount dynamic is adjusted to 20s.Wherein, the embodiment of the present application is not limited the method for determination of network state, for example, can root It is determined according to the power of network signal.It, can also be in addition, for the corresponding relationship between network state and current time offset It is set based on experience value, the embodiment of the present application is not limited this.
Step 203, it is made requests and is retried according to the time offset that current request retries.
When client gets the time offset that current request retries from memory, time for being retried according to the request Offset, which makes requests, to be retried.For example, it is 5s that the time offset that current request retries is obtained from the memory of client, if on The secondary time for sending request is 10:10:08, it is determined that the time that current request retries is 10:10:13.Reach 10 when the time: When 10:13, request is retransmitted.
Optionally, make requests retry when, the time migration for repeatedly requesting to retry can be successively obtained according to business scenario Amount, it is subsequent according to the time for requesting the time offset retried to determine that current request retries every time, reach what current request retried After time, request is retransmitted.If receiving request during request retries and retrying corresponding response, ending request retries. For example, getting the time offset for repeatedly requesting to retry, is made requests and retried according to the time offset that current request retries Afterwards, when client, which receives request, retries corresponding response, terminate subsequent request and retry.
Optionally, it receives after request retries corresponding response, method provided by the embodiments of the present application is supported will request weight The response of examination is stored, response of the response that the request of storage retries as subsequent same request.
For example, after client makes requests and retries, if client receives request when retrying corresponding response, this is asked It asks the task of retrying to terminate, and request is retried into corresponding response and is stored in the memory of client, when client is in receipt of subsequent To when identical request, directly fed back the response in client's end memory as its corresponding response.
It wherein,, can also be with being stored in memory even the response that retries of request since memory storage space is limited Response equally periodically deleted, deletion mode can be found in the related content of above-mentioned steps 201, no longer repeat one by one herein.
In a kind of optional embodiment, it is based on same idea, referring to Fig. 3, in method provided by the embodiments of the present application, When client make requests retry when, further include following steps:
Step 204, number of retries threshold value is obtained;If number of retries reaches number of retries threshold value, ending request is retried.
After client gets the time offset that current request retries from memory, also gets and retry from memory Frequency threshold value, make requests retry when, if number of retries reaches number of retries threshold value, asked no matter whether client receives It asks and retries corresponding response, terminate this time request and retry task.
Wherein, number of retries threshold value can be 6 perhaps 10 or according to the actual situation or empirical value is set, The embodiment of the present application is not limited this.
Optionally, according to business scenario, dynamic adjusts number of retries threshold value.
Wherein, basis in the mode and above-mentioned steps 202 of dynamic adjustment is carried out to frequency threshold value is retried according to business scenario Business scenario is the same to the mode of the dynamic adjustment of time offset, and details are not described herein.
In a kind of optional embodiment, referring to fig. 4, by taking the prize in game is provided as an example.When user shares daily When game, a game competition certificate can be obtained, click needs to send striding course request, do not have in client when getting the competition certificate When receiving with the striding course corresponding response of request, in order to guarantee to take in competition, certificate is normally issued in the account of user, therefore, is being sent The time offset that acquisition request retries after striding course request failure.
After user's associated play, due to the sharing operation of user, when first service striding course is asked to second service transmission When asking, second service, which receives, to be requested and responds to the request, which is fed back to first service, user is according to the first clothes The feedback of business gets competition certificate.However, not received any anti-after user's associated play when getting competition certificate When feedback, starting request retries strategy.
Unsuccessfully occur for example, user gets competition certificate in 00:00, client can time migration that successively acquisition request retries Amount 5,10,30,60,120,240,300,600,1200,3600,7200;Then request, which retries, understands in 00:00:05,00:00:15, 00:00:45,00:01:45,00:03:45,00:07:45,00:12:45,00:22:45,00:42:45,01:42:45,03: 42:45 is successively carried out.After user gets competition certificate success, it can stop retrying request;Or work as the number that request retries When reaching number of retries threshold value, i.e., after retrying time 03:42:45 for the last time, stops request and retry task.
Technical solution bring beneficial effect provided by the embodiments of the present application includes at least:
After sending striding course request, if not receiving the corresponding response of request, by obtain that current request retries when Between offset, make requests and retry, since the time offset is dynamically determined according to business scenario, thus avoid request solid Interior batch of fixing time retries, and improves flexibility and success rate that request retries;And it avoids because service fault causes to be called The load at end increases.
By requesting corresponding response and request to retry corresponding response and store striding course, in order to store Response of the response as subsequent same request, and then response speed can be improved.
By obtaining number of retries threshold value, ending request retries task after number of retries reaches number of retries threshold value, and By adjusting to the dynamic for retrying frequency threshold value, timely ending request retries, avoids client and carry out useless request weight Examination.
The embodiment of the present application provides a kind of device for requesting to retry, and referring to Fig. 5, which includes:
Sending module 501, for sending striding course request;
First obtains module 502, if obtaining the time migration that current request retries for not receiving the corresponding response of request Amount;
Module 503 is retried, the time offset for retrying according to current request, which makes requests, to be retried;
Wherein, striding course is for carrying out data exchange between different application;The time offset that current request retries For the time interval of Twice requests, time interval is dynamically determined according to business scenario.
In a kind of optional embodiment, module 503 is retried, if retrying corresponding response for receiving request, knot Beam request retries.
In a kind of optional embodiment, referring to Fig. 6, the device further include:
First memory module 504, the response for retrying request store, the response conduct that the request of storage retries The response of subsequent same request.
In a kind of optional embodiment, referring to Fig. 7, the device further include:
Second obtains module 505, for obtaining number of retries threshold value;
Module 503 is retried, if being also used to number of retries reaches number of retries threshold value, ending request is retried.
In a kind of optional embodiment, referring to Fig. 8, the device further include:
Module 506 is adjusted, for according to business scenario, dynamic to adjust number of retries threshold value.
In a kind of optional embodiment, referring to Fig. 9, the device further include:
Second memory module 507 requests corresponding response for receiving striding course;By striding course request it is corresponding respond into Row storage, response of the response that the request of storage retries as subsequent same request.
Technical solution bring beneficial effect provided by the embodiments of the present application includes at least:
After sending striding course request, if not receiving the corresponding response of request, by obtain that current request retries when Between offset, make requests and retry, since the time offset is dynamically determined according to business scenario, thus avoid request solid Interior batch of fixing time retries, and improves flexibility and success rate that request retries;And it avoids because service fault causes to be called The load at end increases.
By requesting corresponding response and request to retry corresponding response and store striding course, in order to store Response of the response as subsequent same request, and then response speed can be improved.
By obtaining number of retries threshold value, ending request retries task after number of retries reaches number of retries threshold value, and By adjusting to the dynamic for retrying frequency threshold value, timely ending request retries, avoids client and carry out useless request weight Examination.
It should be noted that device provided by the above embodiment is when realizing its function, only with above-mentioned each functional module It divides and carries out for example, can according to need in practical application and be completed by different functional modules above-mentioned function distribution, The internal structure of equipment is divided into different functional modules, to complete all or part of the functions described above.In addition, Apparatus and method embodiment provided by the above embodiment belongs to same design, and specific implementation process is detailed in embodiment of the method, this In repeat no more.
Referring to Figure 10, it illustrates a kind of structural representations for the terminal 1000 for requesting to retry provided by the embodiments of the present application Figure.The terminal 1000 can be portable mobile termianl, such as: smart phone, tablet computer, MP3 player (Moving Picture Experts Group Audio Layer III, dynamic image expert's compression standard audio level 3), MP4 (Moving Picture Experts Group Audio Layer IV, dynamic image expert's compression standard audio level 4) is broadcast Put device, laptop or desktop computer.Terminal 1000 be also possible to referred to as user equipment, portable terminal, laptop terminal, Other titles such as terminal console.
In general, terminal 1000 includes: processor 1001 and memory 1002.
Processor 1001 may include one or more processing cores, such as 4 core processors, 5 core processors Deng.Processor 1001 can use DSP (Digital Signal Processing, Digital Signal Processing), FPGA (Field- Programmable Gate Array, field programmable gate array), PLA (Programmable Logic Array, may be programmed Logic array) at least one of example, in hardware realize.Processor 1001 also may include primary processor and coprocessor, master Processor is the processor for being handled data in the awake state, also referred to as CPU (Central Processing Unit, central processing unit);Coprocessor is the low power processor for being handled data in the standby state.? In some embodiments, processor 1001 can be integrated with GPU (Graphics Processing Unit, image processor), GPU is used to be responsible for the rendering and drafting of content to be shown needed for display screen.In some embodiments, processor 1001 can also be wrapped AI (Artificial Intelligence, artificial intelligence) processor is included, the AI processor is for handling related machine learning Calculating operation.
Memory 1002 may include one or more computer readable storage mediums, which can To be non-transient.Memory 1002 may also include high-speed random access memory and nonvolatile memory, such as one Or multiple disk storage equipments, flash memory device.In some embodiments, the non-transient computer in memory 1002 can Storage medium is read for storing at least one instruction, at least one instruction performed by processor 1001 for realizing this Shen Please in the method that retries of request that provides of embodiment of the method.
In some embodiments, terminal 1000 is also optional includes: peripheral device interface 1003 and at least one periphery are set It is standby.It can be connected by bus or signal wire between processor 1001, memory 1002 and peripheral device interface 1003.It is each outer Peripheral equipment can be connected by bus, signal wire or circuit board with peripheral device interface 1003.Specifically, peripheral equipment includes: In radio circuit 1004, touch display screen 1005, camera 1006, voicefrequency circuit 1007, positioning component 1008 and power supply 1009 At least one.
Peripheral device interface 1003 can be used for I/O (Input/Output, input/output) is relevant outside at least one Peripheral equipment is connected to processor 1001 and memory 1002.In some embodiments, processor 1001, memory 1002 and periphery Equipment interface 1003 is integrated on same chip or circuit board;In some other embodiments, processor 1001, memory 1002 and peripheral device interface 1003 in any one or two can be realized on individual chip or circuit board, this implementation Example is not limited this.
Radio circuit 1004 is for receiving and emitting RF (Radio Frequency, radio frequency) signal, also referred to as electromagnetic signal. Radio circuit 1004 is communicated by electromagnetic signal with communication network and other communication equipments.Radio circuit 1004 is by telecommunications Number being converted to electromagnetic signal is sent, alternatively, the electromagnetic signal received is converted to electric signal.Optionally, radio circuit 1004 include: antenna system, RF transceiver, one or more amplifiers, tuner, oscillator, digital signal processor, volume solution Code chipset, user identity module card etc..Radio circuit 1004 can by least one wireless communication protocol come with it is other Terminal is communicated.The wireless communication protocol includes but is not limited to: Metropolitan Area Network (MAN), each third generation mobile communication network (2G, 3G, 4G and 5G), WLAN and/or WiFi (Wireless Fidelity, Wireless Fidelity) network.In some embodiments, radio frequency electrical Road 1004 can also include NFC (Near Field Communication, wireless near field communication) related circuit, the application This is not limited.
Display screen 1005 is for showing UI (User Interface, user interface).The UI may include figure, text, Icon, video and its their any combination.When display screen 1005 is touch display screen, display screen 1005 also there is acquisition to exist The ability of the touch signal on the surface or surface of display screen 1005.The touch signal can be used as control signal and be input to place Reason device 1001 is handled.At this point, display screen 1005 can be also used for providing virtual push button and/or dummy keyboard, it is also referred to as soft to press Button and/or soft keyboard.In some embodiments, display screen 1005 can be one, and the front panel of terminal 1000 is arranged;Another In a little embodiments, display screen 1005 can be at least two, be separately positioned on the different surfaces of terminal 1000 or in foldover design; In still other embodiments, display screen 1005 can be flexible display screen, is arranged on the curved surface of terminal 1000 or folds On face.Even, display screen 1005 can also be arranged to non-rectangle irregular figure, namely abnormity screen.Display screen 1005 can be with Using LCD (Liquid Crystal Display, liquid crystal display), OLED (Organic Light-Emitting Diode, Organic Light Emitting Diode) etc. materials preparation.
CCD camera assembly 1006 is for acquiring image or video.Optionally, CCD camera assembly 1006 includes front camera And rear camera.In general, the front panel of terminal is arranged in front camera, the back side of terminal is arranged in rear camera.? In some embodiments, rear camera at least two is that main camera, depth of field camera, wide-angle camera, focal length are taken the photograph respectively As any one in head, to realize that main camera and the fusion of depth of field camera realize background blurring function, main camera and wide Pan-shot and VR (Virtual Reality, virtual reality) shooting function or other fusions are realized in camera fusion in angle Shooting function.In some embodiments, CCD camera assembly 1006 can also include flash lamp.Flash lamp can be monochromatic temperature flash of light Lamp is also possible to double-colored temperature flash lamp.Double-colored temperature flash lamp refers to the combination of warm light flash lamp and cold light flash lamp, can be used for Light compensation under different-colour.
Voicefrequency circuit 1007 may include microphone and loudspeaker.Microphone is used to acquire the sound wave of user and environment, and It converts sound waves into electric signal and is input to processor 1001 and handled, or be input to radio circuit 1004 to realize that voice is logical Letter.For stereo acquisition or the purpose of noise reduction, microphone can be separately positioned on the different parts of terminal 1000 to be multiple. Microphone can also be array microphone or omnidirectional's acquisition type microphone.Loudspeaker is then used to that processor 1001 or radio frequency will to be come from The electric signal of circuit 1004 is converted to sound wave.Loudspeaker can be traditional wafer speaker, be also possible to piezoelectric ceramics loudspeaking Device.When loudspeaker is piezoelectric ceramic loudspeaker, the audible sound wave of the mankind can be not only converted electrical signals to, can also be incited somebody to action Electric signal is converted to the sound wave that the mankind do not hear to carry out the purposes such as ranging.In some embodiments, voicefrequency circuit 1007 may be used also To include earphone jack.
Positioning component 1008 is used for the current geographic position of positioning terminal 1000, to realize navigation or LBS (Location Based Service, location based service).Positioning component 1008 can be the GPS (Global based on the U.S. Positioning System, global positioning system), the dipper system of China, Russia Gray receive this system or European Union The positioning component of Galileo system.
Power supply 1009 is used to be powered for the various components in terminal 1000.Power supply 1009 can be alternating current, direct current Electricity, disposable battery or rechargeable battery.When power supply 1009 includes rechargeable battery, which can support wired Charging or wireless charging.The rechargeable battery can be also used for supporting fast charge technology.
In some embodiments, terminal 1000 further includes having one or more sensors 1010.One or more sensing Device 1010 includes but is not limited to: acceleration transducer 1011, gyro sensor 1012, pressure sensor 1013, fingerprint sensing Device 1014, optical sensor 1015 and proximity sensor 1016.
Acceleration transducer 1010 can detecte the acceleration in three reference axis of the coordinate system established with terminal 1000 Size.For example, acceleration transducer 1011 can be used for detecting component of the acceleration of gravity in three reference axis.Processor The 1001 acceleration of gravity signals that can be acquired according to acceleration transducer 1011, control touch display screen 1005 with transverse views Or longitudinal view carries out the display of user interface.Acceleration transducer 1011 can be also used for game or the exercise data of user Acquisition.
Gyro sensor 1012 can detecte body direction and the rotational angle of terminal 1000, gyro sensor 1012 Acquisition user can be cooperateed with to act the 3D of terminal 1000 with acceleration transducer 1011.Processor 1001 is according to gyro sensors The data that device 1012 acquires, following function may be implemented: action induction (for example changing UI according to the tilt operation of user) is clapped Image stabilization, game control and inertial navigation when taking the photograph.
The lower layer of side frame and/or touch display screen 1005 in terminal 1000 can be set in pressure sensor 1013.When When the side frame of terminal 1000 is arranged in pressure sensor 1013, user can detecte to the gripping signal of terminal 1000, by Reason device 1001 carries out right-hand man's identification or prompt operation according to the gripping signal that pressure sensor 1013 acquires.Work as pressure sensor 1013 when being arranged in the lower layer of touch display screen 1005, is grasped by processor 1001 according to pressure of the user to touch display screen 1005 Make, realization controls the operability control on the interface UI.Operability control include button control, scroll bar control, At least one of icon control, menu control.
Fingerprint sensor 1014 is used to acquire the fingerprint of user, is collected by processor 1001 according to fingerprint sensor 1014 Fingerprint recognition user identity, alternatively, by fingerprint sensor 1014 according to the identity of collected fingerprint recognition user.Knowing Not Chu the identity of user when being trusted identity, authorize the user to execute relevant sensitive operation by processor 1001, which grasps Make to include solving lock screen, checking encryption information, downloading software, payment and change setting etc..Fingerprint sensor 1014 can be set Set the front, the back side or side of terminal 1000.When being provided with physical button or manufacturer Logo in terminal 1000, fingerprint sensor 1014 can integrate with physical button or manufacturer Logo.
Optical sensor 1015 is for acquiring ambient light intensity.In one embodiment, processor 1001 can be according to light The ambient light intensity that sensor 1015 acquires is learned, the display brightness of touch display screen 1005 is controlled.Specifically, work as ambient light intensity When higher, the display brightness of touch display screen 1005 is turned up;When ambient light intensity is lower, the aobvious of touch display screen 1005 is turned down Show brightness.In another embodiment, the ambient light intensity that processor 1001 can also be acquired according to optical sensor 1015, is moved The acquisition parameters of state adjustment CCD camera assembly 1006.
Proximity sensor 1016, also referred to as range sensor are generally arranged at the front panel of terminal 1000.Proximity sensor 1016 for acquiring the distance between the front of user Yu terminal 1000.In one embodiment, when proximity sensor 1016 is examined When measuring the distance between the front of user and terminal 1000 and gradually becoming smaller, by processor 1001 control touch display screen 1005 from Bright screen state is switched to breath screen state;When proximity sensor 1016 detect the distance between front of user and terminal 1000 by When gradual change is big, touch display screen 1005 is controlled by processor 1001 and is switched to bright screen state from breath screen state.
It, can be with it will be understood by those skilled in the art that the restriction of the not structure paired terminal 1000 of structure shown in Figure 10 Including than illustrating more or fewer components, perhaps combining certain components or being arranged using different components.
In the exemplary embodiment, a kind of computer equipment is additionally provided, computer equipment includes processor and memory, At least one instruction is stored in memory.At least one instruction is configured to be executed by one or more than one processor, To realize method that above-mentioned request retries.
In the exemplary embodiment, a kind of computer readable storage medium is additionally provided, is stored at least in storage medium The method that above-mentioned request retries is realized in one instruction, at least one instruction when being executed by the processor of computer equipment.
All the above alternatives can form the alternative embodiment of the disclosure, herein no longer using any combination It repeats one by one.
Above is only an example of the present application, all in spirit herein and principle not to limit the application Within, any modification, equivalent replacement, improvement and so on should be included within the scope of protection of this application.

Claims (14)

1. a kind of method for requesting to retry, which is characterized in that the described method includes:
Send striding course request;
If not receiving the corresponding response of the request, the time offset that current request retries is obtained;
It is made requests and is retried according to the time offset that the current request retries;
Wherein, the time offset that the current request retries is the time interval of Twice requests, and the time interval is according to industry Scene dynamics of being engaged in determine.
2. the method according to claim 1, wherein the time offset retried according to the current request It makes requests after retrying, further includes:
If receiving the request retries corresponding response, ending request is retried.
3. according to the method described in claim 2, it is characterized in that, after the ending request retries, further includes:
The response retried is requested to store by described, sound of the response that the request of storage retries as subsequent same request It answers.
4. method according to claim 1 to 3, which is characterized in that the method, further includes:
Obtain number of retries threshold value;
If number of retries reaches number of retries threshold value, ending request is retried.
5. according to the method described in claim 4, it is characterized in that, the method, further includes:
According to business scenario, the number of retries threshold value is dynamically adjusted.
6. the method according to claim 1, wherein after transmission striding course request, further includes:
It receives the striding course and requests corresponding response;
Corresponding response is requested to store the striding course, the striding course of storage requests corresponding response as subsequent identical The response of request.
7. a kind of request the device that retries, which is characterized in that described device includes:
Sending module, for sending striding course request;
First obtains module, if obtaining the time offset that current request retries for not receiving the corresponding response of the request;
Module is retried, the time offset for retrying according to the current request, which makes requests, to be retried;
Wherein, the time offset that the current request retries is the time interval of Twice requests, and the time interval is according to industry Scene dynamics of being engaged in determine.
8. device according to claim 7, which is characterized in that it is described to retry module, if being also used to receive the request Corresponding response is retried, ending request retries.
9. device according to claim 8, which is characterized in that described device further include:
First memory module, for requesting the response retried to store for described, the response that the request of storage retries is made For the response of subsequent same request.
10. according to any device of claim 7-9, which is characterized in that described device further include:
Second obtains module, for obtaining number of retries threshold value;
Described to retry module, if being also used to number of retries reaches number of retries threshold value, ending request is retried.
11. device according to claim 10, which is characterized in that described device further include:
Module is adjusted, for dynamically adjusting the number of retries threshold value according to business scenario.
12. device according to claim 7, which is characterized in that described device further include:
Second memory module requests corresponding response for receiving the striding course;The striding course is requested into corresponding response It is stored, response of the response that the request of storage retries as subsequent same request.
13. a kind of request the equipment that retries, which is characterized in that the equipment includes processor and memory, in the memory It is stored at least one instruction, described instruction is shown by the processor and executed to realize such as institute any in claim 1-6 The method that the request stated retries.
14. a kind of computer readable storage medium, which is characterized in that be stored at least one instruction, institute in the storage medium Instruction is stated to be shown by processor and executed to realize such as the method as claimed in any one of claims 1 to 6 for requesting to retry.
CN201811640170.0A 2018-12-29 2018-12-29 Method, device and equipment for requesting retry and readable storage medium Active CN109697113B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811640170.0A CN109697113B (en) 2018-12-29 2018-12-29 Method, device and equipment for requesting retry and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811640170.0A CN109697113B (en) 2018-12-29 2018-12-29 Method, device and equipment for requesting retry and readable storage medium

Publications (2)

Publication Number Publication Date
CN109697113A true CN109697113A (en) 2019-04-30
CN109697113B CN109697113B (en) 2021-06-01

Family

ID=66233019

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811640170.0A Active CN109697113B (en) 2018-12-29 2018-12-29 Method, device and equipment for requesting retry and readable storage medium

Country Status (1)

Country Link
CN (1) CN109697113B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111241112A (en) * 2019-12-27 2020-06-05 山大地纬软件股份有限公司 Micro-service call supervision system and method for guaranteeing idempotent
CN112134958A (en) * 2020-09-23 2020-12-25 北京奇艺世纪科技有限公司 Data request method, device, server and storage medium
CN112395155A (en) * 2020-11-06 2021-02-23 微民保险代理有限公司 Service monitoring method and device, storage medium and electronic device
CN113923163A (en) * 2021-10-20 2022-01-11 广东亿迅科技有限公司 Long connection message channel based current limiting method and system
CN114827280A (en) * 2022-04-26 2022-07-29 中国建设银行股份有限公司 Request processing method, device, equipment and medium
CN116932290A (en) * 2023-09-18 2023-10-24 北京睿企信息科技有限公司 Data processing system for obtaining target model

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1193903A1 (en) * 2000-05-22 2002-04-03 Mitsubishi Denki Kabushiki Kaisha Data transmission system
CN101459496B (en) * 2008-12-18 2011-05-04 北京大学 Regulating method and apparatus for timeout interval for messages
CN102769577A (en) * 2012-08-21 2012-11-07 迈普通信技术股份有限公司 Method and network device for achieving message retransmission
CN103067895A (en) * 2013-01-04 2013-04-24 东莞宇龙通信科技有限公司 Retransmission method of long text message and communication terminal
CN103095428A (en) * 2011-11-02 2013-05-08 上海贝尔股份有限公司 Method and device for radio link control protocol data unit (RLC PDU) transmission
CN107040343A (en) * 2016-02-03 2017-08-11 中国移动通信集团公司 A kind of retransfer scheduling method and device
CN108234599A (en) * 2017-12-06 2018-06-29 链家网(北京)科技有限公司 A kind of message repeating method and system
CN108492109A (en) * 2018-03-15 2018-09-04 平安科技(深圳)有限公司 The processing method and storage medium that electronic device, dynamic code are asked
CN108712494A (en) * 2018-05-18 2018-10-26 阿里巴巴集团控股有限公司 Handle the method, apparatus and equipment of asynchronous message
WO2018198363A1 (en) * 2017-04-28 2018-11-01 富士通株式会社 Base station device, terminal device, wireless communication system and communication method
CN108965164A (en) * 2017-05-17 2018-12-07 北京京东尚科信息技术有限公司 Service request repeating method, device and readable storage medium storing program for executing based on message queue
CN109245867A (en) * 2018-08-14 2019-01-18 深圳壹账通智能科技有限公司 A kind of message method, computer readable storage medium and terminal device

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1193903A1 (en) * 2000-05-22 2002-04-03 Mitsubishi Denki Kabushiki Kaisha Data transmission system
CN101459496B (en) * 2008-12-18 2011-05-04 北京大学 Regulating method and apparatus for timeout interval for messages
CN103095428A (en) * 2011-11-02 2013-05-08 上海贝尔股份有限公司 Method and device for radio link control protocol data unit (RLC PDU) transmission
CN102769577A (en) * 2012-08-21 2012-11-07 迈普通信技术股份有限公司 Method and network device for achieving message retransmission
CN103067895A (en) * 2013-01-04 2013-04-24 东莞宇龙通信科技有限公司 Retransmission method of long text message and communication terminal
CN107040343A (en) * 2016-02-03 2017-08-11 中国移动通信集团公司 A kind of retransfer scheduling method and device
WO2018198363A1 (en) * 2017-04-28 2018-11-01 富士通株式会社 Base station device, terminal device, wireless communication system and communication method
CN108965164A (en) * 2017-05-17 2018-12-07 北京京东尚科信息技术有限公司 Service request repeating method, device and readable storage medium storing program for executing based on message queue
CN108234599A (en) * 2017-12-06 2018-06-29 链家网(北京)科技有限公司 A kind of message repeating method and system
CN108492109A (en) * 2018-03-15 2018-09-04 平安科技(深圳)有限公司 The processing method and storage medium that electronic device, dynamic code are asked
CN108712494A (en) * 2018-05-18 2018-10-26 阿里巴巴集团控股有限公司 Handle the method, apparatus and equipment of asynchronous message
CN109245867A (en) * 2018-08-14 2019-01-18 深圳壹账通智能科技有限公司 A kind of message method, computer readable storage medium and terminal device

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111241112A (en) * 2019-12-27 2020-06-05 山大地纬软件股份有限公司 Micro-service call supervision system and method for guaranteeing idempotent
CN112134958A (en) * 2020-09-23 2020-12-25 北京奇艺世纪科技有限公司 Data request method, device, server and storage medium
CN112395155A (en) * 2020-11-06 2021-02-23 微民保险代理有限公司 Service monitoring method and device, storage medium and electronic device
CN113923163A (en) * 2021-10-20 2022-01-11 广东亿迅科技有限公司 Long connection message channel based current limiting method and system
CN114827280A (en) * 2022-04-26 2022-07-29 中国建设银行股份有限公司 Request processing method, device, equipment and medium
CN114827280B (en) * 2022-04-26 2024-04-26 中国建设银行股份有限公司 Request processing method, device, equipment and medium
CN116932290A (en) * 2023-09-18 2023-10-24 北京睿企信息科技有限公司 Data processing system for obtaining target model
CN116932290B (en) * 2023-09-18 2023-12-08 北京睿企信息科技有限公司 Data processing system for obtaining target model

Also Published As

Publication number Publication date
CN109697113B (en) 2021-06-01

Similar Documents

Publication Publication Date Title
CN109697113A (en) Request method, apparatus, equipment and the readable storage medium storing program for executing retried
CN111225042B (en) Data transmission method and device, computer equipment and storage medium
WO2020001564A1 (en) Method, apparatus, and system for processing tasks
CN113536063B (en) Information processing method, device, equipment and storage medium
CN110147503B (en) Information issuing method and device, computer equipment and storage medium
CN110213153A (en) Display methods, acquisition methods, device, terminal and the storage medium of unread message
CN110147380A (en) Data-updating method, device, server and storage medium
CN108900925A (en) The method and apparatus of live streaming template are set
CN110058935A (en) Log rank method of adjustment, apparatus and system, readable storage medium storing program for executing
CN110535890A (en) The method and apparatus that file uploads
CN110673944A (en) Method and device for executing task
CN110290191B (en) Resource transfer result processing method, device, server, terminal and storage medium
CN112836838B (en) Reservation request processing method, device, equipment and storage medium
CN112560435B (en) Text corpus processing method, device, equipment and storage medium
CN109600301A (en) Message treatment method and device
CN111694521B (en) Method, device and system for storing file
CN114785766A (en) Control method of intelligent equipment, terminal and server
CN114140105A (en) Resource transfer method, device, equipment and computer readable storage medium
CN111222124B (en) Method, device, equipment and storage medium for using authority distribution
CN114862205B (en) Resource allocation method, device, equipment and computer readable storage medium
CN110545299A (en) content list information acquisition method, content list information providing method, content list information acquisition device, content list information providing device and content list information equipment
CN112700249B (en) Order information management method, device and system and storage medium
CN111490979B (en) Information interaction method and device and storage medium
CN109981310B (en) Resource management method, device and storage medium
CN115019945A (en) Order distribution method, device, equipment and computer readable storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20210111

Address after: 511442 3108, 79 Wanbo 2nd Road, Nancun Town, Panyu District, Guangzhou City, Guangdong Province

Applicant after: GUANGZHOU CUBESILI INFORMATION TECHNOLOGY Co.,Ltd.

Address before: 511446 28th floor, block B1, Wanda Plaza, Wanbo business district, Nancun Town, Panyu District, Guangzhou City, Guangdong Province

Applicant before: GUANGZHOU HUADUO NETWORK TECHNOLOGY Co.,Ltd.

EE01 Entry into force of recordation of patent licensing contract
EE01 Entry into force of recordation of patent licensing contract

Application publication date: 20190430

Assignee: GUANGZHOU HUADUO NETWORK TECHNOLOGY Co.,Ltd.

Assignor: GUANGZHOU CUBESILI INFORMATION TECHNOLOGY Co.,Ltd.

Contract record no.: X2021440000052

Denomination of invention: Method, device, device and readable storage medium for requesting retrial

License type: Common License

Record date: 20210222

GR01 Patent grant
GR01 Patent grant