Multi-bin patch verification method and device, code server and readable storage medium

By using an automated multi-warehouse patch verification method, the problem of long patch verification cycles in software maintenance is solved, enabling simultaneous capture and verification of multiple patches, thus improving efficiency and speed.

CN114490346BActive Publication Date: 2026-08-25TCL TECH ELECTRONICS (HUIZHOU) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111675545.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-31
Publication Date
2026-08-25
Estimated Expiration
2041-12-31

AI Technical Summary

Technical Problem

In existing technologies, the storage, distribution, and testing of software patches rely on manual operations, which are time-consuming, labor-intensive, and prone to errors, resulting in long software maintenance cycles.

Method used

By receiving patch information and verifying whether it conforms to preset input rules, extracting problem identifiers and patch codes, caching them in a temporary area, and having the patch testing device perform tests based on the problem identifiers, automated verification of multi-warehouse patches is achieved.

Benefits of technology

It enables simultaneous capture and verification of multiple patches, eliminating the hassle of manual single-warehouse operations and greatly improving the efficiency and speed of patch verification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114490346B_ABST
    Figure CN114490346B_ABST
Patent Text Reader

Abstract

The application discloses a kind of multi-bin patch verification methods, including steps: when receiving input patch information, check whether the patch information meets preset input rule;If the patch information meets preset input rule, extract the problem identification in the patch information and the patch code corresponding to the problem identification;The patch code is cached to the temporary area in the code management device, and the problem identification is sent to the patch test device connected with the code management device, so that the patch test device tests the patch code according to the problem identification.The application also discloses a kind of multi-bin patch verification system, code server and readable storage medium.By applying the multi-bin patch verification method of the application to the multi-bin patch verification system, code server, multiple patches and corresponding multiple code repositories can be verified simultaneously, greatly improving the efficiency of patch verification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of software maintenance, and more particularly to a multi-warehouse patch verification method, apparatus, code server, and readable storage medium. Background Technology

[0002] Software maintenance, a software engineering term, refers to software modifications performed after a software product is released to fix bugs, improve performance, or enhance other attributes. It is the final and longest stage of the software lifecycle. The cost of application software maintenance is approximately four times the development cost. With the rapid development of software engineering, source code has grown from thousands or tens of thousands of lines to tens of millions of lines. Many projects use multi-repository management, making code management more complex and cumbersome. A typical example is the Android codebase; the latest version, Android 11, is 200GB, composed of thousands of code repositories, with some repositories containing hundreds of thousands or even millions of lines (tens of GB). Therefore, version control of source code is crucial. In the entire software testing process, software patches are a core component of software maintenance. The need for quick processing and verification of patches corresponding to these source codes is urgent. Currently, patch storage, distribution, and testing verification processes are all done manually—introducing patches into specific code repositories and then performing manual software testing—which is time-consuming, labor-intensive, and prone to errors, resulting in a very long software maintenance cycle. Summary of the Invention

[0003] This invention proposes a multi-repository patch verification method, apparatus, code server, and readable storage medium, aiming to solve the technical problem of long patch verification cycles in code repositories.

[0004] To achieve the above objectives, the present invention provides a multi-warehouse patch verification method, which includes the following steps:

[0005] When patch information is received, verify whether the patch information conforms to the preset input rules;

[0006] If the patch information conforms to the preset input rules, then the problem identifier and the patch code corresponding to the problem identifier are extracted from the patch information;

[0007] The patch code is cached in the temporary area of ​​the code management device, and the problem identifier is sent to the patch testing device connected to the code management device, so that the patch testing device can test the patch code according to the problem identifier.

[0008] Optionally, the step of verifying whether the patch information conforms to preset input rules includes:

[0009] Determine whether patch code exists in the patch information;

[0010] If the patch information contains patch code, then determine whether the patch information contains a problem identifier, submission instructions, and verification commands.

[0011] If the patch information contains a problem identifier, submission instructions, and verification commands, then the patch information is determined to conform to the preset input rules.

[0012] Optionally, the step of determining all code repositories corresponding to the patch information based on the issue identifier includes:

[0013] Based on the issue identifier, determine the configuration file corresponding to the issue identifier, and determine the code repository keyword corresponding to the issue identifier;

