Method and apparatus for service monitoring

By monitoring the second service associated with the first service and reverting the state of the first service in case of anomalies, the problem of time-consuming fault location in downstream services was solved, and rapid fault response and loss reduction were achieved.

CN113961431BActive Publication Date: 2026-02-27VIVO MOBILE COMM CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111260254.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-10-27
Publication Date
2026-02-27
Estimated Expiration
2042-02-27

AI Technical Summary

Technical Problem

In business scenarios, the long time required to locate faults in downstream businesses leads to significant business losses.

Method used

By obtaining the monitoring and alarm configuration information of the first service, the second service associated with it is monitored, and when the second service is abnormal, the first service is rolled back to its state before the change.

Benefits of technology

This shortened the time for locating business faults and reduced business losses.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113961431B_ABST
    Figure CN113961431B_ABST
Patent Text Reader

Abstract

The application discloses a service monitoring method and device, and belongs to the technical field of system monitoring. The service monitoring method comprises the following steps: in the case that a first service is changed, monitoring alarm configuration information of the first service is acquired, wherein the monitoring alarm configuration information comprises at least one second service having an associated relationship with the first service and monitoring indexes corresponding to the second service; the second service is monitored according to the monitoring alarm configuration information, and monitoring alarm information is obtained; and in the case that the monitoring alarm information indicates that the second service is abnormal, the first service is rolled back to a state before the change.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application belongs to the technical field of system monitoring, and particularly relates to a service monitoring method and device. BACKGROUND

[0002] At present, in various service scenarios, multiple services with a dependency relationship can form a service dependency chain, and a downstream service of the service dependency chain can be affected by an upstream service. For example, when the upstream service is changed, the downstream service can be affected and fail.

[0003] In the related art, after the downstream service fails, a human being needs to track the failure cause of the downstream service and determine whether the failure of the downstream service is related to the change of the upstream service, so as to roll back the upstream service when the failure of the downstream service is related to the change of the upstream service. However, this method takes a long time and causes great business loss. SUMMARY

[0004] Embodiments of the present application provide a service monitoring method, device and electronic equipment, which can solve the problem that the failure of a downstream service is tracked by a human being, a long time is taken, and great business loss is caused.

[0005] In a first aspect, a service monitoring method is provided, and the method comprises the following steps.

[0006] In a case where a first service is changed, monitoring alarm configuration information of the first service is acquired, wherein the monitoring alarm configuration information comprises at least one second service having an association relationship with the first service and monitoring indicators corresponding to the second service.

[0007] The second service is monitored according to the monitoring alarm configuration information, and monitoring alarm information is obtained.

[0008] In a case where the monitoring alarm information indicates that the second service is abnormal, the first service is rolled back to a state before the change.

[0009] In a second aspect, a service monitoring device is provided, and the device comprises the following modules.

[0010] An acquisition module is configured to acquire monitoring alarm configuration information of a first service in a case where the first service is changed, wherein the monitoring alarm configuration information comprises at least one second service having an association relationship with the first service and monitoring indicators corresponding to the second service.

[0011] A monitoring module is configured to monitor the second service according to the monitoring alarm configuration information, and obtain monitoring alarm information.

[0012] a rollback module, configured to rollback the first service to a state before the change in a case that the monitoring alarm message indicates that the second service is abnormal.

[0013] In a third aspect, an electronic device is provided, which includes a processor, a memory, and a program or instruction stored in the memory and executable on the processor, and the program or instruction, when executed by the processor, implements the steps of the method according to the first aspect.

[0014] In a fourth aspect, a readable storage medium is provided, which stores a program or instruction, and the program or instruction, when executed by a processor, implements the steps of the method according to the first aspect.

[0015] In a fifth aspect, a chip is provided, which includes a processor and a communication interface, the communication interface is coupled to the processor, and the processor is configured to execute a program or instruction to implement the method according to the first aspect.

[0016] In the embodiments of the present application, in a case that a first service is changed, monitoring alarm configuration information of the first service is obtained, at least one second service having an association relationship with the first service is monitored according to the monitoring alarm configuration information, a monitoring alarm message is obtained, and the first service is rolled back to a state before the change in a case that the monitoring alarm message indicates that the second service is abnormal. In this way, the change platform and the monitoring alarm platform can be associated, the second service having the association relationship with the first service can be tracked when the first service is changed, and the first service can be automatically rolled back to the state before the change when the second service is abnormal. Compared with the prior art of tracking the fault reason after the service is faulty, the positioning time of service fault can be shortened, and the loss can be reduced. BRIEF DESCRIPTION OF DRAWINGS

