Equipment fault diagnosis method based on micro-service architecture
By building a comprehensive service platform and the fault diagnosis component, rapid fault diagnosis of different types of equipment is achieved, and the problem that equipment cannot be diagnosed simultaneously in the existing technology is solved, which improves the efficiency of equipment recovery and operation and the quality of fault diagnosis.
Patent Information
- Application Number
- CN202510475352.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-16
- Publication Date
- 2025-07-25
AI Technical Summary
Existing equipment fault diagnosis methods cannot simultaneously diagnose different types of equipment, resulting in the equipment being unable to resume operation in a short period of time, affecting work efficiency and causing waste of material and financial resources.
Build a comprehensive service platform and fault diagnosis component, receive fault detection data through the comprehensive service platform, judge the device type and send it to the corresponding fault diagnosis component for analysis, obtain analysis results and repair plans, and store and feedback the results.
It realizes rapid fault diagnosis of different types of equipment, ensures that the equipment resumes operation in a short time, improves the efficiency and quality of fault diagnosis, and ensures the stability of components.
Smart Images

Figure CN120378283A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of Internet of Things, and particularly relates to a device fault diagnosis method based on a microservice architecture. Background Technique
[0002] The microservice architecture is a new technology for deploying applications and services in the cloud. Microservices can run in their own programs. In traditional service exposure, many services can be restricted by internal independent processes. If any one of these services needs to add a certain function, then the process scope must be reduced. In the microservice architecture, only the required function needs to be added to a specific service without affecting the overall process architecture.
[0003] Fault diagnosis is a technology that understands and masters the state of a machine during operation, determines whether its overall or local part is normal or abnormal, discovers faults and their causes at an early stage, and can predict the development trend of faults. Oil monitoring, vibration monitoring, noise monitoring, performance trend analysis, and non-destructive testing are its main diagnostic technology methods. System fault diagnosis is to make a judgment on the operating state and abnormal conditions of the system, and provide a basis for system fault recovery according to the diagnosis. To diagnose the faults of a system, it must first be detected. When a system fault occurs, diagnose the fault type, fault location, and cause, and finally give a solution to achieve fault recovery. However, in the existing device fault diagnosis, for different types of devices, only specific instruments can be relied on for fault diagnosis. Without specific instruments, it is impossible to diagnose and repair the device in time, and it is impossible to make the device resume operation in a short time, which greatly affects the normal work efficiency and causes waste of material and financial resources. Therefore, there is an urgent need for a method that can simultaneously diagnose and analyze faults of multiple types of devices. Summary of the Invention
[0004] The purpose of the present invention is to provide a device fault diagnosis method based on a microservice architecture to solve the problems existing in the above-mentioned prior art.
[0005] To achieve the above purpose, the present invention provides a device fault diagnosis method based on a microservice architecture, including the following steps:
[0006] Construct an integrated service platform for receiving data and sending instructions and construct several fault diagnosis components, and connect the integrated service platform with the fault diagnosis components;
[0007] Receive the fault detection data sent by the user;
[0008] The integrated service platform determines the device type based on the fault detection data and sends the fault detection data to the fault diagnosis component corresponding to the device type;
[0009] The fault diagnosis component analyzes the fault detection data, obtains the analysis result and the repair plan, stores the fault detection data, the analysis result and the repair plan, and simultaneously sends the analysis result and the repair plan to the user;
[0010] The user feeds back the result to the integrated service platform, and the integrated service platform processes the feedback result.
[0011] Optionally, the process by which the integrated service platform determines the device type based on the fault detection data includes:
[0012] The integrated service platform parses the fault detection data it belongs to, obtains the identification information, parameter type, and dimension information of the fault detection data it belongs to. The dimension information includes multiple query dimensions, and based on an Internet query, information data with the same characteristics as the identification information and the parameter type is retrieved. If the same information data is retrieved, the device type to which the device belongs is determined through the same information data;
[0013] If the same information data cannot be retrieved through the identification information and the parameter type, multiple queries are performed through multiple dimensions of the dimension information, and the results after multiple queries are combined and compared with the fault information. If the similarity is greater than 80%, the device type is determined through the characteristics of the dimension.
[0014] Optionally, the process by which the integrated service platform sends the fault detection data to the fault diagnosis component includes:
[0015] The integrated service platform generates a service instruction based on the device type and sends the service instruction to a corresponding number of fault diagnosis components. The several components compete for the service instruction through generating threads, and the fault diagnosis component that obtains the service instruction performs the fault diagnosis process, and the threads of other components enter the standby state.
[0016] Optionally, each fault diagnosis component can perform at most two fault diagnosis processes simultaneously.
[0017] Optionally, if a fault diagnosis component corresponding to the device type is missing in the fault diagnosis components, the integrated service platform sends a connection request to the outside based on the Internet, obtains the component corresponding to the device type and makes a connection;
[0018] If several components corresponding to the device type are all performing two fault diagnosis processes, the integrated service platform sends a connection request to the outside based on the Internet, obtains the same type of components and makes a connection.
[0019] Optionally, the analysis result includes the fault location, fault cause, and fault time; the repair plan includes the repair method, repair tools, and repair duration.
[0020] Optionally, after the fault diagnosis component stores the fault detection data, if similar data to the stored fault detection data is received again, it directly outputs the analysis result and repair plan corresponding to the stored fault detection data; the similar data is data with a similarity greater than 90% to the fault detection data.
[0021] Optionally, the process of the integrated service platform processing the feedback result includes:
[0022] Judging and classifying the feedback result, and processing the fault diagnosis component according to the classification result.
[0023] Optionally, the process of processing the fault diagnosis component according to the classification result includes:
[0024] The classification result includes "repaired" and "not repaired". The integrated service platform records the feedback result and the corresponding fault diagnosis component. If the fault diagnosis component is recorded as "not repaired" continuously for 5 times, the connection with this fault diagnosis component is disconnected.
[0025] The technical effects of the present invention are:
[0026] Through the construction of the integrated service platform and the connection of the fault diagnosis component, and through the component connection function of the integrated service platform, the present invention realizes the effect of simultaneously diagnosing faults for different types of equipment, ensuring the equipment can resume operation in a short time, quickly and efficiently. And through the storage design of the fault diagnosis component, it can quickly obtain the analysis result and repair strategy for similar situations, greatly improving the service efficiency. At the same time, the performance design and elimination mechanism of the fault diagnosis component ensure the stability of the component and improve the quality of equipment fault diagnosis. Description of the Drawings
[0027] The drawings constituting a part of this application are used to provide a further understanding of this application. The schematic embodiments of this application and their descriptions are used to explain this application and do not constitute an improper limitation to this application. In the drawings:
[0028] Figure 1 It is a flowchart of the device fault diagnosis method based on the microservice architecture in the embodiment of the present invention. Detailed Embodiments
[0029] It should be noted that, without conflict, the embodiments in this application and the features in the embodiments can be combined with each other. The following will refer to the drawings and combine the embodiments to detail this application.
[0030] It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. And although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order than here.
[0031] Embodiment 1
[0032] As Figure 1 shown, in this embodiment, a device fault diagnosis method based on a microservice architecture is provided, including:
[0033] Construct an integrated service platform for receiving data and sending instructions and connect several fault diagnosis components;
[0034] Receive the fault detection data sent by the user;
[0035] The integrated service platform determines the device type based on the fault detection data and sends the fault detection data to the fault diagnosis component;
[0036] The fault diagnosis component analyzes based on the fault detection data, obtains the analysis result and the repair plan, stores the fault detection data, the analysis result, and the repair plan, and at the same time sends the analysis result and the repair plan to the user;
[0037] The user feeds back the result to the integrated service platform, and the integrated service platform processes the feedback result.
[0038] The integrated service platform may include a control module with upstream and downstream communication functions and a query and detection module based on big data technology. Among them, the control module is used to take over all the traffic entering and leaving the microservice program and implement the core service governance capabilities. For example, the core service governance capabilities may include several categories such as connection, control, observation, and feedback. The query and detection module is used to detect data similar to the fault data characteristics based on big data technology and judge the type of the faulty device based on this.
[0039] The integrated service platform detects feature data similar to the fault detection data based on big data technology and determines the device type based on the feature data. The specific process includes: the integrated service platform analyzes the fault data to obtain the identification information, parameter type, and dimension information of the fault data. The dimension information includes multiple query dimensions, and based on the Internet, it queries information data with the same characteristics as the identification information and parameter type. If the same information data is queried, the type to which the device belongs is determined through the same information data; if the same information data cannot be queried through the identification information and parameter type, multiple queries are performed through multiple dimensions of the dimension information, and the results after multiple queries are combined and compared with the fault information. If the similarity is greater than 80%, the device type is determined through the characteristics of the dimension.
[0040] The fault diagnosis component includes several components corresponding to the device type. To meet the different requirements for device fault diagnosis and analysis, different deployed microservices of fault detection components may all require data of a certain device type as data support. Therefore, in some embodiments of the present invention, the fault diagnosis components associated with the device data of each type can be one or more, and the microservices corresponding to the fault diagnosis components of each type can share the device characteristics of this type.
[0041] In the field of microservices, the interaction methods between devices and software are diverse. A large part of the protocols, such as MQTT, MTConnect, OPC-UA, etc., are transmitted in the form of broadcasts, and multiple microservice components can obtain the same data copy from the integrated service platform. In this case, to avoid repeated data acquisition, the integrated service platform needs to ensure that there is only one component responsible for the fault diagnosis process in the entire system at the same time. In a specific business scenario, which component executes the fault depends on the set system policies. The system policies mainly include judgment, load balancing, etc., and can be extended according to business needs.
[0042] In specific implementation, different fault detection components may be distributed on different devices. For example, some fault detection components can be deployed on devices in the local computer room, some can be deployed on devices in the remote computer room, and some can be deployed on cloud servers. In this way, it is necessary to register the service information of the managed components, such as the address and port number, to the integrated service platform, so that the integrated service platform can call the components according to the saved service information of each component to achieve business functions.
[0043] The integrated service platform sends a service instruction to several components corresponding to the device type. The several components compete for the service instruction, and the component that obtains the service instruction performs the fault diagnosis process. Each component can perform at most two fault diagnosis processes simultaneously.
[0044] After the integrated service platform generates a service instruction, several fault diagnosis components corresponding to the device type will all start a thread to compete for the service instruction. The fault diagnosis component that obtains the service instruction starts to receive fault data and performs the diagnosis process, and the corresponding threads of other fault diagnosis components will enter the standby state.
[0045] If a component corresponding to the device type is missing in the fault diagnosis component, the integrated service platform sends a connection request to the outside based on the Internet, obtains and connects to the component corresponding to the device type, and sends the fault diagnosis data to the newly connected component for the fault diagnosis process;
[0046] When several components corresponding to the device type are all in the process of two fault diagnosis processes, the integrated service platform sends a connection request to the outside based on the Internet, obtains components of the same type, and obtains and registers service information, so as to quickly complete business expansion.
[0047] The analysis results include the fault location, fault cause, and fault time; the repair plan includes the repair method, repair tool, and repair duration.
[0048] After the fault diagnosis component stores the fault detection data, if it receives similar data to the stored fault detection data again, it directly outputs the analysis result and repair plan corresponding to the stored fault detection data. The similar data is data with a similarity degree greater than 90% to the fault detection data.
[0049] Judge and classify the feedback results, and process the fault diagnosis components according to the classification results.
[0050] The classification results include "repaired" and "not repaired". The integrated service platform records the feedback results and the corresponding fault diagnosis components. If a fault diagnosis component is continuously recorded as "not repaired" 5 times, the service information of this component will be deleted and the connection with this fault diagnosis component will be disconnected.
[0051] As a preferred embodiment of the present application, several of the fault diagnosis components are automatically adjusted based on the multi-ant colony algorithm to achieve the optimization of fault diagnosis network resources:
[0052] If there are M fault diagnosis components representing n traffic flows in the microservice architecture looking for the best path, then, mark the M fault diagnosis components as A1, A2, A3,......, A m ; and for the fault diagnosis component k located at node r at time t, select the next node s to complete the visit, and the corresponding optimization probability is:
[0053]
[0054] Among them, represents the optimization probability on the path (r, s); C ik ={1, 2, 3,......, M - 1} represents the set of nodes that the fault diagnosis component k can select the next node; the nodes support different data transmissions between the networks formed. represents the pheromone concentration on the path (r, s); δ rs (t) represents the heuristic factor of the component group on the path (r, s); α (α≥0) represents the heuristic information; β (β≥0) represents the importance factor; represents the suppression factor of the pheromone of component Ai.
[0055] In this embodiment, by connecting the construction of the integrated service platform with the fault diagnosis component and through the component connection function of the integrated service platform, the effect of simultaneously diagnosing faults for different types of devices is achieved, ensuring the restoration of the device's operation in a short time, quickly and efficiently. And through the storage design of the fault diagnosis component, it can quickly obtain the analysis results and repair strategies for similar situations, greatly improving the service efficiency. At the same time, the performance design and elimination mechanism of the fault diagnosis component ensure the stability of the component and improve the quality of device fault diagnosis.
[0056] As described above, the above is only a preferred specific embodiment of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by those skilled in the art within the technical scope disclosed in the present application should be covered by the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
Claims
1. A device fault diagnosis method based on a microservices architecture, characterized in that, It includes the following steps: Construct an integrated service platform for receiving data and sending instructions, and construct several fault diagnosis components, where the integrated service platform is connected to the fault diagnosis components; Receive the fault detection data sent by the user; The integrated service platform determines the device type based on the fault detection data, and sends the fault detection data to the corresponding fault diagnosis component of the device type; The fault diagnosis component analyzes the fault detection data, obtains the analysis result and repair plan, stores the fault detection data, analysis result, and repair plan, and simultaneously sends the analysis result and repair plan to the user; The user feeds back the result to the integrated service platform, and the integrated service platform processes the feedback result.
2. The device fault diagnosis method based on the microservice architecture according to claim 1, characterized in that, The process by which the integrated service platform determines the device type based on the fault detection data includes: The integrated service platform parses the fault detection data it belongs to, obtains the identification information, parameter type, and dimension information of the fault detection data it belongs to. The dimension information includes multiple query dimensions, and based on the Internet, it queries information data with the same characteristics as the identification information and the parameter type. If the same information data is queried, the device type to which the device belongs is determined through the same information data; If the same information data cannot be queried through the identification information and the parameter type, multiple queries are performed through multiple dimensions of the dimension information, and the results after multiple queries are combined and compared with the fault information. If the similarity is greater than 80%, the device type is determined through the characteristics of the dimension.
3. The device fault diagnosis method based on a microservice architecture according to claim 1, characterized in that The process by which the integrated service platform sends the fault detection data to the fault diagnosis component includes: The integrated service platform generates a service instruction based on the device type and sends the service instruction to the corresponding several fault diagnosis components. The several components compete for the service instruction by generating threads, and the fault diagnosis component that obtains the service instruction performs the fault diagnosis process, and the threads of other components enter the standby state.
4. The device fault diagnosis method based on a microservice architecture according to claim 3, characterized in that, Each fault diagnosis component can perform at most two fault diagnosis processes simultaneously.
5. The device fault diagnosis method based on a microservice architecture according to claim 1, characterized in that If a fault diagnosis component corresponding to the device type is missing in the fault diagnosis components, the integrated service platform sends a connection request to the outside based on the Internet, obtains the component corresponding to the device type and makes a connection; If several components corresponding to the device type are all performing two fault diagnosis processes, the integrated service platform sends a connection request to the outside based on the Internet, obtains the components of the same type and makes a connection.
6. The device fault diagnosis method based on the microservice architecture according to claim 1, wherein The analysis result includes the fault location, fault cause, and fault time; the repair plan includes the repair method, repair tool, and repair duration.
7. The device fault diagnosis method based on the microservice architecture according to claim 1, characterized in that After the fault diagnosis component stores the fault detection data, if similar data to the stored fault detection data is received again, the analysis result and repair plan corresponding to the stored fault detection data are directly output; the similar data is data with a similarity greater than 90% to the fault detection data.
8. The device fault diagnosis method based on a microservice architecture according to claim 1, characterized in that The process by which the integrated service platform processes the feedback result includes: Judge and classify the feedback result, and process the fault diagnosis component according to the classification result.
9. The device fault diagnosis method based on a microservice architecture according to claim 8, characterized in that The process of processing the fault diagnosis component according to the classification result includes: The classification result includes "repaired" and "not repaired". The integrated service platform records the feedback result and the corresponding fault diagnosis component. If the fault diagnosis component is continuously recorded as "not repaired" for 5 times, the connection with the fault diagnosis component is disconnected.