Module hot replacement processing method and system, electronic equipment and storage medium

Through automated dependency analysis and implementation of processing strategies, the problem of difficulty and insufficient stability of module hot replacement tools in complex front-end projects is solved, and efficient and intelligent dependency management and performance optimization are achieved.

CN119718391APending Publication Date: 2025-03-28GREE ELECTRIC APPLIANCE INC OF ZHUHAI +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411637257.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-15
Publication Date
2025-03-28

AI Technical Summary

Technical Problem

Existing module hot replacement tools have difficulty in managing dependency relationships and insufficient stability when dealing with complex front-end projects, resulting in version conflicts, configuration errors and performance degradation.

Method used

By obtaining the dependency data of the project, performing feature extraction and analysis, automatically identifying problems in the dependency, and implementing corresponding processing strategies, including version management, dependency chain optimization and performance improvement.

Benefits of technology

It realizes efficient and intelligent dependency management, reduces the time for manual debugging and problem solving, improves development efficiency and application stability, and avoids performance problems and application crash risks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119718391A_ABST
    Figure CN119718391A_ABST
Patent Text Reader

Abstract

The invention discloses a module hot replacement processing method and system, electronic equipment and a storage medium. The method comprises the following steps: obtaining dependency relationship data of a project; performing feature extraction on the dependency relationship data to convert the dependency relationship data into analyzable data, and analyzing the analyzable data to automatically determine problems existing in the current dependency relationship; executing a processing strategy corresponding to the question; and when the project is subjected to module hot replacement, executing a corresponding updating strategy according to the dependency relationship of the module, the size of the module, the complexity of the module and the load condition of the system. According to the method, efficient and intelligent dependency management is realized, the development efficiency is improved, errors and delay caused by dependency problems are remarkably reduced, smooth module hot replacement is ensured, a corresponding updating strategy is executed according to actual conditions to ensure that functions and performance of an application program are not influenced during updating, good performance and stability are kept, and the method is suitable for large-scale popularization and application. The problems of difficulty in dependency relationship management and insufficient stability of existing module hot replacement are solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data processing technology, and in particular to a processing method, system, electronic device and storage medium for hot replacement of modules. Background Art

[0002] In front-end development, Hot Module Replacement (HMR) is an important technology that allows developers to update application modules without refreshing the entire page. This technology is particularly useful in large single-page applications (SPA) and complex front-end projects, and can significantly improve development efficiency and user experience.

[0003] However, there are some challenges with current module hot replacement tools. First, in traditional front-end development, as the complexity of the project increases, the dependencies in the front-end project are usually very complex, including multiple modules and versions. The dependencies become difficult to manage, which easily leads to version conflicts and configuration errors. Developers need to spend a lot of time manually managing these dependencies. Secondly, there is a lack of intelligent mechanisms to automatically resolve dependency conflicts and version compatibility issues. Developers need to spend a lot of time manually debugging and solving problems, which limits the efficiency of the development team and the stability of the application. In addition, existing module hot replacement tools may encounter performance degradation and stability issues when dealing with large-scale projects, especially when hot module replacement is performed frequently.

[0004] With respect to the problems of difficulty in dependency management and insufficient stability in the existing module hot replacement technology, no effective solution has been proposed so far. Summary of the invention

[0005] The embodiments of the present invention provide a processing method, system, electronic device and storage medium for hot module replacement, so as to at least solve the problems of difficulty in dependency management and insufficient stability in hot module replacement in the prior art.

[0006] In order to solve the above technical problems, an embodiment of the present invention provides a processing method for hot replacement of a module, comprising:

[0007] Get the project's dependency data;

[0008] Extracting features from the dependency data to convert it into analyzable data, and analyzing the analyzable data to automatically determine problems existing in the current dependency;

[0009] Execute the processing strategy corresponding to the problem;

[0010] When hot replacement of modules is performed on the project, a corresponding update strategy is executed according to module dependencies, module sizes, module complexity, and system load conditions.

[0011] Optionally, get dependency data for the project, including:

[0012] By analyzing the project configuration file and the runtime dependency loading log, the library currently used by the project, the library version information and the library dependency are extracted;

[0013] The extracted data is preprocessed to obtain the dependency data, wherein the preprocessing at least includes: converting the extracted data into a unified data format, performing data cleaning to filter invalid data and redundant data and repairing incomplete or erroneous entries, reconstructing the dependency into a tree diagram, and converting data from different sources into a unified standard description.

[0014] Optionally, extracting features from the dependency data to convert them into analyzable data includes:

[0015] Perform feature extraction for each library in the dependency relationship data, the extracted features including at least: library name, version, dependency depth, number of direct dependencies, number of dependencies, update frequency, usage frequency, number of dependency paths, and dependency clustering coefficient;

[0016] For each library, the features of the library are converted into feature vectors, and the feature vectors are normalized to obtain the analyzable data.

[0017] Optionally, extracting features from the dependency data to convert it into analyzable data further includes: if the project records a change history of the dependency, extracting time series features, and converting the time series features into a feature matrix as part of the analyzable data.

[0018] Optionally, analyzing the analyzable data to automatically determine problems existing in the current dependency relationship includes:

[0019] Performing cluster analysis on the analyzable data using a clustering algorithm to discover anomalies in the current dependency relationship; and / or,

[0020] The analyzable data is analyzed using an association rule algorithm to discover potential associations between libraries.

[0021] Optionally, cluster analysis is performed on the analyzable data using a clustering algorithm, including:

[0022] clustering all libraries in the project based on the analyzable data using a clustering algorithm;

[0023] According to the clustering results, libraries with similar dependency depths, a dependency number greater than a preset number, and an update frequency greater than a preset frequency are determined as core libraries, and / or libraries with abnormal dependencies are determined.

[0024] Optionally, analyzing the analyzable data using an association rule algorithm includes:

[0025] Analyze the analyzable data using an association rule algorithm and preset rule parameters to determine a combination of libraries that are simultaneously dependent, a combination of library versions that often cause conflicts, and / or a combination of libraries that cause performance problems in project operation;

[0026] The preset rule parameters include: support, confidence and lift. The support is the frequency of a single library or a combination of libraries appearing in a dependency relationship. The confidence is the probability that when any library appears, the other library also appears. The lift is the correlation between the two libraries.

[0027] Optionally, executing a processing strategy corresponding to the problem includes:

[0028] To solve the problem of version conflicts, avoid using conflicting version combinations when building projects. If the new version causes incompatibility, roll back to the previous stable version. If different modules need to use different versions of the same library, isolate the conflicting versions and run them in different environments.

[0029] To address the problem of dependency chain depth, replace the indirect dependency library in the dependency chain with the direct dependency version to reduce the dependency chain depth, and / or extract the frequently-depended sub-dependencies independently to become direct dependency libraries;

[0030] To address performance issues, upgrade library versions and / or reduce interactions between libraries through caching.

[0031] To address the issue of redundant dependencies, remove libraries that are not called or whose functions have been replaced based on the frequency of library use, and / or use lightweight libraries to replace lengthy libraries.

[0032] Optionally, when hot-replacing modules of the project, a corresponding update strategy is executed according to module dependencies, module sizes, module complexity, and system load conditions, including:

[0033] If the number of modules having dependency relationships with the module to be updated is greater than a preset number, incremental update is performed to gradually replace various parts of the module to be updated;

[0034] If the system load is greater than the preset load, parallel update is performed;

[0035] If the module volume is larger than the preset volume or the structural complexity is greater than the preset complexity, the preloading mechanism is used to load the updated content into the cache in advance.

[0036] Optionally, the method further comprises: displaying at least one of a current dependency status, a current processing strategy and a real-time update progress.

[0037] Optionally, the method further includes: acquiring system indicators, wherein the system indicators include at least one of the following: conflict resolution rate, update success rate and user satisfaction; and optimizing the processing strategy and the update strategy according to the system indicators.

[0038] The embodiment of the present invention further provides a module hot replacement processing system, including:

[0039] Get module, used to get the dependency data of the project;

[0040] An analysis module, used for extracting features from the dependency data to convert it into analyzable data, and analyzing the analyzable data to automatically determine problems existing in the current dependency;

[0041] A processing module, used for executing a processing strategy corresponding to the problem;

[0042] The update module is used to execute corresponding update strategies according to module dependencies, module sizes, module complexity, and system load conditions when hot replacing modules in the project.

[0043] An embodiment of the present invention further provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method described in the embodiment of the present invention when executing the computer program.

[0044] The embodiment of the present invention further provides a non-volatile computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of the method described in the embodiment of the present invention are implemented.

[0045] By applying the technical solution of the present invention, the dependencies in the project are monitored and analyzed in real time, and the problems existing in the current dependencies, such as dependency conflicts, version incompatibility, etc., are automatically identified, and corresponding processing strategies are provided to automatically solve the problems, thereby realizing efficient and intelligent dependency management. Developers do not need to spend a lot of time manually debugging and solving problems, nor do they need to have an in-depth understanding of the complexity of each dependency. This can not only improve development efficiency and reduce configuration errors, but also significantly reduce errors and delays caused by dependency problems; and through the automatic identification and processing of dependencies, potential problems in dependencies are solved, thereby ensuring smooth module hot replacement. When performing module hot replacement, the corresponding update strategy is executed according to the actual situation to ensure that the function and performance of the application are not affected during the update, maintain good performance and stability, avoid performance problems and application crash risks that traditional tools may encounter when processing large-scale projects, improve system response speed and stability, realize performance optimization, and solve the problems of difficult dependency management and insufficient stability in module hot replacement in the prior art. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] Figure 1 is a flow chart of a processing method for hot replacement of modules provided by an embodiment of the present invention;

[0047] Figure 2 is a processing flow chart of module hot replacement provided by an embodiment of the present invention;

[0048] Figure 3 is a schematic diagram of dependency relationships provided by an embodiment of the present invention;

[0049] Figure 4 is a structural block diagram of a module hot replacement processing system provided by an embodiment of the present invention;

[0050] Figure 5 It is a schematic diagram of the hardware structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0051] In order to make the purpose, technical scheme and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0052] It should be noted that the terms "first", "second", etc. in the specification, claims and drawings of the present invention are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0053] It should be noted that the steps shown in the flowcharts of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and that, although a logical order is shown in the flowcharts, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0054] It should be understood that the term "and / or" used in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.

[0055] The optional embodiments of the present invention are described in detail below with reference to the accompanying drawings.

[0056] Example 1

[0057] This embodiment provides a processing method for hot replacement of a module. Figure 1 is a flow chart of a processing method for hot replacement of modules provided by an embodiment of the present invention, such as Figure 1 As shown, the method comprises the following steps:

[0058] S101, obtaining dependency data of the project.

[0059] S102, extracting features from the dependency data to convert them into analyzable data, and analyzing the analyzable data to automatically determine problems existing in the current dependency.

[0060] S103: Execute a processing strategy corresponding to the problem.

[0061] S104, when performing hot module replacement on the project, executing a corresponding update strategy according to module dependencies, module sizes, module complexity, and system load conditions.

[0062] This embodiment monitors and analyzes the dependencies in the project in real time, automatically identifies problems existing in the current dependencies, such as dependency conflicts, version incompatibility, etc., and provides corresponding processing strategies to automatically solve the problems, thereby realizing efficient and intelligent dependency management. Developers do not need to spend a lot of time manually debugging and solving problems, nor do they need to have an in-depth understanding of the complexity of each dependency. This can not only improve development efficiency and reduce configuration errors, but also significantly reduce errors and delays caused by dependency problems; and through the automatic identification and processing of dependencies, potential problems in dependencies are solved, thereby ensuring smooth module hot replacement. When performing module hot replacement, the corresponding update strategy is executed according to the actual situation to ensure that the function and performance of the application are not affected during the update, maintain good performance and stability, avoid performance problems and application crash risks that traditional tools may encounter when processing large-scale projects, improve system response speed and stability, realize performance optimization, and solve the problems of difficult dependency management and insufficient stability in module hot replacement in the prior art.

[0063] In one embodiment, obtaining dependency data of a project includes: extracting the libraries currently used by the project, library version information, and library dependencies by analyzing the project configuration file and the dependency loading log at runtime; preprocessing the extracted data to obtain the dependency data, wherein the preprocessing includes at least: converting the extracted data into a unified data format, performing data cleaning to filter invalid data and redundant data and repairing incomplete or erroneous entries, reconstructing dependencies into a tree diagram, and converting data from different sources into a unified standard description.

[0064] The dependency data of a project may come from different sources, such as package.json files, runtime dependency loading logs, etc. The formats of these data may not be uniform, so it is necessary to parse different data sources and convert them into a unified structured data format (such as JSON or database table), which will help the subsequent data cleaning and data standardization to proceed smoothly and ensure that subsequent analysis can be carried out based on a consistent and reliable data foundation.

[0065] Data cleaning mainly involves filtering out invalid and redundant data, and repairing incomplete or erroneous entries. For example, deleting duplicates: If the dependencies of the same library are recorded multiple times, only the latest or most relevant version is retained; handling empty or missing values: Some dependency information may lack version numbers or other important fields, and default values ​​will be used or data will be completed from other sources; handling outliers: If there are circular dependencies or unreasonable version numbers, they can be corrected through rules or manually.

[0066] When acquiring the dependency data of the project, this implementation method converts data from different sources into a unified data format and a unified standard description to achieve data standardization, ensuring that subsequent analysis can be performed based on a consistent and reliable data foundation; through data cleaning, it can ensure that the information is complete, accurate and avoids redundancy; the dependency relationship is reconstructed into a hierarchical tree diagram to ensure that all direct and indirect dependencies are correctly mapped, so as to facilitate the subsequent analysis of the dependency depth and dependency conflicts of the library.

[0067] In one embodiment, feature extraction is performed on the dependency data to convert it into analyzable data, including: feature extraction is performed on each library in the dependency data, the extracted features include at least: library name, version, dependency depth, number of direct dependencies, number of dependencies, update frequency, usage frequency, number of dependency paths and dependency clustering coefficient; for each library, the features of the library are converted into feature vectors, and the feature vectors are normalized to obtain the analyzable data.

[0068] Taking library a as an example, the number of direct dependencies refers to the number of other libraries that library a directly depends on, the number of dependencies refers to how many other libraries depend on library a, the update frequency refers to the number of times library a has been updated in the past period of time, the usage frequency refers to the frequency of library a being used in the project, the dependency depth refers to the longest path length from the root node (i.e. the project itself) to the library a node, the number of dependency paths refers to the number of all paths from the root node to the library a node, and the dependency clustering coefficient refers to the degree of association between its dependent objects in the dependency graph of library a, describing whether the libraries that library a depends on (i.e. neighboring nodes) are also dependent on each other. For example, there is a project that depends on library a, and library a depends on library b and library c. The dependency clustering coefficient of library a is to see whether library b and library c are also dependent on each other. If library b and library c are dependent on each other, the dependency clustering coefficient of library a is high. If library b and library c are not related, the dependency clustering coefficient of library a is low. The dependency clustering coefficient is used to evaluate the tightness of a library's dependency environment. A high clustering coefficient means that the dependency relationship is more complex and tight. When modifying or upgrading the library, you may need to consider its impact on multiple other dependent objects.

[0069] Among them, dependency depth, number of dependency paths, and dependency clustering coefficient can be considered as high-order features, based on which we can more comprehensively understand the complexity and potential risks of dependency relationships. The feature vector of each library can be represented as a multidimensional vector, where each dimension corresponds to a feature.

[0070] This implementation method extracts features and vectorizes dependency data to facilitate subsequent machine learning models or statistical analysis, and normalizes feature vectors to ensure that all features are on the same scale to avoid some eigenvalues ​​being too large or too small and affecting the analysis results.

[0071] Furthermore, extracting features from the dependency data to convert it into analyzable data also includes: if the project records a change history of the dependency, extracting time series features, and converting the time series features into a feature matrix as part of the analyzable data. For example, the feature matrix can reflect the version number changes of each library at different time points, the increase or decrease of dependencies, etc.

[0072] This implementation takes into account the change history of the dependency relationship, extracts time series features, and converts them into a feature matrix, which can facilitate the analysis of the evolution of the dependency relationship over time.

[0073] In one embodiment, the analyzable data is analyzed to automatically determine problems existing in the current dependency relationship, including: using a clustering algorithm to perform cluster analysis on the analyzable data to discover anomalies in the current dependency relationship; and / or, using an association rule algorithm to analyze the analyzable data to discover potential association relationships between libraries.

[0074] This embodiment can automatically determine the problems existing in the current dependency relationship more accurately and reliably through cluster analysis and / or association rule mining.

[0075] The following are explanations respectively.

[0076] (1) Cluster analysis

[0077] The analyzable data is clustered and analyzed using a clustering algorithm, including: clustering all libraries in the project according to the analyzable data using a clustering algorithm; according to the clustering results, determining libraries with similar dependency depths, a dependency number greater than a preset number, and an update frequency greater than a preset frequency as core libraries, and / or determining libraries with abnormal dependencies.

[0078] Among them, clustering algorithms can use K-means, DBSCAN (Density-Based Spatial Clustering of Applications with Noise), hierarchical clustering, etc. You can choose a suitable clustering algorithm according to the specific situation. For example, the K-means algorithm is suitable for discovering obvious dependency patterns, dividing libraries into several groups, and can identify which libraries have similar dependency patterns and may have the same problems; the DBSCAN algorithm is used to discover noise points (abnormal dependency libraries) in dependency relationships. These abnormal dependencies may cause version conflicts or performance problems.

[0079] Both the preset number and preset frequency can be set according to the actual situation. That is, libraries with similar dependency depth, large number of dependencies and high update frequency are grouped together as core libraries. If there are version conflicts or infrequent updates between these libraries, they may be potential bottlenecks.

