Data processing method and device in service architecture, electronic equipment and storage medium

By obtaining and analyzing error information in the service architecture, and automatically determining the services that cause service request failure, the problem of inefficient error positioning in the prior art is solved and the efficiency of system recovery is improved.

CN120201076APending Publication Date: 2025-06-24BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510387297.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-28
Publication Date
2025-06-24

AI Technical Summary

Technical Problem

The efficiency of mislocalization in the prior art is low, resulting in a lower efficiency of the system recovering from failures.

Method used

By implementing the data processing method in the service architecture, a service request from the terminal device is received, an error information of the first service is obtained when the request fails, and a service that causes the service request to fail is determined based on this information.

Benefits of technology

It improves the accuracy and efficiency of mispositioning, reduces the time for manual investigation, and thus improves the efficiency of the system to recover from failure.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120201076A_ABST
    Figure CN120201076A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a data processing method and device in a service architecture, electronic equipment and a storage medium, and relates to the technical field of the Internet, and the method comprises the steps: receiving a service request sent by terminal equipment; when the service request fails, first information is obtained from first services corresponding to the service request, the first services are services which have errors when the service request is processed, and the first information comprises error information corresponding to each first service; and according to the first information, determining the service causing the failure of the service request in the first service. And the error positioning efficiency and accuracy are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present disclosure relate to the field of Internet technologies, and in particular, to a data processing method, apparatus, electronic device, and storage medium in a service architecture. Background Art

[0002] The functions of an application can be completed through the cooperation of multiple services. When a function fails, relevant personnel need to locate errors in multiple services.

[0003] Currently, when a function fails, relevant personnel can determine whether an error has occurred in a service in sequence according to the call chain of multiple services related to the function. For example, the call chain corresponding to the function is Service 1 - Service 2 - Service 3. When an error occurs in Service 2 and causes the function request to fail, Service 1 feedbacks that the function request fails. Relevant personnel can determine whether an error has occurred in Service 1. When there is no error in Service 1, then determine whether an error has occurred in Service 2. In the above method, manual error location takes a long time, resulting in low efficiency of error location. Summary of the Invention

[0004] Embodiments of the present disclosure provide a data processing method, apparatus, electronic device, and storage medium in a service architecture, which are used to solve the technical problem of low efficiency of error location in the prior art.

[0005] In a first aspect, embodiments of the present disclosure provide a data processing method in a service architecture. The data processing method in the service architecture includes:

[0006] Receiving a service request sent by a terminal device;

[0007] When the service request fails, obtaining first information in a first service corresponding to the service request, where the first service is the service that has an error when processing the service request, and the first information includes error information corresponding to each first service;

[0008] Determining, according to the first information, the service that causes the service request to fail in the first service.

[0009] In a second aspect, embodiments of the present disclosure provide a data processing apparatus in a service architecture. The data processing apparatus in the service architecture includes a receiving module, an obtaining module, and a determining module, where:

[0010] The receiving module is configured to receive a service request sent by a terminal device;

[0011] The obtaining module is configured to, when the service request fails, obtain first information in a first service corresponding to the service request, where the first service is the service that has an error when processing the service request, and the first information includes error information corresponding to each first service;

[0012] The determining module is configured to determine, according to the first information, a service in the first service that causes the service request to fail.

[0013] In a third aspect, the present disclosure provides an electronic device including: a processor and a memory;

[0014] The memory stores computer-executable instructions;

[0015] The processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the data processing method in the service architecture as described in the first aspect and various possible aspects of the first aspect.

[0016] In a fourth aspect, the present disclosure provides a computer-readable storage medium storing computer-executable instructions, and when the processor executes the computer-executable instructions, the data processing method in the service architecture as described in the first aspect and various possible aspects of the first aspect is implemented.

[0017] In a fifth aspect, the present disclosure provides a computer program product including a computer program, and when the computer program is executed by a processor, the data processing method in the service architecture as described in the first aspect and various possible aspects of the first aspect is implemented.

[0018] The embodiments of the present disclosure provide a data processing method, apparatus, electronic device, and storage medium in a service architecture. The electronic device can receive a service request sent by a terminal device. When the service request fails, the electronic device can obtain first information in the first service corresponding to the service request, where the first service may be the service where an error occurs when processing the service request, and the first information may include error information corresponding to each first service. The terminal device can determine, according to the first information, the service that causes the service request to fail in the first service. In the above method, when the service request fails, since the first information can include error information corresponding to each service where an error occurs, the electronic device can accurately determine the service that causes the service request to fail based on this first information, improving the accuracy of error location. Moreover, there is no need for manual step-by-step investigation of each first service based on the call chain. Therefore, the efficiency of error location can be improved, and further the efficiency of the system recovering from failure can be improved. Description of the Drawings

[0019] In order to more clearly illustrate the technical solutions in the embodiments of the present disclosure or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present disclosure. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0020] Figure 1 A schematic diagram of an application scenario provided by an embodiment of the present disclosure;

[0021] Figure 2 A flowchart of a data processing method in a service architecture provided by an embodiment of the present disclosure;

[0022] Figure 3 A schematic diagram of a service architecture provided by an embodiment of the present disclosure;

[0023] Figure 4 A schematic diagram of a method for determining a service that causes a service request to fail provided by an embodiment of the present disclosure;

[0024] Figure 5 A schematic diagram of a dependency relationship provided by an embodiment of the present disclosure;

[0025] Figure 6 A schematic diagram of a process for determining first information provided by an embodiment of the present disclosure;

[0026] Figure 7 Another schematic diagram of a method for determining a service that causes a service request to fail provided by an embodiment of the present disclosure;

[0027] Figure 8 A schematic diagram of the structure of a data processing device in a service architecture provided by an embodiment of the present disclosure;

[0028] Figure 9 A schematic diagram of the structure of an electronic device provided by an embodiment of the present disclosure. Detailed implementation manners

[0029] Here, exemplary embodiments will be described in detail, and examples thereof are shown in the drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementation manners described in the following exemplary embodiments do not represent all implementation manners consistent with the present disclosure. On the contrary, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.

[0030] It can be understood that before using the technical solutions disclosed in the embodiments of the present disclosure, the types, usage scopes, usage scenarios, etc. of the personal information involved in the present disclosure should be informed to users and user authorization should be obtained in an appropriate manner in accordance with relevant laws and regulations.

[0031] For example, when responding to an active request from a user, a prompt message is sent to the user to clearly prompt the user that the operation requested by the user will require obtaining and using the user's personal information. Thus, the user can autonomously choose whether to provide personal information to software or hardware such as a terminal device, an application, a server, or a storage medium that performs the operations of the present disclosure's technical solution based on the prompt message.

[0032] As an optional but non-limiting implementation manner, when responding to an active request received from a user, the manner of sending a prompt message to the user may, for example, be in the form of a pop-up window, and the prompt message may be presented in text in the pop-up window. In addition, the pop-up window may also carry a selection control for the user to choose "agree" or "disagree" to provide personal information to the terminal device.

