CN105656962A - Service calling method and device - Google Patents

Service calling method and device Download PDF

Info

Publication number
CN105656962A
CN105656962A CN201410643943.6A CN201410643943A CN105656962A CN 105656962 A CN105656962 A CN 105656962A CN 201410643943 A CN201410643943 A CN 201410643943A CN 105656962 A CN105656962 A CN 105656962A
Authority
CN
China
Prior art keywords
service
calling
request
invocation
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.)
Pending
Application number
CN201410643943.6A
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.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding 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 Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201410643943.6A priority Critical patent/CN105656962A/en
Publication of CN105656962A publication Critical patent/CN105656962A/en
Pending legal-status Critical Current

Links

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

The invention relates to the field of communication, and particularly to a service calling method and device used for solving problems of unsteady terminal services and poor availability of the terminal services caused by a complex access environment and uncertain factors in the prior art. The service calling method comprises the steps of, when a terminal receives a type of service calling request sent by a requester, and when the fact that a monitoring index of one calling result of a service called by the service calling request is beyond a corresponding preset threshold is determined based on the obtained monitoring index of the calling result of the service calling request, carrying out degradation processing for the service calling request; and setting a simulation request pool, storing the service calling request subjected to the degradation processing to the simulation request pool according to a set proportion, then calling corresponding services by aiming at the service calling request in the simulation request pool and carrying on monitoring for the calling result. Therefore, the service availability is ensured, and the response speed and efficiency of the terminal are increased greatly.

Description