[0080] Libraries marked as abnormal in the dependency relationship may be caused by a long dependency chain or a complex dependency relationship, so you can focus on troubleshooting.

[0081] This implementation can quickly and effectively identify core libraries and / or abnormal libraries based on a clustering algorithm to discover problems in dependencies.

[0082] (2) Association rule mining

[0083] Analyzing the analyzable data using an association rule algorithm includes: analyzing the analyzable data using an association rule algorithm and preset rule parameters to determine a combination of libraries that are simultaneously dependent, a combination of library versions that often cause conflicts, and / or a combination of libraries that cause performance problems in project operation; wherein the preset rule parameters include: support, confidence, and lift, wherein the support is the frequency with which a single library or a combination of libraries appears in a dependency relationship, the confidence is the probability that when any library appears, the other library also appears, and the lift is the correlation between the two libraries.

[0084] Association rule algorithms can use Apriori or FP-Growth, etc.

[0085] This implementation can quickly and effectively determine simultaneously dependent library combinations, library version combinations that often cause conflicts, and / or library combinations that cause performance problems in project operations based on an association rule algorithm, so as to discover potential problems in dependency relationships.

[0086] In one embodiment, executing a processing strategy corresponding to the problem includes:

[0087] To solve the problem of version conflicts, avoid using conflicting version combinations when building projects. If the new version causes incompatibility, roll back to the previous stable version. If different modules need to use different versions of the same library, isolate the conflicting versions and run them in different environments.

[0088] To address the problem of dependency chain depth, replace the indirect dependency library in the dependency chain with the direct dependency version to reduce the dependency chain depth, and / or extract the frequently-depended sub-dependencies independently to become direct dependency libraries;

[0089] To address performance issues, upgrade library versions and / or reduce interactions between libraries through caching.

[0090] To address the issue of redundant dependencies, remove libraries that are not called or whose functions have been replaced based on the frequency of library use, and / or use lightweight libraries to replace lengthy libraries.

[0091] This implementation provides corresponding processing strategies to achieve optimization for specific problems existing in dependency relationships.

[0092] In one embodiment, when hot replacement of modules is performed on the project, a corresponding update strategy is executed according to module dependencies, module sizes, module complexity, and system load conditions, including:

[0093] If the number of modules having dependency relationships with the module to be updated is greater than a preset number, incremental update is performed to gradually replace various parts of the module to be updated;

[0094] If the system load is greater than the preset load, parallel update is performed;

[0095] If the module volume is larger than the preset volume or the structural complexity is greater than the preset complexity, the preloading mechanism is used to load the updated content into the cache in advance.

[0096] This implementation method implements corresponding update strategies for different actual situations, minimizes possible system interruptions and performance impacts during the update process, prioritizes user experience and system stability, and ensures the smoothness and controllability of the update operation. For situations where the module to be updated has many dependencies with other modules, priority is given to incremental updates to gradually replace various parts of the module to ensure the compatibility of dependencies and avoid sudden interruptions of the entire system; for high-load situations, parallel updates are performed to distribute the update process to different threads or nodes to reduce the pressure on a single server and ensure that the system can maintain stable operation while processing updates; for modules with large size or complex structure, the preloading mechanism can load the update content into the memory or cache in advance to reduce the delay during formal replacement; for small or highly independent modules, simple parallel updates can be used to achieve rapid replacement.

[0097] This embodiment also provides a user interface and a visualization tool for displaying at least one of the current dependency status, the current processing strategy, and the real-time update progress, so that developers can quickly understand the improvements recommended by the system and the impact after the operation, and can make decisions and operations quickly, thereby improving development efficiency and quality. Moreover, through the visual interface, developers can intuitively manage and adjust dependencies without having to deeply understand the complexity of each dependency, thereby reducing configuration errors.

[0098] In one embodiment, the method further includes: obtaining system indicators, wherein the system indicators include at least one of the following: conflict resolution rate, update success rate and user satisfaction; and optimizing the processing strategy and the update strategy according to the system indicators.

[0099] This implementation method performs iterative optimization of strategies based on monitoring results and user feedback, thereby being able to adapt to changing project requirements and emerging problems.

[0100] Example 2

[0101] The following is a description of the processing method for hot replacement of the above module in conjunction with a specific embodiment. However, it is worth noting that this specific embodiment is only for better illustrating the present application and does not constitute an improper limitation on the present application. The explanation of terms that are the same or corresponding to the above embodiment will not be repeated in this embodiment.

[0102] like Figure 2 As shown, it is a processing flow chart of module hot replacement, which includes the following steps:

[0103] S201, start.

[0104] S202, data acquisition.

[0105] Collect the dependency data of the front-end project and perform preprocessing. The preprocessing includes at least: unified data format, data cleaning, reconstruction of tree diagram, and unified standard description.

[0106] In front-end projects, package.json files are often used to manage dependencies. For example, a project depends on the Vue framework (Vue is a JavaScript framework for building user interfaces) and multiple other libraries, such as Axios (for processing HTTP requests) and Lodash (for providing utility functions). In this step, the system will analyze the package.json file and read the dependent libraries and their version numbers listed in it, for example: vue version 3.0.0, axios version 0.21.1, lodash version 4.17.21.

[0107] Considering that the library version may be expressed in different ways, such as "^1.0.0", "~2.1.0", "latest", etc., these version numbers need to be converted into clear semantic version numbers (such as 1.0.0 or 2.1.0, etc.) to achieve version standardization for subsequent version comparison and conflict detection.

[0108] Convert the extracted data into a unified structured data format (such as JSON or a database table) as follows:

[0109]

[0110] During the data cleaning process, invalid and redundant data are filtered out, and incomplete or incorrect entries are repaired. For example, if the dependencies of the same library are recorded multiple times, only the latest or most relevant version is retained, that is, duplicates are deleted; some dependency information may lack version numbers or other important fields, and default values ​​are used or data is supplemented from other sources to handle null or missing values; for abnormal dependencies, such as circular dependencies or unreasonable version numbers, they are corrected through rules or manual corrections. Data cleaning ensures that the dependency information in the data is complete and accurate.