[0033] It can be understood that the above process of notifying and obtaining user authorization is only illustrative and does not constitute a limitation on the implementation manner of the present disclosure. Other manners that comply with relevant laws and regulations can also be applied to the implementation manner of the present disclosure.

[0034] Next, in conjunction with Figure 1 , the application scenarios of the embodiments of the present disclosure will be described.

[0035] Figure 1 FIG. is a schematic diagram of an application scenario provided by an embodiment of the present disclosure. Please refer to Figure 1 , which includes a terminal device and a server. Among them, the interface displayed by the terminal device includes a recorded meeting, a text recording control, and a speaker control. When the user clicks on the text recording control, the terminal device can display the text corresponding to the voice in the recorded meeting. However, due to the failure of the voice-to-text request, the text loading of the recorded meeting fails. The terminal device can send a message indicating the failure of the voice-to-text request to the server. After receiving the message, the server can notify the relevant personnel responsible for maintaining the voice-to-text function and conduct a manual investigation to determine the reason for the failure of the voice-to-text.

[0036] In the related art, the service functions of an application can be completed through the collaboration of multiple services (microservices). Therefore, when a service function request fails, the relevant personnel of the service function need to locate errors in multiple services. Currently, the relevant personnel can determine whether each service has an error in sequence according to the call chain of multiple services related to the service function. For example, when a terminal device requests a service function of an application, the call chain corresponding to the service function is Service 1 - Service 2 - Service 3, that is, the implementation of the service function requires Service 1 to call Service 2, and Service 2 to call Service 3. When an error occurs in Service 3 and causes the service function request to fail, Service 1 can feedback that the service function request fails. The relevant personnel can determine whether Service 1 has an error. When Service 1 has no error, then determine whether Service 2 has an error. When Service 2 has no error, then determine whether Service 3 has an error. In this way, the relevant personnel need to determine whether each service has an error in sequence according to the call chain. When the number of services is large, the efficiency of manual error location is low, which in turn leads to low efficiency of error location.

[0037] To solve the technical problems in the related art, an embodiment of the present disclosure provides a data processing method in a service architecture. An electronic device can receive a service request sent by a terminal device. When the service request fails, the electronic device can obtain first information in a first service corresponding to the service request, where the first service is the service that has an error when processing the service request, and the first information may include error information corresponding to each first service. The electronic device can determine the service that causes the service request to fail in the first service according to the first information.

[0038] In the above method, the error information corresponding to the first service includes at least one of the following: error code, error description, error cause. And if the failure of the service request is caused by the first service, the error information of the first service in the first information includes the error code and the error description. If the failure of the service request is not caused by the first service, the error information of the first service in the first information includes the error code, the error description, and the error cause. Therefore, the electronic device determines the first service in the first information that does not transmit the error cause and determines this first service as the service that causes the service request to fail. This can improve the accuracy of error location, and there is no need for manual step-by-step investigation of each first service based on the call chain. Therefore, the efficiency of error location can be improved.

[0039] The following uses specific embodiments to elaborate in detail on the technical solution of the present disclosure and how the technical solution of the present disclosure solves the above technical problems. These specific embodiments below can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present disclosure will be described below with reference to the accompanying drawings.

[0040] Figure 2 A flowchart of a data processing method in a service architecture provided by an embodiment of the present disclosure. Please refer to Figure 2 The method may include:

[0041] S201. Receive a service request sent by a terminal device.

[0042] The execution subject of the embodiment of the present disclosure may be an electronic device or a data processing device in the service architecture of the electronic device. Among them, the data processing device in the service architecture may be implemented according to software, or may be implemented by a combination of software and hardware. The embodiment of the present disclosure does not limit this.

[0043] In some embodiments, the service request may be used to request the service function of an application. For example, the service request may be used to start the service function of an application, may also be used to close the service function of an application, and may also be used to adjust the parameters corresponding to the service function of an application. The embodiment of the present disclosure does not limit this.

[0044] Exemplarily, when the user clicks the voice-to-text control of the application, the electronic device may generate a service request to start voice-to-text. If the service request is successful, the application may start the voice-to-text service function. If the service request fails, the application cannot start the voice-to-text service function.

[0045] Exemplarily, when the user adds a filter during video recording, the electronic device may generate a service request to add a filter. If the service request is successful, the electronic device may add a filter during video recording. If the service request fails, the electronic device will not add a filter during video recording.

[0046] In some embodiments, the terminal device may send a service request to the electronic device based on the user's operation. For example, the terminal device may start an application, and the user's operation may trigger (gesture trigger, touch trigger, voice trigger, etc.) the service function in the application. When the service function is triggered, the terminal device may send a request for the service function to the server.

[0047] In some embodiments, the electronic device may receive at least one service request sent by one terminal device, or may receive multiple service requests sent by multiple terminal devices. Moreover, the multiple service requests received by the electronic device may be the same or different. The embodiment of the present disclosure does not limit this.

[0048] It should be noted that the electronic device may also receive the service request sent by the terminal device based on any feasible implementation manner. The embodiment of the present disclosure does not limit this.

[0049] S202. When the service request fails, obtain first information in the first service corresponding to the service request.

[0050] In some embodiments, the first service may be the service that encounters an error when processing the service request. For example, an electronic device may process a service request through multiple services. When the service request fails, some services may encounter errors, and among them, the service that encounters an error may be the first service. For example, an electronic device may process a service request through Service 1, Service 2, Service 3, and Service 4. When the service request fails, Service 1, Service 2, and Service 3 encounter errors, and the electronic device may determine that the first service includes Service 1, Service 2, and Service 3.

[0051] Next, in combination with Figure 3 , the service architecture will be described. The service architecture may be composed of services.

[0052] Figure 3 FIG. Figure 3 is a schematic diagram of a service architecture provided by an embodiment of the present disclosure. Please refer to Figure 3 , which includes a service architecture. The service architecture is composed of Service 1, Service 2, Service 3, and Service 4. When completing a service request, Service 1, Service 2, Service 3, and Service 4 will be called (for example, Service 1 is the entry of the service architecture, and Service 1 will directly or indirectly call Service 2, Service 3, and Service 4). When Service 1 fails to call Service 2, the service request will fail. Therefore, the electronic device ( Figure 3 not shown) determines that the services that encounter errors when processing the service request include Service 1 and Service 2 (since Service 2 encounters an error, resulting in Service 1 also encountering an error), and the electronic device may determine that the first service includes Service 1 and Service 2.

[0053] In some embodiments, the first information may include error information corresponding to each first service. For example, the error information can be used to locate the error of the failed service request. For example, when the service request fails, each first service can generate error information, and the electronic device can obtain the error information corresponding to each first service to obtain the first information.

[0054] In some embodiments, the electronic device may merge the error information corresponding to each first service into a structured error chain, and then obtain the first information. In this way, the electronic device can accurately determine the order and association of the errors based on the first information, and then accurately determine the service that causes the request to fail.

[0055] In some embodiments, the error chain corresponding to the first information may be a recursive structure.

[0056] It should be noted that the electronic device may determine the first service based on any feasible implementation manner, and the embodiments of the present disclosure do not limit this.