Service calling method and device
Technical Field
The present application relates to the field of communications, and in particular, to a service invocation method and apparatus.
Background
In various application scenarios based on network services, the interaction mode of a server and a terminal is very common. In the future, cloud services are more a trend, and it is conceivable that our terminal will rely on one or more cloud services, such as a weather forecast service provided by cloud service a, a traffic service provided by cloud service B, a reservation service provided by cloud service C, and the like. At the network location, the services may be in the same local area network, wide area network, cloud service, etc., and the network access mode may be different access modes such as high-speed broadband, 2G, 3G, etc. On the other hand, a party providing a service may have an unstable, unavailable or invalid unmatched service for some uncertain reason, collectively referred to herein as a service exception. In such a complex access environment, and due to the existence of various uncertain factors, the terminal generally cannot control the stability and availability of the service, and thus may cause the unavailability of the terminal service or the system crash of the terminal, and cause the service invocation request of the terminal to be unable to be smoothly performed. Once the problem occurs, a system administrator is difficult to detect, and certain difficulty exists in positioning and solving the problem.
Disclosure of Invention
The embodiment of the application provides a method and a device for calling a service, which are used for solving the problems of unstable terminal service and poor terminal service availability caused by a complex access environment and uncertain factors in the prior art.
The embodiment of the application provides the following specific technical scheme:
a method of service invocation, comprising:
receiving a certain type of service calling request initiated by a requester;
acquiring a monitoring index of a calling result of the service calling request;
when the monitoring index of a certain calling result of the service called by the service calling request exceeds a corresponding preset threshold, performing degradation processing on the service calling request;
setting a simulation request pool, and storing part of the service call requests to the simulation request pool according to a set proportion when judging that the service call requests are subjected to degradation processing;
and calling corresponding services according to the service calling requests in the simulation request pool, and monitoring calling results.
Therefore, the degraded service calling request is stored according to the set proportion and the corresponding service is called, judgment basis is accumulated for next degradation judgment, a judgment result and a response result can be quickly returned when the terminal requests for the next time, and the response speed and efficiency of the terminal are greatly improved. The method can effectively solve the problems of unstable terminal service and poor terminal service availability caused by complex access environment and uncertain factors in the prior art, and ensures the service availability.
Preferably, the obtaining of the monitoring index of the invocation result of the service invocation request specifically includes:
and acquiring one or any combination of the average service response time, the total number of service data errors or exceptions and the percentage of service data errors or exceptions of the service invocation request as a monitoring index of the invocation result of the service invocation request.
Preferably, further comprising:
acquiring local hardware environment monitoring indexes, and performing degradation processing on the service calling request when determining that a certain hardware environment monitoring index in the hardware environment monitoring indexes exceeds a corresponding preset threshold in the execution process of the service calling request; the hardware environment monitoring index includes one or any combination of local processor load value, memory consumption value and network connection average time.
Preferably, further comprising:
and if the multi-class service call requests are subjected to degradation processing, storing the multi-class service call requests into the simulation request pool according to corresponding set proportions, and discarding the exceeding service call requests when the total number of the stored service call requests exceeds the preset storage number.
Preferably, after receiving a certain type of service invocation request initiated to the server, determining that a monitoring index of a certain invocation result of a service invoked by the service invocation request exceeds a corresponding preset threshold, and performing degradation processing on the service invocation request, the method further includes:
directly returning the degraded basic service data to the requester; or,
invoking the preconfigured downgrade service to respond to the requestor.
Preferably, the method for invoking the corresponding service according to the service invocation request in the simulation request pool and monitoring the invocation result specifically includes:
and when the monitoring indexes of all the calling results of the service calling requests do not exceed the corresponding preset threshold, the degradation state of the service calling requests is relieved.
An apparatus for service invocation, comprising:
a receiving unit, configured to receive a service invocation request of a certain type initiated to a server;
the acquisition unit is used for acquiring the monitoring index of the calling result of the service calling request;
the judging unit is used for performing degradation processing on the service calling request when the monitoring index of a certain calling result of the service called by the service calling request exceeds a corresponding preset threshold;
the simulation unit is used for establishing a simulation request pool, and storing part of the service call requests to the simulation request pool according to a set proportion when judging that the degradation processing is carried out on the service call requests;
and the simulation calling unit is used for calling corresponding services according to the service calling requests in the simulation request pool and monitoring calling results.
Therefore, the degraded service calling request is stored according to the set proportion and the corresponding service is called, judgment basis is accumulated for next degradation judgment, a judgment result and a response result can be quickly returned when the terminal requests for the next time, and the response speed and efficiency of the terminal are greatly improved. The method can effectively solve the problems of unstable terminal service and poor terminal service availability caused by complex access environment and uncertain factors in the prior art, and ensures the service availability.
Preferably, when the monitoring index of the call result of the service call request is obtained, the obtaining unit is specifically configured to:
and acquiring one or any combination of the average service response time, the total number of service data errors or exceptions and the percentage of service data errors or exceptions of the service invocation request as a monitoring index of the invocation result of the service invocation request.
Preferably, the determination unit is further configured to:
acquiring local hardware environment monitoring indexes, and performing degradation processing on the service calling request when determining that a certain hardware environment monitoring index in the hardware environment monitoring indexes exceeds a corresponding preset threshold in the execution process of the calling service calling request; the hardware environment monitoring index includes one or any combination of local processor load value, memory consumption value and network connection average time.
Preferably, the analog unit is further configured to:
and if the multi-class service call requests are subjected to degradation processing, storing the multi-class service call requests into the simulation request pool according to corresponding set proportions, and discarding the exceeding service call requests when the total number of the stored service call requests exceeds the preset storage number.
Preferably, further comprising:
the degradation processing unit is used for directly returning degradation basic service data to the requester; alternatively, invoking the preconfigured downgrade service responds to the requestor.
Preferably, when the corresponding service is called for the service call request in the simulation request pool and the call result is monitored, the simulation call unit is specifically configured to:
and when the monitoring indexes of all the calling results of the service calling requests do not exceed the corresponding preset threshold, the degradation state of the service calling requests is relieved.
Drawings
FIG. 1 is a flow chart summarizing a service invocation in an implementation of the present application;
fig. 2 is a schematic structural diagram of a terminal and a network layer in an embodiment of the present application;
FIG. 3 is a schematic diagram of a service invocation in the practice of the present application;
fig. 4 is a specific flow chart of service invocation in the implementation of the present application.
Detailed Description
In order to solve the problems of unstable terminal service and poor terminal service availability caused by complex access environment and uncertain factors in the prior art, in the embodiment of the application, when a terminal receives a certain type of service calling request initiated by a requester, according to the obtained monitoring index of the calling result of the service calling request, when the monitoring index of the calling result of the service called by the service calling request is determined to exceed a corresponding preset threshold, the service calling request is subjected to degradation processing; and establishing a simulation request pool, storing the service call requests subjected to degradation processing into the simulation request pool according to a set proportion, calling corresponding services according to the service call requests in the simulation request pool, and continuously monitoring the calling results.
Preferred embodiments of the present invention will be described in detail below with reference to the accompanying drawings.
Referring to fig. 1, in the embodiment of the present application, a specific flow of service invocation is as follows:
step 100: a service invocation request of a certain type initiated by a requester is received.
Step 110: and acquiring a monitoring index of the calling result of the service calling request.
Specifically, one or any combination of the average service response time, the total number of service data errors or exceptions, and the percentage of service data errors or exceptions of the service invocation request is obtained as the monitoring index of the invocation result of the service invocation request.
Step 120: and when the monitoring index of a certain calling result of the service called by the service calling request exceeds a corresponding preset threshold, performing degradation processing on the service calling request.
For example, a service exception refers to a service throwing an error or an exception code when requesting the service, and the service exception is usually 500 service errors, exception logs, and the like. A service data error is a comparison of data to a monitoring index to find that the returned data is incorrect, even though the requested service did not throw an error back to the response data. And when the service data error total number, the service exception total number, the ratio of the service data error total number in the total service or the ratio of the service exception total number in the total service exceeds a corresponding preset threshold in the monitoring index, performing degradation processing on the service call request.
The various monitoring indexes and the corresponding preset thresholds are preset in the parameter configuration table and stored in the terminal, so that when a certain type of service calling request initiated by a requester is received, the terminal can monitor the calling result of the type of service calling request through the monitoring indexes in the parameter configuration table, thereby determining whether the type of service is in a normal working state currently, and when the service is found to be abnormal, the type of service calling request is degraded.
Further, in addition to the running state of the service itself, the hardware environment in which the terminal is located can also be included, which can affect the quality of the service. Therefore, in the process of monitoring the service, the terminal also needs to periodically obtain local hardware environment monitoring indexes, and when it is determined that any kind of hardware environment monitoring indexes exceed the corresponding preset threshold, degradation processing needs to be performed on the corresponding service invocation request (which may be all the service invocation requests or a part of the service invocation requests that may be affected by the hardware environment monitoring instructions).
Specifically, a local hardware environment monitoring index is obtained, and when a certain hardware environment monitoring index in the hardware environment monitoring index exceeds a corresponding preset threshold in the execution process of a certain type of service calling request, degradation processing is performed on the type of service calling request; the hardware environment monitoring index includes one or any combination of local processor load value, memory consumption value and network connection average time.
Step 130: and establishing a simulation request pool, and storing part of the service call requests to the simulation request pool according to a set proportion when judging that the degradation processing is carried out on the service call requests.
In addition, if the multi-class service call requests are subjected to degradation processing, the multi-class service call requests are stored in the simulation request pool according to corresponding set proportions, and when the total number of the stored service call requests exceeds the preset storage number, the exceeding service call requests are discarded.
In practical application, the terminal may set the total amount and the concurrency of the service invocation request when saving the downgraded service invocation request. For example, the total amount of requests is 100, the concurrency amount is 10, and assuming that 5 services are downgraded, the numbers are 1 to 5, and the storage ratios are set to 10%, 20%, 30%, 40%, and 50%, respectively. If there are 100 requests for each 5 services, then 10, 20, 30, 40, 50 requests are saved, the first 10 requests are executed immediately, the following requests wait for subsequent processing, and when the total amount of requests reaches 100, the requests exceeding the total amount are abandoned, so the last 40 requests in the above requests are discarded.
Step 140: and calling corresponding services according to the service calling requests in the simulation request pool, and monitoring calling results.
Specifically, the corresponding service is called according to the service call request in the simulation request pool, the monitoring index of the corresponding call result is obtained, and when the monitoring index of all the call results of the service call request is determined not to exceed the corresponding preset threshold, the degradation state of the service call request is removed.
When the service is degraded, it is likely that the service pressure is too large and the response is slow, and at this time, if the terminal sends the service invocation request, the time of the terminal user and the resources consumed by the terminal will be wasted, and the processing capability of the terminal is greatly reduced. At this time, in order to check the accumulated data basis for the next monitoring, the terminal stores the service calling request according to the set proportion and continues to call the service, and collects the related data as the basis for the next degradation judgment.
Therefore, when the terminal requests the service next time, the judgment result and the response result can be quickly returned, and the response speed and the response efficiency of the terminal are greatly improved.
In addition, after the terminal performs degradation processing on the service calling request, the terminal also pushes a processing result to a specified management platform for fault analysis.
Therefore, the terminal can push the degradation result to the designated management platform in time for fault analysis, so that the fault can be immediately alarmed when occurring, and the position and the reason of the fault can be quickly positioned by using the collected information.
Furthermore, when a terminal receives a certain service call request initiated to a server and determines that a monitoring index of a certain call result of a service called by the service call request exceeds a corresponding preset threshold, after the service call request is subjected to degradation processing, basic service data for degradation can be directly returned to a requesting party; alternatively, invoking the preconfigured downgrade service responds to the requestor.
On the other hand, if the service is in a normal state, the service is directly called.
Specifically, if a service invocation request of a certain type is in a degraded state, it indicates that the service performance of the current corresponding service is in an abnormal state, and therefore, the terminal does not need to spend excessive time and resources to invoke external resources, but directly provides degraded basic service data, for example, if the service is a weather forecast service, the terminal only returns the air temperature according to the last acquired weather data (for example, the weather data acquired 3 days ago aiming at the forecast of the same day), and the data of humidity, ultraviolet intensity and the like need to wait until the service is recovered and then read; on the other hand, the terminal may also invoke the degraded service, for example, if the service is a weather forecast service, the terminal may invoke the degraded service that only provides basic data from a fixed application provider, and the data volume of the degraded service is limited, but the service quality is guaranteed, so that the terminal may obtain part of the weather data through the degraded service, and thus, the query requirement of the user may be met in a short time.
Referring to fig. 2, in the embodiment of the present application, a system for a terminal to process a service invocation request is configured as follows:
the terminal comprises various intelligent terminals and devices, such as computers, smart phones, intelligent wearable devices, intelligent household products and the like, and further comprises secondary packaging services and platforms.
The usage behavior (behavior for short) of the user received by the terminal is identified by C1, and the monitoring module and the degradation module included in the terminal are identified by C2 and C3, respectively. Wherein,
c1 refers to a certain usage behavior of the user on the terminal. For example, a user requests a certain type of service through the terminal (identified as S1), the terminal sends the type of service invocation request action to C2 first, and then the service invocation request is initiated by C2 to S1.
C2 is responsible for monitoring, including service condition monitoring and hardware condition monitoring. The service condition monitoring refers to obtaining monitoring indexes of call results of various service call requests periodically, and in this embodiment, C2 requests to obtain performance and data items related to the requests through the proxy terminal. The hardware condition monitoring means that local hardware environment monitoring indexes are acquired periodically.
The C2 further includes an independent monitoring thread, which is used to compare the call results obtained periodically for each service call request with the built-in monitoring index and the corresponding preset threshold, and determine whether each service call request needs to be downgraded according to the comparison result. The parameter configuration list composed of the built-in monitoring indexes and the corresponding preset thresholds can be pre-manufactured in the C2, and can also be pushed by a configuration module (marked by S3), so that the judgment standard of dynamic customization of service upgrading and downgrading can be realized.
The C2 is also provided with a simulation request pool for storing the service call requests for the degradation processing according to a set proportion. The simulation request pool can set the total quantity of the service call request to be saved and the concurrency quantity of the service call request, can adjust the saving proportion and the saving total quantity according to the actual condition of the service call request, and can adjust the concurrency quantity of the service call request to be saved. The simulation request pool calls corresponding services based on the stored service call requests, the call results are compared with built-in monitoring indexes and corresponding preset thresholds, and when the monitoring indexes of all call results of a certain type of service call requests do not exceed the corresponding preset thresholds, the degradation state of the service call requests can be relieved. The built-in monitoring index and the corresponding preset threshold used herein are the same as the monitoring index and the corresponding preset threshold used for performing degradation processing on a certain type of service call request.
In addition, C2 can also formulate a maximum number of concurrent requests, which is not limited by default.
C3 is used to process the degraded service call request. A destaging configuration list is built in the C3, and the destaging configuration list can be prefabricated in the C3 or pushed through S3. The downgrade configuration sheet sets the processing rules of the downgrade service, and includes two cases, one is pre-made in C3 and adopts the default mechanism to process the downgrade service and return downgrade basic service data, and the other is to request the downgrade service (identified by S4) to process the downgrade service and return downgrade service response results. Therefore, whatever rules are adopted to handle degraded services, the degraded data that C3 last generated is returned to C1 via C2.
C3 dynamically sets the demotion logic in a dynamic language or a scripting language. The source of the degraded data is divided into local and remote 2 ways. The local demotion data can dynamically customize the demotion service data, i.e., the basic service data provided by the demotion module itself, by pre-preparing within C3 or by pushing the demotion data logic and data format on demand through S3. The remote downgrade data dynamically customizes the downgrade service data by prepending it in C3 or by pushing the service address, name, etc. as needed through S3, i.e., the downgrade service data is returned by call S4. Common dynamic schemes include groovy based on a java terminal, lua based on a C/C + + terminal, PHP, C # and the like, and detailed description of the dynamic schemes is not involved here, and therefore is not repeated.
The four modules at the network side form an interactive relation with the terminal system to jointly complete the service calling request, and the four modules comprise:
s1 refers to providing a terminal with a required Service, and the Service may be in the form of a Service-oriented architecture (SOA) or a cloud-based Service. Normally, the service call request initiated by C1 reaches S1 via C2, and S1 responds to the request and returns the corresponding result to C2, which is then sent to C1 by C2.
The management platform for fault analysis (identified as S2) is used to analyze service anomalies and faults and alert important information. The service processing result is pushed to the S2 through the C2, the S2 can master the service and hardware running conditions at any time, the monitoring result is output through a related report and a display device, and further, fault information can be sent to a related person in charge through a short message or a mail.
S3 may be used to push a parameter configuration table for C2 or a downgrade configuration sheet for C3.
S4 refers to a failover service compatible with S1 services, which handles service invocation requests sent by C3 and returns degraded service data to C3.
For example, referring to FIG. 3, FIG. 3 is a schematic diagram of a service invocation.
C2 receives the service call request sent by C1, judges whether the service call request is degraded or not according to the call result monitoring index and the hardware environment monitoring index of various service call requests periodically obtained by C2, and directly calls corresponding services if the service call request is not degraded; if yes, the service calling request is sent to the C3 for processing, the service calling request is stored in a simulation request pool according to a set proportion, the simulation request pool calls corresponding services according to the number of concurrence of the simulation request pool, and calling results are monitored.
Referring to fig. 4, in the embodiment of the present application, a terminal specifically includes the following units:
a receiving unit 40, configured to receive a service invocation request of a certain type initiated to a server;
an obtaining unit 41, configured to obtain a monitoring index of a call result of the service call request;
the determining unit 42 is configured to perform degradation processing on the service invocation request when it is determined that a monitoring index of a certain invocation result of the service invoked by the service invocation request exceeds a corresponding preset threshold;
the simulation unit 43 is configured to set up a simulation request pool, and when it is determined that degradation processing is performed on the service invocation request, store a part of the service invocation request to the simulation request pool according to a set proportion;
and the simulation calling unit 44 is used for calling the corresponding service for the service calling request in the simulation request pool, and monitoring the calling result.
Preferably, when acquiring the monitoring index of the invocation result of the service invocation request, the acquiring unit 41 is specifically configured to:
and acquiring one or any combination of the average service response time, the total number of service data errors or exceptions and the percentage of service data errors or exceptions of the service invocation request as a monitoring index of the invocation result of the service invocation request.
Preferably, the determination unit 42 is further configured to:
acquiring local hardware environment monitoring indexes, and performing degradation processing on a certain type of service calling request when determining that the certain hardware environment monitoring index in the hardware environment monitoring indexes exceeds a corresponding preset threshold in the execution process of the service calling request; the hardware environment monitoring index includes one or any combination of local processor load value, memory consumption value and network connection average time.
Preferably, the simulation unit 43 is further configured to:
and if the multi-class service call requests are subjected to degradation processing, storing the multi-class service call requests into the simulation request pool according to corresponding set proportions, and discarding the exceeding service call requests when the total number of the stored service call requests exceeds the preset storage number.
Preferably, further comprising:
a downgrade processing unit 45, configured to directly return downgrade basic service data to the requester; alternatively, invoking the preconfigured downgrade service responds to the requestor.
Preferably, when the corresponding service is called for the service call request in the simulation request pool and the call result is monitored, the simulation call unit 44 is specifically configured to:
and when the monitoring indexes of all the calling results of a certain service calling request are determined not to exceed the corresponding preset threshold, the degradation state of the service calling request is relieved.
In the above logical structure, the receiving unit 40, the obtaining unit 41, the determining unit 42, the simulating unit 43, and the simulation invoking unit 44 are used to complete the function of the monitoring module, and the degradation processing unit 45 is used to complete the function of the degradation module.
To sum up, in the present application, when a terminal receives a service invocation request of a certain type initiated by a requester, according to an obtained monitoring index of an invocation result of the service invocation request, when determining that the monitoring index of the invocation result of the service invoked by the service invocation request exceeds a corresponding preset threshold, performing degradation processing on the service invocation request; and establishing a simulation request pool, storing the service call requests subjected to degradation processing into the simulation request pool according to a set proportion, calling corresponding services according to the service call requests in the simulation request pool, and continuously monitoring the calling results. Therefore, the method can effectively solve the problems of unstable terminal service and poor terminal service availability caused by complex access environment and uncertain factors, and ensures the service availability.
On the other hand, the degraded service call request is stored according to the set proportion, the corresponding service call request is called, and the call result is continuously monitored, so that the judgment basis can be accumulated for the next degradation judgment, the judgment result and the response result can be quickly returned when the terminal sends the service call request next time, and the response speed and the response efficiency of the terminal are greatly improved.
Furthermore, various monitoring indexes, corresponding preset thresholds, basic service data configuration and degraded service response data configuration can be pushed through the network side, dynamic customization of parameters is achieved, and monitoring and management of the terminal are greatly facilitated.
In addition, the terminal can also push the degradation result to a specified management platform for fault analysis, so that the fault can be immediately alarmed when occurring, and the position and the reason of the fault can be quickly positioned by using the collected information.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While the preferred embodiments of the present application have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all alterations and modifications as fall within the scope of the application.
It will be apparent to those skilled in the art that various changes and modifications may be made in the embodiments of the present application without departing from the spirit and scope of the embodiments of the present application. Thus, if such modifications and variations of the embodiments of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to encompass such modifications and variations.

