RuleGo-based orchestrable CMDB data discovery method and system

By creating a custom RuleGo node in the CMDB data discovery method, centrally processing the data synchronization logic between the component and CMDB, the problems of high API call complexity and intuition of orchestration process in the prior art are solved, and low maintenance costs and high stability are achieved during component upgrades or API changes.

CN120144553APending Publication Date: 2025-06-13TONGFANG YOUYUN (BEIJING) TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510159708.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-13
Publication Date
2025-06-13

AI Technical Summary

Technical Problem

The existing CMDB data discovery methods have problems such as high API call complexity and intuition of orchestration process, which leads to large-scale system adjustments when facing component upgrades and replacements, which increases maintenance costs and learning difficulties.

Method used

By creating a custom RuleGo node, centrally processing the data synchronization logic between components and CMDB. All logic is concentrated in a custom RuleGo node. When Nacos upgrades or its API changes, you only need to modify the code in this custom RuleGo node, reducing maintenance costs.

Benefits of technology

It realizes that when component upgrades or API changes, the code of only a single custom RuleGo node needs to be modified, avoids large-scale system adjustments, reduces maintenance costs, and enhances system stability and reliability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120144553A_ABST
    Figure CN120144553A_ABST
Patent Text Reader

Abstract

The invention provides an orchestrable CMDB data discovery method and system based on RuleGo. The method comprises the following steps: creating a user-defined RuleGo node; compiling a rule script by using a domain specific language DSL provided by RuleGo, and defining an operation executed every time a specific condition is met; and a mapping mechanism is created and set, and configuration data structure fields in the Nacos are mapped and converted into formats suitable for being stored in the CMDB. According to the method, data synchronization between the customized RuleGo node processing component and the CMDB is created, all logics are concentrated in one RuleGo node, and when the Nacos is upgraded or the API of the Nacos is changed, only codes in the node need to be modified, so that the maintenance cost is reduced; even if incompatible changes are introduced into Nacos upgrading, the Nacos upgrading is limited in the self-defined RuleGo node, the CMDB or other system components are not affected, and the stability and reliability of the system are enhanced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data discovery, and in particular, to a RuleGo-orchestratable CMDB data discovery method and system. Background Art

[0002] Data discovery in CMDB refers to the process of automatically identifying and recording configuration items (such as hardware, software, network devices, etc.) and the relationships between them. This typically involves scanning networks, operating systems, applications, and other resources to collect the necessary information and update it in the CMDB. Effective data discovery can reduce manual input errors, ensure that the data in the CMDB is up-to-date, and reflect the actual state of the IT environment.

[0003] As a component orchestration rule engine, RuleGo allows users to define business logic rules to process and orchestrate data from different sources. In the context of CMDB, RuleGo can help achieve the following functions:

[0004] 1. Automated data collection: Trigger automated processes by defining rules to collect data from various sources (such as network scans, API calls, log files, etc.).

[0005] 2. Data validation and cleaning: Use predefined rules to validate the collected data to ensure it meets the expected format and quality standards. Duplicate or inaccurate data entries can also be cleaned up.

[0006] 3. Relationship mapping: Automatically establish relationships between configuration items according to established rules. For example, determine which server hosts which application, or which network devices are connected to a specific server.

[0007] 4. Change detection and synchronization: Continuously monitor changes in the IT environment and use rules to determine when and how to synchronize these changes to the CMDB.

[0008] Current existing CMDB data discovery methods usually rely on specific APIs provided by users and perform orchestration operations through components in the RuleGo interface, and finally store the processed data in a database or model. The configuration platform provides a set of basic data discovery functions for this purpose, and the data discovery process mainly includes the following specific steps:

[0009] 1. Design custom RuleGo nodes;

[0010] 2. Write initialization configurations into the nodes;

[0011] 3. Orchestrate and process the data through node orchestration;

[0012] 4. Assign the results to the corresponding model instances or databases;

[0013] However, the existing above-mentioned data discovery methods have the following disadvantages:

[0014] 1. High complexity of API calls: When it comes to complex API call logic, users need to deeply understand the API interface details, parameter configurations, and error handling mechanisms.

[0015] 2. The orchestration process is not intuitive enough: Although RuleGo provides a powerful rule engine to orchestrate data flows, for non-technical personnel, understanding and using these tools can be challenging, resulting in a steep learning curve and difficulty in mastering in the initial stage of learning. Summary of the Invention