[0057] In some embodiments, the electronic device may obtain first information in a first service corresponding to a service request based on the following feasible implementation: determine the processing order of the first service for processing the service request, determine the first service that processes the service request first according to the processing order, obtain the error information corresponding to the first service that processes the service request first, and obtain the first information. In this way, since the first information is a recursive error chain, each first service will send error information to the previous first service level by level. Therefore, the electronic device can obtain the first information at the first first service, improving the accuracy and efficiency of obtaining the first information.

[0058] Among them, the processing order may be the order in which the first service processes the service request. For example, in Figure 3 the illustrated embodiment, if the first service includes Service 1, Service 2, and Service 4, the electronic device may determine the processing order of the first service for processing the service request as: Service 1 - Service 2 - Service 4. It should be noted that the electronic device may determine this processing order based on any feasible implementation, and the embodiments of the present disclosure do not limit this.

[0059] Exemplarily, when the service request fails, the first service may feedback the error information corresponding to the first service to the previous service (which may also be the first service). Therefore, the error information corresponding to each first service may be included at the first service (or the first first service). In Figure 3 the illustrated embodiment, Service 1 may generate the error information of Service 1, Service 2 may generate the error information of Service 2, and Service 2 may send the error information of Service 2 to Service 1. In this way, the electronic device can obtain the error information of Service 1 and the error information of Service 2 at Service 1, and accurately locate the error based on the error information of Service 1 and the error information of Service 2.

[0060] In some embodiments, the error information may include at least one of the following:

[0061] Error code;

[0062] Error description;

[0063] Cause of error.

[0064] The error code may be a unique identifier. For example, the error code may be represented in the form of numbers or codes, and the error code may be used to represent the occurred error or exception.

[0065] The error description may be an explanation or description of the error code. For example, the error description may be represented in the form of text, and the error description may indicate the nature, cause, and possible impact of the error.

[0066] Exemplarily, if the error code is: 400, the error description corresponding to this error code can be: Bad Request. That is, there is a syntax error in the request, or the request is invalid, or the server cannot understand the content of the request.

[0067] Exemplarily, if the error code is: 401, the error description corresponding to the error code can be: Unauthorized. That is, the request requires user authentication, but due to lack of authentication or authentication failure, the server refuses to provide the requested resource.

[0068] Exemplarily, if the error code is: 403, the error description corresponding to the error code can be: Forbidden. That is, the server can understand the request, but refuses to execute it. For example, due to insufficient permissions of the requesting user, the server refuses to provide the requested resource.

[0069] Exemplarily, if the error code is: 404, the error description corresponding to the error code can be: NotFound. That is, the requested resource is not obtained on the server. For example, when the user enters an incorrect Uniform Resource Locator (URL), or the resource requested by the user has been deleted, the error code is 404.

[0070] Exemplarily, if the error code is: 500, the error description corresponding to this error code can be: Internal Server Error. That is, there is an unknown situation on the server, resulting in the server being unable to complete the request. For example, an internal error or configuration problem on the server.

[0071] Exemplarily, if the error code is: 502, the error description corresponding to the error code can be: BadGateway. That is, the server acting as a gateway or proxy received an invalid response from the upstream server.

[0072] Exemplarily, if the error code is: 503, the error description corresponding to the error code can be: Service Unavailable. That is, the server is currently unavailable (due to overload or maintenance).

[0073] Exemplarily, if the error code is: 504, the error description corresponding to the error code can be: GatewayTimeout. That is, the server acting as a gateway or proxy did not receive the request from the upstream server in time.

[0074] It should be noted that the content of the above examples is only an example of the error code and error description, and is not a limitation on the error code and error description in the embodiments of the present disclosure.

[0075] In some embodiments, when an error occurs in the first service, the first service may determine the error code and error description corresponding to the error. The electronic device may also obtain the error code and error description of the first service according to any feasible implementation manner, and the embodiments of the present disclosure do not limit this.

[0076] In this way, the electronic device can quickly identify and classify the error types occurring in the first service through the error code. Moreover, based on the error description, the nature of the error, the cause of the error, and the possible impacts can be accurately determined. Therefore, the electronic device can quickly perform error localization according to the error information and determine the service that causes the service request to fail.

[0077] In some embodiments, the cause of the error may be the reason that causes the error in the first service. For example, the first service 1 may call the first service 2, and the cause of the error in the first service 1 is the error of the first service 2, that is, the cause of the error in the first service 1 may be the error information of the first service 2. If the first service 2 can call the first service 3, then the cause of the error in the first service 2 is the error of the first service 3, that is, the cause of the error in the first service 2 may be the error information of the first service 3.

[0078] S202. Determine the service that causes the service request to fail in the first service according to the first information.

[0079] In some embodiments, when the electronic device processes a service request, the called services include service 1, service 2, service 3, and service 4. Among them, service 1, service 2, and service 3 have errors during the process of processing the service request. The electronic device may determine that the first service includes service 1, service 2, and service 3. Moreover, if the errors of service 2 and service 1 are caused by the error of service 3, the electronic device may determine service 3 as the service that causes the service request to fail. For example, in Figure 3 the shown embodiment, service 1 and service 2 have errors. Among them, the error of service 1 is caused by the error of service 2. Therefore, the electronic device may determine service 2 as the service that causes the service request to fail.

[0080] An embodiment of the present disclosure provides a data processing method in a service architecture. An electronic device may receive a service request sent by a terminal device. When the service request fails, the electronic device may determine the processing order of the first service for processing the service request, and based on the processing order, determine the first service that processes the service request first. The electronic device may obtain the error information corresponding to the first service that processes the service request first to obtain the first information, and based on the first information, determine the service that causes the service request to fail in the first service. In the above method, the error information corresponding to the first service may include an error code, an error description, and an error cause. Therefore, the electronic device may accurately determine the service that causes the service request to fail based on the error information corresponding to each first service in the first information, improving the accuracy of error location. Moreover, there is no need for manual step-by-step investigation of each first service based on the call chain. Therefore, the efficiency of error location can be improved.

[0081] Based on the embodiment shown in Figure 2 , the following will combine Figure 4 to elaborate in detail on the method by which the electronic device determines the service that causes the service request to fail in the first service in the above data processing method in the service architecture.

[0082] Figure 4 FIG. is a schematic diagram of a method for determining the service that causes the service request to fail provided by an embodiment of the present disclosure. Please refer to Figure 4 , and the method flow includes:

[0083] S401. Determine the error information in the first information that does not include the error cause.

[0084] In some embodiments, the error information corresponding to the first service in the first information may not include the error cause. In other words, the failure of the service request is caused by the first service. Therefore, the first service does not include the error cause, that is, the first service calls other services successfully, or the first service does not have other services to call, but the first service has an error. In this way, the electronic device may determine that the error information corresponding to the first service does not include the error cause.

[0085] In some embodiments, there are the following two situations for the error information of the first service:

[0086] Situation 1: The failure of the service request is caused by the first service.

