Project processing method and device, computer equipment and storage medium

By building and integrating code analysis plug-ins to generate target packers and automatically analyze project files, the problem of inefficient maintenance and iteration of public methods and components in the existing technology is solved, and rapid and accurate identification and recording is achieved, and development efficiency is improved. Code quality.

CN119473258APending Publication Date: 2025-02-18PING AN BANK CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411471827.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-21
Publication Date
2025-02-18

AI Technical Summary

Technical Problem

When handling the maintenance and iteration of public methods and components, the prior art mainly relies on manual search and analysis, resulting in inefficient processing and increasing uncertainty and risks in the maintenance and iteration process.

Method used

By determining whether the user has received the analysis request for the target project, obtain the project file, call the static module packer, build a specified plug-in based on the code analysis method, integrate the processing to obtain the target packer, analyze the project file based on the target packer, and output the public method and component usage information.

Benefits of technology

实现了自动准确地识别和记录目标项目的公共方法或组件使用情况,快速定位所有使用场景,避免了手动搜索的繁琐和可能的遗漏,提高了处理效率,提升了开发效率和代码质量,并降低 Uncertainty in maintenance and iteration processes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119473258A_ABST
    Figure CN119473258A_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of data processing, relates to a project processing method and device, computer equipment and a storage medium, is applied to the field of financial science and technology, and comprises the following steps: judging whether an analysis request for a target project triggered by a user is received or not; if yes, obtaining a project file corresponding to the target project; calling a preset static module packer; constructing a specified plug-in based on a preset code analysis method; performing integration processing on the static module packager based on the specified plug-in to obtain a corresponding target packager; analyzing the project file based on the target packer to obtain use information of a public method and a public component corresponding to the project file; and outputting the use information to a preset specified file. In addition, the use information of the application can be stored in the block chain. According to the invention, the processing efficiency of maintenance and iteration of common methods and components of the project is improved, and the uncertainty in the maintenance and iteration process of the project is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the fields of data processing technology and financial technology, and in particular to project processing methods, devices, computer equipment and storage media. Background Art

[0002] In the program development practice in the financial field, the reusability of public methods and components is regarded as the core element to improve development efficiency and ensure code quality. This concept is based on the modularization and componentization ideas in software engineering, and aims to reduce duplication of work, accelerate product development cycles, and promote code consistency and maintainability by building reusable code blocks. Especially in the development of financial systems, due to the involvement of a large number of common functions such as data processing, transaction logic, and security control, the reasonable design and reuse of public methods and components are particularly important.

[0003] However, as the scale of financial application projects continues to expand, the number of public methods and components contained in the system has increased dramatically, which directly brings huge challenges in maintenance and iteration. On the one hand, it is necessary to ensure that these public components can adapt to the ever-changing business needs and technical environment and maintain their effectiveness and security; on the other hand, it is also necessary to efficiently manage the dependencies between components to avoid version conflicts and performance bottlenecks.

[0004] At present, the industry mainly relies on manual search and analysis methods when dealing with the maintenance and iteration of public methods and components. Developers need to manually browse the code base, identify which parts are public components, evaluate their status (such as whether they are outdated, whether there are security vulnerabilities, etc.), and formulate maintenance and update strategies accordingly. The significant drawbacks of this method are its inefficiency and error-proneness. Faced with a huge code base, manual search is not only time-consuming and labor-intensive, but also very easy to miss key information, especially those component problems hidden in deep dependencies or complex logic. In addition, due to human cognitive limitations, manual analysis may also introduce subjective judgment errors, further increasing the uncertainty and risk in the maintenance and iteration process. Summary of the invention

[0005] The purpose of the embodiments of the present application is to propose a project processing method, apparatus, computer equipment and storage medium to solve the technical problems that the existing methods mainly rely on manual search and analysis when dealing with the maintenance and iteration problems of common methods and components, which have low processing efficiency and increase the uncertainty and risk in the maintenance and iteration process.

[0006] In order to solve the above technical problems, the present application embodiment provides a project processing method, which adopts the following technical solution:

[0007] Determine whether a user-triggered analysis request for a target project is received;

[0008] If so, obtaining a project file corresponding to the target project;

[0009] Call the preset static module packager;

[0010] Build specified plug-ins based on preset code analysis methods;

[0011] Based on the specified plug-in, the static module packager is integrated to obtain a corresponding target packager;

[0012] Analyzing the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file;

[0013] The usage information is output to a preset designated file.

[0014] Furthermore, the step of integrating the static module packager based on the specified plug-in to obtain the corresponding target packager specifically includes:

[0015] Obtain the configuration file of the static module packager;

[0016] Add the specified plug-in to the target array in the configuration file to obtain a processed static module packager;

[0017] The processed static module packager is used as the target packager.

[0018] Furthermore, the analysis request carries the user information of the user; and the step of obtaining the project file corresponding to the target project specifically includes:

[0019] extracting the user information from the analysis request;

[0020] Performing authority verification on the user based on the user information and a preset authority analysis model;

[0021] If the user passes the authority verification, the step of obtaining the project file corresponding to the target project is performed.

[0022] Furthermore, the step of verifying the user's authority based on the user information and a preset authority analysis model specifically includes:

[0023] Calling the permission analysis model and obtaining a preset operation permission table;

[0024] Acquire a target permission level corresponding to the user information based on the permission analysis model;

[0025] Query the specified permission level interval corresponding to the project analysis operation from the operation permission table;

[0026] Determining whether the target permission level is within the specified permission level range;

[0027] If so, it is determined that the user has passed the authority verification; otherwise, it is determined that the user has not passed the authority verification.

[0028] Furthermore, after the step of outputting the usage information to a preset designated file, the method further includes:

[0029] Analyze and process the specified file to obtain corresponding analysis results;

[0030] Generate a corresponding target optimization strategy based on the analysis results;

[0031] The target project is optimized based on the target optimization strategy.

[0032] Furthermore, after the step of outputting the usage information to a preset designated file, the method further includes:

[0033] Call the preset data statistics tool;

[0034] Performing statistical processing on the designated file based on the data statistical tool to obtain usage data corresponding to the common component;

[0035] The usage data is visualized.

[0036] Furthermore, after the step of outputting the usage information to a preset designated file, the method further includes:

[0037] Obtaining a specified storage method corresponding to the specified file;

[0038] Determining a designated storage medium corresponding to the designated storage method;

[0039] Upload the specified file to the specified storage medium.

[0040] In order to solve the above technical problems, the embodiment of the present application further provides a project processing device, which adopts the following technical solution:

[0041] A judgment module, used to judge whether an analysis request for a target project triggered by a user is received;

[0042] A first acquisition module, configured to acquire a project file corresponding to the target project;

[0043] The first calling module is used to call the preset static module packager;

[0044] The building module is used to build a specified plug-in based on the preset code analysis method;

[0045] An integration module, used for integrating the static module packager based on the specified plug-in to obtain a corresponding target packager;

[0046] A first analysis module, configured to analyze the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file;

[0047] The output module is used to output the usage information to a preset designated file.

[0048] In order to solve the above technical problems, the embodiment of the present application further provides a computer device, which adopts the following technical solution:

[0049] Determine whether a user-triggered analysis request for a target project is received;

[0050] If so, obtaining a project file corresponding to the target project;

[0051] Call the preset static module packager;

[0052] Build specified plug-ins based on preset code analysis methods;

[0053] Based on the specified plug-in, the static module packager is integrated to obtain a corresponding target packager;

[0054] Analyzing the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file;

[0055] The usage information is output to a preset designated file.

[0056] In order to solve the above technical problems, the embodiment of the present application further provides a computer-readable storage medium, which adopts the following technical solution:

[0057] Determine whether a user-triggered analysis request for a target project is received;

[0058] If so, obtaining a project file corresponding to the target project;

[0059] Call the preset static module packager;

[0060] Build specified plug-ins based on preset code analysis methods;

[0061] Based on the specified plug-in, the static module packager is integrated to obtain a corresponding target packager;

[0062] Analyzing the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file;

[0063] The usage information is output to a preset designated file.

[0064] Compared with the prior art, the embodiments of the present application have the following beneficial effects:

[0065] The present application first determines whether a user-triggered analysis request for a target project is received; if so, obtains a project file corresponding to the target project; then calls a preset static module packager; then builds a specified plug-in based on a preset code analysis method; subsequently, the static module packager is integrated based on the specified plug-in to obtain a corresponding target packager; further, the project file is analyzed based on the target packager to obtain usage information of public methods and public components corresponding to the project file; and finally, the usage information is output to a preset specified file. When the present application is maintaining and iterating the public methods and components of the target project, the preset static module packager is integrated using a specified plug-in constructed by a code analysis method to obtain a target packager, and then the project file is analyzed based on the target packager, which can realize automatic and accurate automatic identification and recording of the usage of the public methods or components of the target project, can quickly locate all usage scenarios, avoid the tediousness of manual search and possible omissions, effectively improve processing efficiency, thereby improving the development efficiency and code quality of the target project, and can reduce uncertainty in the maintenance and iteration process of the target project. BRIEF DESCRIPTION OF THE DRAWINGS

[0066] In order to more clearly illustrate the scheme in the present application, a brief introduction is given below to the drawings required for use in the description of the embodiments of the present application. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0067] Figure 1 is an exemplary system architecture diagram to which the present application may be applied;

[0068] Figure 2 A flowchart of an embodiment of a project processing method according to the present application;

[0069] Figure 3 is a schematic structural diagram of an embodiment of an item processing device according to the present application;