[0014] Obtain the code repository path corresponding to the code repository keyword in the configuration file, and cache the patch code and the code repository path in the temporary area of ​​the code management device.

[0015] Furthermore, to achieve the above objectives, the present invention also provides a multi-warehouse patch verification method; the multi-warehouse patch verification method is applied to a patch testing device, and the multi-warehouse patch verification method includes:

[0016] The system receives a problem identifier sent by a code management device. The problem identifier and the corresponding patch code are included in the patch information received by the code management device that conforms to preset input rules.

[0017] Extract the patch code corresponding to the problem identifier from the temporary area in the code management device;

[0018] The verification instructions associated with the patch code are determined in the patch information;

[0019] The patch code is tested according to the verification instructions.

[0020] Optionally, the step of extracting the patch code corresponding to the problem identifier from the temporary area in the code management device includes:

[0021] Based on the problem identifier, determine the configuration file corresponding to the problem identifier;

[0022] According to the configuration file, the patch code corresponding to the problem identifier is extracted from the temporary area in the code management device.

[0023] Optionally, the step of testing the patch code according to the verification instruction includes:

[0024] Obtain the source image file corresponding to the patch code;

[0025] The source image file and the patch code are compiled together to obtain the image file to be tested.

[0026] Configure the image file to be tested onto the corresponding application platform to obtain the client to be tested;

[0027] The verification command is triggered to perform a test operation on the client to be tested.

[0028] Optionally, after the step of extracting the patch code corresponding to the problem identifier from the temporary area in the code management device, the method further includes:

[0029] Determine whether the patch code was successfully extracted;

[0030] If extraction fails, it is determined to be an illegal patch, and a prompt message corresponding to the illegal patch is pushed.

[0031] If the extraction is successful, proceed to the step of obtaining the source image file corresponding to the patch code.

[0032] Furthermore, to achieve the above objectives, the present invention also provides a multi-warehouse patch verification system, the multi-warehouse patch verification system comprising:

[0033] A code management device is used to, upon receiving input patch information, verify whether the patch information conforms to preset input rules; if the patch information conforms to the preset input rules, extract the problem identifier and the patch code corresponding to the problem identifier from the patch information; cache the patch code in the temporary area of ​​the code management device, and send the problem identifier to a patch testing device connected to the code management device, so that the patch testing device can test the patch code according to the problem identifier;

[0034] A patch testing device is used to receive a problem identifier sent by a code management device, wherein the problem identifier and the corresponding patch code are contained in patch information received by the code management device and conforming to preset input rules; extract the patch code corresponding to the problem identifier from the temporary area in the code management device; determine the verification instruction associated with the patch code in the patch information; and test the patch code according to the verification instruction.

[0035] In addition, to achieve the above objectives, the present invention also provides a code server, the code server including a memory, a processor, and a multi-warehouse patch verification program stored on the memory and executable on the processor, wherein: when the multi-warehouse patch verification program is executed by the processor, it implements the steps of the multi-warehouse patch verification method as described above.

[0036] In addition, to achieve the above objectives, the present invention also provides a readable storage medium storing a multi-warehouse patch verification program, which, when executed by a processor, implements the steps of the multi-warehouse patch verification method as described above.

[0037] The multi-repository patch verification method of this invention first verifies whether the received patch information conforms to preset input rules. If the patch information conforms to the preset input rules, it extracts the issue identifier and the corresponding patch code from the patch information. This ensures that the patch information submitted by developers, including patch code and issue identifiers, conforms to internal specifications, thus facilitating the retrieval of multiple patch codes stored in the code management device. Furthermore, by caching the patch code in the temporary area of ​​the code management device and sending the issue identifier to a patch testing device connected to the code management device, the patch testing device tests the patch code based on the issue identifier. This process distributes and saves each patch code to its corresponding code repository temporary area, facilitating the extraction of patch code belonging to various repositories awaiting testing by the patch testing device. These steps automatically complete the patch saving process during patch verification, overcoming the technical limitation of patches being saved only in a single repository. This enables simultaneous capture and verification of multiple patches, eliminating the hassle of manual single-repository operations and greatly improving the efficiency of patch verification. Furthermore, based on the fact that the patch information conforms to the preset input rules and the problem identifier is associated with the patch code in the patch information, not only is the patch saving speed accelerated, but the subsequent patch verification process is also greatly facilitated, thus speeding up the patch verification process as a whole. Attached Figure Description