[0017] Figure 1 is one of flow diagrams of a service monitoring method provided by the embodiments of the present application;

[0018] Figure 2 is another one of flow diagrams of a service monitoring method provided by the embodiments of the present application;

[0019] Figure 3 is a third one of flow diagrams of a service monitoring method provided by the embodiments of the present application;

[0020] Figure 4 is a structural diagram of a service monitoring device provided by the embodiments of the present application;

[0021] Figure 5 is a structural diagram of an electronic device provided by the embodiments of the present application;

[0022] Figure 6 is a hardware structure schematic diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0023] The technical solutions in the embodiments of the present application will be clearly described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, but not all of them. Based on the embodiments in the present application, all other embodiments obtained by a person of ordinary skill in the art belong to the scope of protection of the present application.

[0024] The terms "first", "second", and the like in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described herein, and the objects distinguished by "first", "second", etc. are usually a category, and are not limited to the number of objects, for example, the first object can be one or more. In addition, "and / or" in the specification and claims means at least one of the connected objects, and the character " / ", generally represents a "or" relationship between the front and rear associated objects.

[0025] The business monitoring method provided by the embodiments of the present application will be described in detail below with reference to the drawings and specific embodiments and application scenarios.

[0026] As shown in Figure 1 The embodiments of the present application provide a business monitoring method, which can include steps 1100-1300, which will be described in detail below.

[0027] Step 1100, in the case of a change in a first business, obtaining monitoring alarm configuration information of the first business, wherein the monitoring alarm configuration information includes at least one second business having an associated relationship with the first business, and a monitoring indicator corresponding to the second business.

[0028] In the present embodiment, the first business can be one of the businesses in a business link. The business link can include a plurality of businesses having an associated relationship. For example, business link 1: business a→ business b→ business c→ business d→ business e. For another example, business link 2: business b→ business d→ business f→ business g→ business h. For another example, business link 3: business b→ business d→ business e→ business j→ business k. The second business can be other business in the business link except the first business. For example, the first business is business a in business link 1, and the second business can include one or more of business b, business c, business d, and business e.

[0029] The first service can be changed, and the first service can be upgraded. For example, the first service can be changed by changing a platform. For example, a user can register the first service through the changed platform, and when the first service needs to be upgraded, the version of the first service can be changed through the changed platform.

[0030] The monitoring alarm configuration information of the first service can indicate a service that needs to be monitored when the first service is changed. The monitoring alarm configuration information can include a second service identifier of a second service, or can include second service identifiers of multiple second services. That is, the monitoring alarm configuration information of the first service can include one or more other services in the service link corresponding to the first service, or can include all other services in the service link corresponding to the first service. The second service can be a service having an association relationship with the first service. The second service identifier is used to indicate the service type of the second service. Different second services correspond to different second service identifiers.

[0031] The monitoring alarm configuration information can also include monitoring indicators corresponding to the second service. The monitoring indicators can indicate indicators of the second service to be monitored by the user. For example, the monitoring indicators can be data traffic, request volume of a data interface, occupied CPU memory, and the like. For different types of second services, different monitoring indicators can be set. For example, the first service generates data, and the second service receives data output by the first service. When the first service is changed, the change in the input data volume of the second service can be monitored to monitor whether the second service is affected by the change of the first service.

[0032] It should be noted that the monitoring alarm configuration information of the first service can be pre-configured by the user. For example, when the first service is registered through the changed platform, the monitoring alarm configuration information of the first service can be configured. For example, when the first service is changed, the monitoring alarm configuration information of the first service can also be configured.

[0033] After step 1100, step 1200 is performed, and the second service is monitored according to the monitoring alarm configuration information to obtain a monitoring alarm message.

[0034] In this embodiment, the monitoring alarm information can indicate whether the monitoring indicators corresponding to the second service are abnormal.

[0035] In some embodiments of the present application, the monitoring the second service according to the monitoring alarm configuration information to obtain a monitoring alarm message can further include: obtaining monitoring data corresponding to the second service and a preset alarm condition, wherein the preset alarm condition includes at least one of a traffic alarm condition, an interface request volume alarm condition, and a memory occupancy ratio alarm condition; and generating the monitoring alarm message in a case where the monitoring data corresponding to the second service meets the preset alarm condition.

