CN109684105A - Method, equipment and the storage medium that request is controlled under micro services framework - Google Patents

Method, equipment and the storage medium that request is controlled under micro services framework Download PDF

Info

Publication number
CN109684105A
CN109684105A CN201811554548.5A CN201811554548A CN109684105A CN 109684105 A CN109684105 A CN 109684105A CN 201811554548 A CN201811554548 A CN 201811554548A CN 109684105 A CN109684105 A CN 109684105A
Authority
CN
China
Prior art keywords
micro services
application
request
predetermined
case
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.)
Pending
Application number
CN201811554548.5A
Other languages
Chinese (zh)
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.)
Ping An Life Insurance Company of China Ltd
Original Assignee
Ping An Life Insurance Company of China 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 Ping An Life Insurance Company of China Ltd filed Critical Ping An Life Insurance Company of China Ltd
Priority to CN201811554548.5A priority Critical patent/CN109684105A/en
Publication of CN109684105A publication Critical patent/CN109684105A/en
Pending legal-status Critical Current

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/54Interprogram communication
    • G06F9/547Remote procedure calls [RPC]; Web services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Telephonic Communication Services (AREA)

Abstract

This disclosure relates to the method, equipment and the storage medium that are controlled under micro services framework request.The described method includes: judging that one or more of micro services apply the response time to call request whether more than the first predetermined threshold;It is more than the micro services application of the first predetermined threshold for the response time in the application of one or more of micro services, judges the current request number applied to the micro services whether more than the first predetermined quantity;The case where being no more than the first predetermined quantity for the current request number degrades the predetermined micro services application of the application platform in the case where not fusing the call request to micro services application.By the presently disclosed embodiments, micro services application operating lag can be solved the problems, such as more quickly, realizes load balancing, improve system effectiveness and performance.

Description