[0038] Figure 1 This is a schematic diagram of the terminal structure of the hardware operating environment of the code server involved in the embodiments of the present invention;

[0039] Figure 2 This is a flowchart illustrating the first embodiment of the multi-warehouse patch verification method of the present invention;

[0040] Figure 3 This is a flowchart illustrating the second embodiment of the multi-warehouse patch verification method of the present invention;

[0041] Figure 4 This is a schematic diagram of a three-terminal interaction scenario involved in the multi-warehouse patch verification method of the present invention;

[0042] Figure 5 This is a diagram illustrating the patch verification time effect of the multi-warehouse patch verification method of the present invention.

[0043] Figure 6 This is a schematic diagram of the framework structure of the multi-warehouse patch verification system of the present invention. Detailed Implementation

[0044] It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.

[0045] like Figure 1 As shown, Figure 1 This is a schematic diagram of the terminal structure of the hardware operating environment of the code server involved in the embodiments of the present invention.

[0046] like Figure 1 As shown, the terminal may include: a processor 1001, such as a CPU; a network interface 1004; a user interface 1003; a memory 1005; and a communication bus 1002. The communication bus 1002 is used to enable communication between these components. The user interface 1003 may include a display or an input unit such as a control panel; optionally, the user interface 1003 may also include a standard wired interface or a wireless interface. The network interface 1004 may optionally include a standard wired interface or a wireless interface (such as a WLAN interface). The memory 1005 may be high-speed RAM or stable non-volatile memory, such as a disk drive. Optionally, the memory 1005 may also be a storage device independent of the aforementioned processor 1001. The memory 1005, as a computer storage medium, may include a multi-warehouse patch verification program.

[0047] Those skilled in the art will understand that Figure 1 The terminal structure shown does not constitute a limitation on the terminal and may include more or fewer components than shown, or combine certain components, or have different component arrangements.

[0048] like Figure 2 As shown, Figure 2 This is a flowchart illustrating the first embodiment of the multi-repository patch verification method of the present invention. In this embodiment, the multi-repository patch verification method is applied to a code management device; the multi-repository patch verification method includes:

[0049] Step S10: When the input patch information is received, verify whether the patch information conforms to the preset input rules;

[0050] A patch is a small program that fixes system vulnerabilities; at its core, it's a type of computer programming code. The patch verification process can be broadly divided into two parts: patch creation, patch storage and management, and patch testing.

[0051] In this embodiment, the main focus is on the creation and management of patches. The patches are created from the computer client directly interacting with the developers, while the management of patches is performed in the code management device.

[0052] Specifically, the code management device is primarily responsible for code storage, downloading and uploading, and patch information detection and verification. It uses Git tools to manage and transfer code. Based on the Gerrit system, it operates a Gerrit server that can manage source code from multiple repositories. Each repository is a Git repository, and multiple repositories can be managed using the `repo` tool.

[0053] The patch information received by the code management device originates from a series of data created by developers on the corresponding client. Patch information must include at least: patch code, the corresponding verification command, a submission description, and an issue identifier. Before saving the patch information submitted by a developer, the code management device verifies it. Specifically, it verifies whether the submitted patch information contains the patch code, the corresponding verification command, the submission description, and the issue identifier. Specifically, the code management device or the computer client integrates hooks that require developers to submit patches according to specific rules. If any of the above information is missing, the patch information is deemed not to conform to the preset input rules, and a relevant prompt message is pushed to the developer informing them that they need to check the patch information or recreate it.

[0054] In one embodiment, the step of verifying whether the patch information conforms to a preset input rule includes:

[0055] Step a: Determine whether patch code exists in the patch information;

[0056] Step b: If the patch information contains patch code, then determine whether the patch information contains a problem identifier, submission instructions, and verification commands.

[0057] Step c: If the patch information contains a problem identifier, submission instructions, and verification commands, then the patch information is determined to conform to the preset input rules.