[0111] In some cases, a library may depend on other libraries, forming a multi-layer dependency chain. These multi-layer dependencies are parsed into a tree structure to ensure that all direct and indirect dependencies are correctly mapped. For example, React depends on scheduler and react-dom, and Axios may depend on follow-redirects. These dependencies are reconstructed into a hierarchical tree diagram to facilitate subsequent analysis of the library's dependency depth and dependency conflicts.

[0112] During the data standardization process, dependency data from different sources (such as from npm, yarn, or runtime loading logs) are converted into a unified standard dependency description, which ensures that subsequent analysis and comparison are performed on a unified basis.

[0113] S203, feature extraction.

[0114] Perform feature extraction on the dependency data to convert it into an analyzable form. The extracted features may include:

[0115] Library name: the name of the dependent library;

[0116] Version number: the specific version of the library;

[0117] Direct dependency count: the number of other libraries that the library directly depends on;

[0118] Dependency count: how many other libraries depend on this library;

[0119] Update frequency: the number of times the library has been updated in the past period of time;

[0120] Frequency of use: How often the library is used in a project, which can be measured by the number of times it is referenced in the project code.

[0121] For example, a dependency is characterized as:

[0122]

[0123] You can also build higher-order features that can help you more fully understand the complexity and potential risks of dependencies, such as dependency depth (also known as dependency hierarchy), number of dependency paths, and dependency clustering coefficient. Other features related to performance and stability may also need to be extracted based on specific needs.

[0124] Dependency depth refers to the longest path length from the project root node to a dependency library node in the project's dependency tree. This concept is used to measure the "distance" of a dependency relative to the project, that is, how many layers of other dependency libraries are needed to finally depend on the library. For example, the project's dependencies are: Project A depends on library B and library C, library B depends on library D, library D depends on library E, and library C directly depends on library F, which can be represented by a dependency graph as follows: Figure 3 As shown in the figure, the dependency depth of library B is 1, the dependency depth of library D is 2, the dependency depth of library E is 3, and the dependency depth of library F is 2. The number of dependency paths refers to the number of all paths from the root node to a library node. The dependency clustering coefficient refers to the degree of association between the libraries that a library depends on.

[0125] The extracted features are vectorized and converted into feature vectors for subsequent machine learning models or statistical analysis. The feature vector of each library can be represented as a multidimensional vector, where each dimension corresponds to a feature. For example, the feature vector is represented as: library_features = [version, depth, direct_dependencies, dependent_libraries, update_frequency, usage_frequency], for example: react_vector = [17.0.2, 5, 100, 12, 50]. The feature vectors are normalized to ensure that all features are on the same scale to avoid some feature values ​​being too large or too small to affect the analysis results.

[0126] In addition, if the change history of dependencies is recorded in the project, time series features can also be extracted, such as the version number changes of each library at different time points, the increase or decrease of dependencies, etc. The time series data is converted into a feature matrix to analyze the evolution of dependencies over time.

[0127] S204, intelligent analysis.

[0128] Analyze data through cluster analysis and association rule mining using machine learning algorithms to identify patterns and potential problems in dependencies, such as version conflicts and performance bottlenecks.

[0129] (1) Cluster analysis

[0130] Clustering algorithms can discover patterns or anomalies in dependency relationships. Common clustering algorithms include K-means, DBSCAN, hierarchical clustering, etc. The K-means algorithm is suitable for discovering obvious dependency patterns. Dividing libraries into several groups can help identify which libraries have similar dependency patterns and may have the same problems. The DBSCAN algorithm is used to discover noise points (abnormal dependency libraries) in dependency relationships. These abnormal dependencies may cause version conflicts or performance issues.

[0131] The steps of cluster analysis are as follows:

[0132] 1) Determine clustering features: Clustering is performed based on the extracted feature vectors (such as dependency depth, update frequency, dependency number, etc.). Select appropriate feature subsets, such as dependency depth, dependency number, and usage frequency.

[0133] 2) Execute clustering algorithm: Cluster all dependent libraries in the project. For example, group libraries with similar dependency depth, high update frequency and large number of dependencies into one category. These libraries may be common "core dependencies".

[0134] 3) Analyze clustering results: The clustering results may include: libraries in the same category may be core libraries that are frequently relied on. If there are version conflicts or infrequent updates between these libraries, they may be potential bottlenecks; outliers (noise points), that is, libraries marked as abnormal in the dependency relationship, may be caused by a too long dependency chain or too complex dependency relationship, and can be checked in detail.

[0135] (2) Association rule mining

[0136] Association rule mining is used to discover potential associations between dependent libraries, such as which libraries often appear together and which versions of libraries may cause conflicts. Commonly used association rule algorithms include Apriori and FP-Growth.

[0137] The steps of association rule mining are as follows:

[0138] 1) Define the mining object

[0139] Co-occurrence pattern of libraries: Analyze the combination of libraries introduced at the same time in the project to find out which libraries often appear together. For example, if library A and library B are always depended on together, analyze whether there is a conflict between their versions.

[0140] Version conflict mode: Analyze which specific versions of libraries conflict with specific versions of other libraries in the dependencies of multiple projects. For example, a version of library A and a version of library B often appear in the dependency tree that causes conflicts.

[0141] Performance bottleneck mode: Find out which combinations of libraries cause performance problems when the project is running. For example, when certain libraries are combined together, the dependency chain is too long or the interaction between libraries is inefficient.

[0142] 2) Perform association rule mining

[0143] First, define the rule parameters: support (i.e., define the frequency of a certain library or library combination appearing in the project dependency), confidence (i.e., the probability that another library will also appear when a certain library appears), and lift (measure the correlation between two libraries). Next, determine the algorithm to be used, such as Apriori or FP-Growth algorithm, to find frequent patterns in project dependencies, for example, find patterns like "library A version X and library B version Y combination always cause conflicts."

[0144] 3) Rule Analysis