[0070] Figure 4 It is a structural diagram of an embodiment of a computer device according to the present application. DETAILED DESCRIPTION

[0071] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by technicians in the technical field of the present application; the terms used in the specification of the application herein are only for the purpose of describing specific embodiments and are not intended to limit the present application; the terms "including" and "having" and any variations thereof in the specification and claims of the present application and the above-mentioned drawings are intended to cover non-exclusive inclusions. The terms "first", "second", etc. in the specification and claims of the present application or the above-mentioned drawings are used to distinguish different objects, not to describe a specific order.

[0072] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.

[0073] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the accompanying drawings.

[0074] like Figure 1 As shown, the system architecture 100 may include a terminal device 101, a network 102 and a server 103. The terminal device 101 may be a laptop 1011, a tablet computer 1012 or a mobile phone 1013. The network 102 is used to provide a medium for a communication link between the terminal device 101 and the server 103. The network 102 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.

[0075] The user can use the terminal device 101 to interact with the server 103 through the network 102 to receive or send messages, etc. Various communication client applications can be installed on the terminal device 101, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, social platform software, etc.

[0076] The terminal device 101 can be any electronic device with a display screen and supporting web browsing. In addition to the laptop computer 1011, tablet computer 1012 or mobile phone 1013, the terminal device 101 can also be an e-book reader, an MP3 player (Moving Picture Experts Group Audio Layer III), an MP4 (Moving Picture Experts Group Audio Layer IV), a laptop computer, a desktop computer, etc.

[0077] The server 103 may be a server that provides various services, such as a background server that provides support for a web page displayed on the terminal device 101 .

[0078] It should be noted that the project processing method provided in the embodiment of the present application is generally executed by a server / terminal device, and accordingly, the project processing device is generally arranged in the server / terminal device.

[0079] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to the implementation requirements.

[0080] Continue to refer Figure 2 , shows a flow chart of an embodiment of the project processing method according to the present application. According to different requirements, the order of the steps in the flow chart can be changed, and some steps can be omitted. The project processing method provided in the embodiment of the present application can be applied to any scenario where project processing is required, and the project processing method can be applied to products in these scenarios, for example, financial project processing in the financial insurance field. The project processing method includes the following steps:

[0081] Step S201 : determining whether an analysis request for a target project triggered by a user is received.

[0082] In this embodiment, the electronic device (eg, Figure 1The server / terminal device shown in the figure) can obtain the analysis request through a wired connection or a wireless connection. It should be noted that the above-mentioned wireless connection method may include but is not limited to 3G / 4G / 5G connection, WiFi connection, Bluetooth connection, WiMAX connection, Zigbee connection, UWB (ultra wideband) connection, and other wireless connection methods currently known or developed in the future. The executor of this application may be a project processing system, or simply referred to as a system. The above-mentioned analysis request is a user-triggered request for identifying and recording the usage of public methods and public components in the target project. In the business scenario of project processing in finance and insurance, the above-mentioned target projects may include claims projects, auto insurance projects, and the like.

[0083] Step S202: If yes, obtain the project file corresponding to the target project.

[0084] In this embodiment, the above-mentioned project files refer to all files involved in the development or packaging process of the target project. Among them, the specific implementation process of obtaining the project files corresponding to the target project will be further described in detail in the subsequent specific embodiments of this application, and will not be elaborated on here.

[0085] Step S203, calling a preset static module packager.

[0086] In this embodiment, the static module packager may specifically be Webpack, which is a popular JavaScript application packaging tool that supports modularization and code splitting.

[0087] Step S204: construct a specified plug-in based on a preset code analysis method.

[0088] In the present embodiment, the above-mentioned code analysis method is used to detect whether a specific public method or component method is used in a file. Specifically, a new JavaScript file is created to define a Webpack plug-in (specified plug-in). The specified plug-in contains a code analysis method, which will be called in the compilation process of Webpack. Among them, in the code analysis method of the specified plug-in, the API provided by Webpack is used to traverse each module in the compilation process. For each module, the source code of the module is parsed by using an existing parsing library, and it is detected whether a specific public method is called or a public component is used. And when the use of a public method or component is detected, the specified plug-in can record the relevant usage information (such as file path, public method used or component name) into a data structure.

[0089] Step S205: integrating the static module packager based on the specified plug-in to obtain a corresponding target packager.

[0090] In this embodiment, the above-mentioned specific implementation process of integrating the static module packager based on the specified plug-in to obtain the corresponding target packager will be further described in detail in subsequent specific embodiments of the present application, and will not be elaborated in detail here.

[0091] Step S206: analyzing the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file.

[0092] In this embodiment, the target packager is used to compile the project files of the target project, and the specified plug-in is called when each project file is compiled. The specified plug-in can process various file types, and during the analysis process, it will record the usage information of the public methods and public components corresponding to the project file in real time, including detailed information such as file path and usage time.

[0093] Step S207: output the usage information to a preset designated file.

[0094] In this embodiment, the generated designated file contains usage records of all public methods and public components, such as file path, usage time, name of the public method or component used, etc., to facilitate subsequent maintenance and iteration work.

[0095] The present application first determines whether a user-triggered analysis request for a target project is received; if so, obtains a project file corresponding to the target project; then calls a preset static module packager; then builds a specified plug-in based on a preset code analysis method; subsequently, the static module packager is integrated based on the specified plug-in to obtain a corresponding target packager; further, the project file is analyzed based on the target packager to obtain usage information of public methods and public components corresponding to the project file; and finally, the usage information is output to a preset specified file. When the present application is maintaining and iterating the public methods and components of the target project, the preset static module packager is integrated using a specified plug-in constructed by a code analysis method to obtain a target packager, and then the project file is analyzed based on the target packager, which can realize automatic and accurate automatic identification and recording of the usage of the public methods or components of the target project, can quickly locate all usage scenarios, avoid the tediousness of manual search and possible omissions, effectively improve processing efficiency, thereby improving the development efficiency and code quality of the target project, and can reduce uncertainty in the maintenance and iteration process of the target project.

[0096] In some optional implementations, step S205 includes the following steps:

[0097] Get the configuration file of the static module bundler.

[0098] In this embodiment, the static module packager can specifically use Webpack. By correctly installing and configuring Webpack in the target project, Webpack and related dependencies can be added in package.json, and a Webpack configuration file (such as webpack.config.js) can be created to define the entry point, output path, loader, and plug-in of the package.

[0099] The specified plug-in is added to the target array in the configuration file to obtain a processed static module packager.

[0100] In this embodiment, the target array refers to the plugins array in the configuration file. By adding a custom specified plug-in to the plugins array. In this way, Webpack will call the plug-in's code analysis method during the compilation process. Whenever Webpack compiles a project, the specified plug-in will be triggered and the code analysis method will be executed. This process is automatic and does not require manual intervention. In addition, ensure that the entry and module rules in the Webpack configuration file can cover all JavaScript, Vue, React and other file types in the project. In this way, the specified plug-in can analyze all relevant source code files.

[0101] The processed static module packager is used as the target packager.

[0102] The present application obtains the configuration file of the static module packager; then adds the specified plug-in to the target array in the configuration file to obtain the processed static module packager; and subsequently uses the processed static module packager as the target packager. The present application obtains the configuration file of the static module packager, and then adds the specified plug-in to the target array in the configuration file, so that the integrated processing of the static module packager can be completed quickly and intelligently, thereby improving the construction efficiency of the target packager.

[0103] In some optional implementations of this embodiment, the analysis request carries the user information of the user; step S202 includes the following steps:

[0104] The user information is extracted from the analysis request.

[0105] In this embodiment, the analysis request may be subjected to information parsing to extract the user information carried inside the analysis request. The user information may include the user name.

[0106] The user's authority is verified based on the user information and a preset authority analysis model.

[0107] In this embodiment, the specific implementation process of the above-mentioned permission verification of the user based on the user information and the preset permission analysis model will be further described in detail in the subsequent specific embodiments of this application, and will not be elaborated in detail here.

[0108] If the user passes the authority verification, the step of obtaining the project file corresponding to the target project is performed.

[0109] In this embodiment, if the user fails to pass the authority verification, the user is restricted from responding to the above analysis request.

[0110] This application extracts the user information from the analysis request; then verifies the user's authority based on the user information and a preset authority analysis model; if the user passes the authority verification, the step of obtaining the project file corresponding to the target project is executed. After receiving the analysis request for the target project triggered by the user, this application will intelligently extract the user information from the analysis request, and verify the user's authority based on the user information and a preset authority analysis model. Only after detecting that the user has passed the authority verification will the subsequent response processing for the analysis request for the target project triggered by the user be executed, which effectively improves the intelligent processing and standardized processing of the analysis request for the target project, and ensures the security of the response to the analysis request for the target project.

[0111] In some optional implementations, the performing authority verification on the user based on the user information and a preset authority analysis model includes the following steps:

[0112] The permission analysis model is called and a preset operation permission table is obtained.

[0113] In this embodiment, the authority analysis model is a pre-built big data model that stores a one-to-one mapping relationship between the name information of each enterprise employee and the authority level. The operation authority table is a pre-built data table that stores multiple business operation identifiers and the authority level intervals corresponding to the various business operation identifiers. Among them, the business operation identifier is unique, and one business operation corresponds to one business operation identifier.

[0114] A target permission level corresponding to the user information is acquired based on the permission analysis model.

[0115] In this embodiment, the permission analysis model may be queried using the user information to obtain a target permission level corresponding to the user information.

[0116] The specified permission level interval corresponding to the project analysis operation is queried from the operation permission table.