[0036] The monitoring data can be data corresponding to the monitoring indicators of the second service. In a specific implementation, the data corresponding to the monitoring indicators of the second service is obtained by collecting log data of the second service and filtering the log data.

[0037] The preset alarm condition can be a condition for triggering a monitoring alarm that is set in advance by a monitoring alarm platform. The preset alarm condition can include at least one of a traffic alarm condition, an interface request volume alarm condition, and a memory occupancy ratio alarm condition. The traffic alarm condition can be a minimum value traffic alarm condition, i.e., a monitoring alarm is triggered when the input data volume of the second service is less than a minimum value traffic alarm threshold. The interface request volume alarm condition can be a maximum value request volume alarm condition, i.e., a monitoring alarm is triggered when the interface request volume of the second service is greater than a maximum value request volume alarm threshold. The memory occupancy ratio alarm condition can be a maximum value memory occupancy ratio alarm condition, i.e., a monitoring alarm is triggered when the memory occupied by the second service in the CPU is greater than a maximum value memory alarm threshold.

[0038] In this embodiment, the user can pre-configure the monitoring alarm configuration information and set different monitoring indicators and alarm conditions for different types of services. In this way, when the first service is changed, the second service having an associated relationship with the first service can be monitored according to the monitoring alarm configuration information configured by the user, the second service can be monitored in a timely manner to determine whether the second service is affected by the first service, the fault tracking time can be shortened, and the loss can be reduced.

[0039] After step 1200, step 1300 is performed. In a case where the monitoring alarm message indicates that the second service is abnormal, the first service is rolled back to a state before the change.

[0040] In the embodiments of the present application, in the case that the first service is changed, the monitoring alarm configuration information of the first service is acquired, at least one second service having an association relationship with the first service is monitored according to the monitoring alarm configuration information, the monitoring alarm message is obtained, and in the case that the monitoring alarm message indicates that the second service is abnormal, the first service is rolled back to the state before the change. In this way, the change platform and the monitoring alarm platform can be associated, the second service having an association relationship with the first service can be tracked when the first service is changed, and the first service can be automatically rolled back to the state before the change when the second service is abnormal. Compared with the prior art in which the fault reason is tracked after the service is faulty, the positioning time of the service fault can be shortened, and the loss can be reduced.

[0041] In some embodiments of the present application, in the case that the monitoring alarm message indicates that the second service is abnormal, rolling back the first service to the state before the change can further include: determining whether the second service is in the service link corresponding to the first service according to the monitoring alarm message and the second service identifier of the second service; and rolling back the first service to the state before the change in the case that the second service is determined to be in the service link corresponding to the first service.

[0042] In the embodiments, in the case that the monitoring alarm message indicates that the second service is abnormal, the monitoring alarm message is matched with the service link information corresponding to the first service to determine the first service causing the fault of the second service, so as to roll back the corresponding first service to the state before the change, which can improve the accuracy of identification.

[0043] In some optional embodiments, as shown in Figure 2 The step of determining whether the second service is in the service link corresponding to the first service according to the monitoring alarm message and the second service identifier of the second service can further include steps 2100-2300.

[0044] In step 2100, the target monitoring identifier is obtained according to the monitoring alarm message.

[0045] In this embodiment, the target monitoring identifier is used to identify a monitoring task generated by a change of the first service. Each service change corresponds to a unique monitoring task. That is, different service change generates different monitoring tasks. For example, service link 1: service a→service b→service c→service d→service e, the monitoring alarm configuration information includes service c and service d, when service a changes, a monitoring task t1 is generated, the monitoring task t1 is a task of monitoring service c and service d. For another example, service link 2: service b→service d→service f→service g→service h, the monitoring alarm configuration information includes service d and service f, when service b changes, a monitoring task t2 is generated, the monitoring task t2 is a task of monitoring service d and service f.

[0046] In step 2200, according to the target monitoring identifier, service link information corresponding to the first service is obtained, wherein the service link information includes service identifiers of all services having an association relationship with the first service.

[0047] In step 2300, in a case where the second service identifier exists in the service link information, the first service is rolled back to a state before the change.

[0048] In this embodiment, for the same service that may belong to different service links, different monitoring tasks can monitor the same service. For example, monitoring task t1 and monitoring task t2 both monitor service d. In this case, when a certain service is abnormal, the monitoring task corresponding to the service, i.e., the service link corresponding to the service, needs to be determined.

[0049] In specific implementation, in a case where the monitoring alarm message indicates that the second service is abnormal, the monitoring alarm message is obtained, the target monitoring identifier is matched with a task identifier of a monitoring task generated by a change of the first service, a service link list corresponding to the change of the first service can be determined, the second service identifier is matched with the service link list, and in a case where the second service identifier exists in the service link information, the first service is rolled back to a state before the change.

[0050] In this embodiment, in a case where the monitoring alarm message indicates that the second service is abnormal, the monitoring alarm message is matched with service link information corresponding to the first service to determine the first service causing the failure of the second service, so that the corresponding first service is rolled back to a state before the change, and the accuracy of identification can be improved.

[0051] In the embodiment, in order to reduce the amount of matched data and improve the monitoring identification efficiency, before determining whether the second service is in the service link corresponding to the first service according to the monitoring alarm message and the second service identifier of the second service, the second service with an exception can be screened according to the change time information and the service area information. The following is described with specific embodiments.

[0052] In some embodiments of the present application, as shown in Figure 3 Before determining whether the second service is in the service link corresponding to the first service according to the monitoring alarm message and the second service identifier of the second service, the method can further include steps 3100-3300.

[0053] Step 3100, match the monitoring alarm message with the change time information of the change of the first service.

[0054] The change time information can include a change time window and a change operation time. The change time window can be a time period in which a service can perform a change operation. For example, the change time window of service a is 8:00-12:00, and the change time window of service b is 14:00-17:00. The change operation time can be the time when a service changes.

[0055] In some embodiments of the present application, the change time information includes a change time window and a change operation time, and matching the monitoring alarm message with the change time information of the change of the first service can further include: obtaining an alarm time according to the monitoring alarm message; comparing the alarm time with the change operation time if the alarm time is within the change time window; and determining that the monitoring alarm information matches the change time information if the difference between the alarm time and the change operation time is not greater than a preset threshold.

[0056] In this embodiment, the alarm time can be the time when the second service has an exception. The alarm time of the second service is matched with the change time window corresponding to the first service. If the alarm time of the second service is not within the change time window corresponding to the first service, it means that the failure of the second service is not caused by the change of the first service. If the alarm time of the second service is within the change time window corresponding to the first service, it means that the time when the second service has an exception and the time when the first service changes can overlap, and it is necessary to further compare the alarm time of the second service with the change operation time information of the first service to determine whether the monitoring alarm information of the second service matches the change time information of the first service.

[0057] The preset threshold value can reflect whether the time when the second service is abnormal is close to the time when the first service is changed. In a case where a difference between the alarm time and the change operation time is not greater than the preset threshold value, it is indicated that the time when the second service is abnormal is consistent with the time when the first service is changed, and the possibility that the failure of the second service is caused by the change of the first service is greater. The monitoring alarm message and the service link information corresponding to the first service can be further matched to determine the first service causing the failure of the second service, so as to rollback the corresponding first service to the state before the change.

[0058] In the embodiment, in a case where the monitoring alarm message indicates that the second service is abnormal, the alarm time of the second service is compared with the change time information of the first service, the services that are not matched with the change time of the first service can be directly excluded, the operation amount can be reduced, and the fault identification speed can be improved.

[0059] After step 3100, step 3200 is performed. In a case where the monitoring alarm information is matched with the change time information, the monitoring alarm message is matched with service area information of the first service.

[0060] The service area information of the first service can include machine room information and logical partition information of a machine room where the first service is located. The machine room information can be a physical partition of the first service. The logical partition information of the first service can be preset by a user according to a service type of the first service. It should be noted that the service area information of the first service can be configured when the first service is registered on a change platform.

[0061] In some embodiments of the present application, the service area information of the first service includes machine room information and logical partition information of a machine room where the first service is located. The matching of the monitoring alarm message with the service area information of the first service can further include: obtaining alarm service area information according to the monitoring alarm message; in a case where the alarm service area information is in a service area corresponding to the machine room information, comparing the alarm service area information with the logical partition information; and in a case where the alarm service area information is matched with the logical partition information, determining that the monitoring alarm message is matched with the service area information of the first service.

[0062] The alarm service area information can include the data center information and logical partition information of the data center where the second service is located. Matching the data center information of the second service with that of the first service, if they are inconsistent, it indicates that the failure of the second service is not caused by the change in the first service. If they are consistent, it indicates that the failure of the second service may be caused by the change in the first service. Further matching of the logical partition information of the second service with that of the first service is needed to determine if the monitoring alarm information of the second service matches the change time information of the first service. If the logical partition information of the second service matches that of the first service, it is highly likely that the failure of the second service was caused by the change in the first service. Further matching of the monitoring alarm messages with the corresponding service link information of the first service can be performed to identify the first service causing the failure of the second service, thereby reverting the corresponding first service to its pre-change state.