[0145] Conflict rules: Identify which library version combinations often cause conflicts, and generate "risk rules" to provide reference for subsequent optimization. For example, if it is automatically detected that a specific version combination of library A and library B often causes conflicts, you can avoid using these version combinations when building the project.

[0146] Performance bottleneck rule: Find out the library combination that causes performance problems. For example, if some libraries combined together will cause the dependency chain to be too long, you can adjust the dependencies or update the library version to reduce the dependency chain depth when optimizing the project.

[0147] S205, Decision-making and Optimization.

[0148] Based on the results of data analysis, intelligent processing strategies are given for optimization. The decision-making process takes into account project requirements, library stability assessment, and feedback on known issues to ensure the reliability and effectiveness of the decision.

[0149] After the system performs data analysis, it provides processing strategies for specific problems in dependencies, as follows:

[0150] (1) Version conflict: Incompatibility between multiple library versions may cause compilation failure or runtime errors. A common manifestation is that the version update of a library causes it to be incompatible with other dependencies.

[0151] The processing strategy is as follows:

[0152] A. Version rollback: If the new version of the dependent library causes incompatibility issues, the system will suggest rolling back to the previous stable version until the compatibility issue is resolved.

[0153] B. Multi-version isolation: When different modules need to use different versions of the same library, it is recommended to use containerization or modularization strategies to isolate conflicting versions and run them in different environments.

[0154] (2) Dependency chains are too long: A dependency chain that is too long means that some of the dependent libraries in the project are indirectly dependent on other libraries at multiple levels, which may cause performance problems or increase maintenance complexity. Each additional level of dependency increases the risk of errors and affects performance.

[0155] The processing strategy is as follows:

[0156] A. Reduce the depth of the dependency chain: It is recommended to replace some indirect dependency libraries in the dependency chain and use direct dependency versions to reduce the level of intermediate libraries.

[0157] B. Library merging optimization: If multiple libraries frequently depend on the same sub-dependencies, the system can recommend extracting these sub-dependencies independently and making them direct dependency libraries, thereby reducing the dependency chain level.

[0158] (3) Performance bottleneck: Some libraries or library combinations exhibit performance issues at runtime, which may be due to unreasonable library combinations, redundant dependencies, or high resource consumption of certain libraries. Frequent interactions between libraries, inefficient algorithms, or outdated dependency libraries may all lead to performance degradation.

[0159] The processing strategy is as follows:

[0160] A. Library version upgrade: It is recommended to upgrade to the latest, performance-optimized library version to reduce resource usage and improve operating efficiency.

[0161] B. Cache optimization: For libraries that rely on frequent calls, it is recommended to use caching technology to reduce unnecessary interactions between libraries, thereby improving overall system performance.

[0162] (4) Redundant dependencies: There are unnecessary dependent libraries in the project, which may be due to the introduction of useless libraries during the development process, or some functional libraries are no longer needed in the current version of the project. These redundant dependencies will increase the complexity of the project, increase the build time, and occupy unnecessary resources.

[0163] The processing strategy is as follows:

[0164] A. Dependency cleanup: The system analyzes the usage frequency of project dependencies and recommends deleting dependent libraries that are not called or whose functions have been replaced to reduce project complexity.

[0165] B. Lightweight library replacement: It is recommended to replace some lengthy and bulky libraries with lighter alternatives to reduce the size of project build and deployment.

[0166] S206, hot replacement of modules.

[0167] When developers perform hot module replacement, the system instantly applies optimized update strategies to minimize system interruptions and performance impacts that may occur during the update process. Update strategies include: parallelized updates, incremental updates, and preloading mechanisms.

[0168] Module dependencies: If the updated module has many dependencies with other modules, give priority to incremental updates to gradually replace parts of the module to ensure the compatibility of dependencies and avoid sudden interruptions of the entire system.

[0169] System load and resource status: In high-load scenarios, parallel updates are more applicable. By distributing the update process to different threads or nodes, the pressure on a single server is reduced, ensuring that the system can maintain stable operation while processing updates.

[0170] Module size and complexity: For modules that are large or complex, the preloading mechanism can load the updated content into memory or cache in advance to reduce the delay when formally replacing it. Small or independent modules can be replaced quickly by simple parallel updates.

[0171] By parallelizing updates, the system can handle update tasks for multiple modules at the same time, speeding up the overall update speed. Incremental updates help load and apply only the changed parts without completely replacing the modules, thereby reducing the demand and impact of the update process on system resources. The preloading mechanism can load some resources in advance before the update to ensure that the system is immediately available after the update. When selecting and implementing these optimization algorithms, the system always prioritizes user experience and system stability to ensure the smoothness and controllability of the update operation.

[0172] S207, user interface interaction.

[0173] To simplify the operations of developers, the system provides an intuitive user interface and interactive design. The interface can display the current dependency status, recommended optimization solutions, and real-time update progress, allowing developers to quickly understand the improvements recommended by the system and the impact of operations. Through visualization tools, developers can make decisions and operations quickly, improving development efficiency and quality.

[0174] After the system is deployed, continuous monitoring and feedback loops are key to ensure continuous optimization of the system. Monitor system performance indicators such as conflict resolution rate, update success rate, and user satisfaction, collect real-time feedback and analyze it. Based on monitoring results and user feedback, the system iterates and optimizes algorithms and strategies to adapt to changing project requirements and emerging problems.

[0175] S208, end.

[0176] This embodiment introduces machine learning and data analysis technology to monitor and analyze dependencies in the project in real time, automatically identify and resolve potential dependency conflicts and version compatibility issues, and provide intelligent solutions, significantly reducing the workload of manual dependency management and realizing intelligent dependency analysis and optimization.

[0177] This embodiment optimizes the algorithm and process of module hot replacement, improves the system response speed and stability, ensures that the function and performance of the application are not affected when updating the module, realizes real-time performance optimization and ensures stability, ensures that the system can maintain good performance and stability when performing module hot replacement, and avoids performance problems and application crash risks that traditional tools may encounter when processing large-scale projects.