[0117] In this embodiment, the designated business operation identifier corresponding to the business operation of the project analysis operation can be obtained, and then the designated business operation identifier can be used to query the above operation permission table to obtain the designated permission level interval corresponding to the business operation of the project analysis operation.

[0118] Determine whether the target permission level is within the specified permission level range.

[0119] In this embodiment, the target permission level can be compared with the two endpoint values ​​included in the above-mentioned specified permission level interval to obtain a corresponding numerical comparison result, and based on the numerical comparison result, it can be identified whether the target permission level is within the specified permission level interval.

[0120] If so, it is determined that the user has passed the authority verification; otherwise, it is determined that the user has not passed the authority verification.

[0121] In this embodiment, if the target permission level is within the specified permission level interval, it indicates that the user has the permission to perform the project analysis operation, and thus the user is determined to have passed the permission authentication. If the target permission level is not within the specified permission level interval, it indicates that the user does not have the permission to perform the project analysis operation, and thus the user is determined to have failed the permission authentication.

[0122] This application calls the permission analysis model and obtains the preset operation permission table; then obtains the target permission level corresponding to the user information based on the permission analysis model; then queries the specified permission level interval corresponding to the project analysis operation from the operation permission table; subsequently determines whether the target permission level is within the specified permission level interval; if so, determines that the user has passed the permission verification, otherwise determines that the user has not passed the permission verification, which effectively improves the processing intelligence and processing accuracy of the user's permission authentication, and ensures the accuracy of the obtained user's permission authentication result. In addition, only after detecting that the user has passed the permission verification, will the response processing for the analysis request for the target project triggered by the user be executed later, which effectively improves the intelligent processing and standardized processing of the analysis request for the target project, and ensures the response security of the analysis request for the target project.

[0123] In some optional implementations, after step S207, the electronic device may further perform the following steps:

[0124] The designated file is analyzed and processed to obtain a corresponding analysis result.

[0125] In this embodiment, by analyzing the designated file, key information such as component name, file path used, number of times used, etc. can be found and recorded in the designated file. During the analysis process, attention is paid to identifying any potential problems or inconsistencies. For example, if it is found that a component is used a lot but has poor performance, or a component is used incorrectly in an irrelevant context, problems that need further investigation and optimization, i.e., the above analysis results, can be obtained.

[0126] A corresponding target optimization strategy is generated based on the analysis results.

[0127] In this embodiment, a corresponding target optimization strategy can be formulated according to the obtained analysis results. The target optimization strategy may specifically include: Code optimization strategy: optimize performance bottlenecks or redundant codes to improve the efficiency and maintainability of components. Refactoring strategy: reorganize the code structure to improve the reusability and scalability of components. It may include splitting large components into smaller components, or abstracting similar functions into reusable modules. Document update strategy: update the project's documentation to reflect the latest component usage and best practices. This includes updating the component library's usage guide, API documentation, and sample code.

[0128] The target project is optimized based on the target optimization strategy.

[0129] In this embodiment, the optimization process for the target project can be gradually implemented according to the policy content in the above-mentioned target optimization policy.

[0130] This application analyzes and processes the specified file to obtain the corresponding analysis result; then generates the corresponding target optimization strategy based on the analysis result; and subsequently optimizes the target project based on the target optimization strategy. After outputting the usage information to the preset specified file, this application will further analyze and process the obtained specified file to obtain the analysis result, and then generate the corresponding target optimization strategy based on the analysis result, and then automatically and intelligently optimize the target project based on the target optimization strategy, thereby helping to improve the code quality of the target project, improve development efficiency and reduce maintenance costs.

[0131] In some optional implementations of this embodiment, after step S207, the electronic device may further perform the following steps:

[0132] Call the preset data statistics tool.

[0133] In this embodiment, the data statistics tool is a pre-built tool that has the function of counting the number of times a component is used, and counting the usage of the component in different files or modules.

[0134] The designated file is statistically processed based on the data statistics tool to obtain usage data corresponding to the common component.

[0135] In this embodiment, the usage data may include the number of times the common component is used, or may also include the usage of the common component in different files or modules.

[0136] The usage data is visualized.

[0137] In this embodiment, a bar chart or a heat map or other display method may be used to realize visualization of the usage data.

[0138] This application calls a preset data statistics tool; then performs statistical processing on the specified file based on the data statistics tool to obtain usage data corresponding to the common component; and then performs visualization processing on the usage data. After outputting the usage information to a preset specified file, this application will further perform statistical processing on the specified file based on the use of a data statistics tool to obtain usage data corresponding to the common component, and then perform visualization processing on the usage data, thereby intelligently improving the intelligent display of usage data of the common components contained in the specified file, which is beneficial to improving the user experience.

[0139] In some optional implementations of this embodiment, after step S207, the electronic device may further perform the following steps:

[0140] Get the specified storage method corresponding to the specified file.