[0058] To improve efficiency during patch information verification, the first step is to check if patch code exists within the patch information. If no patch code is found, the verification process stops, and the developers are notified that no patch code exists in the patch information. If patch code exists, the patch information is then checked for issue identifiers, submission instructions, and verification commands. Issue identifiers refer to the symbols corresponding to various computer vulnerabilities (bugs), which can be issue codes, such as 1 and 2. 1 represents an audio malfunction, and 2 represents a display malfunction. Submission instructions are the textual descriptions of the patch code. Verification commands are the script instructions that initiate patch code tests for different patch codes.

[0059] If a patch message contains all three required elements—a problem identifier, a commit message, and a verification instruction—it is considered to conform to the preset input rules. It's important to note that a patch message can only contain a unique problem identifier; that is, one patch message corresponds to one problem identifier. In other words, the problem identifier is associated with other data in the patch message, primarily with the patch code. Each patch code is associated with its corresponding code repository, meaning the problem identifier can be further associated with multiple code repositories.

[0060] In addition, the process of verifying patch information described above can also be performed by the developer's computer system.

[0061] Step S20: If the patch information conforms to the preset input rules, then extract the problem identifier and the patch code corresponding to the problem identifier from the patch information;

[0062] If the patch information conforms to the preset input rules, the issue identifier is extracted from the patch information. In practical applications, this issue identifier is called a Change-id. When developers submit a patch for a software or system bug for the first time, they don't need to manually enter the issue identifier. The computer system can automatically generate the issue identifier based on the patch information and save it in two ways: first, it is automatically saved and added to the original patch information to obtain the new patch information, which is then sent to the code management device; second, it is saved in the developer's client or computer system. The generated issue identifier can be a hash value generated from the patch information. Subsequent times, when developers address the same bug in the same software or system, they need to enter or select the issue identifier when submitting patch information to the code management device.

[0063] Step S30: Cache the patch code in the temporary area of ​​the code management device, and send the problem identifier to the patch testing device connected to the code management device, so that the patch testing device can test the patch code according to the problem identifier.

[0064] All patch code is cached in a temporary area within the code management device. This temporary area is a dedicated partition created by the code management device to store the patch code awaiting testing. Cacheing each patch code from the patch information in the temporary area of ​​the code management device facilitates the retrieval of patch code and other data information from the code management device for testing purposes, thus improving the overall efficiency of multi-warehouse patch verification.

[0065] The problem identifier is sent to the patch testing device, which is electrically or wirelessly connected to the code management device. The patch testing device parses and identifies the input problem identifier, thereby testing the patch code.

[0066] Specifically, in one embodiment, the step of caching the patch code in the temporary area of ​​the code management device includes:

[0067] Step d: Based on the problem identifier, determine the configuration file corresponding to the problem identifier, and determine the code repository keyword corresponding to the problem identifier;

[0068] Step e: Obtain the code repository path corresponding to the code repository keyword in the configuration file, and cache the patch code and the code repository path in the temporary area of ​​the code management device.

[0069] The code management device contains multiple manifest.xml configuration files, with issue identifiers pre-associated with each manifest.xml file. Upon receiving patch information, the issue identifier is extracted, the corresponding configuration file is located based on the issue identifier, and the issue identifier is parsed to retrieve the corresponding code repository keywords from the preset code repository directory. The code repository keywords are then extracted and searched in the manifest.xml file corresponding to the issue identifier. Specifically, the manifest.xml can be parsed using a repo tool. Once the code repository path associated with the code repository keywords is found, i.e., the code repository's server address and account information, the code repository corresponding to each patch code associated with the issue identifier can be determined. This, in turn, determines all the code repositories corresponding to the patch information. This facilitates the simultaneous loading of each patch code into the repository after all patch codes have successfully passed the saving and testing verification process, improving the efficiency of the loading process.