[0087] If the failure of the service request is caused by the first service, the error information of the first service in the first information includes an error code and an error description.

[0088] Exemplarily, if the first service determines that it causes the failure of the service request, the error information feedback by the first service may include an error code and an error description. In this way, the electronic device can accurately determine the service that causes the service request to fail according to the error information feedback by each first service.

[0089] In some embodiments, the first service may determine whether the failure of the service request is caused by the first service according to the service called by the first service.

[0090] Exemplarily, if the first service can successfully call other services, or other services that the first service does not call, the first service may determine that the failure of the service request is caused by the first service. In other words, the first service can normally call other services, but an error still occurs in the first service. Therefore, the error of the service request is caused by the first service. If the first service cannot successfully call other services, the first service may determine that the failure of the service request is caused by the other services called.

[0091] Exemplarily, in Figure 3 the shown embodiment, Service 1 and Service 2 are the first services. Among them, during the process of Service 1 calling Service 2, an error occurs in Service 1. However, since an error also occurs in Service 2, the root cause of the service request failure is not the error in Service 1. During the process of Service 2 calling Service 4, an error occurs in Service 2. And since Service 2 can successfully call Service 4, Service 4 is normal. The electronic device can determine that the root cause of the service request failure is the error in Service 2.

[0092] In some embodiments, if the service request failure is caused by the first service, the error information corresponding to the first service may include an error code and / or an error description, without including other error-related information. In this way, the electronic device can accurately determine the service that causes the service request to fail according to whether other error-related information is included in the error information.

[0093] Case 2: The failure of the service request is not caused by the first service.

[0094] If the failure of the service request is not caused by the first service, the error information of the first service in the first information includes an error code, an error description, and an error cause.

[0095] Exemplarily, if the first service determines that the failure of the service request is not caused by the first service, the error information feedback by the first service may include an error code, an error description, and an error cause. In this way, the electronic device can accurately determine the service that causes the service request to fail according to the error cause.

[0096] In some embodiments, the error reason of the first service is determined according to the second information. The second information may include at least one of the following: the identifier of the second service, the interface identifier of the second service, and the error information of the second service.

[0097] The second service may be the service of the dependent party corresponding to the first service. For example, the electronic device may determine the service (the service of the dependent party) on which the first service depends according to the first service and the dependency relationship, and determine the service on which the first service depends as the second service corresponding to the first service. In this way, the electronic device can accurately determine the error reason according to the dependency relationship. Moreover, the error information of the first service in the first information is a recursive structure. Therefore, the electronic device can accurately perform error location.

[0098] The dependency relationship may indicate the data call relationship between multiple services required to process the service request. For example, the services required to process the service request include Service 1, Service 2, and Service 3. If Service 1 calls Service 2 and Service 2 calls Service 3, the dependency relationship may be Service 1 - Service 2 - Service 3.

[0099] Next, in combination with Figure 5 , the dependency relationship between multiple services required to process the service request will be described.

[0100] Figure 5 FIG. is a schematic diagram of a dependency relationship provided by an embodiment of the present disclosure. Please refer to Figure 5 , including: Service 1, Service 2, Service 3, and Service 4. Among them, Service 1 may call Service 2 and Service 3, and Service 2 and Service 3 may call Service 4. If the service request to be processed calls Service 1, Service 2, and Service 4, the dependency relationship is Service 1 - Service 2 - Service 4. If the service request to be processed calls Service 1, Service 3, and Service 4, the dependency relationship is Service 1 - Service 3 - Service 4. If the service request to be processed calls Service 1, Service 2, Service 3, and Service 4, the dependency relationships are: Service 1 - Service 2 - Service 4; Service 1 - Service 3 - Service 4.

[0101] In some embodiments, if the second service corresponding to the first service is the service that has an error, the error information of the first service may include the error reason, and the error reason may include the second information; if the second service corresponding to the first service is the service that has no error, the error information of the first service does not include the error reason. In other words, it is the first service that causes the service request to fail. In this way, the electronic device can accurately determine the service that causes the service request to fail according to the error information of the first service.

[0102] Exemplarily, the services required to process a service request include Service 1, Service 2, and Service 3, with a dependency relationship of Service 1 - Service 2 - Service 3. When the service request fails, errors occur in Service 1 and Service 2. That is, the first service includes Service 1 and Service 2. Regarding Service 1, this service depends on the data of Service 2. Therefore, the dependent service corresponding to Service 1 is Service 2. That is, the second service corresponding to Service 1 is Service 2. Regarding Service 2, this service depends on the data of Service 3. Therefore, the dependent service corresponding to Service 2 is Service 3. That is, the second service corresponding to Service 2 is Service 3. Thus, since the Service 2 called by Service 1 is in error and the Service 3 called by Service 2 is normal, the error information feedback by Service 1 includes an error code, an error description, and an error reason. That is, the reason for the error in Service 1 is that the called Service 2 is in error. In other words, the failure of this service request is not caused by Service 1. The error information feedback by Service 2 includes an error code and an error description, and does not include an error reason. That is, the reason for the error in Service 2 is not caused by the called Service 3. In other words, the failure of this service request is caused by Service 2.

[0103] In some embodiments, a service identifier can be used to indicate a second service, and the interface identifier of the second service can be used to indicate an interface in the second service. The error information of the second service can include an error code, an error description, and may include an error reason. In other words, the failure of the service request is not caused by the second service. The error information of the second service in the second information can include an error reason, and the failure of the service request is caused by the second service. The error information of the second service in the second information does not include an error reason.

[0104] In some embodiments, the second service can include multiple sub - services and the interfaces corresponding to each sub - service. For example, Sub - service 1 is associated with Service Request A, and Sub - service 2 is associated with Service Request B. When the electronic device processes Service Request A, it can call Sub - service 1, and when processing Service Request B, it can call Sub - service 2.

[0105] Exemplarily, the second service can include Sub - service 1 and Sub - service 2. Sub - service 1 is associated with Interface a, and Sub - service 2 is associated with Interface b. When the electronic device processes Service Request A, the first service can call Sub - service 1 through Interface a of the second service. When the electronic device processes Service Request B, the first service can call Sub - service 2 through Interface b of the second service.

[0106] In some embodiments, each service required to process a service request can include at least one sub - service and the interface corresponding to each sub - service. The embodiments of the present disclosure do not limit this.

[0107] In some embodiments, the service identifier of the second service may be a unique identifier indicating the second service, or any identifier that can indicate the second service. The interface identifier of the second service may be a unique identifier indicating the interface, or any identifier that can indicate the interface. The embodiments of the present disclosure do not limit this.

[0108] Next, with reference to Table 1, the format of the error message will be described.

[0109] Table 1

[0110]

[0111] It should be noted that Table 1 is only an example of the format of the error message, not a limitation on the format of the error message. The embodiments of the present disclosure do not limit this.

[0112] Next, with reference to Table 2, the format of the error cause will be described.

[0113] Table 2

[0114] Field Name Type Optional Description endpoint string Required Service Identifier method string Required Service Interface Identifier error Error info Required Error Message