Claims (12)

1. A method of service invocation, comprising:
receiving a certain type of service calling request initiated by a requester;
acquiring a monitoring index of a calling result of the service calling request;
when the monitoring index of a certain calling result of the service called by the service calling request exceeds a corresponding preset threshold, performing degradation processing on the service calling request;
setting a simulation request pool, and storing part of the service call requests to the simulation request pool according to a set proportion when judging that the service call requests are subjected to degradation processing;
and calling corresponding services according to the service calling requests in the simulation request pool, and monitoring calling results.
2. The method according to claim 1, wherein obtaining the monitoring index of the invocation result of the service invocation request specifically includes:
and acquiring one or any combination of the average service response time, the total number of service data errors or exceptions and the percentage of service data errors or exceptions of the service invocation request as a monitoring index of the invocation result of the service invocation request.
3. The method of claim 1, further comprising:
acquiring local hardware environment monitoring indexes, and performing degradation processing on the service calling request when determining that a certain hardware environment monitoring index in the hardware environment monitoring indexes exceeds a corresponding preset threshold in the execution process of the calling service calling request; the hardware environment monitoring index comprises one or any combination of a local processor load value, a memory consumption value and a network connection average time.
4. The method of claim 1, 2, or 3, further comprising:
and if the multi-class service call requests are subjected to degradation processing, storing the multi-class service call requests into the simulation request pool according to corresponding set proportions, and discarding the exceeding service call requests when the total number of the stored service call requests exceeds the preset storage number.
5. The method of claim 1, wherein after receiving a certain type of service invocation request initiated to a server, determining that a monitoring index of a certain invocation result of a service invoked by the certain type of service invocation request exceeds a corresponding preset threshold, and performing degradation processing on the certain type of service invocation request, the method further comprises:
directly returning the degraded basic service data to the requester; or,
invoking the preconfigured downgrade service to respond to the requestor.
6. The method of claim 1, wherein invoking the corresponding service for the service invocation request in the simulation request pool, and monitoring the invocation result specifically comprises:
and calling corresponding services aiming at the service calling requests in the simulation request pool, acquiring monitoring indexes of corresponding calling results, and removing the degradation state of the service calling requests when the monitoring indexes of all calling results of the service calling requests do not exceed corresponding preset thresholds.
7. An apparatus for service invocation, comprising:
a receiving unit, configured to receive a service invocation request of a certain type initiated to a server;
the acquisition unit is used for acquiring the monitoring index of the calling result of the service calling request;
the judging unit is used for performing degradation processing on the service calling request when the monitoring index of a certain calling result of the service called by the service calling request exceeds a corresponding preset threshold;
the simulation unit is used for establishing a simulation request pool, and storing part of the service call requests to the simulation request pool according to a set proportion when judging that the service call requests are subjected to degradation processing;
and the simulation calling unit is used for calling corresponding services according to the service calling requests in the simulation request pool and monitoring calling results.
8. The apparatus according to claim 7, wherein, when obtaining the monitoring indicator of the invocation result of the service invocation request, the obtaining unit is specifically configured to:
and acquiring one or any combination of the average service response time, the total number of service data errors or exceptions and the percentage of service data errors or exceptions of the service invocation request as a monitoring index of the invocation result of the service invocation request.
9. The apparatus of claim 7, wherein the determination unit is further to:
acquiring local hardware environment monitoring indexes, and performing degradation processing on the service calling request when determining that a certain hardware environment monitoring index in the hardware environment monitoring indexes exceeds a corresponding preset threshold in the execution process of the calling service calling request; the hardware environment monitoring index comprises one or any combination of a local processor load value, a memory consumption value and a network connection average time.
10. The apparatus of claim 7, wherein the analog unit is further to:
and if the multi-class service call requests are subjected to degradation processing, storing the multi-class service call requests into the simulation request pool according to corresponding set proportions, and discarding the exceeding service call requests when the total number of the stored service call requests exceeds the preset storage number.
11. The apparatus of claim 7, further comprising:
the degradation processing unit is used for directly returning degradation basic service data to the requester; alternatively, invoking the preconfigured downgrade service responds to the requestor.
12. The apparatus of claim 7, wherein when the corresponding service is called for the service call request in the simulation request pool and the call result is monitored, the simulation call unit is specifically configured to:
and calling corresponding services aiming at the service calling requests in the simulation request pool, acquiring monitoring indexes of corresponding calling results, and removing the degradation state of the service calling requests when the monitoring indexes of all calling results of the service calling requests do not exceed corresponding preset thresholds.
CN201410643943.6A 2014-11-11 2014-11-11 Service calling method and device Pending CN105656962A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410643943.6A CN105656962A (en) 2014-11-11 2014-11-11 Service calling method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410643943.6A CN105656962A (en) 2014-11-11 2014-11-11 Service calling method and device