[0063] In this embodiment, when a monitoring alarm message indicates that the second service is abnormal, the alarm service area information of the second service is compared with the service area information of the first service. Services that do not match the service area information of the first service can be directly excluded, which can reduce the amount of computation and improve the speed of fault identification.

[0064] Step 3300: If the alarm service area information corresponding to the monitoring alarm message matches the service area information of the first service, perform the step of determining whether the second service is in the service link corresponding to the first service based on the monitoring alarm message and the second service identifier of the second service.

[0065] In this embodiment, when the monitoring alarm message indicates that the second service is abnormal, the abnormal second service can be filtered according to the change time information and service area information, which can reduce the amount of computation and improve the efficiency of fault identification.

[0066] In some embodiments of this application, after determining whether the second service is in the service link corresponding to the first service based on the monitoring alarm message and the second service identifier of the second service, the method may further include: if it is determined that the second service is not in the service link corresponding to the first service, pushing a prompt message indicating that the second service is abnormal.

[0067] In this embodiment, the prompt message is used to prompt the user to track the failure of the second service. The prompt information of the abnormal second service can be pushed according to the pre-acquired push path. The push path can be mail push, short message push, etc.

[0068] In this embodiment, when the second service is not in the service link corresponding to the first service, it is indicated that the failure of the second service is not caused by the change of the first service. At this time, the prompt message of the abnormal second service is pushed, which can prompt the relevant personnel to track the failure of the second service, so as to timely solve the failure of the second service and reduce the loss.

[0069] It should be noted that the execution subject of the service monitoring method provided in the embodiment of the application can be a service monitoring device, or a control module in the service monitoring device for executing the service monitoring method. In the embodiment of the application, the service monitoring method executed by the service monitoring device is taken as an example to illustrate the service monitoring device provided in the embodiment of the application.

[0070] Please refer to Figure 4 The embodiment of the application further provides a service monitoring device 400, which comprises an acquisition module 401, a monitoring module 402 and a rollback module 403.

[0071] The acquisition module 401 is configured to acquire monitoring alarm configuration information of a first service in the case where the first service is changed, wherein the monitoring alarm configuration information comprises at least one second service having an associated relationship with the first service, and a monitoring index corresponding to the second service.

[0072] The monitoring module 402 is configured to monitor the second service according to the monitoring alarm configuration information, to obtain a monitoring alarm message.

[0073] The rollback module 403 is configured to rollback the first service to a state before the change in the case where the monitoring alarm message indicates that the second service is abnormal.

[0074] Optionally, the rollback module 403 comprises a first determination unit configured to determine whether the second service is in a service link corresponding to the first service according to the monitoring alarm message and a second service identifier of the second service; and a rollback unit configured to rollback the first service to the state before the change in the case where it is determined that the second service is in the service link corresponding to the first service.

[0075] Optionally, the first determining unit is specifically configured to: obtain a target monitoring identifier according to the monitoring alarm message, wherein the target monitoring identifier is used to identify a monitoring task generated by the first service change; obtain service link information corresponding to the first service according to the target monitoring identifier, wherein the service link information comprises service identifiers of all services having an association relationship with the first service; and in a case where the second service identifier exists in the service link information, roll back the first service to a state before the change.

[0076] Optionally, the apparatus further comprises: a first matching module configured to match the monitoring alarm message with change time information of the first service change; a second matching module configured to match the monitoring alarm message with service area information of the first service in a case where the monitoring alarm information matches the change time information; and an executing module configured to execute the step of determining whether the second service is in the service link corresponding to the first service according to the monitoring alarm message and the second service identifier of the second service in a case where alarm service area information corresponding to the monitoring alarm message matches the service area information of the first service.

[0077] Optionally, the change time information comprises a change time window and a change operation time, and the first matching module comprises: a first obtaining unit configured to obtain an alarm time according to the monitoring alarm message; a first comparing unit configured to compare the alarm time with the change operation time in a case where the alarm time is within the change time window; and a second determining unit configured to determine that the monitoring alarm information matches the change time information in a case where a difference between the alarm time and the change operation time is not greater than a preset threshold.