[0115] It should be noted that Table 2 is only an example of the format of the error cause, not a limitation on the format of the error cause. The embodiments of the present disclosure do not limit this.

[0116] In some embodiments, each first service can feedback error information to the corresponding dependent service. That is, each first service can send the error information of the first service to the previous first service. In this way, the first first service can include the error information of each first service. That is, the error information of the first first service can include the error information of each first service.

[0117] Next, with reference to Figure 6 , the process of determining the first information will be described.

[0118] Figure 6 is a schematic diagram of the process of determining the first information provided by the embodiments of the present disclosure. Please refer to Figure 6 , including: Service 1, Service 2, and Service 3. Service 1 includes Interface A, Service 2 includes Interfaces B and C, and Service 3 includes Interfaces D and E. When an electronic device ( Figure 6 not shown) processes a service request, Service 1 can call Service 2 through Interface A and Interface C, and Service 2 can call Service 3 through Interface C and Interface D.

[0119] Please refer to Figure 6, when the service request fails, errors occur in Service 1, Service 2, and Service 3. When Service 3 encounters an error, Service 3 can feedback error message a to Service 2. Since Service 3 does not call other services, the root cause of the request failure is the error in Service 3. The error message a feedback by Service 3 can include an error code and an error description, but not the error cause. Among them, the error code is 500, and the error description is "storage error".

[0120] Please refer to Figure 6 , when Service 2 encounters an error, Service 2 can feedback error message b to Service 1. Since the Service 3 called by Service 2 encounters an error, the error message b feedback by Service 2 can include an error code, an error description, and an error cause. Among them, the error code is 502, the error description is "dependency error", and the error cause includes a service identifier, an interface identifier of the service, and an error message. Among them, the service identifier is Service 3 (the identifier of Service 3), the interface identifier of the service is Interface D (the identifier of Interface D), and the error message is the error code (500) and the error description ("storage error"), that is, the error message in the error cause is the error message a feedback by Service 3.

[0121] Please refer to Figure 6 , when Service 1 encounters an error, Service 1 can determine error message c. Since the Service 2 called by Service 1 encounters an error, the error message c determined by Service 1 can include an error code, an error description, and an error cause. Among them, the error code is 502, the error description is "dependency error", and the error cause includes a service identifier, an interface identifier of the service, and an error message. Among them, the service identifier is Service 2 (the identifier of Service 2), the interface identifier of the service is Interface C (the identifier of Interface C), and the error message is the error message b feedback by Service 2. The electronic device can determine that the first information is error message c.

[0122] S402. Determine the first service corresponding to the error message that does not include the error cause as the service that causes the service request to fail.

[0123] In some embodiments, after the electronic device obtains the first information, it can determine the error message that does not include the error cause, accurately determine the cause of the error based on the error code and error description in the error message, and accurately determine the first service that causes the service request to fail based on the service identifier and interface identifier in the error cause that includes the error message. In this way, the electronic device can accurately locate the error.

[0124] Exemplarily, in Figure 6In the illustrated embodiment, the first information obtained by the electronic device is error message c. Since error message c includes the error cause, the electronic device determines that the failure of the service request is not caused by Service 1. Moreover, the electronic device can determine that Service 1 has a dependency error based on the error code and error description in error message c, and determine that the error of Service 1 is caused by Interface C of Service 2 according to the error cause in error message c, that is, an error occurs in Interface C of Service 2, causing an error in Service 1. The electronic device can obtain error message b from the error cause in error message c, determine that Service 2 has a dependency error based on the error code and error description in error message b, and determine that the error of Service 2 is caused by Interface D of Service 3 according to the error cause in error message b, that is, an error occurs in Interface D of Service 3, causing an error in Service 2. The electronic device can obtain error message a from the error cause in error message b. Since error message a does not include the error cause, the electronic device can determine that the failure of the service request is caused by Interface D of Service 3, and determine that the root cause of the failure of the service request based on the error code and error description in error message a is: a storage error occurs in Interface D of Service 3. In this way, the electronic device can perform error localization in a timely and accurate manner, accurately determine the root cause of the service request failure, thereby improving the accuracy and efficiency of error localization, and can also improve the efficiency of error handling.

[0125] The embodiments of the present disclosure provide a method for determining the service that causes the failure of a service request. If the failure of the service request is caused by the first service, the error information of the first service in the first information includes an error code and an error description. If the failure of the service request is not caused by the first service, the error information of the first service in the first information includes an error code, an error description, and an error cause. Therefore, the electronic device can determine the error information in the first information that does not include the error cause, and determine the first service corresponding to the error information that does not include the error cause as the service that causes the failure of the service request. In the above method, the error cause in the error information of the first service is determined based on the identifier of the second service, the interface identifier of the second service, and the error information of the second service. Therefore, the electronic device can perform error localization in a timely and accurate manner based on the error information of the first service in the first information, accurately determine the root cause of the service request failure, thereby improving the accuracy and efficiency of error localization, and can also improve the efficiency of error handling.

[0126] Based on any of the above embodiments, the data processing method in the above service architecture further includes another method for determining the service that causes the failure of a service request. Next, in combination with Figure 7 , a detailed description of another method for determining the service that causes the failure of a service request will be given.

[0127] Figure 7 Another schematic diagram of a method for determining a service that causes a service request to fail provided by an embodiment of the present disclosure. Please refer to Figure 7 , and the method flow may include:

[0128] S701. In response to the failure of multiple service requests received from a terminal device, obtain first information corresponding to each service request.

[0129] In some embodiments, when a service request sent by a terminal device fails, the electronic device may not perform error localization (for example, a service request failure caused by network fluctuations, etc.). When the service request fails multiple times, the electronic device can determine that there are errors in multiple services corresponding to the service function. Therefore, the electronic device can obtain multiple first information corresponding to the service requests that have failed multiple times (a first information is determined each time a service request fails), and perform error localization based on the multiple first information.

[0130] In some embodiments, within a period of time, multiple terminal devices may request the same service function, that is, the electronic device can receive multiple service requests sent by multiple terminal devices within a period of time. The multiple service requests are used to request the same service function. When the multiple service requests fail multiple times, the electronic device can obtain multiple first information corresponding to the multiple failed service requests, and perform error localization based on the multiple first information.

[0131] Exemplarily, the first threshold may be 100. Within a period of time, if 150 service requests all fail, the electronic device can obtain the first information corresponding to the 150 service requests.

[0132] In some embodiments, when the number of continuously failed service requests is greater than or equal to a second threshold, the electronic device can obtain multiple first information corresponding to multiple service requests. For example, the second threshold may be 50. If 60 consecutive service requests all fail, the electronic device can obtain 60 first information corresponding to the 60 failed service requests.

[0133] S702. Based on the multiple first information, access logs, and / or preset metrics, determine the service that causes the multiple service requests to fail among the multiple services corresponding to each service request.

[0134] In some embodiments, the electronic device can determine the service that causes the service request to fail according to the multiple first information and preset metrics. For example, the preset metrics may include service identifiers, interface identifiers, error codes, etc. The electronic device can inject the multiple first information into the preset metrics to obtain the quantity of each preset metric. The electronic device can determine the service that causes the service request to fail and the root cause of the service request failure according to the quantity of each preset metric.