[0141] In this embodiment, there is no specific limitation on the selection of the above-mentioned designated storage method, which can be set according to actual storage needs, for example, it can include version control system storage or cloud storage service storage.

[0142] A designated storage medium corresponding to the designated storage method is determined.

[0143] In this embodiment, the above-mentioned designated storage medium may include a version control system or a cloud storage service.

[0144] Upload the specified file to the specified storage medium.

[0145] In this embodiment, a communication connection may be established with the above-mentioned designated storage medium, and then the designated file may be uploaded to the designated storage medium based on the communication connection.

[0146] The present application obtains the designated storage method corresponding to the designated file; then determines the designated storage medium corresponding to the designated storage method; and subsequently uploads the designated file to the designated storage medium. After outputting the usage information to the preset designated file, the present application further obtains the designated storage method corresponding to the designated file, determines the designated storage medium corresponding to the designated storage method, and then uploads the designated file to the designated storage medium, thereby realizing intelligent storage of the designated file and ensuring the data security of the designated file. In addition, by uploading the designated file to the designated storage medium, relevant personnel can share and access the usage information in the designated file for further maintenance and iteration work, thereby improving the work experience of relevant personnel.

[0147] In some optional implementations, the user information obtained is subject to the user's consent and complies with relevant laws and policies.

[0148] In addition, the non-Company software tools or components that appear in the embodiments of the present application are merely examples and do not represent actual use.

[0149] It should be understood that the order of execution of the steps in the above embodiment does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present invention.

[0150] It should be emphasized that in order to further ensure the privacy and security of the above usage information, the above usage information can also be stored in a blockchain node.

[0151] The blockchain referred to in this application is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm, etc. Blockchain is essentially a decentralized database, a string of data blocks generated by cryptographic methods. Each data block contains a batch of network transaction information, which is used to verify the validity of its information (anti-counterfeiting) and generate the next block. Blockchain can include the underlying blockchain platform, platform product service layer, and application service layer.

[0152] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Among them, artificial intelligence (AI) is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results.

[0153] AI basic technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, mechatronics, etc. AI software technologies mainly include computer vision technology, robotics technology, biometrics technology, speech processing technology, natural language processing technology, and machine learning / deep learning.

[0154] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through computer-readable instructions, and the computer-readable instructions can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, the aforementioned storage medium can be a non-volatile storage medium such as a disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).

[0155] It should be understood that, although the steps in the flowchart of the accompanying drawings are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.

[0156] Further references Figure 3 , as a response to the above Figure 2 In order to realize the method shown in the figure, the present application provides an embodiment of a project processing device, and the device embodiment is Figure 2 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.

[0157] like Figure 3As shown, the project processing device 300 described in this embodiment includes: a judgment module 301, a first acquisition module 302, a first calling module 303, a construction module 304, an integration module 305, a first analysis module 306 and an output module 307. Among them:

[0158] The judgment module 301 is used to judge whether an analysis request for a target project triggered by a user is received;

[0159] A first acquisition module 302, configured to acquire a project file corresponding to the target project;

[0160] The first calling module 303 is used to call a preset static module packager;

[0161] A construction module 304 is used to construct a specified plug-in based on a preset code analysis method;

[0162] An integration module 305 is used to integrate the static module packager based on the specified plug-in to obtain a corresponding target packager;

[0163] A first analysis module 306, configured to analyze the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file;

[0164] The output module 307 is used to output the usage information to a preset designated file.

[0165] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the project processing method in the aforementioned implementation mode, and will not be repeated here.

[0166] In some optional implementations of this embodiment, the integration module 305 includes:

[0167] Obtain a submodule for obtaining a configuration file of the static module packager;

[0168] Add a submodule, used to add the specified plug-in to the target array in the configuration file to obtain a processed static module packager;

[0169] A submodule is determined, for using the processed static module packager as the target packager.

[0170] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the project processing method in the aforementioned implementation mode, and will not be repeated here.

[0171] In some optional implementations of this embodiment, the analysis request carries the user information of the user; the first acquisition module 302 includes:

[0172] An extraction submodule, used to extract the user information from the analysis request;

[0173] A verification submodule, used to verify the authority of the user based on the user information and a preset authority analysis model;

[0174] The execution submodule is used to execute the step of acquiring the project file corresponding to the target project if the user passes the authority verification.

[0175] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the project processing method in the aforementioned implementation mode, and will not be repeated here.

[0176] In some optional implementations of this embodiment, the verification submodule includes:

[0177] A calling unit, used to call the permission analysis model and obtain a preset operation permission table;

[0178] An acquisition unit, configured to acquire a target authority level corresponding to the user information based on the authority analysis model;

[0179] A query unit, used to query the specified permission level interval corresponding to the project analysis operation from the operation permission table;

[0180] A judging unit, used to judge whether the target permission level is within the specified permission level range;

[0181] The determination unit is used to determine that if yes, the user has passed the authority verification; otherwise, determine that the user has not passed the authority verification.