[0078] In the embodiments of the present application, in a case where a first service changes, monitoring alarm configuration information of the first service is obtained, at least one second service having an association relationship with the first service is monitored according to the monitoring alarm configuration information, a monitoring alarm message is obtained, and in a case where the monitoring alarm message indicates that the second service has an exception, the first service is rolled back to a state before the change. In this way, the change platform and the monitoring alarm platform can be associated, the second service having an association relationship with the first service can be tracked when the first service changes, and the first service can be automatically rolled back to the state before the change when the second service has an exception. Compared with the prior art in which a fault reason is tracked after a service has a fault, the positioning time of the service fault can be shortened, and the loss can be reduced.

[0079] The service monitoring apparatus in the embodiments of the present application can be an apparatus, or a component, an integrated circuit, or a chip in a terminal. The apparatus can be a mobile electronic device, or a non-mobile electronic device. Exemplarily, the mobile electronic device can be a mobile phone, a tablet computer, a notebook computer, a palm computer, a vehicle-mounted electronic device, a wearable device, an ultra-mobile personal computer (UMPC), a netbook, or a personal digital assistant (PDA), etc., and the non-mobile electronic device can be a server, a network attached storage (NAS), a personal computer (PC), a television (TV), a teller machine, or a self-service machine, etc., and the embodiments of the present application are not limited specifically.

[0080] The service monitoring apparatus in the embodiments of the present application can be an apparatus with an operating system. The operating system can be an Android operating system, an iOS operating system, or other possible operating systems, and the embodiments of the present application are not limited specifically.

[0081] The service monitoring apparatus provided in the embodiments of the present application can implement the method embodiments, and each process of the method embodiments is not repeated here to avoid repetition. Figure 1 The service monitoring apparatus provided in the embodiments of the present application can implement the method embodiments, and each process of the method embodiments is not repeated here to avoid repetition.

[0082] Optionally, as shown in Figure 5 The embodiments of the present application further provide an electronic device 500, which includes a processor 501, a memory 502, a program or instruction stored in the memory 502 and executable on the processor 501. The program or instruction is executed by the processor 501 to implement each process of the above service monitoring method embodiments and achieve the same technical effects. Each process of the method embodiments is not repeated here to avoid repetition.

[0083] It should be noted that the electronic device in the embodiments of the present application includes the above-mentioned mobile electronic device and non-mobile electronic device.

[0084] Figure 6 A hardware structure schematic diagram of an electronic device for implementing the embodiments of the present application.

[0085] The electronic device 600 includes, but is not limited to, a radio frequency unit 601, a network module 602, an audio output unit 603, an input unit 604, a sensor 605, a display unit 606, a user input unit 607, an interface unit 608, a memory 609, and a processor 610, etc.

[0086] Those skilled in the art can understand that the electronic device 600 can further include a power supply (such as a battery) for supplying power to each component, and the power supply can be logically connected to the processor 610 through a power management system, so that the power management system can realize functions such as management of charging, discharging, and power consumption management. Figure 6 The electronic device structure shown in the foregoing embodiments does not constitute a limitation on the electronic device, and the electronic device can include more or fewer components than those shown, or combine certain components, or arrange different components, which will not be described here.

[0087] The processor 610 is configured to: in a case where a first service is changed, acquire monitoring alarm configuration information of the first service, wherein the monitoring alarm configuration information includes at least one second service having an association relationship with the first service, and monitoring indicators corresponding to the second service; monitor the second service according to the monitoring alarm configuration information to obtain a monitoring alarm message; and in a case where the monitoring alarm message indicates that the second service is abnormal, roll back the first service to a state before the change.

[0088] Optionally, when the processor 610 rolls back the first service to the state before the change in the case where the monitoring alarm message indicates that the second service is abnormal, the processor 610 is configured to: determine whether the second service is in a service link corresponding to the first service according to the monitoring alarm message and a second service identifier of the second service; and in a case where it is determined that the second service is in the service link corresponding to the first service, roll back the first service to the state before the change.

[0089] Optionally, when the processor 610 determines whether the second service is in the service link corresponding to the first service according to the monitoring alarm message and the second service identifier of the second service, the processor 610 is configured to: obtain a target monitoring identifier according to the monitoring alarm message, wherein the target monitoring identifier is used to identify a monitoring task generated by the change of the first service; obtain service link information corresponding to the first service according to the target monitoring identifier, wherein the service link information includes service identifiers of all services having an association relationship with the first service; and in a case where the second service identifier exists in the service link information, roll back the first service to the state before the change.