Method, equipment and the storage medium that request is controlled under micro services framework
Technical field
The present invention relates to micro services architecture technology fields, in particular to a kind of to control under micro services framework request Method, apparatus, calculate equipment and computer readable storage medium.
Background technique
Micro services framework is a kind of new technology for application deployment and service.It is smaller by resolving into application and service , the components of loose couplings, they can be more easier to upgrade and extend.
In order to handle the high concurrent service request under micro services framework, fusing mechanism is introduced.Generally, when call some When micro services unsuccessfully reach certain threshold value (such as 20 failures in 5 seconds), fusing machine system just will start.Fusing under micro services framework Strategy is the key that processing high concurrent business, guarantees that micro services operate normally.To adapt to a variety of different demands, people are constantly Adjustment and improvement fusing strategy.
Summary of the invention
The first purpose of the embodiment of the present invention is to provide a kind of new fusing strategy for micro services framework.
According to a first aspect of the present application, it provides and a kind of request is controlled in the application platform of micro services framework Method, wherein the application platform calls one or more micro services applications to handle service request from the user, the method Include:
Judge that one or more of micro services apply the response time to call request whether more than the first predetermined threshold;
It is more than the micro services application of the first predetermined threshold for the response time in the application of one or more of micro services, sentences Whether the disconnected current request number applied to the micro services is more than the first predetermined quantity;
The case where being no more than the first predetermined quantity for the current request number, in the tune to micro services application that do not fuse The predetermined micro services application of the application platform is degraded in the case where request.
According to an exemplary embodiment, the method also includes:
In the case where degrading the predetermined micro services application up to predetermined amount of time, judge that the response time is more than the Whether the response time of the micro services application of one predetermined threshold is still above the first predetermined threshold;
In the case where the response time is still above the first predetermined threshold, transmission is asked what the micro services application was restarted It asks.
According to an exemplary embodiment, the method also includes:
In the case where the current request number is more than the first predetermined quantity, the calling applied to the micro services that fuses is asked It asks.
According to an exemplary embodiment, the method also includes:
Judge the number of request of micro services application being blown whether more than the second predetermined quantity;
The number of request being blown be more than the second predetermined quantity in the case where, by the application platform it is predetermined in incognito Business application degrades.
According to an exemplary embodiment, the method also includes:
In response to the call request to the application of the second micro services applied from the first micro services, judge that the first micro services are answered It whether is more than third predetermined quantity to the call request number of the second micro services application within the unit time, wherein the first micro services It is any two micro services application that the application platform is included using with the second micro services application;
In the case that call request number within the unit time is more than third predetermined quantity, to the first micro services application Predetermined default value is returned, and never calls the application of the second micro services and handles the call request.
According to an exemplary embodiment, the method also includes:
In the case where calling the number of the degraded predetermined micro services application failure to be more than four predetermined quantities, hair Send the request for restarting the degraded predetermined micro services application.
According to a second aspect of the present application, it provides and a kind of request is controlled in the application platform of micro services framework Device, wherein the application platform calls one or more micro services applications to handle service request from the user, described device Include:
First judgment module is configured as: judging one or more of micro services using the response to call request Whether the time is more than the first predetermined threshold;
Second judgment module, is configured as: being more than for the response time in the application of one or more of micro services Whether the micro services application of one predetermined threshold judges the current request number applied to the micro services more than the first predetermined quantity;
Degradation module, is configured as: the case where being no more than the first predetermined quantity for the current request number, melting The predetermined micro services application of the application platform is degraded in the case where the disconnected call request applied to the micro services.
According to an exemplary embodiment, the first judgment module is also configured to
In the case where degrading the predetermined micro services application up to predetermined amount of time, judge that the response time is more than the Whether the response time of the micro services application of one predetermined threshold is still above the first predetermined threshold;
Wherein, described device further includes Restart Request module, is configured as: pre- still above first in the response time In the case where determining threshold value, the request for restarting the micro services application is sent.
According to an exemplary embodiment, described device further include:
Fuse module, is configured as: in the case where the current request number is more than the first predetermined quantity, fusing to this The call request of micro services application.
According to an exemplary embodiment, described device further include:
Whether third judgment module, is configured as: judging the number of request of micro services application being blown more than second Predetermined quantity;
Wherein, the degradation module is also configured in the number of request being blown be more than the feelings of the second predetermined quantity Under condition, the predetermined micro services application of the application platform is degraded.
According to an exemplary embodiment, described device further includes current limliting module, and the current limliting module includes:
4th judging unit, is configured as: in response to from the first micro services apply to the second micro services application Call request judges that whether the first micro services are applied within the unit time to the call request number of the second micro services application more than the Three predetermined quantities, wherein the first micro services are applied and the second micro services application is that any two that the application platform is included are micro- It is served by;
Current limiting unit is configured as: the call request number within the unit time is more than the feelings of third predetermined quantity Under condition, predetermined default value is returned to the application of the first micro services, and never calls the application of the second micro services and handles the call request.
According to an exemplary embodiment, the Restart Request module is also configured to
In the case where calling the number of the degraded predetermined micro services application failure to be more than four predetermined quantities, hair Send the request for restarting the degraded predetermined micro services application.
According to the third aspect of the application, a kind of calculating equipment is provided comprising memory and processor, the memory In be stored with computer program, the computer program by the processor when being executed, so that calculatings equipment execution is such as Upper any of the embodiment of the method.
According to the fourth aspect of the application, a kind of computer readable storage medium is provided, computer program is stored thereon with, The computer program realizes any of embodiment of the method as described above when being executed by one or more processors.
The technical solution that embodiments herein provides can include the following benefits:
By the application each embodiment as described above and as described below, the efficiency of fusing mechanism can be improved, more preferably Ground guarantees the performance that high concurrent business is handled under micro services framework.
It should be understood that the above general description and the following detailed description are merely exemplary, this can not be limited It is open.
Detailed description of the invention
Fig. 1 is the simplified schematic diagram of implementation environment involved in the application shown according to an exemplary embodiment.
Fig. 2 be according to shown in one exemplary embodiment of the application under the application platform of micro services framework to request carry out The schematic flow diagram of the method for control.
Fig. 3 is an exemplary tool of the process for restarting micro services application that embodiment of the method shown in Fig. 2 can also include The schematic flow diagram of body embodiment.
Fig. 4 is an exemplary specific reality of demotion processes after the first fusing that embodiment of the method shown in Fig. 2 can also include Apply the schematic flow diagram of mode.
Fig. 5 is an exemplary specific embodiment party of the current limliting treatment process that embodiment of the method shown in Fig. 2 can also include The schematic flow diagram of formula.
Fig. 6 be according to shown in one exemplary embodiment of the application under the application platform of micro services framework to request carry out The signal composition block diagram of the device of control.
Fig. 7 is the signal composition block diagram according to the calculating equipment shown in one exemplary embodiment of the application.
Specific embodiment
In order to make the objectives, technical solutions, and advantages of the present invention clearer, with reference to the accompanying drawings and embodiments, right Exemplary embodiment of the present invention is further elaborated.In the following description when referring to the accompanying drawings, unless otherwise indicated, it is different Same numbers in attached drawing indicate the same or similar element.The not generation of embodiment described in following exemplary embodiment The table all embodiments consistent with the application.On the contrary, they are only and as detailed in the attached claim, this Shen The example of the consistent device and method of some aspects please.It should be appreciated that specific embodiment described herein is used only for It explains the present invention, is not intended to limit the present invention.
Fig. 1 is the simplified schematic diagram of implementation environment involved in the application shown according to an exemplary embodiment.Such as Fig. 1 institute Show, application platform 110 is micro services framework comprising one or more micro services applications are (as an example, be shown in FIG. 1 Four micro services applications) 111,112,113,114.Application platform 110 further includes current limliting and device for fusing 115, for for micro- Mutual call request between being served by executes current limliting and/or fusing strategy, in case high concurrent call request makes using flat Platform 110 is collapsed since processing capacity is unbearable.For service request from the user, application platform 110 calls micro services The service request, current limliting and device for fusing 115 are handled using one or more of 111,112,113,114 using fusing plan Slightly (including service degradation strategy) is controlled and is managed to the call request between micro services application.
It is unavailable and cause whole system not often to will appear some called micro services in the system of micro services framework The case where can using, this phenomenon, which is referred to as, services avalanche effect.In one example, used by current limliting and device for fusing 115 Fusing strategy are as follows: when application platform 110 calls one or more micro services applications to handle service request from the user, current limliting Each micro services are monitored using the response time to call request with device for fusing 115, and judge whether the response time is more than pre- Determine threshold value, if being not above predetermined threshold, hold fire, predetermined threshold if more than then melts the call request It is disconnected, that is, so that the micro services are using being operated or handled not for the call request, but to the promoter of call request Directly return to scheduled default value.It can make the response time that will not be applied due to the micro services slow in this way and influence to user Service request the Whole Response time, avoid avalanche effect.In this example, current limliting and device for fusing 115 can also be Some or certain predetermined micro services of application platform 110 are dropped in the case where the call request quantity a predetermined level is exceeded being blown Grade, reduces the processing pressure of whole system, thus restores the response time as early as possible to the micro services application of response timeout.
But above-mentioned fusing strategy can not avoid avalanche effect in time sometimes, because of the response timeout of micro services application It is not always excessively to make its processing pressure excessive due to the call request to it and cause, it may be possible to be caused due to other Its response timeout, such as since system disposed of in its entirety pressure is excessive.In this case, the call request to it is fused not It can tackle the problem at its root, the time solved the problems, such as may be delayed instead.The inventors have recognized that in such feelings Alleviate the disposed of in its entirety pressure of system by the way that predetermined micro services degrade under condition, can effectively make the micro services of response timeout Application recovery is normal.
Therefore, in one example, current limliting and device for fusing 115 can be using following fusing strategies: when finding certain in incognito When business application is more than predetermined threshold to the response time of call request, directly by the tune unlike in example described above It is fused with request, but further judgement is directed to the current call request number of micro services application, if currently to the micro services The call request number of application does not fuse then there is no excessive (such as being not above certain predetermined quantity) to micro services application Call request, but predetermined micro services are degraded, to alleviate system integral pressure so that response time time-out this in incognito Business application restores normal as early as possible.
Fig. 1 and above description are the exemplary embodiment of implementation environment involved in the application, it is to be understood that suitable For the implementation environment of the application, there are various deformations.
It is illustrated below with reference to Fig. 2-5 by the description of each method embodiment to the application above-mentioned molten Disconnected strategy.
Fig. 2 be according to shown in one exemplary embodiment of the application under the application platform of micro services framework to request carry out The schematic flow diagram of the method for control.The executor of the exemplary method can be current limliting as shown in Figure 1 and device for fusing 115.As shown in the exemplary embodiment of Fig. 2, this method may include step:
S210 judges that one or more micro services apply the response time to call request whether more than the first predetermined threshold Value.
It can monitor and calculate each micro services that application platform is included and apply response time to call request, to sentence Break its response whether time-out.In one example, the first predetermined threshold (such as 200ms) can be set, will monitor and be calculated Response time be compared with the first predetermined threshold, to judge whether response timeout.
S220 is more than the micro services application of the first predetermined threshold for the response time, judges to work as the micro services application Whether preceding number of request is more than the first predetermined quantity.
In the embodiment shown in Figure 2, when judging some micro services application response timeout in step S210, it is not Directly the call request applied to the micro services is fused, but further judges the current request number applied to the micro services. This is because if the reason of micro services application response timeout be not due to excessive to its number of request and cause, even when The call request to fuse to it also can not fundamentally solve the problems, such as the response timeout of micro services application.Therefore, in step The current request number of micro services application is further judged in S220.
In one example, benchmark of first predetermined quantity as judgement can be set, such as can be by the first predetermined number Amount is set as 60, if the current request number of micro services application is no more than first predetermined quantity, shows its response timeout The reason of be not that number of request is excessive.If current request number is more than first predetermined quantity, show that micro services application is rung The reason for answering time-out is likely to be because number of request is excessive.
It is understood that the first predetermined quantity can be set to the numerical value other than 60, no matter what it is arranged to Value, the value all should can accurately show whether current request number is more than whether the reason of value represents response timeout asks as far as possible Ask number excessive.
S230, for the current request number be no more than the first predetermined quantity the case where, the micro services are answered not fusing The predetermined micro services application of the application platform is degraded in the case where call request.
As previously mentioned, showing the micro services application response timeout if current request number is no more than the first predetermined quantity The reason of be not that number of request is excessive, can not fundamentally to solve this micro- for the call request to micro services application that at this moment fuses The problem of being served by response timeout.Since another for causing the micro services application response timeout is due to there is a strong possibility The disposed of in its entirety pressure of application platform is excessive, therefore, mitigates integral pressure by making certain micro services degrade, it is possible to can make The micro services for obtaining operating lag are restored.Therefore, in the embodiment shown in Figure 2, in step S230, not for current request number The case where more than the first predetermined quantity, the measure of service degradation is taken, and the call request to micro services application that do not fuse.
So-called " service degradation " refers to, making this service is actually to hang, that is, the content returned is empty or old Or pre-set default value.Be performed service degradation micro services application be it is pre-set, can be one ratio More peripheral, less important micro services application is also possible to multiple less important micro services applications.In an example In, this multiple micro services, which is applied, has respective degradation priority, when executing service degradation first to the higher execution of priority.
By embodiment shown in Fig. 2, in the case that not number of request is excessive the reason of judgement causes operating lag, directly Execution service degradation is connect, without being more than that certain amount just executes service degradation until the request being blown, therefore, more quickly It solves the problems, such as micro services application operating lag, improves system effectiveness and performance.
Fig. 3 is an exemplary tool of the process for restarting micro services application that embodiment of the method shown in Fig. 2 can also include The schematic flow diagram of body embodiment.As shown in figure 3, the embodiment method can also include step after the step S230 of Fig. 2 It is rapid:
S310 judges the response time in the case where the predetermined micro services application degradation is reached predetermined amount of time More than the first predetermined threshold the micro services apply response time whether still above the first predetermined threshold.
After the service degradation for applying predetermined micro services, if the reason of micro services application operating lag, is that system is whole Body pressure is excessive, then the certain time after service degradation, and when system integral pressure gradually mitigates due to service degradation, this is micro- The response time being served by should be able to restore.If do not restored, then it represents that reason judges possible mistake, needs to take other Measure.Therefore, in step s310, after service degradation reaches predetermined amount of time (such as 80ms), original operating lag is checked Micro services application, sees whether its response time restores.
S320, in the case where the response time is still above the first predetermined threshold, the micro services application is restarted in transmission Request.
If the response time does not restore, other measures can be taken to attempt to restore the micro services application.For example, In step S320, the request for restarting the micro services application can be sent.In one example, sending Restart Request can wrap It includes: directly restarting micro services application after sending the request predetermined time (such as 10s).In another example, weight is sent Opening request may include: to send Restart Request in O&M message queue, this is restarted after the confirmation for obtaining administrator in incognito Business application.
If the judging result of step S310 is to have restored the response time of micro services application, show operating lag Reason correct judgment can will be dropped after (such as after restoring predetermined amount of time) the response time recovery that micro services are applied The micro services application of grade is restarted, that is, starts offer service.
Fig. 4 is an exemplary specific reality of demotion processes after the first fusing that embodiment of the method shown in Fig. 2 can also include Apply the schematic flow diagram of mode.In the embodiment shown in Figure 2, if be judged as in step S220 to micro services application Current request number is more than the first predetermined quantity, then the strategy for first fusing and degrading afterwards is executed after step S220, as shown in figure 4, The process to degrade afterwards that first fuses may include step:
S410, in the case where the current request number is more than the first predetermined quantity, fuse the tune applied to the micro services With request.
If a micro services application response timeout, and it is judged as that its current request number be more than the first predetermined quantity, Then show that the reason of causing its response timeout is likely to be that number of request excessively causes it to handle not come.Therefore, in step In S410, the call request to micro services application that can fuse keeps its response time extensive as early as possible to mitigate its processing pressure It is multiple.
Whether S420 judges the number of request of micro services application being blown more than the second predetermined quantity.
S430, in the case where the number of request being blown is more than the second predetermined quantity, by the pre- of the application platform Determine micro services application to degrade.
If the number of request that the micro services application is blown has reached certain amount (such as more than second predetermined quantity), still The micro services request this measure also not enough using still without the recovery response time, then showing to fuse, it may be necessary to take Other measures.Therefore, in step S430, it is being judged as that the number of request of micro services application being blown is more than the second predetermined number In the case where amount, service degradation measure can be taken, that is, scheduled one or more micro services applications degrade, are to mitigate System disposed of in its entirety pressure, so that the micro services application of operating lag restores normal as early as possible.
Later, if the micro services application recovery of operating lag is normal, it can send and restart degraded micro services and answer Request (such as after the micro services application recovery normal predetermined time).Although alternatively, the micro services application of operating lag Do not restore normal, but in the case where calling the number of degraded micro services application failure to be more than a predetermined quantity, sends weight Open the request of the degraded predetermined micro services application.
In addition to above-mentioned fusing (including degradation) strategy, current limliting strategy can also be taken, i.e., to the phase between micro services application Mutually number of request is called to be limited.Fig. 5 is an example of the current limliting treatment process that embodiment of the method shown in Fig. 2 can also include The schematic flow diagram of property specific embodiment.As shown in figure 5, current limliting treatment process may include step:
S510 judges the first micro services in response to the request to the application of the second micro services applied from the first micro services Whether apply within the unit time is more than third predetermined quantity to the call request number of the second micro services application.
Wherein, the first micro services are applied and the second micro services application is that any two micro services that application platform is included are answered With.In one example, third predetermined quantity is arranged to per second 2000 interior.
S520 is returned pre- in the case where the service request number is more than third predetermined quantity to the application of the first micro services Determine default value, and never calls the application of the second micro services and handle the call request.
By current limiting measures, the burst applied from some micro services can effectively be prevented largely to call, guarantee micro services The normal operation of application.
According to the another aspect of the application, also discloses and request is controlled in the application platform of micro services framework Device.Fig. 6 is according to controlling under the application platform of micro services framework to request shown in one exemplary embodiment of the application The signal composition block diagram of the device of system, the device 601 can current limliting as shown in Figure 1 and device for fusing 115 above.The device 601 for executing each method embodiment as described above.As shown in fig. 6, exemplary device 601 may include:
First judgment module 610, is configured as: judging that one or more of micro services apply the sound to call request Whether more than the first predetermined threshold between seasonable;
Second judgment module 620, is configured as: being more than for the response time in the application of one or more of micro services Whether the micro services application of the first predetermined threshold judges the current request number applied to the micro services more than the first predetermined quantity;
Degradation module 630, is configured as: the case where being no more than the first predetermined quantity for the current request number, It does not fuse and the application of the predetermined micro services of the application platform degrades in the case where the call request to micro services application.
Embodiment according to figure 6, the first judgment module 610 can be additionally configured to:
In the case where degrading the predetermined micro services application up to predetermined amount of time, judge that the response time is more than the Whether the response time of the micro services application of one predetermined threshold is still above the first predetermined threshold;
Wherein, described device 601 can also include Restart Request module 640, be configured as: the response time still In the case where the first predetermined threshold, the request for restarting the micro services application is sent.
Embodiment according to figure 6, device 601 can also include:
Fuse module 650, is configured as: in the case where the current request number is more than the first predetermined quantity, fusing Call request to micro services application.
Embodiment according to figure 6, device 601 can also include:
Whether third judgment module 660, is configured as: judging the number of request of micro services application being blown more than the Two predetermined quantities;
Wherein, the degradation module 630 is also configured in the number of request being blown be more than the second predetermined quantity In the case of, the predetermined micro services application of the application platform is degraded.
Embodiment according to figure 6, device 601 can also include current limliting module 670, and the current limliting module 670 can be with Include:
4th judging unit 671, is configured as: in response to from the first micro services apply to the second micro services application Call request, judge the first micro services apply within the unit time to the second micro services application call request number whether be more than Third predetermined quantity, wherein the first micro services are applied and the second micro services application is any two that the application platform is included Micro services application;
Current limiting unit 672, is configured as: the call request number within the unit time is more than third predetermined quantity In the case of, predetermined default value is returned to the application of the first micro services, and never call the application of the second micro services and handle the call request.
Embodiment according to figure 6, the Restart Request module 640 are also configured to
In the case where calling the number of the degraded predetermined micro services application failure to be more than four predetermined quantities, hair Send the request for restarting the degraded predetermined micro services application.
Each unit/module function and the realization process and correlative detail of effect are specifically detailed in above-mentioned in above-mentioned apparatus The realization process of step is corresponded in embodiment of the method, details are not described herein.
Installation practice in the above various embodiments can realize by way of hardware, software, firmware or combinations thereof, And which can be implemented as an individual devices, also may be implemented as each composition units/modules and are dispersed in one or more The logic integrated system of corresponding function is executed in a calculating equipment and respectively.
Each unit/module that the device is formed in the above various embodiments is divided according to logic function, they can be with It is repartitioned according to logic function, such as can realize the device by more or fewer units/modules.These compositions Units/modules can realize that they can be the independence of difference by way of hardware, software, firmware or combinations thereof respectively Component is also possible to multiple components and combines execute integrated unit/module of corresponding logic function.The hardware, software, The mode of firmware or combinations thereof may include: the hardware component of separation, by the functional module of programming mode realization, by that can compile The functional module, etc. that journey logical device is realized, or with the combination of upper type.
According to an exemplary embodiment, which can be implemented as a kind of calculating equipment comprising memory and processing Device is stored with computer program in the memory, and the computer program by the processor when being executed, so that the meter It calculates equipment and executes any of each method embodiment as described above, alternatively, the computer program is by the processor The function of making the calculating equipment realize that component units/module of each Installation practice as described above is realized when execution.
Processor described in above embodiment can refer to single processing unit, such as central processing unit CPU, can also To be the processing unit/processor distributed processor system for including multiple dispersions.
Memory described in above embodiment may include one or more memories, can be and calculates equipment Internal storage, such as transient state or non-transient various memories, are also possible to be connected to calculating equipment by memory interface External memory.
Fig. 7 shows the signal composition block diagram of such exemplary embodiment for calculating equipment 701.As shown in fig. 7, Calculating equipment 701 may include: processor 710, communication interface 720, memory 730 and bus 740.Storage in memory 730 There is the computer program that can be executed by processor 710.Processor 710 is realized in above-described embodiment when executing the computer program Method and device function.The quantity of memory 730 and processor 710 can be respectively one or more.Communication interface 720 For the communication between processor 710 and external equipment.
Wherein, processor 710 can be central processing unit, general processor, digital signal processor, dedicated integrated electricity Road, field programmable gate array or other programmable logic device, transistor logic, hardware component or its any group It closes.It, which may be implemented or executes, combines various illustrative process steps, functional unit/mould described in the disclosure of invention Block and/or circuit.The processor is also possible to realize the combination of computing function, such as includes one or more microprocessors group Conjunction, digital signal processor etc..
Memory 730 may include volatile memory and/or nonvolatile memory, such as non-volatile dynamic random Access memory, phase change random access memory devices, magnetic random access memory, magnetic disk storage, Electrical Erasable can be compiled Journey read-only memory, flush memory device, semiconductor devices (such as solid state hard disk) etc..Memory 730 optionally can also be external Remote storage.
It is total that bus 740 can be industry standard architecture (ISA, Industry Standard Architecture) Line, external equipment interconnection (PCI, Peripheral Component) bus or extended industry-standard architecture (EISA, Extended Industry Standard Component) bus etc..It is total that the bus can be divided into address bus, data Line, control bus etc..Only to be indicated with a thick line in Fig. 7, it is not intended that an only bus or a type convenient for indicating The bus of type.Optionally, if memory 730, processor 710 and communication interface 720 are integrated on one chip, memory 730, processor 710 and communication interface 720 can complete mutual communication by internal interface.
The above each method and Installation practice are also implemented as the form of computer program, are stored in storage medium On, and can be distributed.Therefore, according to another aspect of the present disclosure, a kind of computer program product is also provided, the computer journey Sequence product is stored on computer readable storage medium, and realize when being executed by processor each method as described above and Any of Installation practice.According to the another aspect of the disclosure, a kind of computer readable storage medium is also provided, is deposited thereon The computer program executed for processor is contained, the computer program is realized as described above each when being executed by processor Any of method and apparatus embodiment.
The computer readable storage medium can be any finger that can be kept and store and can be used by instruction execution equipment The tangible device of order.For example, it can be ,-- but is not limited to-- storage device electric, magnetic storage apparatus, light storage device, electricity Magnetic storage apparatus, semiconductor memory apparatus or above-mentioned any appropriate combination.The more specific example of storage medium is (non-poor The list of act) it include: portable computer diskette, hard disk, random access memory (RAM), read-only memory (ROM), erasable type Programmable read only memory (EPROM or flash memory), static random access memory (SRAM), Portable compressed disk read-only memory (CD-ROM), digital versatile disc (DVD), memory stick, floppy disk, mechanical coding equipment, the punching for being for example stored thereon with instruction Card or groove internal projection structure and above-mentioned any appropriate combination.
Computer program/computer instruction as described herein can download to each meter from computer readable storage medium Calculation/processing equipment, or outer computer is downloaded to by network, such as internet, local area network, wide area network and/or wireless network Or External memory equipment.Network may include copper transmission cable, optical fiber transmission, wireless transmission, router, firewall, interchanger, Gateway computer and/or Edge Server.Adapter or network interface in each calculating/processing equipment connect from network Computer-readable program instructions are received, and forward the computer-readable program instructions, for being stored in each calculating/processing equipment Computer readable storage medium in.
Computer program instructions described in the disclosure can be assembly instruction, instruction set architecture (ISA) instructs, machine refers to It enables, machine-dependent instructions, microcode, firmware instructions, condition setup data or with any group of one or more programming languages The source code or object code write are compiled in collaboration with, the programming language includes programming language-such as Smalltalk, C+ of object-oriented + etc., and conventional procedural programming languages-such as " C " language or similar programming language.Computer-readable program instructions It can fully execute on the user computer, partly execute, held as an independent software package on the user computer Part executes on the remote computer or holds on a remote computer or server completely on the user computer for row, part Row.In situations involving remote computers, remote computer can include local area network (LAN) by the network-of any kind Or wide area network (WAN)-is connected to subscriber computer, or, it may be connected to outer computer (such as utilize Internet service Provider is connected by internet).In some embodiments, by the status information using computer-readable program instructions come Personalized customization electronic circuit, such as programmable logic circuit, field programmable gate array (FPGA) or programmable logic array (PLA), which can execute computer-readable program instructions, to realize various aspects of the invention.
Referring herein to according to the method for the embodiment of the present invention, the flow chart of device (system) and computer program product and/ Or block diagram describes various aspects of the invention.It should be appreciated that flowchart and or block diagram each box and flow chart and/ Or in block diagram each box combination, can be realized by computer-readable program instructions.
These computer-readable program instructions can be supplied to general purpose computer, special purpose computer or other programmable datas The processor of processing unit, so that a kind of machine is produced, so that these instructions are passing through computer or other programmable datas When the processor of processing unit executes, function specified in one or more boxes in implementation flow chart and/or block diagram is produced The device of energy/movement.These computer-readable program instructions can also be stored in a computer-readable storage medium, these refer to It enables so that computer, programmable data processing unit and/or other equipment work in a specific way, thus, it is stored with instruction Computer-readable medium then includes a manufacture comprising in one or more boxes in implementation flow chart and/or block diagram The instruction of the various aspects of defined function action.
Computer-readable program instructions can also be loaded into computer, other programmable data processing units or other In equipment, so that series of operation steps are executed in computer, other programmable data processing units or other equipment, to produce Raw computer implemented process, so that executed in computer, other programmable data processing units or other equipment Instruct function action specified in one or more boxes in implementation flow chart and/or block diagram.
The flow chart and block diagram in the drawings show the system of multiple embodiments according to the present invention, method and computer journeys The architecture, function and operation in the cards of sequence product.In this regard, each box in flowchart or block diagram can generation One module of table, program segment or a part of instruction, the module, program segment or a part of instruction include one or more use The executable instruction of the logic function as defined in realizing.In some implementations as replacements, function marked in the box It can occur in a different order than that indicated in the drawings.For example, two continuous boxes can actually be held substantially in parallel Row, they can also be executed in the opposite order sometimes, and this depends on the function involved.It is also noted that block diagram and/or The combination of each box in flow chart and the box in block diagram and or flow chart, can the function as defined in executing or dynamic The dedicated hardware based system made is realized, or can be realized using a combination of dedicated hardware and computer instructions.It is right For those skilled in the art it is well known that, by hardware mode realize, by software mode realize and pass through software and It is all of equal value that the mode of combination of hardware, which is realized,.
It should be noted that all the embodiments in this specification are described in a progressive manner, each embodiment weight Point explanation is the difference from other embodiments, and the same or similar parts between the embodiments can be referred to each other. But it will be clear for those skilled in the art that the various embodiments described above, which can according to need exclusive use or be combined with each other, to be made With.In addition, for device embodiment, since it is corresponding with embodiment of the method, so describe fairly simple, it is related Place referring to the corresponding part of embodiment of the method explanation.
The embodiments described above only express several embodiments of the present invention, and the description thereof is more specific and detailed, but simultaneously Limitations on the scope of the patent of the present invention therefore cannot be interpreted as.It should be pointed out that for those of ordinary skill in the art For, without departing from the inventive concept of the premise, various modifications and improvements can be made, these belong to guarantor of the invention Protect range.Therefore, the scope of protection of the patent of the invention shall be subject to the appended claims.

Claims (10)

1. a kind of method controlled in the application platform of micro services framework request, which is characterized in that the application is flat Platform calls one or more micro services applications to handle service request from the user, which comprises
Judge that one or more of micro services apply the response time to call request whether more than the first predetermined threshold;
It is more than the micro services application of the first predetermined threshold, judgement pair for the response time in the application of one or more of micro services Whether the current request number of micro services application is more than the first predetermined quantity;
The case where being no more than the first predetermined quantity for the current request number asks the calling of micro services application not fusing The predetermined micro services application of the application platform is degraded in the case where asking.
2. the method as described in claim 1, which is characterized in that further include:
In the case where the predetermined micro services application degradation is reached predetermined amount of time, judge that the response time is more than first pre- Whether the response time of micro services application of threshold value is determined still above the first predetermined threshold;
In the case where the response time is still above the first predetermined threshold, the request for restarting the micro services application is sent.
3. the method as described in claim 1, which is characterized in that further include:
In the case where the current request number is more than the first predetermined quantity, fuse the call request applied to the micro services.
4. method as claimed in claim 3, which is characterized in that further include:
Judge the number of request of micro services application being blown whether more than the second predetermined quantity;
In the case where the number of request being blown is more than the second predetermined quantity, the predetermined micro services of the application platform are answered With degradation.
5. such as method of any of claims 1-4, which is characterized in that further include:
In response to the call request to the application of the second micro services applied from the first micro services, judge that the first micro services are applied It whether is more than third predetermined quantity to the call request number of the second micro services application in unit time, wherein the first micro services application It is any two micro services application that the application platform is included with the second micro services application;
In the case that call request number within the unit time is more than third predetermined quantity, returned to the application of the first micro services Predetermined default value, and never call the application of the second micro services and handle the call request.
6. method as described in claim 1 or 4, which is characterized in that further include:
In the case where calling the number of the degraded predetermined micro services application failure to be more than four predetermined quantities, weight is sent Open the request of the degraded predetermined micro services application.
7. a kind of device controlled in the application platform of micro services framework request, which is characterized in that the application is flat Platform calls one or more micro services applications to handle service request from the user, and described device includes:
First judgment module is configured as: judging that one or more of micro services apply the response time to call request Whether more than the first predetermined threshold;
Second judgment module, is configured as: being more than first pre- for the response time in the application of one or more of micro services Whether the micro services application for determining threshold value judges the current request number applied to the micro services more than the first predetermined quantity;
Degradation module, is configured as: the case where being no more than the first predetermined quantity for the current request number is not fusing pair The predetermined micro services application of the application platform is degraded in the case where the call request of micro services application.
8. device as claimed in claim 7, which is characterized in that the first judgment module is also configured to
In the case where the predetermined micro services application degradation is reached predetermined amount of time, judge that the response time is more than first pre- Whether the response time of micro services application of threshold value is determined still above the first predetermined threshold;
Wherein, described device further includes Restart Request module, is configured as: in the response time still above the first predetermined threshold In the case where value, the request for restarting the micro services application is sent.
9. a kind of calculating equipment comprising memory and processor are stored with computer program, the calculating in the memory Machine program by the processor when being executed, so that the calculating equipment executes such as side described in any one of claims 1 to 6 Method.
10. a kind of computer readable storage medium is stored thereon with computer program, the computer program is by one or more Such as method described in any one of claims 1 to 6 is realized when a processor executes.
CN201811554548.5A 2018-12-18 2018-12-18 Method, equipment and the storage medium that request is controlled under micro services framework Pending CN109684105A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811554548.5A CN109684105A (en) 2018-12-18 2018-12-18 Method, equipment and the storage medium that request is controlled under micro services framework

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811554548.5A CN109684105A (en) 2018-12-18 2018-12-18 Method, equipment and the storage medium that request is controlled under micro services framework