Publications (1)

Publication Number Publication Date
CN105656962A true CN105656962A (en) 2016-06-08

Family

ID=56479557

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410643943.6A Pending CN105656962A (en) 2014-11-11 2014-11-11 Service calling method and device

Country Status (1)

Country Link
CN (1) CN105656962A (en)

Cited By (19)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106294073A (en) * 2016-08-15 2017-01-04 合智能科技(深圳)有限公司 Service calling method and device
CN106776099A (en) * 2017-01-11 2017-05-31 北京皮尔布莱尼软件有限公司 One kind service fusing shielding system and method
CN107196785A (en) * 2017-03-31 2017-09-22 北京奇艺世纪科技有限公司 The method and device that back-end services degrade automatically
CN107659431A (en) * 2017-08-15 2018-02-02 北京趣拿软件科技有限公司 Interface processing method, apparatus, storage medium and processor
CN107689886A (en) * 2017-08-11 2018-02-13 北京小度信息科技有限公司 Data-interface fault handling method, device and electronic equipment
CN107707384A (en) * 2017-09-06 2018-02-16 北京五八到家信息技术有限公司 A kind of service state monitoring method and monitoring system based on calling external service
CN108880854A (en) * 2018-04-09 2018-11-23 阿里巴巴集团控股有限公司 A kind of method, device and equipment of service degradation
CN108984376A (en) * 2018-05-31 2018-12-11 阿里巴巴集团控股有限公司 A kind of system anomaly detection method, device and equipment
CN109862052A (en) * 2017-11-30 2019-06-07 中国移动通信集团安徽有限公司 Call method, device, computer equipment and the storage medium of service request
CN109976900A (en) * 2017-12-28 2019-07-05 北京京东尚科信息技术有限公司 The method and apparatus for calling service
CN110012053A (en) * 2018-12-25 2019-07-12 阿里巴巴集团控股有限公司 System call method, device, equipment and SOA system architecture under SOA system architecture
CN110022301A (en) * 2019-03-07 2019-07-16 北京华安普特网络科技有限公司 Firewall is used in internet of things equipment protection
CN110034946A (en) * 2019-01-03 2019-07-19 阿里巴巴集团控股有限公司 Adaptive service degradation method and apparatus
CN110071952A (en) * 2018-01-24 2019-07-30 北京京东尚科信息技术有限公司 The control method and device of service call amount
CN110069337A (en) * 2018-01-24 2019-07-30 北京京东尚科信息技术有限公司 A kind of method and apparatus that disaster tolerance degrades
CN110162409A (en) * 2018-02-11 2019-08-23 北京京东尚科信息技术有限公司 Control method and device
CN110889073A (en) * 2019-11-21 2020-03-17 掌阅科技股份有限公司 Page request response method, server and computer storage medium
CN111181777A (en) * 2019-12-17 2020-05-19 深圳前海环融联易信息科技服务有限公司 Service degradation method, device, computer equipment and storage medium
CN114090037A (en) * 2021-11-12 2022-02-25 北京字节跳动网络技术有限公司 Service degradation method, device, computer equipment and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101272280A (en) * 2008-04-02 2008-09-24 北京邮电大学 Method and system for Web service management
CN102595518A (en) * 2011-01-14 2012-07-18 中兴通讯股份有限公司 Method and system for ensuring user service quality of household base station
CN103023938A (en) * 2011-09-26 2013-04-03 阿里巴巴集团控股有限公司 Service capability control method and system of server cluster

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101272280A (en) * 2008-04-02 2008-09-24 北京邮电大学 Method and system for Web service management
CN102595518A (en) * 2011-01-14 2012-07-18 中兴通讯股份有限公司 Method and system for ensuring user service quality of household base station
CN103023938A (en) * 2011-09-26 2013-04-03 阿里巴巴集团控股有限公司 Service capability control method and system of server cluster