[0070] The multi-repository patch verification method of this invention first verifies whether the received patch information conforms to preset input rules. If the patch information conforms to the preset input rules, it extracts the issue identifier and the corresponding patch code from the patch information. This ensures that the patch information submitted by developers, including patch code and issue identifiers, conforms to internal specifications, thus facilitating the retrieval of multiple patch codes stored in the code management device. Furthermore, by caching the patch code in the temporary area of ​​the code management device and sending the issue identifier to a patch testing device connected to the code management device, the patch testing device tests the patch code based on the issue identifier. This process distributes and saves each patch code to its corresponding code repository temporary area, facilitating the extraction of patch code belonging to various repositories awaiting testing by the patch testing device. These steps automatically complete the patch saving process during patch verification, overcoming the technical limitation of patches being saved only in a single repository. This enables simultaneous capture and verification of multiple patches, eliminating the hassle of manual single-repository operations and greatly improving the efficiency of patch verification. Furthermore, based on the fact that the patch information conforms to the preset input rules and the problem identifier is associated with the patch code in the patch information, not only is the patch saving speed accelerated, but the subsequent patch verification process is also greatly facilitated, thus speeding up the patch verification process as a whole.

[0071] like Figure 3 As shown, Figure 3 This is a flowchart illustrating a second embodiment of the multi-warehouse patch verification method of the present invention. In this embodiment, the multi-warehouse patch verification method is applied to a patch testing device; the multi-warehouse patch verification method includes:

[0072] Step S50: Receive a problem identifier sent by the code management device. The problem identifier and the patch code corresponding to the problem identifier are included in the patch information received by the code management device that conforms to the preset input rules.

[0073] This embodiment relates to the patch testing process. The patch testing device can be used to extract, test, and score patch code. When a developer submits patch information to the code management device, the patch testing process is triggered.

[0074] Step S60: Extract the patch code corresponding to the problem identifier from the temporary area in the code management device;

[0075] Specifically, in one embodiment, the step of extracting the patch code corresponding to the problem identifier from the temporary area in the code management device includes:

[0076] Step f: Determine the configuration file corresponding to the problem identifier based on the problem identifier;

[0077] Step g: Extract the patch code corresponding to the problem identifier from the temporary area in the code management device according to the configuration file.

[0078] Once the patch code is cached in the temporary area of ​​the code management device, the code management device sends an issue identifier to the patch verification device. The patch verification device automatically and promptly determines the manifest.xml configuration file based on the issue identifier, and uses the review field in the configuration file to determine the code repository path cached in the temporary area of ​​the code management device. Based on the association between the code repository path and the patch code, it retrieves the patch code and verification instructions from the temporary area of ​​the code management device. Alternatively, the patch testing device can receive the issue identifier in two ways: either the developer's computer client can send the issue identifier to the patch testing device simultaneously with the patch information submitted to the code management device, or the code management device can extract the issue identifier from the patch information and forward it to the patch testing device.

[0079] In another embodiment, after step g, the following is included:

[0080] Step h: Determine the preset fields in the configuration file; filter the patch code according to the preset fields to obtain the target patch code, and use the target patch code as the patch code.

[0081] After determining the manifest.xml configuration file, information such as the cached patch code in the temporary area is obtained by querying the review field in the configuration file. A preset script file extracts the preset field "default_revision" from the configuration file. All cached patch code is filtered based on the "default_revision" field to retain the target patch code that matches the value corresponding to the "default_revision" field. The reason for performing this filtering operation is that the same code repository may have different branches. For different branches, it is generally not necessary to extract all cached patches; only patches for specific branches need to be extracted. In this embodiment, both the efficiency and accuracy of patch extraction by the patch testing device are improved. Furthermore, maintenance personnel can select a specific branch of a specific repository when pulling patches, facilitating patch extraction according to actual needs—something that was not possible with previous solutions.

[0082] In another embodiment, after the step of extracting the patch code corresponding to the problem identifier from the temporary area in the code management device, the method further includes:

[0083] Step i: Determine whether the patch code has been successfully extracted;

[0084] Step j: If extraction fails, it is determined to be an illegal patch, and a prompt message corresponding to the illegal patch is pushed.

[0085] Step k: If the extraction is successful, proceed to obtain the source image file corresponding to the patch code.

[0086] If the patch testing device fails to extract patch code and other information during the process, it will be identified as an illegal patch, triggering an email notification to the developer to recreate the patch. Furthermore, if the compilation between the patch code and the source image file fails, it will also be identified as an illegal patch, triggering a corresponding email notification. This allows developers to promptly identify and resolve issues, thereby improving efficiency.