Publications (1)

Publication Number Publication Date
CN109684105A true CN109684105A (en) 2019-04-26

Family

ID=66186207

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811554548.5A Pending CN109684105A (en) 2018-12-18 2018-12-18 Method, equipment and the storage medium that request is controlled under micro services framework

Country Status (1)

Country Link
CN (1) CN109684105A (en)

Cited By (24)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110505155A (en) * 2019-08-13 2019-11-26 北京达佳互联信息技术有限公司 Request degradation processing method, device, electronic equipment and storage medium
CN110535901A (en) * 2019-07-05 2019-12-03 中国平安财产保险股份有限公司 Service degradation method, apparatus, computer equipment and storage medium
CN110661815A (en) * 2019-10-22 2020-01-07 中国林业科学研究院热带林业研究所 Request processing method, device, system and medium based on frequency limitation microservice
CN110673962A (en) * 2019-08-27 2020-01-10 腾讯科技(深圳)有限公司 Content stream processing method, device, equipment and medium
CN110837431A (en) * 2019-11-13 2020-02-25 深圳前海环融联易信息科技服务有限公司 Service control method, service control device, computer equipment and computer-readable storage medium
CN110995472A (en) * 2019-11-15 2020-04-10 苏州浪潮智能科技有限公司 Method and system for fusing micro-service
CN111078468A (en) * 2019-11-21 2020-04-28 贝壳技术有限公司 Service rollback method and device under micro-service architecture
CN111130939A (en) * 2019-12-26 2020-05-08 深圳前海环融联易信息科技服务有限公司 Flow control method and device, computer equipment and storage medium
CN111324471A (en) * 2020-01-22 2020-06-23 远景智能国际私人投资有限公司 Service adjusting method, device, equipment and storage medium
CN111381951A (en) * 2020-03-06 2020-07-07 北京思特奇信息技术股份有限公司 Dirty data processing method and device in system architecture and storage medium
CN111510480A (en) * 2020-04-08 2020-08-07 北京百度网讯科技有限公司 Request sending method and device and first server
CN111787073A (en) * 2020-06-18 2020-10-16 多加网络科技(北京)有限公司 Current-limiting fusing platform and method for unified service
CN112367268A (en) * 2020-11-24 2021-02-12 苏宁云计算有限公司 Current limiting method and device for micro-service
CN112448987A (en) * 2019-08-29 2021-03-05 北京京东尚科信息技术有限公司 Fusing degradation triggering method and system and storage medium
CN112449017A (en) * 2020-11-25 2021-03-05 深圳市欢太科技有限公司 Server and control method thereof
CN112636971A (en) * 2020-12-21 2021-04-09 北京字跳网络技术有限公司 Service degradation method and device, electronic equipment and storage medium
CN112965848A (en) * 2021-03-05 2021-06-15 北京百度网讯科技有限公司 Fusing degradation method, device, equipment and medium for micro service
CN113159845A (en) * 2021-04-21 2021-07-23 杭州网易云音乐科技有限公司 Data processing method, device, equipment and medium
CN113485917A (en) * 2021-06-25 2021-10-08 上海豹云网络信息服务有限公司 Interface management method and device, electronic equipment and storage medium
CN113783822A (en) * 2020-06-03 2021-12-10 北京沃东天骏信息技术有限公司 Service timeout management method and device
CN114006871A (en) * 2021-10-25 2022-02-01 北京有竹居网络技术有限公司 Flow control method, flow control device, container and storage medium
CN114710406A (en) * 2022-04-24 2022-07-05 中国工商银行股份有限公司 Dynamic determination method and device of timeout threshold, electronic equipment and medium
CN115118769A (en) * 2022-06-28 2022-09-27 深圳前海微众银行股份有限公司 Service system parameter configuration and micro-service execution method and device
CN115129490A (en) * 2022-06-30 2022-09-30 中电金信软件有限公司 Micro-service calling method and device and electronic equipment

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107592219A (en) * 2017-09-04 2018-01-16 北京潘达互娱科技有限公司 Service degradation processing method and processing device
CN108427581A (en) * 2018-02-07 2018-08-21 平安普惠企业管理有限公司 System micro services method and terminal device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107592219A (en) * 2017-09-04 2018-01-16 北京潘达互娱科技有限公司 Service degradation processing method and processing device
CN108427581A (en) * 2018-02-07 2018-08-21 平安普惠企业管理有限公司 System micro services method and terminal device