[0182] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the project processing method in the aforementioned implementation mode, and will not be repeated here.

[0183] In some optional implementations of this embodiment, the project processing device further includes:

[0184] The second analysis module is used to analyze and process the specified file to obtain corresponding analysis results;

[0185] A generation module, used to generate a corresponding target optimization strategy based on the analysis result;

[0186] An optimization module is used to optimize the target project based on the target optimization strategy.

[0187] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the project processing method in the aforementioned implementation mode, and will not be repeated here.

[0188] In some optional implementations of this embodiment, the project processing device further includes:

[0189] The second calling module is used to call the preset data statistics tool;

[0190] A statistics module, used for performing statistical processing on the designated file based on the data statistics tool to obtain usage data corresponding to the common component;

[0191] A processing module is used to perform visualization processing on the usage data.

[0192] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the project processing method in the aforementioned implementation mode, and will not be repeated here.

[0193] In some optional implementations of this embodiment, the project processing device further includes:

[0194] A second acquisition module, used to acquire a specified storage method corresponding to the specified file;

[0195] A determination module, used to determine a designated storage medium corresponding to the designated storage method;

[0196] The uploading module is used to upload the specified file to the specified storage medium.

[0197] In this embodiment, the operations performed by the above modules or units correspond one-to-one to the steps of the project processing method in the aforementioned implementation mode, and will not be repeated here.

[0198] To solve the above technical problems, the present application also provides a computer device. Figure 4 , Figure 4 This is a basic structural block diagram of the computer device in this embodiment.

[0199] The computer device 4 includes a memory 41, a processor 42, and a network interface 43 that are interconnected through a system bus. It should be noted that the figure only shows a computer device 4 with components 41-43, but it should be understood that it is not required to implement all the components shown, and more or fewer components can be implemented instead. Among them, those skilled in the art can understand that the computer device here is a device that can automatically perform numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes but is not limited to microprocessors, application specific integrated circuits (Application Specific Integrated Circuit, ASIC), programmable gate arrays (Field-Programmable Gate Array, FPGA), digital processors (Digital Signal Processor, DSP), embedded devices, etc.

[0200] The computer device may be a computing device such as a desktop computer, a notebook, a PDA, a cloud server, etc. The computer device may interact with a user through a keyboard, a mouse, a remote controller, a touch pad, or a voice control device.

[0201] The memory 41 includes at least one type of readable storage medium, and the readable storage medium includes flash memory, hard disk, multimedia card, card-type memory (for example, SD or DX memory, etc.), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, disk, optical disk, etc. In some embodiments, the memory 41 can be an internal storage unit of the computer device 4, such as a hard disk or memory of the computer device 4. In other embodiments, the memory 41 can also be an external storage device of the computer device 4, such as a plug-in hard disk equipped on the computer device 4, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (FlashCard), etc. Of course, the memory 41 can also include both the internal storage unit of the computer device 4 and its external storage device. In this embodiment, the memory 41 is generally used to store the operating system and various application software installed on the computer device 4, such as computer-readable instructions of the project processing method, etc. In addition, the memory 41 can also be used to temporarily store various types of data that have been output or are to be output.

[0202] The processor 42 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chip in some embodiments. The processor 42 is generally used to control the overall operation of the computer device 4. In this embodiment, the processor 42 is used to run computer-readable instructions stored in the memory 41 or process data, such as computer-readable instructions for running the project processing method.

[0203] The network interface 43 may include a wireless network interface or a wired network interface. The network interface 43 is generally used to establish a communication connection between the computer device 4 and other electronic devices.

[0204] Compared with the prior art, the embodiments of the present application have the following beneficial effects:

[0205] In an embodiment of the present application, first determine whether a user-triggered analysis request for a target project is received; if so, obtain a project file corresponding to the target project; then call a preset static module packager; then build a specified plug-in based on a preset code analysis method; subsequently integrate the static module packager based on the specified plug-in to obtain a corresponding target packager; further analyze the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file; finally output the usage information to a preset specified file. When the present application is maintaining and iterating the public methods and components of the target project, the preset static module packager is integrated and processed by using a specified plug-in constructed by a code analysis method to obtain a target packager, and then the project file is analyzed based on the target packager, which can realize automatic and accurate automatic identification and recording of the usage of the public methods or components of the target project, can quickly locate all usage scenarios, avoid the tediousness of manual search and possible omissions, effectively improve processing efficiency, thereby improving the development efficiency and code quality of the target project, and can reduce the uncertainty in the maintenance and iteration process of the target project.

[0206] The present application also provides another embodiment, namely, providing a computer-readable storage medium, wherein the computer-readable storage medium stores computer-readable instructions, and the computer-readable instructions can be executed by at least one processor to enable the at least one processor to perform the steps of the project processing method as described above.