Cited By (29)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106294073A (en) * 2016-08-15 2017-01-04 合智能科技(深圳)有限公司 Service calling method and device
CN106294073B (en) * 2016-08-15 2019-03-12 合一智能科技(深圳)有限公司 Service calling method and device
CN106776099A (en) * 2017-01-11 2017-05-31 北京皮尔布莱尼软件有限公司 One kind service fusing shielding system and method
CN106776099B (en) * 2017-01-11 2020-01-03 北京皮尔布莱尼软件有限公司 Service fusing isolation system and method
CN107196785A (en) * 2017-03-31 2017-09-22 北京奇艺世纪科技有限公司 The method and device that back-end services degrade automatically
CN107689886A (en) * 2017-08-11 2018-02-13 北京小度信息科技有限公司 Data-interface fault handling method, device and electronic equipment
CN107659431A (en) * 2017-08-15 2018-02-02 北京趣拿软件科技有限公司 Interface processing method, apparatus, storage medium and processor
CN107707384A (en) * 2017-09-06 2018-02-16 北京五八到家信息技术有限公司 A kind of service state monitoring method and monitoring system based on calling external service
CN109862052A (en) * 2017-11-30 2019-06-07 中国移动通信集团安徽有限公司 Call method, device, computer equipment and the storage medium of service request
CN109976900B (en) * 2017-12-28 2021-07-30 北京京东尚科信息技术有限公司 Method and device for calling service
CN109976900A (en) * 2017-12-28 2019-07-05 北京京东尚科信息技术有限公司 The method and apparatus for calling service
CN110071952A (en) * 2018-01-24 2019-07-30 北京京东尚科信息技术有限公司 The control method and device of service call amount
CN110069337B (en) * 2018-01-24 2024-07-16 北京京东尚科信息技术有限公司 Disaster recovery degradation method and device
CN110069337A (en) * 2018-01-24 2019-07-30 北京京东尚科信息技术有限公司 A kind of method and apparatus that disaster tolerance degrades
CN110071952B (en) * 2018-01-24 2023-08-08 北京京东尚科信息技术有限公司 Service call quantity control method and device
CN110162409B (en) * 2018-02-11 2024-06-18 北京京东尚科信息技术有限公司 Control method and device
CN110162409A (en) * 2018-02-11 2019-08-23 北京京东尚科信息技术有限公司 Control method and device
CN108880854A (en) * 2018-04-09 2018-11-23 阿里巴巴集团控股有限公司 A kind of method, device and equipment of service degradation
CN108880854B (en) * 2018-04-09 2021-10-29 创新先进技术有限公司 Service degradation method, device and equipment
CN108984376A (en) * 2018-05-31 2018-12-11 阿里巴巴集团控股有限公司 A kind of system anomaly detection method, device and equipment
CN108984376B (en) * 2018-05-31 2021-11-19 创新先进技术有限公司 System anomaly detection method, device and equipment
CN110012053B (en) * 2018-12-25 2021-07-20 创新先进技术有限公司 System calling method, device and equipment under SOA system architecture and SOA system architecture
CN110012053A (en) * 2018-12-25 2019-07-12 阿里巴巴集团控股有限公司 System call method, device, equipment and SOA system architecture under SOA system architecture
CN110034946A (en) * 2019-01-03 2019-07-19 阿里巴巴集团控股有限公司 Adaptive service degradation method and apparatus
CN110022301A (en) * 2019-03-07 2019-07-16 北京华安普特网络科技有限公司 Firewall is used in internet of things equipment protection
CN110889073A (en) * 2019-11-21 2020-03-17 掌阅科技股份有限公司 Page request response method, server and computer storage medium
CN110889073B (en) * 2019-11-21 2024-01-12 掌阅科技股份有限公司 Page request response method, server and computer storage medium
CN111181777A (en) * 2019-12-17 2020-05-19 深圳前海环融联易信息科技服务有限公司 Service degradation method, device, computer equipment and storage medium
CN114090037A (en) * 2021-11-12 2022-02-25 北京字节跳动网络技术有限公司 Service degradation method, device, computer equipment and storage medium