[0090] Optionally, before the determining whether the second service is in the service link corresponding to the first service according to the monitoring alarm message and the second service identifier of the second service, the processor 610 is further configured to: match the monitoring alarm message with change time information of the change of the first service; match the monitoring alarm message with service area information of the first service in the case that the monitoring alarm information matches the change time information; and perform the determining whether the second service is in the service link corresponding to the first service according to the monitoring alarm message and the second service identifier of the second service in the case that the alarm service area information corresponding to the monitoring alarm message matches the service area information of the first service.

[0091] Optionally, the change time information includes a change time window and a change operation time, and when matching the monitoring alarm message with the change time information of the change of the first service, the processor 610 is configured to: obtain alarm time according to the monitoring alarm message; compare the alarm time with the change operation time in the case that the alarm time is within the change time window; and determine that the monitoring alarm information matches the change time information in the case that a difference between the alarm time and the change operation time is not greater than a preset threshold.

[0092] In the embodiments of the present application, in the case that the first service changes, the monitoring alarm configuration information of the first service is obtained, at least one second service having an association relationship with the first service is monitored according to the monitoring alarm configuration information, the monitoring alarm message is obtained, and the first service is rolled back to a state before the change in the case that the monitoring alarm message indicates that the second service has an exception. In this way, the change platform and the monitoring alarm platform can be associated, the second service having an association relationship with the first service can be tracked when the first service changes, and the first service can be automatically rolled back to the state before the change when the second service has an exception. Compared with the way of the prior art that the fault reason is tracked after the service has a fault, the positioning time of the service fault can be shortened, and the loss can be reduced.

[0093] It should be understood that in the embodiments of the present application, the input unit 604 can include a graphics processor (GPU) 6041 and a microphone 6042. The graphics processor 6041 processes image data of a still picture or a video obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The display unit 606 can include a display panel 6061, which can be configured in the form of a liquid crystal display, an organic light-emitting diode, etc. The user input unit 607 includes a touch panel 6071 and other input devices 6072. The touch panel 6071 is also called a touch screen. The touch panel 6071 can include two parts of a touch detection device and a touch controller. The other input devices 6072 can include, but are not limited to, a physical keyboard, function keys (such as volume control keys, on-off keys, etc.), a trackball, a mouse, a joystick, and the like, which will not be described here. The memory 609 can be used to store software programs and various data, including but not limited to application programs and operating systems. The processor 610 can integrate an application processor and a modem processor, wherein the application processor mainly processes operating systems, user interfaces and application programs, etc., and the modem processor mainly processes wireless communication. It can be understood that the above-mentioned modem processor can also not be integrated into the processor 610.

[0094] The embodiments of the present application also provide a readable storage medium, which stores programs or instructions, and the programs or instructions are executed by a processor to realize the processes of the above business monitoring method embodiments and achieve the same technical effects. To avoid repetition, details are not described here.

[0095] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.

[0096] The embodiments of the present application further provide a chip, which includes a processor and a communication interface. The communication interface is coupled with the processor. The processor is configured to run programs or instructions to realize the processes of the above business monitoring method embodiments and achieve the same technical effects. To avoid repetition, details are not described here.

[0097] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip, etc.

[0098] It should be noted that, in the present document, the terms "comprises", "comprising", or any other variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but can include other elements not expressly listed or inherent to such process, method, article, or apparatus. An element proceeded by "comprises... a" does not, without more constraints, exclude the presence of additional identical elements in the process, method, article, or apparatus that comprises the element. Furthermore, it is to be understood that the method and apparatus of the present application can be carried out by more than one process, method, article, or apparatus either simultaneously, concurrently, or with intervening action that are carried out at the same time, either in a simultaneous fashion or in a fashion that is interleaved in time. For example, the described methods can be performed in a different order from that described, and / or various steps can be combined or omitted, and / or additional steps can be added, without departing from the scope of the present application. Also, features described with respect to certain examples can be combined in other examples.

[0099] From the above description of the embodiments, it is apparent that the above-mentioned method can be realized by means of software and necessary universal hardware platform, of course, it can also be realized by hardware, but in many cases, the former is a better embodiment. Based on such understanding, the technical solution of the present application can be embodied in the form of computer software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a plurality of instructions for making a terminal (which can be a mobile phone, computer, server, or network equipment, etc.) execute the method described in various embodiments of the present application.