[0178] This embodiment provides an intuitive user interface and visual tools, allowing developers to easily manage and adjust dependencies without having to deeply understand the complexity of each dependency, reducing the risk of configuration errors and improving development efficiency and product quality.

[0179] This embodiment can achieve efficient intelligent dependency management and module hot replacement optimization, which can not only improve development efficiency and stability, but also significantly reduce errors and delays caused by dependency issues. The logically clear implementation process ensures the operability and effectiveness of the system in practical applications, creating a better working environment and user experience for developers.

[0180] Example 3

[0181] Based on the same inventive concept, this embodiment provides a module hot replacement processing system, which can be used to implement the module hot replacement processing method described in the above embodiment. The module hot replacement processing system can be implemented by software and / or hardware.

[0182] Figure 4 is a structural block diagram of a module hot replacement processing system provided by an embodiment of the present invention, such as Figure 4 As shown, the module hot replacement processing system includes:

[0183] The acquisition module 41 is used to acquire the dependency data of the project;

[0184] An analysis module 42, configured to extract features from the dependency data to convert them into analyzable data, and to analyze the analyzable data to automatically determine problems existing in the current dependency;

[0185] A processing module 43, used for executing a processing strategy corresponding to the problem;

[0186] The update module 44 is used to execute corresponding update strategies according to module dependencies, module sizes, module complexity, and system load conditions when hot replacement of modules is performed on the project.

[0187] Optionally, the acquisition module 41 includes:

[0188] An extraction unit, used to extract the library currently used by the project, the version information of the library and the dependency relationship of the library by analyzing the project configuration file and the dependency loading log at runtime;

[0189] A preprocessing unit is used to preprocess the extracted data to obtain the dependency data, wherein the preprocessing at least includes: converting the extracted data into a unified data format, performing data cleaning to filter invalid data and redundant data and repairing incomplete or erroneous entries, reconstructing the dependency into a tree diagram, and converting data from different sources into a unified standard description.

[0190] Optionally, the analysis module 42 includes:

[0191] A feature extraction unit, configured to extract features for each library in the dependency relationship data, wherein the extracted features include at least: library name, version, dependency depth, number of direct dependencies, number of dependencies, update frequency, usage frequency, number of dependency paths, and dependency clustering coefficient;

[0192] The first processing unit is used to convert the features of each library into a feature vector, and normalize the feature vector to obtain the analyzable data.

[0193] Optionally, the analysis module 42 further includes:

[0194] The second processing unit is configured to extract time series features if a change history of the dependency relationship is recorded in the project, and convert the time series features into a feature matrix as a part of the analyzable data.

[0195] Optionally, the analysis module 42 includes:

[0196] a first analyzing unit, configured to perform cluster analysis on the analyzable data using a clustering algorithm to find anomalies in the current dependency relationship; and / or,

[0197] The second analysis unit is used to analyze the analyzable data using an association rule algorithm to discover potential association relationships between libraries.

[0198] Optionally, the first analysis unit is specifically used to: use a clustering algorithm to cluster all libraries in the project according to the analyzable data; based on the clustering results, determine that the libraries with similar dependency depths, a dependency number greater than a preset number, and an update frequency greater than a preset frequency are core libraries, and / or determine the libraries with abnormal dependencies.

[0199] Optionally, the second analysis unit is specifically used to: use an association rule algorithm and preset rule parameters to analyze the analyzable data to determine the library combinations that are simultaneously dependent, the library version combinations that often cause conflicts, and / or the library combinations that cause performance problems in project operation; wherein the preset rule parameters include: support, confidence and lift, the support is the frequency of a single library or a combination of libraries appearing in a dependency relationship, the confidence is the probability that when any library appears, the other library also appears at the same time, and the lift is the correlation between the two libraries.

[0200] Optionally, the processing module 43 is specifically used for:

[0201] To solve the problem of version conflicts, avoid using conflicting version combinations when building projects. If the new version causes incompatibility, roll back to the previous stable version. If different modules need to use different versions of the same library, isolate the conflicting versions and run them in different environments.

[0202] To address the problem of dependency chain depth, replace the indirect dependency library in the dependency chain with the direct dependency version to reduce the dependency chain depth, and / or extract the frequently-depended sub-dependencies independently to become direct dependency libraries;

[0203] To address performance issues, upgrade library versions and / or reduce interactions between libraries through caching.

[0204] To address the issue of redundant dependencies, remove libraries that are not called or whose functions have been replaced based on the frequency of library use, and / or use lightweight libraries to replace lengthy libraries.

[0205] Optionally, the updating module 44 is specifically used for:

[0206] If the number of modules having dependency relationships with the module to be updated is greater than a preset number, incremental update is performed to gradually replace various parts of the module to be updated;

[0207] If the system load is greater than the preset load, parallel update is performed;

[0208] If the module volume is larger than the preset volume or the structural complexity is greater than the preset complexity, the preloading mechanism is used to load the updated content into the cache in advance.

[0209] Optionally, the module hot replacement processing system further includes:

[0210] The display module is used to display at least one of the current dependency status, the current processing strategy and the real-time update progress.

[0211] Optionally, the module hot replacement processing system further includes:

[0212] An indicator acquisition module, used to acquire system indicators, wherein the system indicators include at least one of the following: conflict resolution rate, update success rate and user satisfaction;

[0213] The optimization module is used to optimize the processing strategy and the update strategy according to the system indicators.

[0214] The module hot replacement processing system can execute the module hot replacement processing method provided in the embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method. For technical details not described in detail in this embodiment, please refer to the module hot replacement processing method provided in the embodiment of the present invention.

[0215] The embodiment of the processing system for hot replacement of modules described above is only illustrative, wherein the units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0216] Example 4

[0217] This embodiment provides an electronic device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method described in the above embodiment when executing the computer program.

[0218] Figure 5 is a schematic diagram of the hardware structure of an electronic device provided by an embodiment of the present invention, such as Figure 5 As shown, the electronic device includes:

[0219] One or more processors 510 and memory 520, Figure 5 A processor 510 is taken as an example.

[0220] The electronic device may further include: an input device 530 and an output device 540 .