[0087] Step S70: Determine the verification instruction associated with the patch code in the patch information;

[0088] Extract the verification instructions associated with the patch code from the patch information in the code management device.

[0089] Step S80: Test the patch code according to the verification instruction.

[0090] Specifically, step S80 includes:

[0091] Step 1: Obtain the source image file corresponding to the patch code;

[0092] Step m: Compile the source image file and the patch code to obtain the image file to be tested;

[0093] Step n: Configure the image file to be tested onto the corresponding application platform to obtain the client to be tested;

[0094] Step o, trigger the verification command to perform test operations on the client to be tested.

[0095] Each patch code has its own corresponding source image file of the software or system, which stores all the data of the original version of the software or system.

[0096] The patch code is compiled into the source image file to obtain the image file to be tested, i.e., the software image with the patch. This patched software image is then automatically burned into the device. This completes the configuration of the file to be tested onto the corresponding application platform, resulting in the complete software or system to be tested. Here, the device refers to smart devices such as mobile phones, tablets, and computers. After the device restarts, the verification command in the patch information is sent to the client to be tested for simulated testing. Only if the result passes is the patch considered valid; otherwise, it is invalid and cannot be applied to the code management device, meaning the previously cached patch code cannot be officially added to the repository. This process automates the tedious manual compilation of patches and source image files. Furthermore, automating the testing of the client to be tested saves a significant amount of manual work in testing the software and system, saving maintenance personnel time and greatly improving the efficiency of patch testing and verification.

[0097] Both the first and second embodiments can be implemented in a code server. For a further understanding of this application, the interaction between the developer client, the code management device, and the patch testing device can be referred to... Figure 4 , Figure 4 The figure shows a schematic diagram of the three-terminal interaction scenario involved in the multi-warehouse patch verification method of the present invention:

[0098] ① First, the code management device performs code synchronization with the developer's client. Here, the code refers to all the source code of the client (software or system) to be tested.

[0099] ② The developer client creates the patch information and pushes the patch to the code management device;

[0100] ③ After the code management device receives the patch information, it triggers the extraction and testing of the patch, that is, it hands it over to the patch testing device for testing;

[0101] ④ After testing the patch code, the patch testing device can also score the patch test results.

[0102] Through implementation of this invention, and through practical application, with reference to Figure 5 , Figure 5This diagram illustrates the patch verification time efficiency of the multi-repository patch verification method of this invention. The horizontal axis represents the number of patch verifications, showing verifications from the 392nd to the 488th. The values ​​10, 85, 39, and 23 on the horizontal axis refer to the server addresses. The vertical axis represents the time taken to complete each patch verification. The diagram shows that even the longest system patch verification takes no more than 30 minutes, and typical software patch verifications only take 1-2 minutes. Conventional manual single-repository patch verification can take anywhere from several hours to several days. This invention enables simultaneous verification of multiple patches and their corresponding code repositories, significantly improving patch verification efficiency.

[0103] In addition, refer to Figure 6 The present invention also proposes a multi-warehouse patch verification system, the multi-warehouse patch verification system comprising:

[0104] The code management device A10 is used to, upon receiving input patch information, verify whether the patch information conforms to preset input rules; if the patch information conforms to preset input rules, extract the problem identifier and the patch code corresponding to the problem identifier from the patch information; cache the patch code in the temporary area of ​​the code management device, and send the problem identifier to the patch testing device connected to the code management device, so that the patch testing device can test the patch code according to the problem identifier;

[0105] The patch testing device A20 is used to receive a problem identifier sent by the code management device. The problem identifier and the corresponding patch code are included in the patch information received by the code management device and conforming to preset input rules. The device extracts the patch code corresponding to the problem identifier from the temporary area in the code management device. The device determines the verification instruction associated with the patch code in the patch information. The device tests the patch code according to the verification instruction.

[0106] Optionally, the code management device A10 is further configured to:

[0107] Determine whether patch code exists in the patch information;

[0108] If the patch information contains patch code, then determine whether the patch information contains a problem identifier, submission instructions, and verification commands.