[0135] Exemplarily, the preset metrics include the identifier of Service 1, the identifier of Service 2, error code 500, error code 504, the number of failed service requests is 100, and the number of the first information is 100. The electronic device may inject the 100 pieces of the first information into the preset metrics (identifiers of services and error codes) to obtain preset metric data. Among them, the number of the identifier of Service 1 in the preset metric data is 10, the number of the identifier of Service 2 is 90, the number of error code 500 is 90, and the number of error code 504 is 10. The electronic device may determine, based on the preset metric data, that Service 2 causes multiple service requests to fail, that is, the error in Service 2 causes the service request to fail. In other words, the error in Service 2 is the root cause of the service request failure. The electronic device may further determine the specific error of Service 2 according to the error description in the error information of Service 2. In this way, the electronic device may perform visual processing of errors through the preset metrics, improve the efficiency of error location, and may reduce the cost of data quantification.

[0136] It should be noted that the above preset metrics are only examples of the metrics, rather than limitations on the metrics. The embodiments of the present disclosure do not limit this.

[0137] In some embodiments, the electronic device may determine the service that causes the service request to fail according to multiple pieces of the first information and the access log. For example, the electronic device may inject multiple pieces of the first information into the structured access log, and the electronic device may perform automated analysis on the structured access log, and then determine the service that causes the service request to fail and the root cause of the service request failure.

[0138] Exemplarily, the number of failed service requests is 100, and the number of the first information is 100. The electronic device may inject 100 pieces of the first information into the structured access log and analyze the structured access log to obtain an analysis result. The analysis result may include information such as the service identifier with the largest number, the interface identifier with the largest number, the error code with the largest number, and the error description with the largest number. The electronic device may determine, based on the analysis result, the service indicated by the service identifier with the largest number as the service that causes the service request to fail, and determine the root cause of the service request failure according to the error code with the largest number and the error description with the largest number.

[0139] It should be noted that the above analysis result is only an example. The analysis result may also include other error-related information in the first information (such as the number of each error code, the number of each service identifier, the number of each interface identifier, etc.). The embodiments of the present disclosure do not limit this.

[0140] In some embodiments, the electronic device may also determine the service that causes the service request to fail according to the first information, the preset metrics, and the access log, which will not be elaborated in the embodiments of the present disclosure.

[0141] Embodiments of the present disclosure provide a method for determining the service that causes the service request to fail. In response to the failure of multiple service requests received from the terminal device, the electronic device may obtain the first information corresponding to each service request, and determine the service that causes the multiple service requests to fail among the multiple services corresponding to each service request according to the multiple first information, the access log, and / or the preset metrics. In the above method, the electronic device may perform visual processing on the error information in the multiple first information through the preset metrics, improve the efficiency of error location, reduce the cost of data quantification, and the electronic device may perform comprehensive and accurate analysis on the multiple first information through the access log. Therefore, the electronic device can accurately determine the service that causes the service request to fail and improve the accuracy of error location.

[0142] Figure 8 It is a schematic structural diagram of a data processing device in a service architecture provided by an embodiment of the present disclosure. Please refer to Figure 8 The data processing device 800 in the service architecture includes a receiving module 801, an obtaining module 802, and a determining module 803, where:

[0143] The receiving module 801 is configured to receive a service request sent by the terminal device;

[0144] The obtaining module 802 is configured to obtain the first information in the first service corresponding to the service request when the service request fails, where the first service is the service in which an error occurs when processing the service request, and the first information includes the error information corresponding to each first service;

[0145] The determining module 803 is configured to determine the service that causes the service request to fail in the first service according to the first information.

[0146] In this way, when the service request fails, since the first information may include the error information corresponding to each service in which an error occurs, the data processing device in the service architecture may accurately determine the service that causes the service request to fail based on the first information, improve the accuracy of error location, and there is no need for manual step-by-step investigation of each first service based on the call chain. Therefore, the efficiency of error location can be improved, and further the efficiency of the system to recover from failure can be improved.

[0147] According to one or more embodiments of the present disclosure, the error information includes at least one of the following:

[0148] Error code;

[0149] Error description;

[0150] Error cause.

[0151] In this way, the data processing device in the service architecture can quickly identify and classify the error types that occur in the first service through the error code, and based on the error description, accurately determine the nature of the error, the cause of the error, and the possible impacts, etc. Based on the error cause, accurately determine the service that causes the service request to fail. Therefore, the accuracy and efficiency of error location can be improved.

[0152] According to one or more embodiments of the present disclosure, if the failure of the service request is caused by the first service, the error information of the first service in the first information includes an error code and an error description;

[0153] If the failure of the service request is not caused by the first service, the error information of the first service in the first information includes an error code, an error description, and an error cause.

[0154] In this way, the data processing device in the service architecture can accurately determine the service that causes the service request to fail according to whether other error-related information is included in the error information.

[0155] According to one or more embodiments of the present disclosure, the error cause of the first service is determined according to the second information, and the second information includes at least one of the following: the service identifier of the second service, the interface identifier of the second service, the error information of the second service, where the second service is the dependent service corresponding to the first service.

[0156] In this way, the data processing device in the service architecture can accurately determine the error cause according to the dependency relationship, and the error information of the first service in the first information is a recursive structure. Therefore, the electronic device can accurately perform error location.

[0157] According to one or more embodiments of the present disclosure, the obtaining module 802 is specifically configured to:

[0158] Determine the processing order of the first service for processing the service request;

[0159] According to the processing order, determine the first service that first processes the service request;

[0160] Obtain the error information corresponding to the first service that first processes the service request to obtain the first information.

[0161] In this way, since the first information is an error chain with a recursive structure, each first service will send error messages up to the previous first service level by level. Therefore, the data processing device in the service architecture can obtain the first information at the first first service, improving the accuracy and efficiency of obtaining the first information.

[0162] According to one or more embodiments of the present disclosure, the determining module 803 is specifically configured to:

[0163] Determine the error information in the first information that does not include the error cause;

[0164] Determine the first service corresponding to the error information that does not include the error cause as the service that causes the service request to fail.

[0165] In this way, the error cause in the error information of the first service is determined based on the identifier of the second service, the interface identifier of the second service, and the error information of the second service. Therefore, the data processing device in the service architecture can perform error localization in a timely and accurate manner based on the error information of the first service in the first information, and accurately determine the root cause of the service request failure, thereby improving the accuracy and efficiency of error localization, and can also improve the efficiency of error handling.

[0166] According to one or more embodiments of the present disclosure, the obtaining module 802 is further configured to:

[0167] In response to the failure of multiple service requests received from the terminal device, obtain the first information corresponding to each service request;

[0168] Based on the multiple first information, as well as the access log and / or preset metrics, determine the service that causes the multiple service requests to fail among the multiple services corresponding to each service request.