Cited By (35)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110535901A (en) * 2019-07-05 2019-12-03 中国平安财产保险股份有限公司 Service degradation method, apparatus, computer equipment and storage medium
CN110505155B (en) * 2019-08-13 2023-12-08 北京达佳互联信息技术有限公司 Request degradation processing method and device, electronic equipment and storage medium
CN110505155A (en) * 2019-08-13 2019-11-26 北京达佳互联信息技术有限公司 Request degradation processing method, device, electronic equipment and storage medium
CN110673962A (en) * 2019-08-27 2020-01-10 腾讯科技(深圳)有限公司 Content stream processing method, device, equipment and medium
CN112448987A (en) * 2019-08-29 2021-03-05 北京京东尚科信息技术有限公司 Fusing degradation triggering method and system and storage medium
CN110661815A (en) * 2019-10-22 2020-01-07 中国林业科学研究院热带林业研究所 Request processing method, device, system and medium based on frequency limitation microservice
CN110837431A (en) * 2019-11-13 2020-02-25 深圳前海环融联易信息科技服务有限公司 Service control method, service control device, computer equipment and computer-readable storage medium
CN110995472A (en) * 2019-11-15 2020-04-10 苏州浪潮智能科技有限公司 Method and system for fusing micro-service
CN111078468A (en) * 2019-11-21 2020-04-28 贝壳技术有限公司 Service rollback method and device under micro-service architecture
CN111130939B (en) * 2019-12-26 2021-09-10 深圳前海环融联易信息科技服务有限公司 Flow control method and device, computer equipment and storage medium
CN111130939A (en) * 2019-12-26 2020-05-08 深圳前海环融联易信息科技服务有限公司 Flow control method and device, computer equipment and storage medium
CN111324471A (en) * 2020-01-22 2020-06-23 远景智能国际私人投资有限公司 Service adjusting method, device, equipment and storage medium
CN111324471B (en) * 2020-01-22 2023-07-21 远景智能国际私人投资有限公司 Service adjustment method, device, equipment and storage medium
CN111381951A (en) * 2020-03-06 2020-07-07 北京思特奇信息技术股份有限公司 Dirty data processing method and device in system architecture and storage medium
CN111510480A (en) * 2020-04-08 2020-08-07 北京百度网讯科技有限公司 Request sending method and device and first server
CN113783822A (en) * 2020-06-03 2021-12-10 北京沃东天骏信息技术有限公司 Service timeout management method and device
CN113783822B (en) * 2020-06-03 2023-05-30 北京沃东天骏信息技术有限公司 Service timeout management method and device, electronic equipment and readable medium
CN111787073B (en) * 2020-06-18 2023-08-22 庞茂林 Current limiting fusing platform for unified service and method thereof
CN111787073A (en) * 2020-06-18 2020-10-16 多加网络科技(北京)有限公司 Current-limiting fusing platform and method for unified service
CN112367268A (en) * 2020-11-24 2021-02-12 苏宁云计算有限公司 Current limiting method and device for micro-service
CN112367268B (en) * 2020-11-24 2022-07-05 苏宁云计算有限公司 Current limiting method and device for micro-service
CN112449017A (en) * 2020-11-25 2021-03-05 深圳市欢太科技有限公司 Server and control method thereof
CN112449017B (en) * 2020-11-25 2023-08-18 深圳市欢太科技有限公司 Service end and control method thereof
CN112636971A (en) * 2020-12-21 2021-04-09 北京字跳网络技术有限公司 Service degradation method and device, electronic equipment and storage medium
CN112636971B (en) * 2020-12-21 2023-01-10 北京字跳网络技术有限公司 Service degradation method and device, electronic equipment and storage medium
CN112965848A (en) * 2021-03-05 2021-06-15 北京百度网讯科技有限公司 Fusing degradation method, device, equipment and medium for micro service
CN113159845B (en) * 2021-04-21 2022-09-27 杭州网易云音乐科技有限公司 Data processing method, device, equipment and medium
CN113159845A (en) * 2021-04-21 2021-07-23 杭州网易云音乐科技有限公司 Data processing method, device, equipment and medium
CN113485917A (en) * 2021-06-25 2021-10-08 上海豹云网络信息服务有限公司 Interface management method and device, electronic equipment and storage medium
CN114006871A (en) * 2021-10-25 2022-02-01 北京有竹居网络技术有限公司 Flow control method, flow control device, container and storage medium
CN114710406A (en) * 2022-04-24 2022-07-05 中国工商银行股份有限公司 Dynamic determination method and device of timeout threshold, electronic equipment and medium
CN114710406B (en) * 2022-04-24 2023-09-26 中国工商银行股份有限公司 Method, device, electronic equipment and medium for dynamically determining timeout threshold
CN115118769A (en) * 2022-06-28 2022-09-27 深圳前海微众银行股份有限公司 Service system parameter configuration and micro-service execution method and device
CN115118769B (en) * 2022-06-28 2024-02-02 深圳前海微众银行股份有限公司 Method and device for configuring parameters of service system and executing micro-service
CN115129490A (en) * 2022-06-30 2022-09-30 中电金信软件有限公司 Micro-service calling method and device and electronic equipment