[0109] If the patch information contains a problem identifier, submission instructions, and verification commands, then the patch information is determined to conform to the preset input rules.

[0110] Optionally, the code management device A10 is further configured to:

[0111] Based on the issue identifier, determine the configuration file corresponding to the issue identifier, and determine the code repository keyword corresponding to the issue identifier;

[0112] Obtain the code repository path corresponding to the code repository keyword in the configuration file, and cache the patch code and the code repository path in the temporary area of ​​the code management device.

[0113] Optionally, the patch testing device A20 is further configured to:

[0114] Based on the problem identifier, determine the configuration file corresponding to the problem identifier;

[0115] According to the configuration file, the patch code corresponding to the problem identifier is extracted from the temporary area in the code management device.

[0116] Optionally, the patch testing device A20 is further configured to:

[0117] Obtain the source image file corresponding to the patch code;

[0118] The source image file and the patch code are compiled together to obtain the image file to be tested.

[0119] Configure the image file to be tested onto the corresponding application platform to obtain the client to be tested;

[0120] The verification command is triggered to perform a test operation on the client to be tested.

[0121] Optionally, the patch testing device A20 is further configured to:

[0122] Determine whether the patch code was successfully extracted;

[0123] If extraction fails, it is determined to be an illegal patch, and a prompt message corresponding to the illegal patch is pushed.

[0124] If the extraction is successful, proceed to the step of obtaining the source image file corresponding to the patch code.

[0125] The specific implementation of the multi-warehouse patch verification system of the present invention is basically the same as the embodiments of the multi-warehouse patch verification method described above, and will not be repeated here.

[0126] Furthermore, the present invention also proposes a code server, which includes a memory, a processor, and a multi-warehouse patch verification program stored on the memory and executable on the processor. When the processor executes the multi-warehouse patch verification program, it implements the steps of the multi-warehouse patch verification method as described in the above embodiments.

[0127] The specific implementation of the code server of the present invention is basically the same as the embodiments of the multi-warehouse patch verification method described above, and will not be repeated here.

[0128] Furthermore, the present invention also proposes a readable storage medium, characterized in that the readable storage medium can be a computer-readable storage medium, including a multi-warehouse patch verification program, which, when executed by a processor, implements the steps of the multi-warehouse patch verification method as described in the above embodiments.

[0129] The specific implementation of the computer-readable storage medium of the present invention is basically the same as the embodiments of the multi-warehouse patch verification method described above, and will not be repeated here.

[0130] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.

