A version automatic publishing method, device, computer equipment and storage medium
Through the scheduled task batch processing mechanism and asynchronous interface calls, the version release process is automated, which solves the problem of manual review occupying operation and maintenance manpower and low efficiency, improves version release efficiency and reduces risks.
Patent Information
- Application Number
- CN202210746259.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-29
- Publication Date
- 2025-09-23
- Estimated Expiration
- 2042-06-29
AI Technical Summary
The existing version release process relies on manual review and operation, resulting in high O&M manpower utilization and low efficiency.
A scheduled task batch processing mechanism is used to automatically obtain the status value of the version check item, determine the release requirements based on the status value, and automatically transfer the version to the deployment state when the conditions are met. The cerely asynchronous scheduled batch processing task mechanism is used to call the Wizard interface through the API, and the circuit breaker mechanism is combined to handle interface access violations.
The version release process is automated, which reduces manual operation and maintenance work, improves version checking and release efficiency, and reduces risks.
Smart Images

Figure CN115033277B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of version testing technology, and in particular to a version automatic publishing method, device, computer equipment and storage medium. Background Art
[0002] On the day of production release, it is necessary to review the various inspection items of the version to see if they meet the release requirements, such as whether the version is sealed and locked in the library, whether the regression test report is issued, whether the assembly line quality access control and code scanning are configured, etc. If all the inspection items meet the release requirements, the version will be handed over to the pending deployment state. In the prior art, on the day of version release, all the above-mentioned inspection items rely on manual intervention and review by operation and maintenance personnel, and after the review of each inspection item is completed, the operation and maintenance personnel manually transfer the version to the production environment on the pipeline to the pending deployment state. On the day of version release, due to the different regression completion times of various system versions, the operation and maintenance personnel need to respond and complete project inspections and production handover actions at all times, which greatly occupies the manpower of operation and maintenance, and the review and release efficiency is low. Summary of the Invention
[0003] The present invention provides a method, apparatus, computer equipment and storage medium for automatic version release, aiming to solve technical problems such as the existing manual version review and release, which occupy operation and maintenance manpower and have low efficiency.
[0004] In order to solve the above technical problems, the technical solution adopted by the present invention is:
[0005] A version automatic release method, comprising:
[0006] Use the scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released according to the set first frequency value;
[0007] Determine whether the version to be released meets the release requirements based on the status values of the various check items. If it meets the release requirements,
[0008] The scheduled task batch processing mechanism is used to capture the version to be released according to the set second frequency value, and the version to be released is automatically transferred to the ready-to-deploy state.
[0009] The technical solution adopted by the embodiment of the present invention also includes: the use of the scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released according to the set first frequency value is specifically:
[0010] Obtain inspection items for the version to be released, including quality access review and system regression test status;
[0011] Utilize the cerely asynchronous timed batch task mechanism, call the relevant interface of Wizard through the API, and capture the status value of each inspection item according to the set first frequency value, and the status value includes pass or fail.
[0012] The technical solution adopted by the embodiment of the present invention further includes: judging whether the to-be-released version meets the release requirements according to the status values of the respective check items is specifically as follows:
[0013] It is determined whether the status values of all the check items of the version to be released are passed. If the status values of all the check items are passed, it means that the version to be released meets the release requirements.
[0014] The technical solution adopted by the embodiment of the present invention further includes: using the scheduled task batch processing mechanism to capture the to-be-released version according to the set second frequency value is specifically:
[0015] The scheduled task batch process captures the version number of the to-be-released version that meets the release requirements at a set second frequency value;
[0016] Read the deployment environment name under the PRD link in the latest pipeline under each module of the version number, use the deployment environment name as an input parameter and call the Magic Wizard automatic transfer front-end interface;
[0017] Query the executable operations corresponding to the deployment environment under the deployment environment name, and call the actual execution interface with the automatic handover request as an input parameter according to the executable operation query result to trigger the production environment handover of the version to be released.
[0018] The technical solution adopted by the embodiment of the present invention further includes: automatically transferring the version to be released to the state to be deployed further includes:
[0019] When executing the automatic handover of the version to be released, determine whether the number of accesses to the Wizard interface in the current time period exceeds the set interface access upper limit. If it exceeds the set interface access upper limit, the fuse mechanism is used to perform fuse dormancy.
[0020] Another technical solution adopted by an embodiment of the present invention is: a version automatic publishing device, comprising:
[0021] Status value acquisition module: used to automatically obtain the status value of each check item in the version to be released according to the set first frequency value using the scheduled task batch processing mechanism;
[0022] Status value judgment module: used to judge whether the version to be released meets the release requirements according to the status values of the various check items;
[0023] Version release module: used for utilizing the scheduled task batch processing mechanism to capture the version to be released according to the set second frequency value, and automatically transferring the version to be released to the ready-to-deploy state.
[0024] The technical solution adopted in the embodiment of the present invention also includes: the status value acquisition module uses the scheduled task batch processing mechanism to automatically obtain the status value of each inspection item under the version to be released according to the set first frequency value, specifically: obtaining the inspection items of the version to be released, the inspection items including quality access control review and system regression test status; using the cerely asynchronous scheduled batch processing task mechanism, calling the relevant interface of Shenbing Wizard through the API, and capturing the status value of each inspection item according to the set first frequency value, the status value including pass or fail.
[0025] The technical solution adopted in the embodiment of the present invention also includes: the version release module uses the scheduled task batch processing mechanism to capture the version to be released according to the set second frequency value. Specifically: the scheduled task batch processing captures the version number of the version to be released that meets the release requirements with the set second frequency value; reads the deployment environment name under the PRD link in the latest pipeline under each module of the version number, takes the deployment environment name as an input parameter and calls the Wizard automatic handover front-end interface; queries the executable operation corresponding to the deployment environment under the deployment environment name, and calls the actual execution interface with the automatic handover request as an input parameter according to the executable operation query result, triggering the production environment handover of the version to be released.
[0026] Another technical solution adopted by an embodiment of the present invention is: a computer device, the computer device comprising:
[0027] a memory storing executable program code;
[0028] a processor connected to the memory;
[0029] The processor calls the executable program code stored in the memory to execute the above-mentioned version automatic publishing method.
[0030] Another technical solution adopted by an embodiment of the present invention is: a storage medium storing program instructions executable by a processor, wherein the program instructions are used to execute the above-mentioned version automatic publishing method.
[0031] The automatic version release method, apparatus, computer equipment, and storage medium of the embodiment of the present invention use a scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released, and judge whether the version to be released meets the release requirements based on the status value of the check item. If the release requirements are met, the scheduled task batch processing mechanism is used to automatically capture the version to be released and automatically transfer the version to be released to the ready-to-deploy state. The embodiment of the present invention optimizes the verification process of handing over to the production environment through process automation, and automatically completes the pipeline code configuration and regression test status, so that version development and testing can be better self-inspected. While reducing manual operation and maintenance operations, it improves the efficiency of version inspection and release, and effectively reduces version risks. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] Figure 1 1 is a flow chart of the method for automatically publishing a version according to the first embodiment of the present invention;
[0033] Figure 2 2 is a flow chart of a method for automatically publishing a version according to a second embodiment of the present invention;
[0034] Figure 3 This is a schematic diagram of the structure of the automatic version publishing device according to an embodiment of the present invention;
[0035] Figure 4 is a schematic diagram of the structure of a computer device according to an embodiment of the present invention;
[0036] Figure 5 It is a schematic diagram of the storage medium structure of an embodiment of the present invention. DETAILED DESCRIPTION
[0037] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.
[0038] The terms "first", "second" and "third" in the present invention are used only for descriptive purposes and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, a feature defined as "first", "second" and "third" may explicitly or implicitly include at least one of such features. In the description of the present invention, "multiple" means at least two, for example, two, three, etc., unless otherwise clearly and specifically defined. All directional indications in the embodiments of the present invention (such as up, down, left, right, front, back...) are only used to explain the relative positional relationship, movement, etc. between the components under a specific posture (as shown in the accompanying drawings). If the specific posture changes, the directional indication will also change accordingly. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units that are not listed, or may optionally include other steps or units inherent to these processes, methods, products or devices.
[0039] References herein to "embodiments" mean that a particular feature, structure, or characteristic described in connection with the embodiments may be included in at least one embodiment of the present invention. The appearance of this phrase in various places in the specification does not necessarily refer to the same embodiment, nor does it constitute a separate or alternative embodiment that is mutually exclusive of other embodiments. It is understood, both explicitly and implicitly, by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0040] See also Figure 1 , is a flow chart of the automatic version publishing method of the first embodiment of the present invention. The automatic version publishing method of the first embodiment of the present invention includes the following steps:
[0041] S100: Automatically obtain the status value of each check item in the version to be released according to the set first frequency value using the scheduled task batch processing mechanism;
[0042] In this step, the inspection items include quality access control review and system regression test status. The present invention uses the cerely asynchronous timed batch task mechanism to call the relevant interface of Magic Wizard through the API, and captures the status value of each inspection item according to the set first frequency value. The status value includes pass or fail.
[0043] S110: Determine whether the version to be released meets the release requirements based on the status values of each check item. If it meets the release requirements, execute S120;
[0044] In this step, the status values of each check item are used to determine whether the version to be released meets the release requirements. Specifically, the following steps are performed: determine whether the status values of all check items of the version to be released are passed. If the status values of all check items are passed, it means that the version to be released meets the release requirements.
[0045] S120: Using the scheduled task batch processing mechanism to capture the version to be released according to the set second frequency value, and automatically transferring the version to be released to the ready-to-deploy state;
[0046] The specific steps of using the scheduled task batch processing mechanism to capture the version to be released according to the set second frequency value are as follows: the scheduled task batch processing captures the version number of the version to be released that meets the release requirements at the set second frequency value; reads the deployment environment name under the PRD link in the latest pipeline under each module of the version number, takes the deployment environment name as the input parameter and calls the Wizard automatic transfer front-end interface; queries the executable operation corresponding to the deployment environment under the deployment environment name, and calls the actual execution interface with the automatic transfer request as the input parameter according to the executable operation query result, triggering the production environment transfer of the version to be released.
[0047] Based on the above, the automatic version release method of the first embodiment of the present invention uses a scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released, and determines whether the status values of all check items are passed. If the status values of all check items are passed, the scheduled task batch processing mechanism is used to automatically capture the version to be released, and automatically transfer the version to be released to the state to be deployed. The embodiment of the present invention optimizes the verification process of handing over to the production environment by means of process automation, and automatically completes the pipeline code configuration and regression test status, so that version development and testing can be better self-inspected, while reducing manual operation and maintenance operations, improving version inspection and release efficiency, and effectively reducing version risks.
[0048] See also Figure 2 , is a flow chart of the automatic version publishing method of the second embodiment of the present invention. The automatic version publishing method of the second embodiment of the present invention includes the following steps:
[0049] S200: Obtain version check items of the version to be released;
[0050] In this step, the version check items include but are not limited to version sealing and locking the library, system regression test report, quality access control review, and code scanning. According to the current status of the existing version release process, the embodiment of the present invention only takes the quality access control review and system regression test status as examples for specific explanation. Among them, the quality access control review means that the corresponding pipeline of the version has performed code security scanning and quality access control inspection, and all pipelines of the version must pass the review before they can be handed over for deployment. The system regression test status means that after the version completes the regression test, the regression status needs to be confirmed to be completed. It is an indicator after the version completes the regression test; whether the regression test is completed is determined based on whether the regression status is completed, so that the subsequent handover is performed. The end of the system regression test status is a necessary condition for the version to seal the board and lock the library.
[0051] S210: Use the scheduled task batch processing mechanism to automatically obtain the status value of each version check item;
[0052] In this step, the cerely asynchronous timed task mechanism is utilized to call the relevant interfaces of the Magic Wizard through the API (Application Program Interface), and the status values of each version check item are captured according to the set first frequency value. Among them, the embodiment of the present invention sets the first frequency value to 5 minutes / time, which can be set specifically according to the actual application scenario. The status values of each version check item include passed or failed. Among them, Magic Wizard is a one-stop IT R&D management platform. Magic Wizard integrates concepts such as agile and DevOps, and implements R&D management processes and security processes, realizing one-stop full-life cycle R&D management from demand proposal, development, testing, deployment, operation and maintenance, security management, process management, etc. Celery is an asynchronous task queue / job queue based on distributed messaging. The Celery framework consists of three parts: a message middleware (message broker) that stores tasks to be executed, a task execution unit (worker), and a task execution result store (backend-task result store). The Celery framework comes with a socket and is itself an independently running service. Start the Celery service to execute tasks in the service. The service has an object for executing tasks, which will execute the tasks that are ready and save the results of the tasks.
[0053] S220: Determine whether the status values of all version check items are passed. If yes, execute S230;
[0054] In this step, if the status values of all version check items are passed, it means that the version meets the release requirements. Conversely, if the status value of at least one check item is failed, it means that the version does not meet the release requirements.
[0055] S230: Using the scheduled task batch processing mechanism to capture all pending versions that meet the release requirements, and automatically transfer the pending versions to the ready-to-deploy state;
[0056] In this step, the scheduled task batch will capture the version number of the to-be-released version that meets the release requirements at the set second frequency value, read the deployment environment name under the PRD (Product Requirement Document) link in the latest pipeline under each module of the version number, and use the deployment environment name as an input parameter to call the Wizard automatic handover front-end interface, query the executable operations corresponding to the deployment environment, and use the automatic handover request as an input parameter to call the actual execution interface according to the executable operation results to trigger the handover of the production environment. Among them, in the embodiment of the present invention, the second frequency value for capturing the version number is set to 10 minutes / time, which can be set specifically according to the actual application scenario.
[0057] Furthermore, since the upper limit of the Shenbing Wizard control account access interface is 300 times / per minute, during the peak period of the regular version day (6-8 o'clock), multiple application scenarios such as obtaining the check item status value, version transfer and version deployment will appear at the same time. Each application scenario requires batch calling of the Shenbing Wizard interface, so it is extremely easy to trigger the call threshold, that is, exceed the access upper limit of the Shenbing Wizard interface. In order to avoid the Shenbing Wizard interface being unavailable due to the triggering of the call threshold, the embodiment of the present invention is also provided with a fuse mechanism, specifically: when the scheduled task batch execution version is automatically transferred, it is judged whether the access upper limit of the Shenbing Wizard interface in the current time period exceeds 300 times / per minute. If it exceeds 300 times / per minute, the fuse mechanism is used to perform fuse dormancy. Wherein, the fuse mechanism refers to a protection measure adopted in a software system to prevent the entire system from failing due to an overload phenomenon in the service due to some reasons.
[0058] Furthermore, scheduled batch processing of pending releases and their automatic transfer to the deployment-ready state are both asynchronously decoupled. This means that after capturing all pending releases that meet release requirements, an automatic transfer request is initiated. Upon receiving this request, the automatic transfer function responds, asynchronously processes the transfer task, and returns the transfer result. Furthermore, during peak business hours, the system receives significant traffic for the two scenarios of obtaining check item status values and automatic transfer results. To ensure system robustness, this embodiment of the present invention uses Celery to control and reduce the number of concurrent database requests, allowing the database sufficient time for data updates.
[0059] Based on the above, the automatic version release method of the second embodiment of the present invention uses a scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released, and determines whether the status values of all check items are passed. If the status values of all check items are passed, the scheduled task batch processing mechanism is used to automatically capture the version to be released, and automatically transfer the version to be released to the state to be deployed. The embodiment of the present invention optimizes the verification process of handing over to the production environment by means of process automation, and automatically completes the pipeline code configuration and regression test status, so that version development and testing can be better self-inspected, while reducing manual operation and maintenance operations, improving version inspection and release efficiency, and effectively reducing version risks.
[0060] In an optional implementation, it is also possible to upload the result of the automatic version publishing method to the blockchain.
[0061] Specifically, corresponding summary information is obtained based on the results of the automatic version publishing method. Specifically, the summary information is obtained by hashing the results of the automatic version publishing method, such as using the sha256s algorithm. Uploading the summary information to the blockchain ensures its security and fairness and transparency to users. Users can download the summary information from the blockchain to verify whether the results of the automatic version publishing method have been tampered with. The blockchain referred to in this example is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms. Blockchain is essentially a decentralized database, a string of data blocks generated using cryptographic methods. Each data block contains information about a batch of network transactions, which is used to verify the validity of the information (to prevent counterfeiting) and generate the next block. Blockchain can include the blockchain underlying platform, the platform product service layer, and the application service layer.
[0062] See also Figure 3 , is a schematic diagram of the structure of the automatic version publishing device according to an embodiment of the present invention. The automatic version publishing device 40 according to the embodiment of the present invention includes:
[0063] Status Value Acquisition Module 41: Utilizes a scheduled task batch processing mechanism to automatically acquire the status values of each check item for the pending release according to a pre-set first frequency. Status Value Acquisition Module 41 first acquires the check items for the pending release, including but not limited to version lockout, system regression test reports, quality control audits, and code scans. Based on the current state of the release process, this embodiment of the present invention uses the quality control audit and system regression test status as examples for specific descriptions. Quality control audits refer to the code security scans and quality control checks performed by the corresponding pipelines of a release. All pipelines must pass these audits before the release can be deployed. System regression test status refers to the completion of regression testing, which requires confirmation of the regression status. This status serves as a marker for the completion of regression testing. The completion of regression testing is determined based on whether the regression test has concluded, allowing for subsequent handover. The completion of the system regression test status is a prerequisite for version lockout. Utilizing the cerely asynchronous scheduled batch processing mechanism, the relevant interfaces of the Wizard are called via an API to capture the status values of each check item according to the pre-set first frequency. The status values can range from passed to failed. Celery is an asynchronous task queue / job queue based on distributed messaging. The Celery framework consists of three parts: a message broker that stores tasks to be executed, task execution units (workers), and a backend-task result store. The Celery framework comes with its own socket and is a standalone service. Starting the Celery service executes tasks within it. The service includes a task execution object that executes ready tasks and stores the results.
[0064] Status value judgment module 42: used to judge whether the version to be released meets the release requirements based on the status value of each check item; wherein, the status value judgment module 42 judges whether the status values of all check items of the version to be released are passed. If the status values of all check items are passed, it means that the version to be released meets the release requirements.
[0065] Version release module 43: used to use the scheduled task batch processing mechanism to capture the version to be released that meets the release requirements according to the set second frequency value, and automatically transfer the version to be released to the state to be deployed; wherein, the version release module 43 uses the scheduled task batch processing mechanism to capture the version to be released according to the set second frequency value specifically: using the scheduled task batch processing to capture the version number of the version to be released that meets the release requirements with the set second frequency value; reading the deployment environment name under the PRD link in the latest pipeline under each module of the version number, using the deployment environment name as an input parameter and calling the Wizard automatic transfer front-end interface; querying the executable operation corresponding to the deployment environment under the deployment environment name, and calling the actual execution interface with the automatic transfer request as an input parameter according to the executable operation query result, triggering the production environment transfer of the version to be released.
[0066] Furthermore, since the upper limit of the Shenbing Wizard control account access interface is 300 times / minute, during the peak period of the regular version day (6-8 o'clock), multiple application scenarios such as obtaining the status value of the check item, version transfer, and version deployment will appear at the same time. Each application scenario requires batch calling of the Shenbing Wizard interface, so it is extremely easy to trigger the call threshold, that is, exceed the access upper limit of the Shenbing Wizard interface. In order to avoid the interface being unavailable due to the triggering of the call threshold, the embodiment of the present invention is provided with a fuse mechanism, specifically: when the scheduled task batch execution version is automatically transferred, it is determined whether the access upper limit of the Shenbing Wizard interface in the current time period exceeds 300 times / minute. If it exceeds 300 times / minute, the fuse is folded and hibernated.
[0067] Furthermore, the scheduled task batch processing of the capture of the versions to be released and the automatic transfer to the state to be deployed are all done through asynchronous decoupling operations, that is, after all the versions to be released that meet the release requirements are captured, an automatic transfer request will be initiated, and the automatic transfer function will respond after receiving the request, and return the transfer result after asynchronously processing the transfer task. In addition, during business peak periods, the two major scenarios of obtaining the status value of the inspection item and the automatic transfer result have a large number of visits within the system. In order to ensure the robustness of the system itself, the embodiment of the present invention controls and reduces the concurrent requests to the database through celery (an asynchronous task queue / job queue based on distributed messaging) to give the database a certain amount of data update time.
[0068] The automatic version release device of the embodiment of the present invention uses a scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released, and determines whether the status values of all check items are passed. If the status values of all check items are passed, the scheduled task batch processing mechanism is used to automatically capture the version to be released, and automatically transfer the version to be released to the ready-to-deploy state. The embodiment of the present invention optimizes the verification process of handing over to the production environment by means of process automation, and automatically completes the pipeline code configuration and regression test status, so that version development and testing can be better self-inspected. While reducing manual operation and maintenance operations, it improves the efficiency of version inspection and release, and effectively reduces version risks.
[0069] See also Figure 4 , is a schematic diagram of the computer device structure according to an embodiment of the present invention. The computer device 50 includes:
[0070] A memory 51 storing executable program code;
[0071] a processor 52 connected to the memory 51;
[0072] The processor 52 is used to call the executable program code stored in the memory 51 and perform the following steps: using the scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released according to the set first frequency value; judging whether the version to be released meets the release requirements based on the status value of each check item; if the release requirements are met, using the scheduled task batch processing mechanism to capture the version to be released according to the set second frequency value, and automatically transferring the version to be released to the deployment state.
[0073] The processor 52 may also be referred to as a CPU (Central Processing Unit). The processor 52 may be an integrated circuit chip having signal processing capabilities. The processor 52 may also be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic device, a discrete gate or transistor logic device, or a discrete hardware component. The general-purpose processor may be a microprocessor or any conventional processor.
[0074] The computer equipment of the embodiment of the present invention uses a scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released, and determines whether the version meets the release requirements based on the status value. If the release requirements are met, the scheduled task batch processing mechanism is used to automatically capture the version to be released and automatically transfer the version to be released to the ready-to-deploy state. The embodiment of the present invention optimizes the verification process of handing over to the production environment through process automation, and automatically completes the pipeline code configuration and regression test status, allowing for better self-inspection of version development and testing. While reducing manual operations of operation and maintenance, it improves the efficiency of version inspection and release, and effectively reduces version risks.
[0075] See also Figure 5 , Figure 5 Schematic diagram of the structure of the storage medium of an embodiment of the present invention. The storage medium of the embodiment of the present invention stores a program file 61 capable of implementing the following steps: using a scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released according to a set first frequency value; judging whether the version to be released meets the release requirements based on the status value of each check item; if it meets the release requirements, using the scheduled task batch processing mechanism to capture the version to be released according to a set second frequency value, and automatically transferring the version to be released to the ready-to-deploy state. Among them, the program file 61 can be stored in the above-mentioned storage medium in the form of a software product, including several instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) or a processor to execute all or part of the steps of the method of each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program code, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, or a terminal device such as a computer, server, mobile phone, or tablet.
[0076] The storage medium of the embodiment of the present invention uses a scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released, and determines whether the release requirements are met based on the status value. If the release requirements are met, the scheduled task batch processing mechanism is used to automatically capture the version to be released and automatically transfer the version to be released to the ready-to-deploy state. The embodiment of the present invention optimizes the verification process of handing over to the production environment through process automation, and automatically completes the pipeline code configuration and regression test status, allowing for better self-inspection of version development and testing. While reducing manual operations of operation and maintenance, it improves the efficiency of version inspection and release, and effectively reduces version risks.
[0077] In the several embodiments provided by the present invention, it should be understood that the disclosed systems, devices, and methods can be implemented in other ways. For example, the system embodiments described above are merely illustrative. For example, the division of units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interface, device or unit, which can be electrical, mechanical or other forms.
[0078] In addition, the functional units in the various embodiments of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware or in the form of software functional units. The above is only an embodiment of the present invention and does not limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. A version automatic publishing method, characterized in that: include: Use the scheduled task batch processing mechanism to automatically obtain the status value of each check item under the version to be released according to the set first frequency value; Determine whether the version to be released meets the release requirements based on the status values of the various check items. If it meets the release requirements, Utilizing the scheduled task batch processing mechanism to capture the to-be-released version according to a set second frequency value, and automatically transferring the to-be-released version to a to-be-deployed state, wherein the scheduled task batch processing performs both the capturing of the to-be-released version and the automatic transfer to the to-be-deployed state through asynchronous decoupling operations; The method of using the scheduled task batch processing mechanism to capture the to-be-released version according to the set second frequency value is specifically as follows: The scheduled task batch process captures the version number of the to-be-released version that meets the release requirements at a set second frequency value; Read the deployment environment name under the PRD link in the latest pipeline under each module of the version number, use the deployment environment name as an input parameter and call the Magic Wizard automatic transfer front-end interface; Query the executable operations corresponding to the deployment environment under the deployment environment name, and call the actual execution interface with the automatic handover request as an input parameter according to the executable operation query result to trigger the production environment handover of the version to be released.
2. The method for automatically publishing a version according to claim 1, characterized in that: The method of automatically obtaining the status values of each check item under the version to be released according to the set first frequency value by using the scheduled task batch processing mechanism is specifically as follows: Obtain inspection items for the version to be released, including quality access review and system regression test status; Utilize the cerely asynchronous timed batch task mechanism, call the relevant interface of Wizard through the API, and capture the status value of each inspection item according to the set first frequency value, and the status value includes pass or fail.
3. The method for automatically publishing a version according to claim 2, characterized in that: The specific method of judging whether the to-be-released version meets the release requirements according to the status values of the various check items is as follows: It is determined whether the status values of all the check items of the version to be released are passed. If the status values of all the check items are passed, it means that the version to be released meets the release requirements.
4. The method for automatically publishing a version according to any one of claims 1 to 3, characterized in that: The automatically transferring the to-be-released version to the to-be-deployed state further includes: When executing the automatic handover of the version to be released, determine whether the number of accesses to the Wizard interface in the current time period exceeds the set interface access upper limit. If it exceeds the set interface access upper limit, the fuse mechanism is used to perform fuse dormancy.
5. A version automatic publishing device, the device is used to implement the steps of the version automatic publishing method according to any one of claims 1 to 4, characterized in that: include: Status value acquisition module: used to automatically obtain the status value of each check item in the version to be released according to the set first frequency value using the scheduled task batch processing mechanism; Status value judgment module: used to judge whether the version to be released meets the release requirements according to the status values of the various check items; Version release module: used for using the scheduled task batch processing mechanism to capture the version to be released according to the set second frequency value, and automatically transferring the version to be released to the ready-to-deploy state; The version release module uses the scheduled task batch processing mechanism to capture the version to be released according to the set second frequency value. Specifically: the scheduled task batch processing captures the version number of the version to be released that meets the release requirements with the set second frequency value; reads the deployment environment name under the PRD link in the latest pipeline under each module of the version number, takes the deployment environment name as the input parameter and calls the Wizard automatic handover front-end interface; queries the executable operation corresponding to the deployment environment under the deployment environment name, and calls the actual execution interface with the automatic handover request as the input parameter according to the executable operation query result, triggering the production environment handover of the version to be released.
6. The version automatic publishing device according to claim 5, characterized in that: The status value acquisition module uses the scheduled task batch processing mechanism to automatically obtain the status value of each inspection item under the version to be released according to the set first frequency value. Specifically: obtain the inspection items of the version to be released, and the inspection items include quality access control review and system regression test status; use the cerely asynchronous scheduled batch processing task mechanism to call the relevant interface of Shenbing Wizard through the API, and capture the status value of each inspection item according to the set first frequency value. The status value includes passed or failed.
7. A computer device, characterized in that: The computer device comprises: a memory storing executable program code; a processor connected to the memory; The processor calls the executable program code stored in the memory to execute the version automatic publishing method according to any one of claims 1 to 4.
8. A storage medium, characterized in that: Program instructions executable by a processor are stored, and the program instructions are used to execute the version automatic publishing method according to any one of claims 1 to 4.
Citation Information
Patent Citations
Complete software life cycle management method and platform based on DevOps
CN111443940A
Software development test method and device, equipment and medium
CN112363930A
Version release platform management method, device and equipment and storage medium
CN112445518A