[0169] In this way, the data processing device in the service architecture can perform visual processing on the error information in the multiple first information through preset metrics, improving the efficiency of error localization, reducing the cost of data quantification, and moreover, the data processing device in the service architecture can perform comprehensive and accurate analysis on the multiple first information through the access log. Therefore, the data processing device in the service architecture can accurately determine the service that causes the service request to fail, improving the accuracy of error localization.

[0170] Figure 9 Schematic diagram of the structure of an electronic device provided by an embodiment of the present disclosure. Please refer to Figure 9, which shows a schematic structural diagram of an electronic device 900 suitable for implementing the embodiments of the present disclosure. Among them, the electronic device may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, personal digital assistants (PDAs), tablet computers, portable media players (PMPs), in-vehicle terminals (such as in-vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 9 The electronic device shown is only an example and should not impose any limitations on the functions and usage scope of the embodiments of the present disclosure.

[0171] As Figure 9 shown, the electronic device 900 may include a processing device (such as a central processing unit, a graphics processing unit, etc.) 901, which may perform various appropriate actions and processes according to the program stored in the read-only memory (ROM) 902 or the program loaded from the storage device 908 into the random access memory (RAM) 903. In the RAM 903, various programs and data required for the operation of the electronic device 900 are also stored. The processing device 901, the ROM 902, and the RAM 903 are connected to each other through a bus 904. The input / output (I / O) interface 905 is also connected to the bus 904.

[0172] Generally, the following devices may be connected to the I / O interface 905: an input device 906 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 907 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 908 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 909. The communication device 909 may allow the electronic device 900 to communicate with other devices wirelessly or wiredly to exchange data. Although Figure 9 the electronic device 900 with various devices is shown, it should be understood that it is not required to implement or have all the shown devices. More or fewer devices may be alternatively implemented or had.

[0173] In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, an embodiment of the present disclosure includes a computer program product that includes a computer program carried on a computer-readable medium, and the computer program includes program code for performing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through a communication device 909, or installed from a storage device 908, or installed from a ROM 902. When the computer program is executed by a processing device 901, the above-described functions defined in the method of the embodiment of the present disclosure are performed.

[0174] It should be noted that the above-mentioned computer-readable medium in the present disclosure can be a computer-readable signal medium or a computer-readable storage medium or any combination of the two. A computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples of the computer-readable storage medium can include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, the computer-readable storage medium can be any tangible medium that contains or stores a program, and the program can be used by or in combination with an instruction execution system, apparatus, or device. In the present disclosure, a computer-readable signal medium can include a data signal propagated in a baseband or as part of a carrier wave, which carries computer-readable program code. Such a propagated data signal can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer-readable signal medium can also be any computer-readable medium other than the computer-readable storage medium, and the computer-readable signal medium can send, propagate, or transmit a program for use by or in combination with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted by any appropriate medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.

[0175] The above-mentioned computer-readable medium can be included in the above-mentioned electronic device; or it can exist separately without being assembled into the electronic device.

[0176] The above-mentioned computer-readable medium carries one or more programs, and when the above-mentioned one or more programs are executed by the electronic device, the electronic device is caused to perform the method shown in the above embodiment.

[0177] An embodiment of the present disclosure provides a computer-readable storage medium storing computer-executable instructions, and when a processor executes the computer-executable instructions, the methods that may be involved in various above embodiments are implemented.

[0178] An embodiment of the present disclosure provides a computer program product including a computer program, and when the computer program is executed by a processor, the methods that may be involved in various above embodiments are implemented.

[0179] An embodiment of the present disclosure provides an electronic device, a computer-readable storage medium, and a computer program product. When a service request fails, since the first information may include error information corresponding to each service with an error, the electronic device can accurately determine the service that causes the service request to fail based on the first information, improving the accuracy of error location. Moreover, there is no need for manual step-by-step troubleshooting of each first service based on the call chain. Therefore, the efficiency of error location can be improved, and further the efficiency of the system's recovery from failure can be improved.

[0180] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages or combinations thereof. The above programming languages include object-oriented programming languages such as Java, Smalltalk, and C++, and also include conventional procedural programming languages such as the "C" language or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, executed as a stand-alone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., by using an Internet service provider to connect through the Internet).

[0181] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architectures, functions, and operations of systems, methods, and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagram may represent a module, a segment of a program, or a part of code that contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions noted in the blocks may occur in a different order than that noted in the accompanying drawings. For example, two consecutive blocks shown may actually be executed substantially in parallel, and they may sometimes be executed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and / or flowchart, and combinations of blocks in the block diagram and / or flowchart, can be implemented by a dedicated hardware-based system that performs the specified functions or operations, or can be implemented by a combination of dedicated hardware and computer instructions.

[0182] The units involved in the embodiments described in the present disclosure can be implemented in software or in hardware. Among them, the name of the unit does not constitute a limitation on the unit itself in some cases. For example, the first acquisition unit can also be described as "the unit for acquiring at least two Internet protocol addresses".

[0183] The functions described above in this document can be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that can be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on a chip (SOCs), complex programmable logic devices (CPLDs), etc.

[0184] In the context of the present disclosure, a machine-readable medium can be a tangible medium that can contain or store a program for use by or in connection with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0185] It should be noted that the modifications of "one" and "multiple" mentioned in this disclosure are illustrative rather than restrictive. Those skilled in the art should understand that unless otherwise clearly specified in the context, it should be understood as "one or more".

[0186] In a first aspect, an embodiment of the present disclosure provides a data processing method in a service architecture. The data processing method in the service architecture includes:

[0187] Receiving a service request sent by a terminal device;

[0188] When the service request fails, obtaining first information in a first service corresponding to the service request. The first service is the service where an error occurs when processing the service request, and the first information includes error information corresponding to each first service;

[0189] Determining, according to the first information, the service that causes the service request to fail in the first service.

[0190] According to one or more embodiments of the present disclosure, the error information includes at least one of the following:

[0191] Error code;

[0192] Error description;

[0193] Error cause.

[0194] According to one or more embodiments of the present disclosure, if the failure of the service request is caused by the first service, the error information of the first service in the first information includes an error code and an error description;

[0195] If the failure of the service request is not caused by the first service, the error information of the first service in the first information includes an error code, an error description, and an error cause.

[0196] According to one or more embodiments of the present disclosure, the error cause of the first service is determined according to second information, and the second information includes at least one of the following: a service identifier of a second service, an interface identifier of the second service, error information of the second service, where the second service is a dependent service corresponding to the first service.

[0197] According to one or more embodiments of the present disclosure, the obtaining first information in the first service corresponding to the service request includes:

[0198] Determining the processing order of the first service for processing the service request;

[0199] Determining, according to the processing order, the first service that first processes the service request;

[0200] Obtain the error information corresponding to the first service that processes the service request for the first time, and obtain the first information.

[0201] According to one or more embodiments of the present disclosure, according to the first information, determining the service that causes the service request to fail in the first service includes:

[0202] Determine the error information in the first information that does not include the error cause;

[0203] Determine the first service corresponding to the error information that does not include the error cause as the service that causes the service request to fail.