[0207] Compared with the prior art, the embodiments of the present application have the following beneficial effects:

[0208] In an embodiment of the present application, first determine whether a user-triggered analysis request for a target project is received; if so, obtain a project file corresponding to the target project; then call a preset static module packager; then build a specified plug-in based on a preset code analysis method; subsequently integrate the static module packager based on the specified plug-in to obtain a corresponding target packager; further analyze the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file; finally output the usage information to a preset specified file. When the present application is maintaining and iterating the public methods and components of the target project, the preset static module packager is integrated and processed by using a specified plug-in constructed by a code analysis method to obtain a target packager, and then the project file is analyzed based on the target packager, which can realize automatic and accurate automatic identification and recording of the usage of the public methods or components of the target project, can quickly locate all usage scenarios, avoid the tediousness of manual search and possible omissions, effectively improve processing efficiency, thereby improving the development efficiency and code quality of the target project, and can reduce the uncertainty in the maintenance and iteration process of the target project.

[0209] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in each embodiment of the present application.

[0210] Obviously, the embodiments described above are only some embodiments of the present application, rather than all embodiments. The preferred embodiments of the present application are given in the accompanying drawings, but they do not limit the patent scope of the present application. The present application can be implemented in many different forms. On the contrary, the purpose of providing these embodiments is to make the understanding of the disclosure of the present application more thorough and comprehensive. Although the present application is described in detail with reference to the aforementioned embodiments, for those skilled in the art, it is still possible to modify the technical solutions recorded in the aforementioned specific implementation methods, or to perform equivalent replacement of some of the technical features therein. Any equivalent structure made using the contents of the specification and drawings of this application, directly or indirectly used in other related technical fields, is similarly within the scope of patent protection of this application.

Claims

1. A project processing method, characterized in that: The steps include: Determine whether a user-triggered analysis request for a target project is received; If so, obtaining a project file corresponding to the target project; Call the preset static module packager; Build specified plug-ins based on preset code analysis methods; Based on the specified plug-in, the static module packager is integrated to obtain a corresponding target packager; Analyzing the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file; The usage information is output to a preset designated file.

2. The project processing method according to claim 1, characterized in that: The step of integrating the static module packager based on the specified plug-in to obtain the corresponding target packager specifically includes: Obtain the configuration file of the static module packager; Add the specified plug-in to the target array in the configuration file to obtain a processed static module packager; The processed static module packager is used as the target packager.

3. The project processing method according to claim 1, characterized in that: The analysis request carries the user information of the user; the step of obtaining the project file corresponding to the target project specifically includes: extracting the user information from the analysis request; Performing authority verification on the user based on the user information and a preset authority analysis model; If the user passes the authority verification, the step of obtaining the project file corresponding to the target project is performed.

4. The project processing method according to claim 3, characterized in that: The step of verifying the user's authority based on the user information and the preset authority analysis model specifically includes: Calling the permission analysis model and obtaining a preset operation permission table; Acquire a target permission level corresponding to the user information based on the permission analysis model; Query the specified permission level interval corresponding to the project analysis operation from the operation permission table; Determining whether the target permission level is within the specified permission level range; If so, it is determined that the user has passed the authority verification; otherwise, it is determined that the user has not passed the authority verification.

5. The project processing method according to claim 1, characterized in that: After the step of outputting the usage information to a preset designated file, the method further includes: Analyze and process the specified file to obtain corresponding analysis results; Generate a corresponding target optimization strategy based on the analysis results; The target project is optimized based on the target optimization strategy.

6. The project processing method according to claim 1, characterized in that: After the step of outputting the usage information to a preset designated file, the method further includes: Call the preset data statistics tool; Performing statistical processing on the designated file based on the data statistical tool to obtain usage data corresponding to the common component; The usage data is visualized.

7. The project processing method according to claim 1, characterized in that: After the step of outputting the usage information to a preset designated file, the method further includes: Obtaining a specified storage method corresponding to the specified file; Determining a designated storage medium corresponding to the designated storage method; Upload the specified file to the specified storage medium.

8. A project processing device, characterized in that: include: A judgment module, used to judge whether an analysis request for a target project triggered by a user is received; A first acquisition module, configured to acquire a project file corresponding to the target project; The first calling module is used to call the preset static module packager; The building module is used to build a specified plug-in based on the preset code analysis method; An integration module, used for integrating the static module packager based on the specified plug-in to obtain a corresponding target packager; A first analysis module, configured to analyze the project file based on the target packager to obtain usage information of public methods and public components corresponding to the project file; The output module is used to output the usage information to a preset designated file.

9. A computer device, characterized in that: It comprises a memory and a processor, wherein the memory stores computer-readable instructions, and the processor implements the steps of the project processing method as described in any one of claims 1 to 7 when executing the computer-readable instructions.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-readable instructions, which, when executed by a processor, implement the steps of the project processing method according to any one of claims 1 to 7.