[0016] In view of this, the purpose of the present invention is to develop an orchestratable CMDB data discovery method and system based on RuleGo. By creating custom RuleGo nodes to handle data synchronization between components and CMDB, all the logic is concentrated in a custom RuleGo node. When Nacos is upgraded or its API changes, only the code in this custom RuleGo node (single change point) needs to be modified, without the need to make large-scale adjustments to the entire system, reducing the maintenance cost; even if the Nacos upgrade introduces incompatible changes, the impact of these changes is limited within the custom RuleGo node and will not directly affect CMDB or other system components, enhancing the stability and reliability of the system.

[0017] The present invention provides an orchestratable CMDB data discovery method based on RuleGo, including the following steps:

[0018] S1. Create a custom RuleGo node;

[0019] Exemplarily, the code implementation of setting the custom RuleGo node node in json type is as follows:

[0020]

[0021] The configuration information is as follows:

[0022]

[0023] S2. Use the domain-specific language DSL provided by RuleGo to write rule scripts and define the operations to be executed whenever specific conditions are met;

[0024] S3. Create a setting mapping mechanism to map and convert the configuration data structure fields in Nacos into a format suitable for storage in CMDB.

[0025] Further, the method for creating a custom RuleGo node in step S1 includes the following steps:

[0026] S11. Set the json type of the custom RuleGo node node;

[0027] S12. Define the node component interface, implement the types.Node interface with the json type of the RuleGo node node, and define the node components deployed by the RuleGo node node;

[0028] Exemplarily, the code implementation for implementing the types.Node interface and defining the node components is as follows:

[0029]

[0030] S13. Register the node components to the registrar;

[0031] Exemplarily, the code implementation is as follows:

[0032]

[0033] S14. Set to listen for configuration changes from Nacos at regular intervals;

[0034] Nacos is a dynamic service discovery, configuration management, and service management platform open-sourced by Alibaba that is easier to build cloud-native applications. Nacos aims to help developers more easily build, deploy, and manage microservice architectures by simplifying service discovery and management, configuration storage and distribution, and service health monitoring.

[0035] S15. Process the received configuration changes according to preset rules;

[0036] S16. Interface with the CMDB API interface and write the processed configuration change data to the corresponding configuration item.

[0037] Since all the logic is concentrated in a custom RuleGo node, when Nacos is upgraded or its API changes, only the code in this RuleGo node needs to be modified. This RuleGo node is the single change point, and there is no need to make large-scale adjustments to the entire system, effectively reducing the maintenance cost.

[0038] Further, the method for processing the received configuration changes in step S15 includes:

[0039] The RuleGo node processes the input messages / events according to the rule chain definition, and drives the rule chain components through the rule chain orchestration engine to complete various services, including: message routing, message processing, message enhancement, message distribution, execution of actions, and linkage with third-party systems.

[0040] Specifically, the rule chain definition supports hot update and dynamically replaces the business logic of each component.

[0041] Further, the method for defining the operations to be performed whenever a specific condition is met in step S2 includes:

[0042] Whenever a new configuration is published or an existing configuration is updated in Nacos, the data synchronization process is triggered.

[0043] Further, the mapping mechanism in the creation of the setting mapping mechanism in step S3 includes:

[0044] Corresponding model id mapping;

[0045] One-to-one mapping between the output fields of the previous metadata and the model fields of CMDB.

[0046] Exemplarily, the code implementation of data conversion and mapping is as follows:

[0047]

[0048] The configuration information is as follows:

[0049]

[0050] The field information of Property is as follows:

[0051]

[0052] Further, the RuleGo node in the creation of the custom RuleGo node in step S1 implements the synchronization logic internally, and the synchronization logic includes:

[0053] Regularly pull the latest configuration from Nacos;

[0054] Convert data using the mapping mechanism;

[0055] Call the CMDB API interface to update or create the corresponding configuration item.

[0056] The present invention also provides a RuleGo-orchestratable CMDB data discovery system for implementing the RuleGo-orchestratable CMDB data discovery method as described above, including:

[0057] Create Node Module: Used to create custom RuleGo nodes;

[0058] Write Rule Script Module: Used to write rule scripts using the domain-specific language DSL provided by RuleGo, defining the actions to be executed whenever specific conditions are met;

[0059] Data Conversion and Mapping Module: Used to create and set up a mapping mechanism to map and convert the configuration data structure fields in Nacos into a format suitable for storage in CMDB.

[0060] In practical applications, the present invention creates custom RuleGo nodes to handle data synchronization between components and CMDB, which can bring the following multiple significant beneficial effects, especially the advantages are more prominent when facing component upgrades and replacements:

[0061] 1. Since all the logic is concentrated in a single custom RuleGo node, when Nacos is upgraded or its API changes, only the code in this single change point needs to be modified, rather than making large-scale adjustments to the entire system, reducing the maintenance cost;