[0131] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes several instructions to cause a terminal device (which may be a code server, mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of the present invention.

[0132] In this invention, the terms "first," "second," "third," "fourth," and "fifth" are used for descriptive purposes only and should not be construed as indicating or implying relative importance. Those skilled in the art can understand the specific meaning of the above terms in this invention according to the specific circumstances.

[0133] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the present invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.

[0134] Although embodiments of the present invention have been shown and described above, the scope of protection of the present invention is not limited thereto. It is understood that the above embodiments are exemplary and should not be construed as limiting the present invention. Those skilled in the art can make changes, modifications, and substitutions to the above embodiments within the scope of the present invention, and such changes, modifications, and substitutions should all be covered within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims

1. A multi-warehouse patch verification method, characterized in that, The multi-repository patch verification method is applied to a code management device, and the multi-repository patch verification method includes the following steps: When patch information is received, verify whether the patch information conforms to the preset input rules; If the patch information conforms to the preset input rules, then the problem identifier and the patch code corresponding to the problem identifier are extracted from the patch information; The patch code is cached in the temporary area of ​​the code management device, and the problem identifier is sent to the patch testing device connected to the code management device, so that the patch testing device can test the patch code according to the problem identifier; The step of verifying whether the patch information conforms to the preset input rules includes: Determine whether patch code exists in the patch information; If the patch information contains patch code, then determine whether the patch information contains a problem identifier, submission instructions, and verification commands. If the patch information contains a problem identifier, submission instructions, and verification commands, then the patch information is determined to conform to the preset input rules. The step of caching the patch code to the temporary area in the code management device includes: Based on the issue identifier, determine the configuration file corresponding to the issue identifier, and determine the code repository keyword corresponding to the issue identifier; Obtain the code repository path corresponding to the code repository keyword in the configuration file, and cache the patch code and the code repository path in the temporary area of ​​the code management device.

2. A multi-warehouse patch verification method, characterized in that, The multi-warehouse patch verification method is applied to a patch testing device, and the multi-warehouse patch verification method includes: The system receives a problem identifier sent by a code management device. The problem identifier and the corresponding patch code are included in the patch information received by the code management device that conforms to preset input rules. Extract the patch code corresponding to the problem identifier from the temporary area in the code management device; The verification instructions associated with the patch code are determined in the patch information; The patch code is tested according to the verification instructions; After the step of retrieving the patch code corresponding to the problem identifier from the temporary area in the code management device, the method further includes: Determine whether the patch code was successfully extracted; If extraction fails, it is determined to be an illegal patch, and a prompt message corresponding to the illegal patch is pushed. If the extraction is successful, proceed to the step of obtaining the source image file corresponding to the patch code.

3. The multi-warehouse patch verification method as described in claim 2, characterized in that, The step of extracting the patch code corresponding to the problem identifier from the temporary area in the code management device includes: Based on the problem identifier, determine the configuration file corresponding to the problem identifier; According to the configuration file, the patch code corresponding to the problem identifier is extracted from the temporary area in the code management device.

4. The multi-warehouse patch verification method as described in claim 2, characterized in that, The step of testing the patch code according to the verification instruction includes: Obtain the source image file corresponding to the patch code; The source image file and the patch code are compiled together to obtain the image file to be tested. Configure the image file to be tested onto the corresponding application platform to obtain the client to be tested; The verification command is triggered to perform a test operation on the client to be tested.

5. A multi-warehouse patch verification system, characterized in that, The multi-warehouse patch verification system includes: A code management device is used to, upon receiving input patch information, verify whether the patch information conforms to preset input rules; if the patch information conforms to the preset input rules, extract the issue identifier and the patch code corresponding to the issue identifier from the patch information; cache the patch code in a temporary area of ​​the code management device, and send the issue identifier to a patch testing device connected to the code management device, so that the patch testing device can test the patch code according to the issue identifier; the step of verifying whether the patch information conforms to the preset input rules includes: determining whether patch code exists in the patch information; if patch code exists in the patch information, determining whether issue identifier, submission instructions, and verification instructions exist in the patch information; if issue identifier, submission instructions, and verification instructions exist in the patch information, determining that the patch information conforms to the preset input rules; the step of caching the patch code in a temporary area of ​​the code management device includes: determining the configuration file corresponding to the issue identifier and determining the code repository keyword corresponding to the issue identifier according to the issue identifier; obtaining the code repository path corresponding to the code repository keyword in the configuration file, and caching the patch code and the code repository path in a temporary area of ​​the code management device; A patch testing device is used to receive a problem identifier sent by a code management device. The problem identifier and the corresponding patch code are included in patch information received by the code management device and conforming to preset input rules. The device extracts the patch code corresponding to the problem identifier from a temporary area in the code management device. It determines a verification instruction associated with the patch code in the patch information. The device tests the patch code according to the verification instruction. After the step of extracting the patch code corresponding to the problem identifier from the temporary area in the code management device, the device further includes: determining whether the patch code extraction was successful; if extraction fails, it is determined to be an illegal patch, and a prompt message corresponding to the illegal patch is pushed; if extraction is successful, the device executes the step of obtaining the source image file corresponding to the patch code.

6. A code server, characterized in that, The code server includes a memory, a processor, and a multi-warehouse patch verification program stored in the memory and executable on the processor, wherein: when the multi-warehouse patch verification program is executed by the processor, it implements the steps of the multi-warehouse patch verification method as described in any one of claims 1 to 4.

7. A readable storage medium, characterized in that, The readable storage medium stores a multi-warehouse patch verification program, which, when executed by a processor, implements the steps of the multi-warehouse patch verification method as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • Software testing method, device and equipment and computer readable storage medium

    CN111782554A

  • Incremental source code collection method and device, electronic equipment and storage medium

    CN113126998A