[0221] The processor 510, the memory 520, the input device 530 and the output device 540 may be connected via a bus or other means. Figure 5 The example of connecting through bus is taken in the following.

[0222] The memory 520, as a non-volatile computer-readable storage medium, can be used to store non-volatile software programs, non-volatile computer executable programs and modules, such as program instructions / modules corresponding to the module hot replacement processing method in the embodiment of the present invention. The processor 510 executes various functional applications and data processing by running the non-volatile software programs, instructions and modules stored in the memory 520, that is, implementing the above-mentioned module hot replacement processing method.

[0223] The memory 520 may include a program storage area and a data storage area, wherein the program storage area may store an application required for operating the device and at least one function; the data storage area may store various data in the process of hot module replacement, etc. In addition, the memory 520 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage devices.

[0224] The input device 530 can receive input digital or character information and generate key signal input related to user settings and function control of the electronic device. The output device 540 can include a display device such as a display screen.

[0225] Example 5

[0226] This embodiment provides a non-volatile computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of the method described in the above embodiment are implemented.

[0227] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0228] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for processing module hot replacement, characterized in that: include: Get the project's dependency data; Extracting features from the dependency data to convert it into analyzable data, and analyzing the analyzable data to automatically determine problems existing in the current dependency; Execute a processing strategy corresponding to the problem; When hot replacement of modules is performed on the project, a corresponding update strategy is executed according to module dependencies, module sizes, module complexity, and system load conditions.

2. The method according to claim 1, characterized in that Get project dependency data, including: By analyzing the project configuration file and the runtime dependency loading log, the library currently used by the project, the library version information and the library dependency are extracted; The extracted data is preprocessed to obtain the dependency data, wherein the preprocessing at least includes: converting the extracted data into a unified data format, performing data cleaning to filter invalid data and redundant data and repairing incomplete or erroneous entries, reconstructing the dependency into a tree diagram, and converting data from different sources into a unified standard description.

3. The method according to claim 1, characterized in that Extracting features from the dependency data to convert them into analyzable data includes: Perform feature extraction for each library in the dependency relationship data, the extracted features including at least: library name, version, dependency depth, number of direct dependencies, number of dependencies, update frequency, usage frequency, number of dependency paths, and dependency clustering coefficient; For each library, the features of the library are converted into feature vectors, and the feature vectors are normalized to obtain the analyzable data.

4. The method according to claim 3, characterized in that Extracting features from the dependency data to convert them into analyzable data also includes: If the change history of the dependency relationship is recorded in the project, time series features are extracted and converted into a feature matrix as part of the analyzable data.

5. The method according to claim 1, characterized in that The analyzable data is analyzed to automatically determine problems existing in the current dependency, including: Performing cluster analysis on the analyzable data using a clustering algorithm to discover anomalies in the current dependency relationship; and / or, The analyzable data is analyzed using an association rule algorithm to discover potential associations between libraries.

6. The method according to claim 5, characterized in that Performing cluster analysis on the analyzable data using a clustering algorithm, including: clustering all libraries in the project based on the analyzable data using a clustering algorithm; According to the clustering results, libraries with similar dependency depths, a dependency number greater than a preset number, and an update frequency greater than a preset frequency are determined as core libraries, and / or libraries with abnormal dependencies are determined.

7. The method according to claim 5, characterized in that Analyzing the analyzable data using an association rule algorithm includes: Analyze the analyzable data using an association rule algorithm and preset rule parameters to determine a combination of libraries that are simultaneously dependent, a combination of library versions that often cause conflicts, and / or a combination of libraries that cause performance problems in project operation; The preset rule parameters include: support, confidence and lift. The support is the frequency of a single library or a combination of libraries appearing in a dependency relationship. The confidence is the probability that when any library appears, the other library also appears. The lift is the correlation between the two libraries.

8. The method according to claim 1, characterized in that Implement the corresponding treatment strategy for the problem, including: To solve the problem of version conflicts, avoid using conflicting version combinations when building projects. If the new version causes incompatibility, roll back to the previous stable version. If different modules need to use different versions of the same library, isolate the conflicting versions and run them in different environments. To address the problem of dependency chain depth, replace the indirect dependency library in the dependency chain with the direct dependency version to reduce the dependency chain depth, and / or extract the frequently-depended sub-dependencies independently to become direct dependency libraries; To address performance issues, upgrade library versions and / or reduce interactions between libraries through caching. To address the issue of redundant dependencies, remove libraries that are not called or whose functions have been replaced based on the frequency of library use, and / or use lightweight libraries to replace lengthy libraries.

9. The method according to claim 1, characterized in that: When hot-replacing modules of the project, corresponding update strategies are executed according to module dependencies, module sizes, module complexity, and system load conditions, including: If the number of modules having dependency relationships with the module to be updated is greater than a preset number, incremental update is performed to gradually replace various parts of the module to be updated; If the system load is greater than the preset load, parallel update is performed; If the module volume is larger than the preset volume or the structural complexity is greater than the preset complexity, the preloading mechanism is used to load the updated content into the cache in advance.

10. The method according to any one of claims 1 to 9, characterized in that Also includes: At least one of a current dependency status, a current processing strategy, and a real-time update progress is displayed.

11. The method according to any one of claims 1 to 9, characterized in that Also includes: Acquire system indicators, wherein the system indicators include at least one of the following: conflict resolution rate, update success rate and user satisfaction; The processing strategy and the update strategy are optimized according to the system indicators.

12. A module hot replacement processing system, characterized in that: include: Get module, used to get the dependency data of the project; An analysis module, used for extracting features from the dependency data to convert it into analyzable data, and analyzing the analyzable data to automatically determine problems existing in the current dependency; A processing module, used for executing a processing strategy corresponding to the problem; The update module is used to execute corresponding update strategies according to module dependencies, module sizes, module complexity, and system load conditions when hot replacing modules in the project.

13. An electronic device, comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method according to any one of claims 1 to 11 when executing the computer program.

14. A non-volatile computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 11 are implemented.