[0062] 2. Operations such as data acquisition, parsing, conversion, and storage can be encapsulated in separate modules, facilitating independent development and testing, and also convenient for adding new functions or improving existing functions in the future, improving the flexibility and scalability of the system;

[0063] 3. Even if Nacos upgrades introduce incompatible changes, the impact of these changes is limited within the custom RuleGo node and will not directly affect CMDB or other system components, enhancing the stability and reliability of the system.

[0064] The present invention also provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the steps of the CMDB data discovery method based on RuleGo orchestration as described above are implemented.

[0065] The present invention also provides a computer device, the computer device includes a memory, a processor, and a computer program stored on the memory and executable on the processor, and when the processor executes the program, the steps of the CMDB data discovery method based on RuleGo orchestration as described above are implemented.

[0066] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0067] The RuleGo-orchestrated CMDB data discovery method and system provided by the present invention handle data synchronization between components and the CMDB by creating custom RuleGo nodes. All logic is centralized in a single custom RuleGo node. When Nacos is upgraded or its API changes, only the code in this node needs to be modified, without the need for large-scale adjustments to the entire system, reducing maintenance costs. Even if Nacos upgrades introduce incompatible changes, the impact of these changes is restricted within the custom RuleGo node and will not directly affect the CMDB or other system components. This advantage is particularly prominent when facing component upgrades and replacements, enhancing the stability and reliability of the system. Operations such as data acquisition, parsing, conversion, and storage can be encapsulated in separate modules, facilitating independent development and testing, and also making it convenient to add new functions or improve existing functions in the future, improving the flexibility and scalability of the system. BRIEF DESCRIPTION OF THE DRAWINGS

[0068] By reading the detailed description of the preferred embodiments below, various other advantages and benefits will become clear to those of ordinary skill in the art. The drawings are only for the purpose of showing the preferred embodiments and are not considered to be a limitation of the present invention.

[0069] In the drawings:

[0070] Figure 1 is a schematic diagram of the architecture for creating a custom RuleGo node according to an embodiment of the present invention;

[0071] Figure 2 is a flowchart for processing messages / events according to the rule chain definition in an embodiment of the present invention;

[0072] Figure 3 is a flowchart of the RuleGo-orchestrated CMDB data discovery method of the present invention;

[0073] Figure 4 is a flowchart of the method for creating a custom RuleGo node of the present invention;

[0074] Figure 5 is a schematic diagram of the composition of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

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

[0076] The terms used in this disclosure are for the purpose of describing particular embodiments only and are not intended to limit the disclosure. The singular forms "a", "the", and "said" used in this disclosure and the appended claims are also intended to include the plural forms unless the context clearly dictates otherwise. It should also be understood that the term "and / or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.

[0077] It should be understood that although the terms first, second, third, etc. may be used in this disclosure to describe various information, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from each other. For example, without departing from the scope of this disclosure, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the word "if" as used herein may be interpreted as "when" or "while" or "in response to determining".

[0078] The embodiments of the present invention will be further described in detail below.

[0079] The embodiments of the present invention provide a RuleGo-orchestratable CMDB data discovery method, as Figure 3 shown, including the following steps:

[0080] S1. Create a custom RuleGo node (as Figure 1 shown);

[0081] For the method of creating a custom RuleGo node, see Figure 4 shown, including the following steps:

[0082] S11. Set the json type of the custom RuleGo node node;

[0083] In this embodiment, the code implementation for setting the json type of the custom RuleGo node node is as follows:

[0084]

[0085] The configuration information is as follows:

[0086]

[0087] S12. Define the node component interface, implement the types.Node interface by the json type of the RuleGo node node, and define the node components deployed by the RuleGo node node;

[0088] In this embodiment, the code implementation for implementing the types.Node interface and defining the node components is as follows:

[0089]

[0090] S13. Register the node component to the registrar;

[0091] In this embodiment, the code implementation is as follows:

[0092]

[0093] S14. Set up a timed listener for configuration changes from Nacos;

[0094] S15. According to the preset rules, perform corresponding processing on the received configuration changes by listening;

[0095] The method for performing corresponding processing on the received configuration changes by listening includes:

[0096] The RuleGo node processes the input messages / events according to the rule chain definition, and drives the rule chain components to complete various services through the rule chain orchestration engine. The services include: message routing, message processing, message enhancement, message distribution, execution of actions, and linkage with third-party systems.

[0097] The rule chain definition supports hot update and dynamically replaces the business logic of each component.

[0098] The process of processing messages / events according to the rule chain definition is as Figure 2 shown.

[0099] S16. Connect to the CMDB API interface and write the processed configuration change data into the corresponding configuration item.