[0204] According to one or more embodiments of the present disclosure, the method further includes:

[0205] In response to the failure of multiple service requests received from the terminal device, obtain the first information corresponding to each service request;

[0206] According to the multiple first information, as well as the access log and / or preset metrics, determine the service that causes the multiple service requests to fail among the multiple services corresponding to each service request.

[0207] In a second aspect, an embodiment of the present disclosure provides a data processing device in a service architecture. The data processing device in the service architecture includes a receiving module, an obtaining module, and a determining module, where:

[0208] The receiving module is configured to receive a service request sent by a terminal device;

[0209] The obtaining module is configured to, when the service request fails, obtain first information in the first service corresponding to the service request. The first service is the service in which an error occurs when processing the service request, and the first information includes the error information corresponding to each first service;

[0210] The determining module is configured to determine the service that causes the service request to fail in the first service according to the first information.

[0211] According to one or more embodiments of the present disclosure, the error information includes at least one of the following:

[0212] Error code;

[0213] Error description;

[0214] Error cause.

[0215] According to one or more embodiments of the present disclosure, if the failure of the service request is caused by the first service, the error information of the first service in the first information includes an error code and an error description;

[0216] If the failure of the service request is not caused by the first service, the error information of the first service in the first information includes an error code, an error description, and an error cause.

[0217] According to one or more embodiments of the present disclosure, the error cause of the first service is determined according to second information, and the second information includes at least one of the following: a service identifier of a second service, an interface identifier of the second service, and error information of the second service, where the second service is a dependent service corresponding to the first service.

[0218] According to one or more embodiments of the present disclosure, the obtaining module is specifically configured to:

[0219] Determine a processing order for the first service to process the service request;

[0220] According to the processing order, determine the first service that first processes the service request;

[0221] Obtain error information corresponding to the first service that first processes the service request to obtain the first information.

[0222] According to one or more embodiments of the present disclosure, the determining module is specifically configured to:

[0223] Determine error information in the first information that does not include an error cause;

[0224] Determine the first service corresponding to the error information that does not include an error cause as the service that causes the service request to fail.

[0225] According to one or more embodiments of the present disclosure, the obtaining module is further configured to:

[0226] In response to failures of multiple service requests received from the terminal device, obtain first information corresponding to each service request;

[0227] According to the multiple first information, as well as access logs and / or preset metrics, determine the services that cause the multiple service requests to fail among the multiple services corresponding to each service request.

[0228] In a third aspect, the present disclosure provides an electronic device including: a processor and a memory;

[0229] The memory stores computer-executable instructions;

[0230] The processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the data processing method in the service architecture as described in the first aspect and various possible aspects related to the first aspect above.

[0231] Fourthly, the present disclosure provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement the data processing method in the service architecture as described in the first aspect above and all possible aspects related to the first aspect.

[0232] Fifthly, the present disclosure provides a computer program product including a computer program, which, when executed by a processor, implements the data processing method in the service architecture as described in the first aspect above and all possible aspects related to the first aspect.

[0233] In summary, when a service request fails, since the first information may include error information corresponding to each service that has an error, the electronic device can accurately determine the service that causes the service request to fail based on this first information, improving the accuracy of error location. Moreover, there is no need for manual step-by-step troubleshooting of each first service based on the call chain. Therefore, the efficiency of error location can be improved, and further the efficiency of the system's recovery from failure can be improved.

[0234] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only for illustrative purposes and are not used to limit the scope of these messages or information.

[0235] It can be understood that the data involved in the technical solution of the present disclosure (including but not limited to the data itself, the acquisition or use of the data) should comply with the requirements of the corresponding laws, regulations and related regulations. The data may include information, parameters, messages, etc., such as traffic indication information.

[0236] The above description is only a preferred embodiment of the present disclosure and an explanation of the applied technical principle. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solution formed by the specific combination of the above technical features, and should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosure concept. For example, a technical solution formed by mutually replacing the above features with the (but not limited to) technical features having similar functions disclosed in the present disclosure.

[0237] Moreover, although the operations are depicted in a particular order, this should not be construed as requiring that the operations be performed in the particular order shown or in sequential order. In certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although several specific implementation details are included in the foregoing discussion, these should not be construed as limitations on the scope of the present disclosure. Certain features that are described in the context of separate embodiments may also be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment may also be implemented separately or in any suitable sub-combination in multiple embodiments. Although the subject matter has been described in language specific to structural features and / or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are merely example forms of implementing the claims.

Claims

1. A data processing method in a service architecture, characterized in that: include: Receiving service requests sent by terminal devices; When the service request fails, obtaining first information from a first service corresponding to the service request, where the first service is a service in which an error occurs when processing the service request, and the first information includes error information corresponding to each first service; A service causing the service request failure is determined in the first service according to the first information.

2. The method according to claim 1, characterized in that The error message includes at least one of the following: Error code; Error description; Cause of the error.

3. The method according to claim 1, characterized in that If the failure of the service request is caused by the first service, the error information of the first service in the first information includes an error code and an error description; If the failure of the service request is not caused by the first service, the error information of the first service in the first information includes an error code, an error description and an error cause.

4. The method according to any one of claims 1 to 3, characterized in that: The error cause of the first service is determined based on second information, and the second information includes at least one of the following: a service identifier of the second service, an interface identifier of the second service, and error information of the second service, wherein the second service is a dependent party service corresponding to the first service.

5. The method according to any one of claims 1 to 3, characterized in that: The acquiring the first information in the first service corresponding to the service request includes: determining a processing order in which the first service processes the service request; Determining, according to the processing order, a first service that first processes the service request; Obtain error information corresponding to a first service that first processes the service request to obtain the first information.

6. The method according to any one of claims 1 to 3, characterized in that: Determining, in the first service, the service causing the service request failure according to the first information, includes: Determining that the first information does not include error information about the cause of the error; The first service corresponding to the error information that does not include an error cause is determined as the service that causes the service request to fail.

7. The method according to any one of claims 1 to 3, characterized in that: The method further comprises: In response to failure of multiple service requests received from the terminal device, obtaining first information corresponding to each service request; According to the multiple first information, access logs and / or preset indicators, the service causing the failure of the multiple service requests is determined among the multiple services corresponding to each service request.

8. A data processing device in a service architecture, characterized in that: It includes a receiving module, an acquiring module and a determining module, wherein: The receiving module is used to receive a service request sent by a terminal device; The acquisition module is used to, when the service request fails, acquire first information from a first service corresponding to the service request, the first service being a service in which an error occurs when processing the service request, and the first information including error information corresponding to each first service; The determination module is used to determine, according to the first information, a service in the first service that causes the service request to fail.

9. An electronic device, characterized in that: include: Processor and memory; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the processor executes the data processing method in the service architecture as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions. When the processor executes the computer-executable instructions, the data processing method in the service architecture according to any one of claims 1 to 7 is implemented.

11. A computer program product, characterized in that It comprises a computer program, which, when executed by a processor, implements the data processing method in the service architecture as described in any one of claims 1 to 7.