Similar Documents

Publication Publication Date Title
CN109684105A (en) Method, equipment and the storage medium that request is controlled under micro services framework
US10432533B2 (en) Automatic detection and prevention of network overload conditions using SDN
US20190288914A1 (en) Allocating VNFC Instances with Anti Affinity Rule to Hosts
CN111736872B (en) Gray scale release upgrading method, device, computer system and readable storage medium
CN108173911A (en) A kind of micro services fault detect processing method and processing device
CN109308252A (en) A kind of fault location processing method and processing device
EP3522449B1 (en) Service state transition method and device
CN107005435A (en) A kind of network service descriptor restocking method and device
CN110391880A (en) Access request processing method and equipment based on terminal-server framework
CN111143023A (en) Resource changing method and device, equipment and storage medium
CN107196777A (en) A kind of method and apparatus of application processing
CN111124593B (en) Information processing method and device, network element and storage medium
CN110019481A (en) Memory database access method, device, equipment and medium
CN113055415A (en) Service providing method, service consuming method, device and equipment
CN105338058A (en) Application updating method and device
CN112286622A (en) Virtual machine migration processing and strategy generating method, device, equipment and storage medium
CN110839066B (en) Data processing method and related equipment
WO2016206399A1 (en) Communication equipment, device and software version upgrade method utilized in communication equipment
CN109067611B (en) Method, device, storage medium and processor for detecting communication state between systems
CN114691395A (en) Fault processing method and device, electronic equipment and storage medium
CN110955647A (en) Database assistance method, database assistance device, computer equipment and storage medium
CN114900860B (en) Edge computing method and device for mobile terminal, edge computing server and medium
KR102157538B1 (en) System for upgrading / updating software of virtual network apparatus or system, method thereof
CN115344366B (en) Connection pool object switching method and device, electronic equipment and readable storage medium
AU2018275024B2 (en) Capacity allocation of call-handling devices

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