[0100] In this embodiment, since all the logics are concentrated in a custom RuleGo node, when Nacos is upgraded or its API changes, only the code in this RuleGo node (single change point) needs to be modified, instead of making large-scale adjustments to the entire system, reducing the maintenance cost.

[0101] S2. Use the domain-specific language DSL provided by RuleGo to write rule scripts and define the operations to be executed whenever specific conditions are met;

[0102] The method for defining the operations to be executed whenever specific conditions are met includes:

[0103] Whenever a new configuration is released in Nacos or an existing configuration is updated, the data synchronization process is triggered.

[0104] S3. Create a setting mapping mechanism to map and convert the configuration data structure fields in Nacos into a format suitable for storing in CMDB.

[0105] The mapping mechanism in creating the setting mapping mechanism includes:

[0106] The corresponding model id mapping;

[0107] One-to-one mapping between the output fields of the previous metadata Metadata and the model fields of CMDB.

[0108] In this embodiment, the code implementation of data conversion and mapping is as follows:

[0109]

[0110] The configuration information is as follows:

[0111]

[0112] The field information of Property is as follows:

[0113]

[0114] In the creation of the custom RuleGo node in the S1 step, the synchronization logic is implemented inside the RuleGo node, and the synchronization logic includes:

[0115] Regularly pull the latest configuration from Nacos;

[0116] Use the mapping mechanism to convert data;

[0117] Call the CMDB API interface to update or create the corresponding configuration item.

[0118] The embodiment of the present invention also provides a RuleGo-orchestrated CMDB data discovery system for implementing the RuleGo-orchestrated CMDB data discovery method as described above, including:

[0119] Create node module: used to create custom RuleGo nodes;

[0120] Write rule script module: used to write rule scripts using the domain-specific language DSL provided by RuleGo to define the operations to be executed whenever specific conditions are met;

[0121] Data conversion and mapping module: used to create a setting mapping mechanism to map and convert the configuration data structure fields in Nacos into a format suitable for storing in CMDB.

[0122] The RuleGo-orchestrated CMDB data discovery method and system according to this embodiment create custom RuleGo nodes to handle data synchronization between components and the CMDB. All the logic is concentrated in a custom RuleGo node. When Nacos is upgraded or its API changes, only the code in this node needs to be modified, without the need for large-scale adjustments to the entire system, reducing the maintenance cost. Even if incompatible changes are introduced during the Nacos upgrade, the impact of these changes is limited within the custom RuleGo node and will not directly affect the CMDB or other system components. Especially when facing component upgrades and replacements, the advantages are more prominent, enhancing the stability and reliability of the system.

[0123] An embodiment of the present invention further provides a computer device. Figure 5 FIG. is a schematic structural diagram of a computer device provided by an embodiment of the present invention; refer to the accompanying drawings Figure 5 As shown, the computer device includes: an input system 23, an output system 24, a memory 22, and a processor 21; the memory 22 is used to store one or more programs; when the one or more programs are executed by the one or more processors 21, the one or more processors 21 implement the RuleGo-orchestrated CMDB data discovery method provided in the above embodiment; wherein the input system 23, the output system 24, the memory 22, and the processor 21 can be connected through a bus or other means. Figure 5 Taking connection through a bus as an example.

[0124] The memory 22, as a readable and writable storage medium of a computing device, can be used to store software programs and computer-executable programs, such as program instructions corresponding to the RuleGo-orchestrated CMDB data discovery method described in the embodiment of the present invention; the memory 22 mainly includes a program storage area and a data storage area. Among them, the program storage area can store an operating system and application programs required for at least one function; the data storage area can store data created according to the use of the device, etc.; in addition, the memory 22 can include high-speed random access memory and can also include non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other non-volatile solid-state storage devices; in some instances, the memory 22 can further include a memory remotely set relative to the processor 21, and these remote memories can be connected to the device through a network. Examples of the above network include the Internet, an enterprise internal network, a local area network, a mobile communication network, and combinations thereof.

[0125] The input system 23 can be used to receive input digital or character information and generate key signal inputs related to the user settings and function control of the device; the output system 24 can include a display device such as a display screen.

[0126] The processor 21 executes various functional applications and data processing of the device by running software programs, instructions, and modules stored in the memory 22, that is, implements the above-mentioned RuleGo-orchestrated CMDB data discovery method.

[0127] The computer device provided above can be used to execute the RuleGo-orchestrated CMDB data discovery method provided in the above embodiment, and has corresponding functions and beneficial effects.

[0128] An embodiment of the present invention further provides a storage medium containing computer-executable instructions. The computer-executable instructions are used to execute the RuleGo-orchestrated CMDB data discovery method provided in the above embodiment when executed by a computer processor. The storage medium is any various types of memory devices or storage devices, including: installation media, such as CD-ROMs, floppy disks, or tape systems; computer system memories or random access memories, such as DRAM, DDRRAM, SRAM, EDO RAM, Rambus RAM, etc.; non-volatile memories, such as flash memories, magnetic media (such as hard disks or optical storage); registers or other similar types of memory elements, etc.; the storage medium may also include other types of memories or combinations thereof; in addition, the storage medium may be located in the first computer system in which the program is executed, or may be located in a different second computer system, and the second computer system is connected to the first computer system through a network (such as the Internet); the second computer system may provide program instructions to the first computer for execution. The storage medium includes two or more storage media that may reside in different locations (such as in different computer systems connected through a network). The storage medium can store program instructions executable by one or more processors (for example, specifically implemented as a computer program).

[0129] Of course, for a storage medium containing computer-executable instructions provided in an embodiment of the present invention, the computer-executable instructions are not limited to the RuleGo-orchestrated CMDB data discovery method described in the above embodiment, and can also execute related operations in the RuleGo-orchestrated CMDB data discovery method provided in any embodiment of the present invention.

[0130] So far, the technical solution of the present invention has been described in combination with the preferred embodiments. However, it is easy for those skilled in the art to understand that the protection scope of the present invention is obviously not limited to these specific embodiments. Without departing from the principle of the present invention, those skilled in the art can make equivalent changes or substitutions to the relevant technical features, and the technical solutions after these changes or substitutions will fall within the protection scope of the present invention.

[0131] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention; for those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included within the protection scope of the present invention.

Claims

1. A CMDB data discovery method based on RuleGo that can be programmed is characterized by: The following steps are involved: S1. Create a custom RuleGo node; S2. Use the domain-specific language DSL provided by RuleGo to write rule scripts and define the actions to be performed whenever specific conditions are met; S3. Create a settings mapping mechanism to convert the configuration data structure field mapping in Nacos into a format suitable for storage in CMDB.

2. The RuleGo-based CMDB data discovery method according to claim 1 is characterized in that: The method for creating a custom RuleGo node in step S1 includes the following steps: S11. Set the json type of the custom RuleGo node node; S12. Define the node component interface, implement the types.Node interface by the json type of the RuleGo node node, and define the node component deployed by the RuleGo node node; S13, registering the node component to the registrar; S14. Set up a timer to monitor configuration changes from Nacos; S15. According to preset rules, the configuration changes received through monitoring are processed accordingly; S16. Connect to the CMDB API interface and write the processed configuration change data into the corresponding configuration item.

3. The RuleGo-based CMDB data discovery method according to claim 2 is characterized in that: The method for correspondingly processing the configuration changes received through monitoring in step S15 includes: The RuleGo node processes the input message / event according to the rule chain definition, and drives the rule chain component through the rule chain orchestration engine to complete various services, including: message routing, message processing, message enhancement, message distribution, execution of actions, and linkage with third-party systems.

4. The RuleGo-based CMDB data discovery method according to claim 1 is characterized in that: The method of defining the operation to be performed whenever a specific condition is met in step S2 includes: Whenever a new configuration release or an existing configuration update is detected in Nacos, the data synchronization process is triggered.

5. The RuleGo-based CMDB data discovery method according to claim 1 is characterized in that: The mapping mechanism in the creation and setting mapping mechanism of step S3 includes: The corresponding model id mapping; The last metadata output fields are mapped one-to-one with the CMDB model fields.

6. The RuleGo-based CMDB data discovery method according to claim 5 is characterized in that: The RuleGo node in the step S1 of creating a custom RuleGo node implements synchronization logic internally, and the synchronization logic includes: Pull the latest configuration from Nacos regularly; transforming the data using the mapping mechanism; Call the CMDB API interface to update or create corresponding configuration items.

7. A CMDB data discovery system based on RuleGo programmable, used to implement the CMDB data discovery method based on RuleGo programmable as claimed in any one of claims 1 to 6, characterized in that: include: Create node module: used to create custom RuleGo nodes; Rule script writing module: used to write rule scripts using the domain-specific language DSL provided by RuleGo to define the actions to be performed whenever specific conditions are met; Data conversion and mapping module: used to create a setting mapping mechanism to convert the configuration data structure field mapping in Nacos into a format suitable for storage in CMDB.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the RuleGo-based CMDB data discovery method described in any one of claims 1 to 6 are implemented.

9. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the steps of the RuleGo-based CMDB data discovery method as described in any one of claims 1 to 6 are implemented.