CN112506799B - Business abnormality positioning method and device, electronic equipment, medium and product - Google Patents

Business abnormality positioning method and device, electronic equipment, medium and product Download PDF

Info

Publication number
CN112506799B
CN112506799B CN202011526955.2A CN202011526955A CN112506799B CN 112506799 B CN112506799 B CN 112506799B CN 202011526955 A CN202011526955 A CN 202011526955A CN 112506799 B CN112506799 B CN 112506799B
Authority
CN
China
Prior art keywords
abnormal
anomaly
business
information
service
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011526955.2A
Other languages
Chinese (zh)
Other versions
CN112506799A (en
Inventor
贾瑞琦
李奇原
刘涛
杨方方
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202011526955.2A priority Critical patent/CN112506799B/en
Publication of CN112506799A publication Critical patent/CN112506799A/en
Application granted granted Critical
Publication of CN112506799B publication Critical patent/CN112506799B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3684Test management for test design, e.g. generating new test cases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The application provides a business anomaly positioning method, which relates to the technical field of computers, in particular to the technical field of Internet, and comprises the following specific implementation schemes: receiving a service path identifier sent by a first scheduler, acquiring service link information corresponding to the service path identifier according to a call chain acquisition probe, wherein the service link information comprises module information related to a service path and instance information of the module, and acquiring logs of corresponding instances according to the instance information; determining a business abnormality positioning result according to an abnormality positioning strategy and a log of an instance, wherein the business abnormality positioning result at least comprises an abnormality root cause module and an abnormality cause; the application also provides a business anomaly positioning device, electronic equipment, a computer readable medium and a computer program product.

Description

Business abnormality positioning method and device, electronic equipment, medium and product
Technical Field
The present application relates to the field of computer technologies, and in particular, to the field of internet technologies, and in particular, to a method and apparatus for locating a business anomaly, an electronic device, a computer readable medium, and a computer program product.
Background
In the service end research and development test flow, when a new code is submitted to a code library, RD (Research and Development engineer ) and QA (Quality Assurance, quality assurance) need to execute a service exception automatic test case set at a back end interface level through a platform to judge whether the newly submitted code can be integrated to the code library. Once the business anomaly automation test case set fails to execute, RD & QA is often required to check the root cause of the localized business anomaly.
Because the back-end service modules are numerous and have complex dependency, a request of a business anomaly automatic test case often needs to be over a plurality of modules, and related personnel need to log in the offline environment one by one to check the problem. After the abnormal root cause module is located, the abnormal cause needs to be determined. However, the reasons for interface abnormality are numerous and various conditions such as dependence on abnormality (storage, database, third party service), code abnormality, configuration abnormality and the like exist, so that a great deal of labor is also required to be consumed for locating the reasons for abnormality, and how to realize automatic service abnormality root cause locating of automatic test cases is an important means for greatly saving project development test time and improving project delivery efficiency.
The traditional abnormal business positioning is currently generally solved by adopting the following scheme:
(1) The manual test scheme needs to manually analyze the system call flow, starts from a place which is possibly abnormal by combining experience, gradually performs abnormal investigation, and gives an investigation conclusion after the investigation is completed. The manual test service abnormality positioning consumes longer time, relies on the familiarity degree of manual work to the system and positioning experience, has higher requirements on positioning personnel, cannot accumulate experience of the system, cannot realize the general purpose of the whole system, and cannot provide good support for the continuous development of the service.
(2) The automatic test scheme can give a preliminary abnormality prompt, such as failure of operation of an automatic use case or failure of a use case in a certain scene, but cannot give a root cause of a business abnormality, and also needs to manually check the abnormality cause. Even if the abnormal cause marking is finished through manual positioning in the follow-up process, the service line cannot see the distribution condition of the abnormal service, and powerful guarantee cannot be provided for the development of the service system.
Disclosure of Invention
Provided are a business anomaly localization method and apparatus, an electronic device, a computer readable medium, and a computer program product.
According to a first aspect, a method for locating business anomalies is provided, including:
receiving a service path identifier sent by a first scheduler, wherein the service path identifier is determined by the first scheduler according to abnormal information in an abnormal positioning request after the first scheduler receives the abnormal positioning request;
acquiring service link information corresponding to the service path identifier according to a call chain acquisition probe, wherein the service link information comprises module information related to a service path and instance information of the module;
acquiring logs of corresponding examples according to the example information;
and determining a business abnormality positioning result according to an abnormality positioning strategy and the log of the instance, wherein the business abnormality positioning result at least comprises an abnormality root cause module and an abnormality cause.
According to a second aspect, there is provided a business anomaly localization device, comprising: the system comprises a receiving module, an acquisition module and an abnormal positioning module, wherein the receiving module is used for receiving a service path identifier sent by a first scheduler, and the service path identifier is determined by the first scheduler according to abnormal information in the first scheduler after receiving an abnormal positioning request;
the acquisition module is used for acquiring service link information corresponding to the service path identifier according to a call chain acquisition probe, wherein the service link information comprises module information related to a service path and instance information of the module; acquiring logs of corresponding examples according to the example information;
the abnormal positioning module is used for determining a business abnormal positioning result according to an abnormal positioning strategy and the log of the instance, and the business abnormal positioning result at least comprises an abnormal root cause module and an abnormal cause.
According to a third aspect, there is provided an electronic device comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform any one of the business anomaly localization methods.
According to a fourth aspect, there is provided a non-transitory computer-readable storage medium storing computer instructions for causing the computer to perform any one of the above-described business anomaly localization methods.
According to a fifth aspect, there is provided a computer program product comprising a computer program which, when executed by a processor, implements a method according to any one of the above business anomaly localization methods.
It should be understood that the description in this section is not intended to identify key or critical features of the embodiments of the disclosure, nor is it intended to be used to limit the scope of the disclosure. Other features of the present disclosure will become apparent from the following specification.
Drawings
The drawings are included to provide a better understanding of the present application and are not to be construed as limiting the application. Wherein:
FIG. 1 is a schematic diagram of a system architecture according to an embodiment of the present application;
fig. 2 is a flowchart of a method for locating business anomalies provided in an embodiment of the present application;
FIG. 3 is a flowchart of determining a business anomaly location result according to an anomaly location policy and an instance log provided by an embodiment of the present application;
FIG. 4 is a schematic diagram of generating an anomaly localization strategy provided by an embodiment of the present application;
FIG. 5 is a flowchart of another method for locating business anomalies provided by an embodiment of the present application;
fig. 6 is a block diagram of a business anomaly locating device according to an embodiment of the present application;
FIG. 7 is a block diagram of another business anomaly locating device according to an embodiment of the present application;
FIG. 8 is a block diagram of another business anomaly locating device according to an embodiment of the present application;
fig. 9 is a block diagram of still another service abnormality locating device according to an embodiment of the present application;
FIG. 10 is a block diagram of another business anomaly locating device according to an embodiment of the present application;
FIG. 11 is a block diagram of an electronic device for implementing business anomaly localization in accordance with an embodiment of the present application.
Detailed Description
Exemplary embodiments of the present application will now be described with reference to the accompanying drawings, in which various details of the embodiments of the present application are included to facilitate understanding, and are to be considered merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
The embodiments of the application and features of the embodiments may be combined with each other without conflict.
As used herein, the term "and/or" includes any and all combinations of one or more of the associated listed items.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used herein, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms "comprises" and/or "comprising," when used in this specification, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
In a first aspect, an embodiment of the present application provides a method for locating a business anomaly, where the method is applied to a system shown in fig. 1. FIG. 1 is a schematic diagram of a system architecture according to an embodiment of the present application, as shown in FIG. 1, the system includes: the system comprises a business anomaly positioning device 1, a first scheduler 2, a second scheduler 3 and a positioning source device 4, wherein the positioning source device 4 is used for monitoring business operation conditions and initiating an anomaly positioning request to the first scheduler 2 when business anomalies are detected; the first scheduler 2 is configured to parse and obtain a service path identifier (traceID) according to the anomaly information in the anomaly location request; the business anomaly positioning device 4 is used for determining a module related to an abnormal business and an instance thereof, acquiring a log of the instance, and determining a business anomaly positioning result based on a positioning strategy and the log; the second scheduler 3 is configured to determine a callback operation according to the anomaly information and the service anomaly location result.
Fig. 2 is a flowchart of a business anomaly positioning method according to an embodiment of the present application, and with reference to fig. 1 and 2, the business anomaly positioning method includes the following steps:
and step 11, receiving the service path identification sent by the first scheduler.
The service path identifier is a service path identifier of an abnormal service, and when the positioning source device 4 detects that the service is abnormal, an abnormal positioning request is initiated to the first scheduler 2, where the abnormal positioning request carries abnormal information, and the abnormal information is related information of the abnormal service, for example, may include a time period in which the abnormality occurs, an operation (such as a specific operation and an operation object executed on a service platform) that causes the service to be abnormal, and the like. The first scheduler 2, after receiving the abnormal positioning request sent by the positioning source device 4, determines a service path identifier according to the abnormal information therein, and sends the service path identifier to the abnormal positioning device 1.
And step 12, acquiring service link information corresponding to the service path identifier according to the call chain acquisition probe, wherein the service link information comprises module information related to the service path and instance information of the module.
An instance refers to an application program instance (i.e., an automation test case) capable of realizing a specific service function, one service path relates to a plurality of modules, each module realizes a different service function, and one module can comprise a plurality of instances.
In this step, the service anomaly positioning device 1 automatically acquires the execution path (i.e., service path) of the anomaly service using the call chain acquisition probe in the off-line test environment. When receiving a traffic path identifier (traceID), the traffic anomaly locating device 1 performs service association using the traffic path identifier, and determines traffic link information including module information and instance information corresponding to the module information.
And step 13, acquiring logs of the corresponding examples according to the example information.
The log is stored on each instance, and is used for recording the execution conditions of the instance, such as instance calling time, calling operation, whether the execution is abnormal or not and the like. In this step, the business anomaly positioning device 1 calls the log stored on the corresponding instance according to the instance information (i.e., the information of the instance related to the abnormal business) acquired in step 12.
And step 14, determining a business abnormal positioning result according to the abnormal positioning strategy and the log of the instance, wherein the business abnormal positioning result at least comprises an abnormal root cause module and an abnormal cause.
In this step, the service anomaly locating device 1 determines an anomaly root cause module and an anomaly cause according to the anomaly locating policy configured locally and the log obtained in step 13, where the anomaly root cause module is a module that causes service anomalies on the service path of the anomaly service, and the anomaly cause is a specific cause that causes service anomalies.
In the embodiment of the application, the business anomaly positioning method comprises the following steps: receiving a service path identifier sent by a first scheduler, acquiring service link information corresponding to the service path identifier according to a call chain acquisition probe, wherein the service link information comprises module information related to a service path and instance information of the module, and acquiring logs of corresponding instances according to the instance information; determining a business abnormality positioning result according to an abnormality positioning strategy and a log of an instance, wherein the business abnormality positioning result at least comprises an abnormality root cause module and an abnormality cause; according to the application, the link information of the abnormal service is automatically acquired based on the call chain acquisition probe, the root cause module and the abnormal reason of failure of the automatic test case can be rapidly determined according to the abnormal positioning strategy and the link information of the abnormal service, and related personnel are not required to log in the offline environment for checking the problem one by one, so that the time consumption of service abnormal checking is reduced, the requirements of the related personnel are reduced, and the method can be applied to various service systems and has universality; the reasons of the business abnormality can be directly positioned, the distribution situation of the business abnormality is obtained, global management is convenient for system maintenance personnel, and automatic positioning of the business abnormality is truly realized.
In some embodiments, the anomaly localization policy includes an anomaly definition, which may include anomaly description information, which is a description of an anomaly, and an anomaly cause corresponding to the anomaly description information, which is a cause of the anomaly. Fig. 3 is a flowchart of determining a business anomaly location result according to an anomaly location policy and an instance log according to an embodiment of the present application. As shown in fig. 3, the determining the business anomaly location result (i.e. step 14) according to the anomaly location policy and the log of the instance includes the following steps:
step 141, scanning logs of each instance according to the abnormal positioning strategy.
In this step, the business anomaly localization device 1 scans the log of each instance according to anomaly description information in the anomaly localization policy.
And step 142, determining an abnormal root cause module to which the corresponding instance belongs in response to the fact that the same abnormal description information is matched in the log, and determining an abnormal reason corresponding to the abnormal description information according to an abnormal positioning strategy.
In this step, if the service anomaly locating device 1 matches the same anomaly description information as the anomaly description information in the anomaly locating policy in the log of each instance, it indicates that the service anomaly locating is successful, considers that the module to which the matched instance belongs is the anomaly root cause module, queries the anomaly locating policy according to the anomaly description information, and determines the anomaly cause corresponding to the anomaly description information. The step can utilize an abnormal positioning strategy to check information such as abnormality, time consumption, error codes and the like in the log.
In some embodiments, the service link information is in a tree structure, and the scanning the log of each instance according to the abnormal location policy (i.e. step 141) includes the following steps: and traversing and scanning logs of each instance according to the tree structure reverse sequence of the service link information according to the abnormal positioning strategy. That is, in this step, the log of each instance is scanned in a reverse order traversal order of tracing back from the child node to the root node by means of tracing back traversal. It should be noted that, during the scanning process, a high-frequency scene of abnormal business may also be recorded. In the service operation process, the service abnormality usually occurs to the child nodes of the tree structure in the service link, so that the abnormality location is performed by adopting a reverse sequence traversal scanning mode, the time required by the abnormality location can be saved, and the abnormality location efficiency is improved.
In some embodiments, before the acquiring the service link information corresponding to the service path identifier according to the call chain acquisition probe (i.e. step 12), the method further includes the following steps: the abnormality information transmitted by the first scheduler 2 is received, the abnormality information being acquired by the first scheduler 2 according to the received abnormality location request.
The anomaly localization policy also includes anomaly solutions corresponding to the anomaly definitions. The business anomaly location result further includes an anomaly solution, and after determining the anomaly cause corresponding to the anomaly description information according to the anomaly location policy (i.e. step 142), the method further includes the following steps: and determining an exception solution corresponding to the exception description information according to the exception positioning strategy.
Correspondingly, after determining the business anomaly location result (i.e. step 14) according to the anomaly location policy and the log of the instance, the method further comprises the following steps: and sending the abnormal information and the business abnormal positioning result to the second scheduler so that the second scheduler determines callback operation according to the abnormal solution in the abnormal information and the business abnormal positioning result.
In the embodiment of the application, the basic capability of the abnormal business positioning is standardized, the capability of determining the abnormal business positioning result according to the abnormal positioning strategy and the log of the example is used as the core capability of the abnormal business positioning device 1, the called entering of the abnormal business positioning device is normalized by the first scheduler 2, and the second scheduler 3 performs the post-processing of the exiting of the entering of the abnormal business positioning device, so that the capability multiplexing among all systems is realized.
The use of the first scheduler 2 allows for inter-system parameter entry and some other parameter preparation during this period. The first scheduler 2 may directly use the preprocessing base class to complete parameter preparation (i.e. obtain the service path identifier), and if the anomaly information is an anomaly occurrence time period, the first scheduler 2 may determine the service path identifier by monitoring other parameters of the service, for example, interface information, DIFF (comparative test) information, etc. The second scheduler 3 may determine the callback operation directly using the preprocessing base class, or may determine the callback operation by monitoring other parameters of the service, for example, interface test information, DIFF (comparative test) information, etc.
In some embodiments, the method for locating business anomalies further includes a step of generating an anomaly locating policy, and the step of generating an anomaly locating policy includes: in response to receiving the business program code, the log specification of the business program code is statically scanned, generating an anomaly localization policy. Fig. 4 is a schematic diagram of generating an anomaly locating policy according to an embodiment of the present application, as shown in fig. 4, after the RD submits the service program code, the service anomaly locating device 1 performs static scanning (static code analysis, SA) on the log specification, so as to generate a policy file. Scan items in the log specification may include, but are not limited to: log level definitions (log levels may include errors, warnings, etc.), exception definitions, exception handling, print specifications, etc. After the policy file is generated, the related personnel can review the policy file, and the policy file can be configured in the business anomaly positioning device 1 after the review is passed. The anomaly localization strategy may be stored in the form of YAML (YAML Ain't Markup Language, another markup language) files. The embodiment of the application can automatically generate the abnormal positioning strategy in the process of service development, and can automatically accumulate new or stock strategies in the process of static scanning of the log specification.
In some embodiments, after determining the business anomaly location result according to the anomaly location policy and the log of the instance (step 14), the method further comprises the steps of: and storing the mapping relation between the service path identification and the service abnormality positioning result. In this step, after determining the service abnormality location result, the service abnormality location device 1 locally stores the service abnormality location result with the storage time as an index, that is, stores the mapping relationship between the service path identifier and the service abnormality location result, so that it is convenient to directly query the service abnormality location result when performing service abnormality location.
In the case where the service anomaly locating device 1 locally stores the mapping relationship between the service path identifier and the service anomaly locating result, in some embodiments, the acquiring, according to the call chain acquisition probe, the service link information corresponding to the service path identifier (i.e. step 12) includes the following steps: and responding to the fact that the service path identifier is not queried within a preset time before the current moment, and acquiring service link information corresponding to the service path identifier according to the call chain acquisition probe. The preset duration may be set as required, for example, 1 hour, that is, after receiving the service path identifier, before performing the service abnormality positioning, it is queried whether the same service abnormality is performed for a short time before performing the service abnormality positioning, and if the service path identifier is not queried, that is, if no abnormality positioning is performed for the corresponding abnormal service for a short time before performing the service abnormality positioning, the foregoing solution according to the embodiment of the present application performs the service abnormality positioning.
Fig. 5 is a flowchart of another method for locating business anomalies according to an embodiment of the present application. As shown in fig. 5, in some embodiments, after receiving the service path identifier sent by the first scheduler (i.e. step 11), the method further includes the following steps:
and step 12', in response to the inquiry of the service path identifier in a preset time before the current moment, determining a service abnormal positioning result corresponding to the service path identifier according to the mapping relation between the locally stored service path identifier and the service abnormal positioning result.
In the step, if the service path identifier is inquired, the abnormal positioning is carried out on the corresponding abnormal service in a short time before, and the abnormal positioning result of the service determined before is directly obtained. By inquiring and judging whether the same abnormal service is subjected to abnormal positioning or not, repeated abnormal positioning for the same abnormal service in a short period can be avoided, the processing amount of the service abnormal positioning device 1 is reduced, and system resources are saved.
According to an embodiment of the present application, fig. 6 is a block diagram of a service abnormality positioning device provided by the embodiment of the present application, and as shown in fig. 6, the service abnormality positioning device includes: the device comprises a receiving module 101, an obtaining module 102 and an abnormal positioning module 103, wherein the receiving module 101 is used for receiving a service path identifier sent by a first scheduler, and the service path identifier is determined by the first scheduler according to abnormal information in the abnormal positioning request after the first scheduler receives the abnormal positioning request.
The acquiring module 102 is configured to acquire service link information corresponding to the service path identifier according to a call chain acquisition probe, where the service link information includes module information related to a service path and instance information of the module; and acquiring a log of the corresponding instance according to the instance information.
The abnormality locating module 103 is configured to determine a service abnormality locating result according to an abnormality locating policy and a log of the instance, where the service abnormality locating result includes at least an abnormality root cause module and an abnormality cause.
In some embodiments, the anomaly localization policy includes an anomaly definition including anomaly description information and an anomaly cause corresponding to the anomaly description information. The exception positioning module 103 is configured to scan the log of each instance according to an exception positioning policy; and determining an abnormal root cause module to which the corresponding instance belongs in response to the fact that the same abnormal description information is matched in the log, and determining an abnormal reason corresponding to the abnormal description information according to the abnormal positioning strategy.
In some embodiments, the data structure of the service link information is a tree structure, and the anomaly locating module 103 is configured to traverse and scan the log of each instance in the reverse order of the tree structure of the service link information according to an anomaly locating policy.
Fig. 7 is a block diagram of another business anomaly positioning device according to an embodiment of the present application, as shown in fig. 7, and in some embodiments, the business anomaly positioning device further includes a sending module 104.
The receiving module 101 is further configured to receive the anomaly information sent by the first scheduler. The abnormal positioning strategy further comprises an abnormal solution corresponding to the abnormal definition, and the business abnormal positioning result further comprises an abnormal solution.
The anomaly locating module 103 is further configured to determine an anomaly solution corresponding to the anomaly description information according to the anomaly locating policy after determining an anomaly cause corresponding to the anomaly description information according to the anomaly locating policy.
The sending module 104 is configured to send the anomaly information and the service anomaly location result to a second scheduler, so that the second scheduler determines a callback operation according to the anomaly information and the anomaly solution in the service anomaly location result.
Fig. 8 is a block diagram of still another service abnormality location apparatus according to an embodiment of the present application, as shown in fig. 8, in some embodiments, the service abnormality location apparatus further includes a policy generation module 105, where the policy generation module 105 is configured to, in response to receiving a service program code, statically scan a log specification of the service program code, and generate an abnormality location policy.
Fig. 9 is a block diagram of still another service anomaly positioning device according to an embodiment of the present application, as shown in fig. 9, in some embodiments, the service anomaly positioning device further includes a storage module 106, where the storage module 106 is configured to store a mapping relationship between the service path identifier and the service anomaly positioning result after the anomaly positioning module 103 determines the service anomaly positioning result according to an anomaly positioning policy and a log of the instance.
Fig. 10 is a block diagram of another service anomaly positioning device according to an embodiment of the present application, as shown in fig. 10, in some embodiments, the service anomaly positioning device further includes a query module 107, and the obtaining module 102 is configured to obtain, according to a call chain acquisition probe, service link information corresponding to the service path identifier in response to the query module 107 failing to query the service path identifier within a preset period of time before a current time.
In some embodiments, the query module 107 is further configured to determine, in response to querying the service path identifier within a preset time period before the current time, a service abnormal location result corresponding to the service path identifier according to a mapping relationship between the locally stored service path identifier and the service abnormal location result.
According to an embodiment of the present application, the present application also provides an electronic device and a readable storage medium.
As shown in fig. 11, a block diagram of an electronic device according to a business anomaly localization method according to an embodiment of the present application is shown. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular telephones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the applications described and/or claimed herein.
As shown in fig. 11, the electronic device includes: one or more processors 201, memory 202, and interfaces for connecting the components, including high-speed interfaces and low-speed interfaces. The various components are interconnected using different buses and may be mounted on a common motherboard or in other manners as desired. The processor may process instructions executing within the electronic device, including instructions stored in or on memory to display graphical information of the GUI on an external input/output device, such as a display device coupled to the interface. In other embodiments, multiple processors and/or multiple buses may be used, if desired, along with multiple memories and multiple memories. Also, multiple electronic devices may be connected, each providing a portion of the necessary operations (e.g., as a server array, a set of blade servers, or a multiprocessor system). One processor 201 is illustrated in fig. 11.
Memory 202 is a non-transitory computer readable storage medium provided by the present application. The memory stores instructions executable by at least one processor to cause the at least one processor to perform the business anomaly locating method provided by the present application. The non-transitory computer readable storage medium of the present application stores computer instructions for causing a computer to execute the business anomaly localization method provided by the present application.
The memory 202 is used as a non-transitory computer readable storage medium for storing non-transitory software programs, non-transitory computer executable programs, and modules, such as program instructions/modules corresponding to the business anomaly localization method in the embodiments of the present application. The processor 201 executes various functional applications of the server and data processing by running non-transitory software programs, instructions, and modules stored in the memory 202, that is, implements the business anomaly localization method in the above-described method embodiments.
Memory 202 may include a storage program area that may store an operating system, at least one application program required for functionality, and a storage data area; the storage data area may store data created according to the use of the electronic device for business anomaly localization, and the like. In addition, memory 202 may include high-speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory 202 may optionally include memory located remotely from processor 201, which may be connected to the electronic device for business anomaly localization via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The electronic device of the business anomaly positioning method may further include: an input device 203 and an output device 204. The processor 201, memory 202, input devices 203, and output devices 204 may be connected by a bus or other means, for example in fig. 11.
The input device 203 may receive input numeric or character information and generate key signal inputs related to user settings and function control of the electronic device for business anomaly localization, such as a touch screen, a keypad, a mouse, a track pad, a touch pad, a pointer stick, one or more mouse buttons, a track ball, a joystick, and the like. The output device 204 may include a display apparatus, auxiliary lighting devices (e.g., LEDs), haptic feedback devices (e.g., vibration motors), and the like. The display device may include, but is not limited to, a Liquid Crystal Display (LCD), a Light Emitting Diode (LED) display, and a plasma display. In some implementations, the display device may be a touch screen.
Various implementations of the systems and techniques described here can be realized in digital electronic circuitry, integrated circuitry, application specific ASIC (application specific integrated circuit), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs, the one or more computer programs may be executed and/or interpreted on a programmable system including at least one programmable processor, which may be a special purpose or general-purpose programmable processor, that may receive data and instructions from, and transmit data and instructions to, a storage system, at least one input device, and at least one output device.
These computing programs (also referred to as programs, software applications, or code) include machine instructions for a programmable processor, and may be implemented in a high-level procedural and/or object-oriented programming language, and/or in assembly/machine language. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus, and/or device (e.g., magnetic discs, optical disks, memory, programmable Logic Devices (PLDs)) used to provide machine instructions and/or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and/or data to a programmable processor.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and pointing device (e.g., a mouse or trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a background component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such background, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), and the internet.
The computer system may include a client and a server. The client and server are typically remote from each other and typically interact through a communication network. The server may also be a server of a distributed system, or a server incorporating a blockchain, the relationship of client and server being created by computer programs running on the respective computers and having a client-server relationship to each other.
According to the service abnormality positioning scheme provided by the embodiment of the application, the service link information of the abnormal service is acquired based on the call chain acquisition probe, and the reason of failure of the automatic test case and the abnormal root cause module can be automatically positioned through a specific point analysis algorithm by combining an abnormality positioning strategy, so that the time of research, development and testing personnel can be greatly saved, the time of service abnormality investigation is shortened, and the project delivery period is shortened.
According to an embodiment of the present application, the present disclosure further provides a computer program product, including a computer program, which when executed by a processor implements any one of the above-mentioned business anomaly localization methods.
According to the business anomaly positioning scheme provided by the embodiment of the application, the abnormal nodes are checked without logging in the offline environment one by manpower, so that the influence of human factors on the business anomaly positioning can be eliminated, and the reasons of the anomalies can be directly positioned, thereby providing more accurate business anomaly investigation records and result display. The abnormal positioning strategy can rapidly position business abnormality by scanning the examples and uniformly checking the frame from the bottommost layer, so that the positioning time consumption is further shortened; the first caller and the second caller can realize capability multiplexing among systems.
It should be appreciated that various forms of the flows shown above may be used to reorder, add, or delete steps. For example, the steps described in the present application may be performed in parallel, sequentially, or in a different order, provided that the desired results of the disclosed embodiments are achieved, and are not limited herein.
The above embodiments do not limit the scope of the present application. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives are possible, depending on design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present application should be included in the scope of the present application.

Claims (9)

1. The business anomaly positioning method is characterized by comprising the following steps:
receiving a service path identifier and abnormal information sent by a first scheduler, wherein the abnormal information is obtained by the first scheduler from a received abnormal positioning request, and the service path identifier is determined by the first scheduler according to the abnormal information;
acquiring service link information corresponding to the service path identifier according to a call chain acquisition probe, wherein the service link information comprises module information related to a service path and instance information of the module;
acquiring logs of corresponding examples according to the example information;
determining a business abnormality positioning result according to an abnormality positioning strategy and the log of the instance, wherein the business abnormality positioning result at least comprises an abnormality root cause module and an abnormality cause;
the anomaly localization strategy comprises anomaly definitions and anomaly solutions corresponding to the anomaly definitions; the anomaly definition comprises anomaly description information and anomaly reasons corresponding to the anomaly description information; the business abnormality positioning result also comprises an abnormality solution;
the determining the business abnormal positioning result according to the abnormal positioning strategy and the log of the example comprises the following steps:
scanning logs of each instance according to an abnormal positioning strategy;
determining an abnormal root cause module to which a corresponding instance belongs in response to the fact that the same abnormal description information is matched in the log, and determining an abnormal cause corresponding to the abnormal description information according to the abnormal positioning strategy;
determining an abnormality solution corresponding to the abnormality description information according to the abnormality positioning strategy;
after determining the business abnormal positioning result according to the abnormal positioning strategy and the log of the example, the method further comprises the following steps:
and sending the anomaly information and the business anomaly location result to a second scheduler so that the second scheduler determines callback operation according to the anomaly solution in the anomaly information and the business anomaly location result.
2. The method of claim 1, wherein the data structure of the traffic link information is a tree structure, and the scanning the log of each instance according to the anomaly localization policy comprises: and traversing and scanning the log of each instance according to the abnormal positioning strategy and the tree structure reverse order of the service link information.
3. The method of claim 1, further comprising the step of generating the anomaly localization strategy, the step of generating the anomaly localization strategy comprising:
in response to receiving the business program code, the log specification of the business program code is statically scanned, generating an anomaly localization strategy.
4. A method according to any one of claims 1-3, wherein after determining a business anomaly location result from an anomaly location policy and a log of the instance, further comprising: and storing the mapping relation between the service path identifier and the service abnormal positioning result.
5. The method according to claim 4, wherein the acquiring, according to a call chain acquisition probe, service link information corresponding to the service path identifier includes:
and responding to the fact that the service path identifier is not queried within a preset time before the current moment, and acquiring service link information corresponding to the service path identifier according to a call chain acquisition probe.
6. The method of claim 4, wherein after receiving the traffic path identifier sent by the first scheduler, further comprising:
and responding to the inquiry of the service path identifier in a preset time before the current moment, and determining a service abnormal positioning result corresponding to the service path identifier according to the mapping relation between the locally stored service path identifier and the service abnormal positioning result.
7. A business anomaly positioning device, comprising: the system comprises a receiving module, an acquisition module, an abnormal positioning module and a sending module, wherein the receiving module is used for receiving a service path identifier and abnormal information sent by a first scheduler, the abnormal information is acquired by the first scheduler from a received abnormal positioning request, and the service path identifier is determined by the first scheduler according to the abnormal information;
the acquisition module is used for acquiring service link information corresponding to the service path identifier according to a call chain acquisition probe, wherein the service link information comprises module information related to a service path and instance information of the module; acquiring logs of corresponding examples according to the example information;
the abnormal positioning module is used for determining a business abnormal positioning result according to an abnormal positioning strategy and the log of the instance, wherein the business abnormal positioning result at least comprises an abnormal root cause module and an abnormal cause; the anomaly localization strategy comprises anomaly definitions and anomaly solutions corresponding to the anomaly definitions; the anomaly definition comprises anomaly description information and anomaly reasons corresponding to the anomaly description information; the business abnormality positioning result also comprises an abnormality solution; wherein, scanning the log of each instance according to an abnormal positioning strategy; determining an abnormal root cause module to which a corresponding instance belongs in response to the fact that the same abnormal description information is matched in the log, and determining an abnormal cause corresponding to the abnormal description information according to the abnormal positioning strategy; determining an abnormality solution corresponding to the abnormality description information according to the abnormality positioning strategy;
the sending module is used for sending the abnormal information and the business abnormal positioning result to a second scheduler so that the second scheduler can determine callback operation according to the abnormal information and the abnormal solution in the business abnormal positioning result.
8. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-6.
9. A non-transitory computer readable storage medium storing computer instructions for causing the computer to perform the method of any one of claims 1-6.
CN202011526955.2A 2020-12-22 2020-12-22 Business abnormality positioning method and device, electronic equipment, medium and product Active CN112506799B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011526955.2A CN112506799B (en) 2020-12-22 2020-12-22 Business abnormality positioning method and device, electronic equipment, medium and product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011526955.2A CN112506799B (en) 2020-12-22 2020-12-22 Business abnormality positioning method and device, electronic equipment, medium and product

Publications (2)

Publication Number Publication Date
CN112506799A CN112506799A (en) 2021-03-16
CN112506799B true CN112506799B (en) 2023-11-10

Family

ID=74921920

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011526955.2A Active CN112506799B (en) 2020-12-22 2020-12-22 Business abnormality positioning method and device, electronic equipment, medium and product

Country Status (1)

Country Link
CN (1) CN112506799B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113204467B (en) * 2021-05-12 2024-01-30 北京百度网讯科技有限公司 Method, device, equipment and storage medium for monitoring online service system
CN113516174B (en) * 2021-06-03 2022-04-19 清华大学 Call chain abnormality detection method, computer device, and readable storage medium
CN114143221A (en) * 2021-11-29 2022-03-04 重庆富民银行股份有限公司 Service asset management method, platform and storage medium based on full link monitoring
CN114253846B (en) * 2021-12-17 2024-05-28 中国联合网络通信集团有限公司 Automatic test abnormality positioning method, device, equipment and readable storage medium
CN114301765A (en) * 2021-12-29 2022-04-08 中国电信股份有限公司 Fault positioning method and device, computer readable medium and electronic equipment
CN114500326B (en) * 2022-02-25 2023-08-11 北京百度网讯科技有限公司 Abnormality detection method, abnormality detection device, electronic device, and storage medium
CN114567573B (en) * 2022-03-10 2023-12-15 贵州中融信通科技有限公司 Abnormal data positioning method, device, server and storage medium
CN114936930B (en) * 2022-07-21 2022-11-29 平安银行股份有限公司 Method for managing abnormal timeliness service of network node, computer equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106250199A (en) * 2016-07-26 2016-12-21 北京北森云计算股份有限公司 The dynamic micro services call method of a kind of multilingual cloud compiling and device
CN107678933A (en) * 2017-09-28 2018-02-09 中国平安人寿保险股份有限公司 Daily record generation management method, device, equipment and computer-readable recording medium
CN109376056A (en) * 2018-10-17 2019-02-22 Oppo广东移动通信有限公司 Abnormal log analysis method, device, storage medium, mobile terminal and server
CN110012005A (en) * 2019-03-29 2019-07-12 新华三大数据技术有限公司 Identify method, apparatus, electronic equipment and the storage medium of abnormal data
CN110245035A (en) * 2019-05-20 2019-09-17 平安普惠企业管理有限公司 A kind of link trace method and device
CN112035318A (en) * 2020-08-28 2020-12-04 北京浪潮数据技术有限公司 Abnormal process positioning method, system and related device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9699049B2 (en) * 2014-09-23 2017-07-04 Ebay Inc. Predictive model for anomaly detection and feedback-based scheduling

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106250199A (en) * 2016-07-26 2016-12-21 北京北森云计算股份有限公司 The dynamic micro services call method of a kind of multilingual cloud compiling and device
CN107678933A (en) * 2017-09-28 2018-02-09 中国平安人寿保险股份有限公司 Daily record generation management method, device, equipment and computer-readable recording medium
CN109376056A (en) * 2018-10-17 2019-02-22 Oppo广东移动通信有限公司 Abnormal log analysis method, device, storage medium, mobile terminal and server
CN110012005A (en) * 2019-03-29 2019-07-12 新华三大数据技术有限公司 Identify method, apparatus, electronic equipment and the storage medium of abnormal data
CN110245035A (en) * 2019-05-20 2019-09-17 平安普惠企业管理有限公司 A kind of link trace method and device
WO2020233015A1 (en) * 2019-05-20 2020-11-26 平安普惠企业管理有限公司 Link tracking method and apparatus
CN112035318A (en) * 2020-08-28 2020-12-04 北京浪潮数据技术有限公司 Abnormal process positioning method, system and related device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于链路状态数据库的数据中心网络异常检测算法;许刚;王展;臧大伟;安学军;;计算机研究与发展(04);全文 *

Also Published As

Publication number Publication date
CN112506799A (en) 2021-03-16

Similar Documents

Publication Publication Date Title
CN112506799B (en) Business abnormality positioning method and device, electronic equipment, medium and product
CN107341098B (en) Software performance testing method, platform, equipment and storage medium
US9824002B2 (en) Tracking of code base and defect diagnostic coupling with automated triage
EP3859533A2 (en) Method and apparatus for testing map service, electronic device, storage medium and computer program product
EP3916560A1 (en) Fault injection method and apparatus, electronic device and storage medium to test microservices in the cloud
EP4006731B1 (en) Method, apparatus, device, storage medium and computer program product for testing code
CN111752843B (en) Method, apparatus, electronic device and readable storage medium for determining influence surface
US20170228220A1 (en) Self-healing automated script-testing tool
CN111666217B (en) Method and apparatus for testing code
CN111309609B (en) software processing system
CN110740071B (en) Method, device and system for monitoring network interface
CN112491617B (en) Link tracking method, device, electronic equipment and medium
KR102488582B1 (en) Method and apparatus for verifying operation state of application
CN113360144B (en) Auxiliary processing method, device, storage medium and program product for software development
CN112199355B (en) Data migration method and device, electronic equipment and storage medium
US20140215441A1 (en) Providing directional debugging breakpoints
US11715496B2 (en) Systems and methods for processing video data
CN110928796A (en) Automatic change test platform
US11874728B2 (en) Software application diagnostic aid
CN111708940B (en) Problem processing method, device, electronic equipment and storage medium
CN116166536A (en) Test method, test device, electronic equipment and storage medium
CN112671665B (en) Intelligent traffic scheduling method, device, equipment and storage medium
CN112527635B (en) Fault injection method and device, electronic equipment and storage medium
CN113434382A (en) Database performance monitoring method and device, electronic equipment and computer readable medium
CN113626288A (en) Fault processing method, system, device, storage medium and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant