A message bus system management method, device, equipment and storage medium

By determining the hierarchy and tree structure of the input characters, a complete command is generated, solving the problem of input errors in the command-line tool's message bus system and achieving efficient and accurate system management.

CN119376983BActive Publication Date: 2026-06-26INSPUR SUZHOU INTELLIGENT TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INSPUR SUZHOU INTELLIGENT TECH CO LTD
Filing Date
2024-10-31
Publication Date
2026-06-26

AI Technical Summary

Technical Problem

In existing technologies, when managing a message bus system through command-line tools, manual input errors are prone to occur, resulting in low management efficiency and inaccuracy, especially when running a large number of services on the system, which affects development and debugging efficiency.

Method used

The lowest level is determined by obtaining the format of the input characters. The matching level includes a parameter layer and a tree structure storage layer. The target parameters are extracted, and the input characters are completed to generate a complete command. The message bus system is managed using the tree structure hierarchy.

Benefits of technology

It improves the efficiency and accuracy of message bus system management, reduces input errors, and enhances operational efficiency and user experience. In particular, it significantly improves the efficiency and accuracy of D-Bus bus debugging and management in system management and server operations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119376983B_ABST
    Figure CN119376983B_ABST
Patent Text Reader

Abstract

The application discloses a message bus system management method and device, equipment and a storage medium, and relates to the technical field of computers. The method comprises the following steps: acquiring an input character, determining a lowest level corresponding to the input character according to the format of the input character, and taking the lowest level as a matching level; a tree structure is used for storing data of the message bus system; if the matching level is a storage layer of the tree structure, a target parameter is extracted from a parameter layer field in the input character according to the format of the input character; a parameter field represents a method function; if the matching level is a parameter layer, a matching parameter corresponding to the input character is determined, and the input character is completed based on the matching parameter to obtain the target parameter; a corresponding relationship between the method function and the tree structure level is inquired, and a target storage layer corresponding to the parameter field is determined; and based on the data of the target storage layer, the input character is filled to obtain a complete command, so that the message bus system is managed by using the complete command. The efficiency and accuracy of the message bus system management can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of computer technology, and in particular to a message bus system management method, apparatus, device, and storage medium. Background Technology

[0002] The message bus system (D-BUS) is used for communication between different processes on the same computer. It supports low-latency, low-overhead, and high-availability inter-process communication (IPC) mechanisms and supports object and method calls.

[0003] In related technologies, message bus systems are managed through command-line tools. These tools allow users to view services, interfaces, and object paths within the message bus system, as well as perform method calls and monitor signals. However, this requires manual input of precise commands into the command-line tool, such as the service, interface, and object paths to be invoked. Manual input is prone to errors and hinders effective management of the message bus system. Summary of the Invention

[0004] In view of this, the purpose of this invention is to provide a message bus system management method, apparatus, device, and storage medium, which can improve the efficiency and accuracy of message bus system management. The specific solution is as follows:

[0005] In a first aspect, this application discloses a message bus system management method, including:

[0006] The system acquires an input character and determines the lowest level corresponding to the input character based on its format, which is then used as the matching level. The matching level includes a parameter layer and various storage layers of the tree structure corresponding to the message bus system. The tree structure is used to store the data of the message bus system.

[0007] If the matching level is the storage layer of the tree structure, then the target parameter is extracted from the parameter layer field of the input character according to the format of the input character; the parameter field is used to represent the method function;

[0008] If the matching level is the parameter level, then the matching parameter corresponding to the input character is determined, and the input character is completed based on the matching parameter to obtain the target parameter;

[0009] By querying the correspondence between the method function and the tree structure level, the target storage layer corresponding to the target parameter is determined;

[0010] Based on the data in the target storage layer, the input characters are filled to obtain a complete command, which is then used to manage the message bus system.

[0011] Optionally, determining the lowest level corresponding to the input character based on the format of the input character includes:

[0012] The lowest level corresponding to the input character is determined based on the number of spaces contained in the input character; the input characters are separated into different levels by spaces, and the input characters are from the highest level to the lowest level.

[0013] Optionally, before filling the input characters with data based on the target storage layer to obtain the complete command, the method further includes:

[0014] Compare the matching level with the target storage layer;

[0015] If the matching level is higher than the target storage level, an alarm is generated;

[0016] If the matching level is lower than or equal to the target storage level, then the operation of filling the input characters with data based on the target storage level to obtain a complete command is performed.

[0017] Optionally, determining the matching parameters corresponding to the input character includes:

[0018] Disable case matching and obtain the matching parameters corresponding to the input character based on sample matching;

[0019] Enable case matching.

[0020] Optionally, the step of filling the input characters with data based on the target storage layer to obtain a complete command includes:

[0021] Retrieve the user-defined filter list; the filter list contains one or more filter items.

[0022] The data in the target storage layer is filtered using the filter list to obtain filtered data.

[0023] The filtered data is used to fill in the input characters to obtain a complete command.

[0024] Optionally, the message bus system management method further includes:

[0025] Retrieve historical query records and calculate the popularity values ​​of different query commands based on the historical query records;

[0026] Based on the popularity value, query commands that are less than a preset popularity threshold are selected as the filter items;

[0027] The filter list is generated based on all filter items.

[0028] Optionally, determining the matching parameters corresponding to the input character and completing the input character based on the matching parameters to obtain the target parameter includes:

[0029] Extract the portion of the input characters that belong to the parameter layer fields;

[0030] The partial characters are compared with standard parameters; the standard parameters are all types of parameters included in the parameter layer.

[0031] From all the aforementioned standard parameters, select the first target standard parameter that matches the partial characters;

[0032] Add the first target standard parameter to the association array;

[0033] Compare the aforementioned partial characters with the custom parameters; the custom parameters are parameter abbreviations preset for the standard parameters;

[0034] From all the custom parameters, filter out the target custom parameters that match the partial characters;

[0035] Query the mapping relationship between preset standard parameters and custom parameters to determine the second target standard parameter corresponding to the target custom parameter;

[0036] Add the second target standard parameter to the association array;

[0037] Based on the associative array, the matching parameters corresponding to the input character are obtained and displayed;

[0038] Based on the selection instruction for the target matching parameters, the partial characters are completed using the target matching parameters to obtain the target parameters.

[0039] Secondly, this application discloses a message bus system management device, comprising:

[0040] The matching level determination module is used to acquire input characters and determine the lowest level corresponding to the input characters based on the format of the input characters, which is used as the matching level; the matching level includes a parameter layer and each storage layer of the tree structure corresponding to the message bus system; the tree structure is used to store the data of the message bus system;

[0041] The target parameter extraction module is used to extract target parameters from the parameter layer field of the input characters according to the format of the input characters if the matching level is the storage layer of the tree structure; the parameter field is used to represent the method function.

[0042] The target parameter completion module is used to determine the matching parameters corresponding to the input character if the matching level is the parameter level, and complete the input character based on the matching parameters to obtain the target parameter;

[0043] The target storage layer determination module is used to determine the target storage layer corresponding to the target parameter by querying the correspondence between the query method function and the tree structure level;

[0044] The command filling module is used to fill the input characters with data from the target storage layer to obtain a complete command, so as to manage the message bus system using the complete command.

[0045] Thirdly, this application discloses an electronic device, including:

[0046] Memory, used to store computer programs;

[0047] A processor is used to execute the computer program to implement the aforementioned message bus system management method.

[0048] Fourthly, this application discloses a computer-readable storage medium for storing a computer program; wherein the computer program, when executed by a processor, implements the aforementioned message bus system management method.

[0049] In this application, input characters are obtained, and the lowest level corresponding to the input characters is determined according to the format of the input characters as the matching level. The matching level includes a parameter layer and various storage layers of the tree structure corresponding to the message bus system. The tree structure is used to store the data of the message bus system. If the matching level is the storage layer of the tree structure, the target parameter is extracted from the parameter layer field of the input characters according to the format of the input characters. The parameter field is used to represent the method function. If the matching level is the parameter layer, the matching parameter corresponding to the input characters is determined, and the input characters are completed based on the matching parameter to obtain the target parameter. The target storage layer corresponding to the target parameter is determined by querying the correspondence between the method function and the tree structure level. Based on the data of the target storage layer, the input characters are filled to obtain a complete command, so as to manage the message bus system using the complete command. Since the fields in the command are ordered hierarchically and the command needs to follow a specific format, the lowest level that the input characters can correspond to is determined as the matching level based on the format. If the matching level is the storage level of the message bus system, it indicates that the input characters already contain parameter layer fields, which represent method functions. In this case, the storage level corresponding to the method function of the parameter layer field is directly determined. If the matching level is the parameter layer, it indicates that the current input characters only reach the parameter layer, and the parameter layer input is incomplete. Therefore, it is necessary to complete the parameter layer fields to obtain the target parameter. The correspondence between method functions and tree structure levels is queried to determine the target storage layer corresponding to the target parameter. Based on the data in the target storage layer, the input characters are filled to obtain the complete command, which can then be used to manage the message bus system. Command completion improves the efficiency and accuracy of message bus system management, and direct querying of the message bus system's tree structure increases the speed of command completion. Attached Figure Description

[0050] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.

[0051] Figure 1 A flowchart of a message bus system management method provided in this application;

[0052] Figure 2 A flowchart of a specific parameter layer field completion method provided in this application;

[0053] Figure 3 A flowchart of a specific message bus system management method provided in this application;

[0054] Figure 4 A flowchart of a specific command completion method provided in this application;

[0055] Figure 5 This application provides a specific configuration file deployment structure diagram;

[0056] Figure 6 A schematic diagram of a message bus system management device is provided in this application;

[0057] Figure 7 This application provides a structural diagram of an electronic device. Detailed Implementation

[0058] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0059] In related technologies, message bus systems are managed using a command-line tool (busctl). This tool allows users to view services, interfaces, and object paths within the message bus system, as well as perform method calls and monitor signals. While busctl is a powerful command-line tool, it still has some drawbacks. For example, users must remember the exact names of services, interfaces, and object paths, and manual input may lead to errors. Furthermore, complex D-Bus messages and calls require correct combination of commands and parameters. Slow query speeds are also a problem, especially when the system is running a large number of services, which can affect development and debugging efficiency. To overcome these technical problems, this application proposes a message bus system management method that improves the efficiency and accuracy of message bus system management.

[0060] This application discloses a message bus system management method. See also Figure 1 As shown, the method may include the following steps:

[0061] Step S11: Obtain the input character, and determine the lowest level corresponding to the input character according to the format of the input character, which is used as the matching level; the matching level includes the parameter layer and each storage layer of the tree structure corresponding to the message bus system; the tree structure is used to store the data of the message bus system.

[0062] In this embodiment, the user input characters are first obtained. It's understood that the user should input a complete command, but due to the requirement for precise command input, and to avoid management failure due to input errors, this embodiment directly completes the current input content during the user's input process. Since the fields in the command are arranged hierarchically, the first is the command-line tool field (busctl) to call the tool, followed by the parameter layer (param), and then the various storage layers of the tree structure corresponding to the message bus system. The storage layers, in descending order, are: SERVICE, OBJECT, INTERFACE, METHOD, SIGNATURE, corresponding to levels 2 to 6, with the param layer being level 1. The data stored in memory by D-Bus is in a structured manner, specifically a tree structure. SERVICE contains multiple OBJECTs, OBJECTs contain multiple INTERFACEs, INTERFACEs contain multiple METHODs, and METHODs contain multiple SIGNATUREs.

[0063] The above-mentioned determination of the lowest level corresponding to the input character based on the format of the input character may include: determining the lowest level corresponding to the input character based on the number of spaces contained in the input character; the input characters are separated into different levels by spaces, and the input characters are from the highest level to the lowest level. It can be understood that a space is entered after each level of parameter in the input character, that is, spaces are used to separate parameters of different levels; for example, if the input character contains 2 spaces, then the current parameter level has been completed, that is, the current parameter level is 1; if the input character contains 3 spaces, then the current input has reached the SERVICE level, that is, the current parameter level is 2.

[0064] Furthermore, this application supports determining whether to enable the message bus system management proposed in this application based on user level. Specifically, before determining the lowest level corresponding to the input character based on its format, user information is obtained, and the user's permissions are determined based on this information. If the user has permissions, the operation of determining the lowest level corresponding to the input character based on its format is executed; otherwise, the original process is followed. This satisfies the needs of different users, allowing for customized function switches based on user level. Administrators can individually configure which users can enable or disable this intelligent auto-completion function, achieving a personalized user experience.

[0065] Step S12: If the matching level is the storage layer of the tree structure, then the target parameter is extracted from the parameter layer field of the input character according to the format of the input character; the parameter field is used to characterize the method function.

[0066] After determining the matching level, if the matching level is any storage layer in the tree structure of the message management system, it indicates that the user input characters contain parameter layer fields. Therefore, the parameter layer fields can be directly extracted from the second field of the input characters to obtain the target parameters. The target parameters are methods or functions such as tree and introspect.

[0067] Step S13: If the matching level is the parameter level, then determine the matching parameter corresponding to the input character, and complete the input character based on the matching parameter to obtain the target parameter.

[0068] If the matching level is the parameter level, it means that the current input has only reached the parameter level and the parameter level has not been completely entered. Therefore, it is necessary to first use matching to suggest the complete input of the parameter level, i.e. the matching input mentioned above, and then use the parameter level field of the currently input characters that is not fully matched to obtain the complete target parameters.

[0069] Specifically, determining the matching parameters corresponding to the input character and completing the input character based on the matching parameters to obtain the target parameter may include:

[0070] S201: Extract the portion of the input characters that belong to the parameter layer field.

[0071] For example, if the current input characters are "busctl tr", then part of the characters in the parameter layer field are "tr".

[0072] S202: Compare the partial characters with standard parameters; the standard parameters are all types of parameters contained in the parameter layer.

[0073] S203: From all the said standard parameters, select the first target standard parameter that matches the partial characters.

[0074] This means pre-storing multiple types of standard parameters, and selecting the closest standard parameter as the first target standard parameter by matching some characters with the standard parameters.

[0075] S204: Add the first target standard parameter to the association array.

[0076] Add the first target standard parameter to the associative array, which is used to store all parameters associated with the above partial characters.

[0077] S205: Compare the partial characters with the custom parameters; the custom parameters are parameter abbreviations preset for the standard parameters.

[0078] Understandably, to further simplify the complexity of user input, it is possible to support pre-defined parameter abbreviations, such as replacing parameters with the letter "A"; and to create a mapping relationship between standard parameters and parameter abbreviations.

[0079] S206: Filter out the target custom parameters that match the partial characters from all the custom parameters.

[0080] S207: Query the mapping relationship between preset standard parameters and custom parameters, and determine the second target standard parameter corresponding to the target custom parameter.

[0081] By matching partial characters with custom parameters, the target custom parameters that are the same as the partial characters are determined. Then, by looking up the pre-built mapping relationship, the standard parameters represented by the target custom parameters are determined as the second target standard parameters.

[0082] S208: Add the second target standard parameter to the association array.

[0083] For example Figure 2 As shown, the process first matches the standard parameters. Since all parameters are defined within the module, the array is directly traversed, and any parameter containing the input character is added to the associative list. Next, the personalized parameters are matched. Because a configuration file is loaded and its data is stored, the array is also directly traversed, and any parameter containing the input character is added to the associative list. Finally, if the currently entered character completely matches a personalized parameter, the user input is replaced, and the custom command is entered into the command line.

[0084] S209: Obtain the matching parameters corresponding to the input character based on the associative array, and display the matching parameters.

[0085] S210: Based on the selection instruction for the target matching parameter, the partial characters are completed using the target matching parameter to obtain the target parameter.

[0086] Understandably, if multiple matching parameters are selected, they can be displayed on the human-computer interaction interface, allowing the user to select the actual parameter needed and then use that target matching parameter to complete the characters to obtain the complete target parameter.

[0087] In some embodiments, commands can also be customized, allowing users to rename a long, complex string of message bus commands to shorter aliases. This involves comparing the input characters with a custom command abbreviation; the custom command abbreviation is a preset command abbreviation for message bus commands; from all the custom command abbreviations, a target command abbreviation matching the input characters is selected; the mapping relationship between message bus commands and command abbreviations is queried to determine the target message bus command corresponding to the target command abbreviation; and the message bus system is directly managed using the target message bus command. In other words, by customizing preset commands, users can rename a long, complex string of D-Bus commands to shorter aliases. The mapping relationship is stored in a configuration file as key-value pairs (i.e., a=b), so that when needed, only the alias needs to be entered to execute the original command, greatly simplifying the operation process.

[0088] In some embodiments, comparing the partial characters with standard parameters includes: comparing the partial characters with standard parameters based on inclusion matching rules; comparing the partial characters with custom parameters includes: comparing the partial characters with custom parameters based on inclusion matching rules. That is, to avoid omissions and improve matching flexibility, it is not limited to matching based on the first character, but adopts a more flexible inclusion matching strategy; that is, the user only needs to input partial keywords, and the system can quickly locate the matching items in the memory based on these keywords, such as inputting "busctl ll" which is automatically completed as "busctlcall", greatly improving the convenience of input.

[0089] In some embodiments, determining the matching parameters corresponding to the input character includes: disabling case matching and obtaining the matching parameters corresponding to the input character based on sample matching; and enabling case matching. For example... Figure 3 As shown, it is understandable that the case-sensitive mode is turned off before intelligent association, so that users do not need to remember the uppercase and lowercase of the matching characters to perform intelligent association; it is turned on after intelligent association to avoid problems with other functions that require case matching.

[0090] In some embodiments, before filling the input characters with data from the target storage layer to obtain a complete command, the method further includes: comparing the matching level with the target storage layer; if the matching level is higher than the target storage layer, generating an alarm; if the matching level is lower than or equal to the target storage layer, performing the operation of filling the input characters with data from the target storage layer to obtain a complete command. It is understood that if the matching level is higher than the target storage layer, it may indicate a problem with the user's input; in this case, generating an alarm and ending the process directly.

[0091] Step S14: Determine the target storage layer corresponding to the target parameter by querying the correspondence between the query method function and the tree structure level.

[0092] Understandably, different methods and functions correspond to different tree structure levels. For example, some methods and functions need to call the OBJECT layer, while others need to call the SIGNATURE layer, which is the lowest level. Therefore, a mapping between methods and functions and tree structure levels is pre-built. By querying this mapping, the target storage layer corresponding to the target parameter can be determined, i.e., which layer among SERVICE, OBJECT, INTERFACE, METHOD, and SIGNATURE. If the current match is layer 2, i.e., SERVICE, all data in the SERVICE layer will be accessed and recorded in memory, and the retrieved data will be populated into the command line.

[0093] This allows for precise determination of the corresponding parameter levels, providing accurate suggestions to users and greatly improving operational efficiency; and by directly accessing the data structure in the memory of the D-Bus bus, the query results are retrieved from its internal storage and returned, thus improving query speed.

[0094] Step S15: Based on the data of the target storage layer, fill in the input characters to obtain a complete command, so as to manage the message bus system using the complete command.

[0095] Finally, using data from the target storage layer, the input characters are filled to obtain a complete command, which is then used to manage the message bus system. If multiple commands are obtained, the user can be displayed to select the actual command needed, and then the selected command can be used to manage the message bus system. To address the diversity of commands, the system can intelligently identify the currently input parameter command and provide corresponding completion suggestions based on its characteristics, helping the user quickly complete the input.

[0096] For example Figure 4As shown, the process of filling the input characters with data from the target storage layer to obtain a complete command may include: obtaining a user-defined filter list; the filter list containing one or more filter items; filtering the data from the target storage layer using the filter list to obtain filtered data; and filling the input characters with the filtered data to obtain a complete command. The process of generating the filter list includes: obtaining historical query records and calculating the popularity values ​​of different query commands based on the historical query records; selecting query commands with popularity values ​​less than a preset popularity threshold as filter items; and generating the filter list based on all filter items. It is understandable that some commands have extremely low usage rates, so these commands are excluded, and the filtered data is used to fill the input. The system intelligently filters and selects the matching items that the user truly needs. For example, it automatically ignores system-level, non-application-related queries, focusing on the types most frequently used in daily user operations, ensuring that every association is accurate and efficient.

[0097] As can be seen from the above, in this embodiment, input characters are acquired, and the lowest level corresponding to the input characters is determined according to the format of the input characters, which is used as the matching level. The matching level includes a parameter layer and various storage layers of the tree structure corresponding to the message bus system. The tree structure is used to store the data of the message bus system. If the matching level is the storage layer of the tree structure, the target parameter is extracted from the parameter layer field of the input characters according to the format of the input characters. The parameter field is used to represent the method function. If the matching level is the parameter layer, the matching parameter corresponding to the input characters is determined, and the input characters are completed based on the matching parameter to obtain the target parameter. The target storage layer corresponding to the target parameter is determined by querying the correspondence between the method function and the tree structure level. Based on the data of the target storage layer, the input characters are filled to obtain a complete command, which is then used to manage the message bus system. As can be seen, the fields in the command are arranged in hierarchical order, and the command needs to follow a certain format. Therefore, by obtaining the input characters and determining the lowest level that the input characters can correspond to based on the format, the matching layer is established. If the matching layer is the storage layer of the message bus system, it indicates that the input characters already contain parameter layer fields, which represent method functions. In this case, the storage layer corresponding to the method function of the parameter layer field is directly determined. If the matching layer is the parameter layer, it indicates that the current input characters only reach the parameter layer, and the parameter layer input is incomplete. Therefore, it is necessary to complete the parameter layer fields to obtain the target parameter. The correspondence between the method function and the tree structure hierarchy is queried to determine the target storage layer corresponding to the target parameter. Based on the data in the target storage layer, the input characters are filled to obtain the complete command, which can then be used to manage the message bus system. Command completion improves the efficiency and accuracy of message bus system management, and by directly querying the tree structure of the message bus system, the speed of command completion is increased.

[0098] This method can be added to the system via a configuration file (.config), for example... Figure 5 As shown, when a user logs into the system, the system loads the current user's configuration files (.profile, .bashrc, .config), then starts a command-line shell and applies the current configuration to this shell, successfully logging in. Each user's configuration file is stored independently. This application uses the configuration file as a system-executed command; this method of injecting user configuration files is system-driven and does not depend on other modules. Because the method exists in the system as a user configuration, the persistent configuration files are also created in the user-level directory, easily enabling personalized configuration. Simultaneously, preset configuration files exist in the system's file system, allowing users to easily configure modules. When a module starts, it reads the corresponding configuration from this configuration file and implements the functionality based on the configuration during execution. The functionality supported by this application is a system-level application, independent of other external modules, making installation and uninstallation simpler; at the same time, it reduces unnecessary memory usage, making the system run more smoothly. It can significantly improve the user experience, especially in system administration and server operation; it can reduce input errors and command lookup time, enabling users to quickly enter correct commands and parameters; new users can more easily familiarize themselves with and master commands and options, improving the usability of command-line tools; intelligent predictive text helps users avoid input errors, ensuring the correctness of commands and parameters and reducing failures caused by spelling mistakes; by providing instant feedback, it helps users understand available command and parameter options, improving the intuitiveness and convenience of operation. It not only optimizes the user operation process but also improves the overall efficiency and reliability of system management. It helps developers or operations personnel better master and use the tool, significantly improving the efficiency and accuracy of D-Bus bus debugging and management in practical applications.

[0099] Accordingly, embodiments of this application also disclose a message bus system management device, see [link to relevant documentation]. Figure 6 As shown, the device includes:

[0100] The matching level determination module 11 is used to acquire input characters and determine the lowest level corresponding to the input characters according to the format of the input characters, which is used as the matching level; the matching level includes a parameter layer and each storage layer of the tree structure corresponding to the message bus system; the tree structure is used to store the data of the message bus system;

[0101] The target parameter extraction module 12 is used to extract target parameters from the parameter layer field of the input characters according to the format of the input characters if the matching level is the storage layer of the tree structure; the parameter field is used to represent the method function.

[0102] The target parameter completion module 13 is used to determine the matching parameter corresponding to the input character if the matching level is the parameter level, and complete the input character based on the matching parameter to obtain the target parameter;

[0103] The target storage layer determination module 14 is used to determine the target storage layer corresponding to the target parameter by querying the correspondence between the query method function and the tree structure level;

[0104] Command filling module 15 is used to fill the input characters based on the data of the target storage layer to obtain a complete command, so as to manage the message bus system using the complete command.

[0105] As can be seen from the above, in this embodiment, input characters are acquired, and the lowest level corresponding to the input characters is determined according to the format of the input characters, which is used as the matching level. The matching level includes a parameter layer and various storage layers of the tree structure corresponding to the message bus system. The tree structure is used to store the data of the message bus system. If the matching level is the storage layer of the tree structure, the target parameter is extracted from the parameter layer field of the input characters according to the format of the input characters. The parameter field is used to represent the method function. If the matching level is the parameter layer, the matching parameter corresponding to the input characters is determined, and the input characters are completed based on the matching parameter to obtain the target parameter. The target storage layer corresponding to the target parameter is determined by querying the correspondence between the method function and the tree structure level. Based on the data of the target storage layer, the input characters are filled to obtain a complete command, which is then used to manage the message bus system. As can be seen, the fields in the command are arranged in hierarchical order, and the command needs to follow a certain format. Therefore, by obtaining the input characters and determining the lowest level that the input characters can correspond to based on the format, the matching layer is established. If the matching layer is the storage layer of the message bus system, it indicates that the input characters already contain parameter layer fields, which represent method functions. In this case, the storage layer corresponding to the method function of the parameter layer field is directly determined. If the matching layer is the parameter layer, it indicates that the current input characters only reach the parameter layer, and the parameter layer input is incomplete. Therefore, it is necessary to complete the parameter layer fields to obtain the target parameter. The correspondence between the method function and the tree structure hierarchy is queried to determine the target storage layer corresponding to the target parameter. Based on the data in the target storage layer, the input characters are filled to obtain the complete command, which can then be used to manage the message bus system. Command completion improves the efficiency and accuracy of message bus system management, and by directly querying the tree structure of the message bus system, the speed of command completion is increased.

[0106] In some specific embodiments, the matching level determination module 11 may specifically include:

[0107] The matching level determination unit is used to determine the lowest level corresponding to the input character based on the number of spaces contained in the input character; the input characters are separated into different levels by spaces, and the input characters are from the highest level to the lowest level.

[0108] In some specific embodiments, the message bus system management device may specifically include:

[0109] A hierarchical comparison unit is used to compare the matching hierarchy with the target storage layer before filling the input characters with data based on the target storage layer to obtain a complete command.

[0110] The prompting unit is used to generate an alarm prompt if the matching level is higher than the target storage level;

[0111] An execution unit is configured to, if the matching level is lower than or equal to the target storage level, execute the operation of filling the input characters with data based on the target storage level to obtain a complete command.

[0112] In some specific embodiments, the target parameter completion module 13 may specifically include:

[0113] The function shutdown unit is used to disable the case matching function and obtain the matching parameters corresponding to the input character based on the sample matching.

[0114] The function enable unit is used to enable case matching.

[0115] In some specific embodiments, the command filling module 15 may specifically include:

[0116] A filter list acquisition unit is used to acquire a filter list set by the user; the filter list contains one or more filter items.

[0117] The filtering unit is used to filter the data of the target storage layer using the filtering list to obtain filtered data;

[0118] A filling unit is used to fill the input characters with the filtered data to obtain a complete command.

[0119] In some specific embodiments, the message bus system management device may further include:

[0120] The historical query record acquisition unit is used to acquire historical query records and to calculate the popularity value of different query commands based on the historical query records.

[0121] The filter item determination unit is used to filter out query commands that are less than a preset popularity threshold based on the popularity value, and use them as the filter items;

[0122] A filter list generation unit is used to generate the filter list based on all filter items.

[0123] In some specific embodiments, the target parameter completion module 13 may specifically include:

[0124] A character extraction unit is used to extract a portion of the input characters that belong to the parameter layer field;

[0125] The first comparison unit is used to compare the partial characters with standard parameters; the standard parameters are all types of parameters included in the parameter layer.

[0126] The first target standard parameter filtering unit is used to filter out the first target standard parameters that match the partial characters from all the standard parameters;

[0127] The first adding unit is used to add the first target standard parameter to the associative array;

[0128] The second comparison unit is used to compare the partial characters with the custom parameters; the custom parameters are parameter abbreviations preset for the standard parameters;

[0129] The target custom parameter filtering unit is used to filter out the target custom parameters that match the partial characters from all the custom parameters;

[0130] The second target standard parameter filtering unit is used to query the mapping relationship between preset standard parameters and custom parameters, and determine the second target standard parameter corresponding to the target custom parameter;

[0131] The second adding unit is used to add the second target standard parameter to the associative array;

[0132] A matching parameter determination unit is used to obtain the matching parameters corresponding to the input character based on the associative array, and to display the matching parameters;

[0133] The target parameter completion unit is used to complete the partial characters using the target matching parameters according to the selection instruction for the target matching parameters, so as to obtain the target parameters.

[0134] Furthermore, this application also discloses an electronic device, see [link to relevant documentation]. Figure 7 As shown, the content in the figure should not be considered as any limitation on the scope of use of this application.

[0135] Figure 7This is a schematic diagram of the structure of an electronic device 20 provided in an embodiment of this application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25, and a communication bus 26. The memory 22 stores a computer program, which is loaded and executed by the processor 21 to implement the relevant steps in the message bus system management method disclosed in any of the foregoing embodiments.

[0136] In this embodiment, the power supply 23 is used to provide operating voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and external devices, and the communication protocol it follows can be any communication protocol applicable to the technical solution of this application, and is not specifically limited here; the input / output interface 25 is used to acquire external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs, and is not specifically limited here.

[0137] In addition, the memory 22, as a carrier for resource storage, can be a read-only memory, random access memory, disk or optical disk, etc. The resources stored thereon include operating system 221, computer program 222 and data 223 including input characters, etc., and the storage method can be temporary storage or permanent storage.

[0138] The operating system 221 manages and controls the various hardware devices on the electronic device 20 and the computer program 222 to enable the processor 21 to perform calculations and processing on the massive amounts of data 223 in the memory 22. The operating system 221 can be Windows Server, Netware, Unix, Linux, etc. In addition to including a computer program capable of performing the message bus system management method executed by the electronic device 20 as disclosed in any of the foregoing embodiments, the computer program 222 may further include computer programs capable of performing other specific tasks.

[0139] Furthermore, this application also discloses a computer storage medium storing computer-executable instructions. When the computer-executable instructions are loaded and executed by a processor, they implement the message bus system management method steps disclosed in any of the foregoing embodiments.

[0140] Furthermore, this application also discloses a computer program product, which stores a computer program. When the computer program is loaded and executed by a processor, it implements the message bus system management method steps disclosed in any of the foregoing embodiments.

[0141] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the apparatus disclosed in the embodiments, since it corresponds to the method disclosed in the embodiments, the description is relatively simple; relevant parts can be referred to in the method section.

[0142] The steps of the methods or algorithms described in conjunction with the embodiments disclosed herein can be implemented directly by hardware, a software module executed by a processor, or a combination of both. The software module can be located in random access memory (RAM), main memory, read-only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or any other form of storage medium known in the art.

[0143] Finally, it should be noted that in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0144] The above provides a detailed description of a message bus system management method, apparatus, device, and storage medium provided by the present invention. Specific examples have been used to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only for the purpose of helping to understand the method and core ideas of the present invention. At the same time, for those skilled in the art, there will be changes in specific implementation methods and application scope based on the ideas of the present invention. Therefore, the content of this specification should not be construed as a limitation of the present invention.

Claims

1. A message bus system management method, characterized in that, include: Obtain the input character, and determine the lowest level corresponding to the input character based on the format of the input character, which is used as the matching level; The matching hierarchy includes a parameter layer and various storage layers of the tree structure corresponding to the message bus system; The tree structure is used to store data from the message bus system; If the matching level is the storage layer of the tree structure, then the target parameter is extracted from the parameter layer field of the input character according to the format of the input character; The parameter layer fields are used to characterize the method function; If the matching level is the parameter level, then the matching parameter corresponding to the input character is determined, and the input character is completed based on the matching parameter to obtain the target parameter; By querying the correspondence between the method function and the tree structure level, the target storage layer corresponding to the target parameter is determined; Based on the data in the target storage layer, the input characters are filled to obtain a complete command, which is then used to manage the message bus system. The step of determining the matching parameters corresponding to the input character and completing the input character based on the matching parameters to obtain the target parameter includes: Extract the portion of the input characters that belong to the parameter layer fields; The partial characters are compared with standard parameters; the standard parameters are all types of parameters included in the parameter layer. From all the aforementioned standard parameters, select the first target standard parameter that matches the partial characters; Add the first target standard parameter to the association array; Compare the aforementioned partial characters with the custom parameters; the custom parameters are parameter abbreviations preset for the standard parameters; From all the custom parameters, filter out the target custom parameters that match the partial characters; Query the mapping relationship between preset standard parameters and custom parameters to determine the second target standard parameter corresponding to the target custom parameter; Add the second target standard parameter to the association array; Based on the associative array, the matching parameters corresponding to the input character are obtained and displayed; Based on the selection instruction for the target matching parameters, the partial characters are completed using the target matching parameters to obtain the target parameters.

2. The message bus system management method according to claim 1, characterized in that, Determining the lowest level corresponding to the input character based on the format of the input character includes: The lowest level corresponding to the input character is determined based on the number of spaces contained in the input character; the input characters are separated into different levels by spaces, and the input characters are from the highest level to the lowest level.

3. The message bus system management method according to claim 1, characterized in that, Before filling the input characters with the data based on the target storage layer to obtain the complete command, the process further includes: Compare the matching level with the target storage layer; If the matching level is higher than the target storage level, an alarm is generated; If the matching level is lower than or equal to the target storage level, then the operation of filling the input characters with data based on the target storage level to obtain a complete command is performed.

4. The message bus system management method according to claim 1, characterized in that, Determining the matching parameters corresponding to the input character includes: Disable case matching and obtain the matching parameters corresponding to the input character based on sample matching; Enable case matching.

5. The message bus system management method according to claim 1, characterized in that, The process of filling the input characters with data from the target storage layer to obtain a complete command includes: Retrieve the user-defined filter list; the filter list contains one or more filter items. The data in the target storage layer is filtered using the filter list to obtain filtered data. The filtered data is used to fill in the input characters to obtain a complete command.

6. The message bus system management method according to claim 5, characterized in that, Also includes: Retrieve historical query records and calculate the popularity values ​​of different query commands based on the historical query records; Based on the popularity value, query commands that are less than a preset popularity threshold are selected as the filter items; The filter list is generated based on all filter items.

7. A message bus system management device, characterized in that, include: The matching level determination module is used to acquire input characters and determine the lowest level corresponding to the input characters based on the format of the input characters, which is then used as the matching level. The matching hierarchy includes a parameter layer and various storage layers of the tree structure corresponding to the message bus system; The tree structure is used to store data from the message bus system; The target parameter extraction module is used to extract the target parameter from the parameter layer field of the input character according to the format of the input character if the matching level is the storage layer of the tree structure. The parameter layer fields are used to characterize the method function; The target parameter completion module is used to determine the matching parameters corresponding to the input character if the matching level is the parameter level, and complete the input character based on the matching parameters to obtain the target parameter; The target storage layer determination module is used to determine the target storage layer corresponding to the target parameter by querying the correspondence between the query method function and the tree structure level; A command filling module is used to fill the input characters based on the data of the target storage layer to obtain a complete command, so as to manage the message bus system using the complete command; The target parameter completion module is used to extract a portion of the input characters that belong to a parameter layer field; compare the portion of the characters with standard parameters; the standard parameters are all types of parameters included in the parameter layer; select a first target standard parameter that matches the portion of the characters from all the standard parameters; add the first target standard parameter to an associative array; compare the portion of the characters with custom parameters; the custom parameters are parameter abbreviations preset for the standard parameters; select a target custom parameter that matches the portion of the characters from all the custom parameters; query the preset mapping relationship between standard parameters and custom parameters to determine a second target standard parameter corresponding to the target custom parameter; add the second target standard parameter to an associative array; obtain the matching parameter corresponding to the input characters based on the associative array and display the matching parameter; and complete the portion of the characters using the target matching parameter according to the selection instruction for the target matching parameter to obtain the target parameter.

8. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor for executing the computer program to implement the message bus system management method as described in any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that, Used to store computer programs; wherein the computer programs, when executed by a processor, implement the message bus system management method as described in any one of claims 1 to 6.