Similar Documents

Publication Publication Date Title
CN105656962A (en) Service calling method and device
US11102286B2 (en) Bandwidth scheduling method and device for cache server
CN108776934B (en) Distributed data calculation method and device, computer equipment and readable storage medium
EP3338191B1 (en) Diagnostic framework in computing systems
CN105743962A (en) End-to-end datacenter performance control
CN114915593B (en) Redis-based flow control method and device, electronic equipment and storage medium
WO2016204804A1 (en) Virtualized network function monitoring
WO2016069038A1 (en) Policy based workload scaler
CN109800204B (en) Data distribution method and related product
CN111124609B (en) Data acquisition method and device, data acquisition equipment and storage medium
US10419305B2 (en) Visualization of workload distribution on server resources
CN109981702B (en) File storage method and system
CN103856337A (en) Resource occupation rate acquiring method, providing method, system and server thereof
CN112579304A (en) Resource scheduling method, device, equipment and medium based on distributed platform
CN111209110A (en) Task scheduling management method, system and storage medium for realizing load balance
CN105049509A (en) Cluster scheduling method, load balancer and clustering system
CN106375102A (en) Service registration method, application method and correlation apparatus
WO2016119389A1 (en) Management method, device and system for system docking
US20190215262A1 (en) System and method for dynamically testing networked target systems
CN103488538B (en) Application extension device and application extension method in cloud computing system
CN103944940A (en) Equipment and method for dynamically configuring proxy server
CN111427674A (en) Micro-service management method, device and system
CN110795202B (en) Resource allocation method and device of virtualized cluster resource management system
CN109510730A (en) Distributed system and its monitoring method, device, electronic equipment and storage medium
CN115002117B (en) Dynamic scheduling method, system, equipment and storage medium for content distribution network

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 1225534

Country of ref document: HK

RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20160608

REG Reference to a national code

Ref country code: HK

Ref legal event code: WD

Ref document number: 1225534

Country of ref document: HK