[0100] The embodiments of the present application are described above in conjunction with the drawings, but the present application is not limited to the above-described specific embodiments, and the above-described specific embodiments are merely illustrative, rather than limiting, and those skilled in the art can make many forms under the inspiration of the present application without departing from the scope of the present application and the protection scope of the claims, which all belong to the protection scope of the present application.

Claims

1. A service monitoring method characterized by, The method comprises: In the case where the first service is changed, obtaining monitoring alarm configuration information of the first service, wherein the monitoring alarm configuration information comprises at least one second service having an association relationship with the first service and monitoring indicators corresponding to the second service; According to the monitoring alarm configuration information, monitoring the second service to obtain a monitoring alarm message; In the case where the monitoring alarm message indicates that the second service is abnormal, rolling back the first service to a state before the change; Wherein, in the case where a second service identifier of the second service exists in service link information corresponding to the first service, the first service is rolled back to the state before the change, the service link information comprises service identifiers of all services having an association relationship with the first service, the service link information is determined according to a target monitoring identifier, the target monitoring identifier is used to identify a monitoring task generated by the change of the first service, and the target monitoring identifier is determined according to the monitoring alarm message.

2. The method of claim 1, wherein, The method further comprises: Matching the monitoring alarm message with change time information of the change of the first service; In the case where the monitoring alarm information matches the change time information, matching the monitoring alarm message with service area information of the first service; 3. The method of claim 2, wherein, In the case where alarm service area information corresponding to the monitoring alarm message matches the service area information of the first service, performing the step of determining whether the second service is in the service link corresponding to the first service according to the monitoring alarm message and the second service identifier of the second service. The change time information comprises a change time window and a change operation time, and the matching of the monitoring alarm message with the change time information of the change of the first service comprises: Obtaining an alarm time according to the monitoring alarm message; In the case where the alarm time is within the change time window, comparing the alarm time with the change operation time; 4. The method of claim 3, wherein, In the case where a difference between the alarm time and the change operation time is not greater than a preset threshold, determining that the monitoring alarm information matches the change time information. The device comprises: An obtaining module, configured to, in the case where a first service is changed, obtain monitoring alarm configuration information of the first service, wherein the monitoring alarm configuration information comprises at least one second service having an association relationship with the first service and monitoring indicators corresponding to the second service; ​ 5. A service monitoring apparatus characterized by comprising: ​ ​ The monitoring module is configured to monitor the second service according to the monitoring alarm configuration information, and obtain a monitoring alarm message. The rollback module is configured to rollback the first service to a state before the change in a case where the monitoring alarm message indicates that the second service is abnormal. In a case where a second service identifier of the second service exists in service link information corresponding to the first service, the rollback module is configured to rollback the first service to the state before the change. The service link information includes service identifiers of all services having an association relationship with the first service. The service link information is determined according to a target monitoring identifier. The target monitoring identifier is used to identify a monitoring task generated by the change of the first service. The target monitoring identifier is determined according to the monitoring alarm message.

6. The apparatus of claim 5, wherein, The rollback module includes: The first determination unit is configured to determine, according to the monitoring alarm message and a second service identifier of the second service, whether the second service is in a service link corresponding to the first service. The rollback unit is configured to rollback the first service to the state before the change in a case where it is determined that the second service is in the service link corresponding to the first service.

7. The apparatus of claim 6, wherein, The apparatus further includes: The first matching module is configured to match the monitoring alarm message with change time information of the change of the first service. The second matching module is configured to match the monitoring alarm message with service area information of the first service in a case where the monitoring alarm information matches the change time information. The execution module is configured to perform the step of determining, according to the monitoring alarm message and the second service identifier of the second service, whether the second service is in the service link corresponding to the first service in a case where alarm service area information corresponding to the monitoring alarm message matches the service area information of the first service.

8. The apparatus of claim 7, wherein, The change time information includes a change time window and a change operation time. The first matching module includes: The first obtaining unit is configured to obtain an alarm time according to the monitoring alarm message. The first comparison unit is configured to compare the alarm time with the change operation time in a case where the alarm time is within the change time window. The second determination unit is configured to determine that the monitoring alarm information matches the change time information in a case where a difference between the alarm time and the change operation time is not greater than a preset threshold.

Citation Information

Patent Citations

  • Fault positioning method and device, computing equipment and medium

    CN111782437A

  • Application system monitoring management method and device, equipment and storage medium

    CN113051134A