CN115203051A - Software production line automatic detection method and device, equipment, medium and product thereof - Google Patents

Software production line automatic detection method and device, equipment, medium and product thereof Download PDF

Info

Publication number
CN115203051A
CN115203051A CN202210893726.7A CN202210893726A CN115203051A CN 115203051 A CN115203051 A CN 115203051A CN 202210893726 A CN202210893726 A CN 202210893726A CN 115203051 A CN115203051 A CN 115203051A
Authority
CN
China
Prior art keywords
branch
development
verification
branches
checking
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210893726.7A
Other languages
Chinese (zh)
Inventor
钟加濠
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangzhou Huanju Shidai Information Technology Co Ltd
Original Assignee
Guangzhou Huanju Shidai Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Huanju Shidai Information Technology Co Ltd filed Critical Guangzhou Huanju Shidai Information Technology Co Ltd
Priority to CN202210893726.7A priority Critical patent/CN115203051A/en
Publication of CN115203051A publication Critical patent/CN115203051A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/368Test management for test version control, e.g. updating test cases to a new software version
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites

Abstract

The application relates to a software assembly line automatic detection method, a device, equipment, a medium and a product thereof, wherein the method comprises the following steps: starting the latest version of the verification program; the checking program carries out checking on the development branches submitted to the test environment by each user in the corresponding pipeline according to the checking configuration information, and sends a notification message to the users of the corresponding development branches and interrupts the pipeline for merging the codes of all the development branches when the checking is not passed; when the software project passes the verification, comparing the pre-issued branch list with the development branches submitted to the test environment by each user, determining a difference branch list, acquiring the update version of the development branches in the difference branch list, and enabling all the development branches to form a legal branch set of the software project; and merging all development branches in the legal branch set to obtain a code set. The method and the device can automatically detect and debug the development branches in the assembly process of the assembly line of the software engineering, and can improve the implementation efficiency of the software engineering.

Description

Software production line automatic detection method and device, equipment, medium and product thereof
Technical Field
The present application relates to the field of software engineering technologies, and in particular, to a method for automatically detecting a software pipeline, and a corresponding apparatus, computer device, computer-readable storage medium, and computer program product.
Background
In the development process, in order to facilitate the maintenance and management of the development branches of the software project, the requirement that the branch names contain specific identifications enables all developers to better understand the contents of the branches (such as functional branch types, developers and online dates). And a set of reasonable merging process specifications can be formulated to ensure that new functions pass through all links of all production lines, and the stable and correct operation of the functions is ensured.
In process management, when a plurality of functions are simultaneously developed, a set of development process is usually formulated to solve the problem of cooperation disorder so as to ensure that the functions are similar to the flow line production, and the functions are orderly released as required through a series of steps of development, joint debugging, testing, acceptance inspection, online and the like. And the development branches are used as carriers in the links, and after the development of the functions is completed, codes are merged into specific branches and are issued to a development environment for joint debugging. And by analogy, the test environments are respectively issued to test personnel for system debugging, issuing to pre-issue for acceptance check, and finally issuing to the production environment according to an online plan.
Currently, these specifications and process control are performed by human hands. In the development process, branch naming is performed, and merging processes are observed by research and development personnel. Before a version needs to be released, a specific developer needs to manually record the branch to be released and notify the related developers to merge into the specific branch to ensure that the branch is not missed. After the release is completed, other still-developing personnel need to be informed to synchronize codes, so that the problems that the versions are too different to be combined and the like are avoided.
Particularly, in the process of testing and pre-releasing a software project, differences often occur due to insufficient detection means, so that a program obtained by a user is inconsistent with the expectation of research and development, and no one finds technical problems, so that a large amount of manpower and material resources are wasted and user experience is lost.
Disclosure of Invention
The present application aims to solve the above problems and provide a software pipeline automatic detection method and a corresponding device, computer equipment, computer readable storage medium, computer program product,
The technical scheme is adopted to adapt to various purposes of the application as follows:
in one aspect, a method for automatic detection of a software pipeline is provided, which comprises:
responding to the pipeline checking event, and starting the latest version of the checking program;
the checking program carries out checking on the development branches submitted to the test environment by each user in the corresponding pipeline according to the checking configuration information, and sends a notification message to the users of the corresponding development branches and interrupts the pipeline for merging the codes of all the development branches when the checking is not passed;
when the software project passes the verification, comparing the pre-issued branch list with the development branches submitted to the test environment by each user, determining a difference branch list, acquiring the update version of the development branches in the difference branch list, and enabling all the development branches to form a legal branch set of the software project;
and responding to the branch merging request, merging all development branches in the legal branch set, and obtaining a code set corresponding to the software project.
Optionally, in response to the pipeline check event, starting the latest version of the check program, including:
responding to a pipeline checking event, and starting a checking program, wherein the pipeline checking event is any one of a development branch submitting event, a merging request submitting event and a timing task triggering event;
and detecting the version of the self-checking program by the checking program, downloading the latest version when the version is laggard, and automatically starting the system after the latest version is installed.
Optionally, the verifying program performs verification on the development branch submitted to the test environment by each user in the corresponding pipeline according to the verification configuration information, including:
the verification program carries out verification on the names of development branches submitted to the test environment by each user according to branch naming rules in the verification configuration information, and when the verification fails, an exception is thrown out and the current pipeline is interrupted;
the verification program verifies the version information of the development branch submitted to the test environment by each user according to the branch synchronization rule in the verification configuration information, when the development branch is behind the main branch in the verification configuration information, the verification is determined to be failed, an exception is thrown out, and the current production line is interrupted;
and the verification program verifies the compatibility between the development branches submitted to the test environment by each user according to the branch merging rule in the verification configuration information, determines that the verification fails when incompatible development branches exist, throws an exception and interrupts the current pipeline.
Optionally, comparing the pre-release branch list with development branches submitted to the test environment by each user, determining a difference branch list, and obtaining an updated version of the development branches in the difference branch list, includes:
responding to a pre-release instruction corresponding to a pre-release environment, and acquiring a pre-release branch list, wherein the pre-release branch list comprises specified information of a plurality of development branches expected to be released;
searching a difference branch list formed by all difference branches which are not added to the pre-release branch list but are released to a test branch list corresponding to the test environment, and sending an updating notification message to a user corresponding to each development branch in the difference branch list;
and acquiring the development branches corresponding to the difference branches submitted in response to the update notification message as update versions, and updating the corresponding development branches in the pre-release branch list to enable all the development branches to form a legal branch set of the software project.
Optionally, responding to the branch merging request, merging all development branches in the legal branch set to obtain a code set corresponding to the software project, including:
creating a combined draft according to the draft creating identification contained in the verification configuration information;
and responding to the user confirmation instruction of the merged draft, merging all the development branches in the legal branch set, and obtaining a code set corresponding to the software project.
Optionally, after obtaining the code set corresponding to the software project, the method includes:
and generating a computer program product corresponding to the code set, and submitting the computer program product to an application store to realize program release.
In another aspect, a software pipeline automatic detection apparatus adapted for one of the purposes of the present application is provided, including: the check starting module is used for responding to the pipeline checking event and starting the check program with the latest version; the verification execution module is used for verifying the development branches submitted to the test environment by each user in the corresponding pipeline according to the verification configuration information by the verification program, sending a notification message to the users of the corresponding development branches when the verification is not passed, and interrupting the pipeline for merging the codes of all the development branches; the release verification module is used for comparing the pre-release branch list with the development branches submitted to the test environment by each user when the software project passes the verification, determining a difference branch list, acquiring the update version of the development branches in the difference branch list, and enabling all the development branches to form a legal branch set of the software project; and the merging execution module is used for responding to the branch merging request, merging all the development branches in the legal branch set, and obtaining a code set corresponding to the software project.
Optionally, the verification starting module includes: the response starting unit is used for responding to a pipeline checking event and starting a checking program, wherein the pipeline checking event is any one of a development branch submitting event, a merging request submitting event and a timing task triggering event; and the detection updating unit is used for detecting the version of the checking program by the checking program, downloading the latest version when the version is lagged behind, and then automatically starting the checking program after the latest version is installed.
Optionally, the check executing module includes: the first checking unit is used for checking the names of development branches submitted to the test environment by each user according to branch naming rules in the checking configuration information by the checking program, and throwing an exception and interrupting the current assembly line when the checking fails; the second checking unit is used for checking the version information of the development branch submitted to the test environment by each user according to the branch synchronization rule in the checking configuration information by the checking program, determining that the checking is not passed when the development branch lags behind the main branch in the checking configuration information, throwing an exception and interrupting the current pipeline; and the third checking unit is used for checking the compatibility of development branches submitted to the test environment by each user according to branch merging rules in the checking configuration information by the checking program, determining that the checking is not passed when incompatible development branches exist, throwing an exception and interrupting the current pipeline.
Optionally, the release checking module includes: the instruction response unit is used for responding to a pre-issued instruction corresponding to a pre-issued environment and acquiring a pre-issued branch list, wherein the pre-issued branch list comprises the specified information of a plurality of development branches expected to be issued; a difference searching unit, configured to search a difference branch list formed by all difference branches that are not added to the pre-release branch list but have been released to the test branch list corresponding to the test environment, and send an update notification message to a user corresponding to each development branch in the difference branch list; and the updating processing unit is used for acquiring the development branches corresponding to the difference branches submitted in response to the updating notification message as updating versions, updating the corresponding development branches in the pre-release branch list, and enabling all the development branches to form a legal branch set of the software project.
Optionally, the merge execution module includes: a draft creating unit, configured to create a merged draft according to a draft creating identifier included in the verification configuration information; and the project merging unit is used for responding to the user confirmation instruction of the merged draft, merging all the development branches in the legal branch set, and acquiring a code set corresponding to the software project.
Optionally, the merge execution module includes: and the project release module is used for generating a computer program product corresponding to the code set and submitting the computer program product to an application store to realize program release.
In yet another aspect, a computer device adapted for one of the purposes of the present application includes a central processing unit and a memory, the central processing unit being configured to invoke execution of a computer program stored in the memory to perform the steps of the software pipeline auto-detection method described herein.
In a further aspect, a computer-readable storage medium is provided, which stores a computer program implemented according to the software pipeline automatic detection method in the form of computer-readable instructions, and when the computer program is called by a computer, executes the steps included in the method.
In yet another aspect, a computer program product is provided to adapt another object of the present application, and includes computer program/instructions that when executed by a processor implement the steps of the software pipeline automatic detection method described in any one of the embodiments of the present application.
The present application has various advantages over the prior art, including but not limited to:
firstly, the verification program is implanted in the pipeline for program development and assembly of different development branches in advance to execute a verification link, so that multi-aspect standard full-process automatic detection of multiple development branches of a software project is realized, the assembly process of the software project is ensured to be smoother through the automatic pipeline, and the software assembly efficiency is improved.
Secondly, by implanting detection on development branches under two conditions of a test environment and a pre-release environment in the automatic detection process, the difference branches of the development side and the user side are effectively found, the updated version of the corresponding development branch is obtained in time, the consistency of the pre-release branch and the test branch is ensured, the user experience is ensured, and unnecessary debugging time cost is avoided being lost.
In addition, the automatic detection process has universality, can be universally used in various software engineering scenes, and can improve the development efficiency of software engineering.
Drawings
The above and/or additional aspects and advantages of the present application will become apparent and readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings of which:
fig. 1 is a schematic flowchart of an embodiment of an automatic detection method for a software pipeline according to the present application.
Fig. 2 is a schematic flow chart of a conventional verification implemented by a verification program in the embodiment of the present application.
Fig. 3 is a schematic flow chart illustrating a verification program implementing a pre-release environment verification according to an embodiment of the present application.
Fig. 4 is a schematic flow chart illustrating implementation of human-computer interaction according to verification configuration information to implement development branch merging in the embodiment of the present application.
FIG. 5 is a functional block diagram of the software pipeline automatic detection device of the present application;
fig. 6 is a schematic structural diagram of a computer device used in the present application.
Detailed Description
Reference will now be made in detail to embodiments of the present application, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the accompanying drawings are exemplary only for explaining the present application and are not construed as limiting the present application.
Unless specified in clear text, the neural network model referred to or possibly referred to in the application can be deployed in a remote server and used for remote call at a client, and can also be deployed in a client with qualified equipment capability for direct call.
The embodiments to be disclosed herein can be flexibly constructed by cross-linking related technical features of the embodiments unless the mutual exclusion relationship between the related technical features is stated in the clear text, as long as the combination does not depart from the inventive spirit of the present application and can meet the needs of the prior art or solve the deficiencies of the prior art. Those skilled in the art will appreciate variations therefrom.
The software pipeline automatic detection method can be programmed into a computer program product and is deployed in a client or a server to run.
In an application scenario of the present application, for example, the computer program product obtained according to the present application may be deployed in a distributed version control system (GIT), which is an open-source distributed version control system and can effectively and quickly process version management of projects from very small to very large. For ease of understanding, for each concept used in the GIT, a brief description follows:
CI (Continuous Integration), which refers to integrating code into a backbone through a pre-built pipeline frequently (several times a day) for the purpose of fast iteration while ensuring product quality; it is often required to pass automated testing to ensure stability of the integrated code.
CD (Continuous Delivery/Deployment), which can be viewed as the next step in the Continuous integration, refers to frequently delivering new versions of software to quality team or user testing. If the test passes, the code may be deployed to the production environment.
Assembly line: refers to the general term of business logic that performs CI/CD flow, through which persistent integration (CI) and/or persistent delivery (CD) may be implemented.
Joint debugging refers to a process of splitting corresponding functions of a software project into a plurality of modules, giving corresponding development branches to a plurality of research and development personnel for completion, and finally integrating the subdivided modules.
And the development environment is a system for internal research and development personnel to research and develop, debug and the like.
And the test environment is a system for providing test personnel to debug and accept the complete functional module or system.
And the pre-release environment gives the internal personnel to perform function acceptance to ensure that the program and the business process are correct and correct.
Production environment giving users access to the system for use.
And (4) checking program, namely a program for implementing the software pipeline automatic detection method obtained according to the application.
The program manager is mainly used for downloading, installing and updating the program of the verification program.
The following disclosure of various embodiments of the present application will be described with reference to various related concepts of the GIT system, but it should be understood that the present application can also be deployed in the same type of systems other than the GIT, without limitation.
Referring to fig. 1, in an embodiment of the present application, the method for automatically detecting a software pipeline includes the following steps:
step S1100, responding to a pipeline checking event, and starting a checking program of the latest version;
in the CI/CD pipeline, the verification program is implanted, and the verification program is realized to be used for implementing normative verification on the whole pipeline operation process and various materials thereof and can be triggered to be implemented in response to corresponding pipeline verification events.
To ensure timeliness, when a check program is initiated in response to a pipeline check event, a default setting is set to initiate the latest version of the check program.
In one embodiment, step S1100 may be implemented according to the following process, including the following specific steps:
step S1110, responding to a pipeline check event, and starting a check program, wherein the pipeline check event is any one of a development branch submission event, a merging request submission event and a timed task trigger event;
the pipeline check event may be triggered at multiple times, for example, when a development branch corresponding to any module is submitted by a corresponding development user, a corresponding development branch submission event is triggered, and the development branch submission event may be used as a pipeline check event for starting a pipeline. For another example, when any user submits a corresponding merge request with the intention of the pipeline to perform merging for each development branch, a merge request submission event is triggered, and the merge request submission event can be used as the pipeline check event. For another example, the pipeline may schedule a task by presetting a timing, and a timing task trigger event may be generated each time a timing arrives, and the timing task trigger event may be used as the pipeline check event. In addition, any computer event that causes the pipeline to run may cause the pipeline to respond by treating it as a pipeline check event, so as to pre-launch the check routine of the present application to perform a corresponding check for the pipeline.
After responding to the pipeline checking event, firstly starting an installed checking program, wherein the checking program is installed in advance, and the checking program can be the latest version or the historical version.
Step S1120, the checking program detects its own version, and downloads the latest version when the version is late, and then the system starts itself after installation.
The checking program realizes the self-checking service logic in advance, after the checking program is started, the corresponding process starts to execute the self-checking service logic, the latest version number corresponding to the checking program in the checking configuration information corresponding to the production line is obtained, then the latest version number is compared with the current version number of the current checking program, if the current version number is the same as the latest version number, the subsequent steps are continuously executed, if the current version number is behind the latest version number, the latest version of the checking program corresponding to the latest version number is correspondingly downloaded, automatic installation and automatic restart are carried out, and the checking program corresponding to the latest version number is ensured to be always operated to carry out checking on the production line after the checking event of the production line is responded.
The method has the advantages that the check program is ensured to be operated in the latest version all the time, the healthy operation of the production line can be effectively maintained, the latest requirements of the whole software project needing to be packaged by the production line can be reflected all the time through the check service logic in the latest version, and therefore the effective operation of the whole software project is ensured.
The verification configuration information may be transmitted to the verification program through a carrier, which may be in the form of a wildcard, a regular expression, a string, a JSON file, a CI/CD configuration file, and the like, by using an environment variable, an execution parameter, and/or a configuration file, where the verification configuration information may include relevant configurations required for implementing the automatic detection method of the present application, including but not limited to various matching rules, a switch state of a verification capability, and configuration items such as a key corresponding to invoking a third-party service, and so on, which are not repeated here.
Step S1200, the checking program checks the development branches submitted to the test environment by each user in the corresponding pipeline according to the checking configuration information, and sends a notification message to the users of the corresponding development branches and interrupts the pipeline for merging the codes of all the development branches when the checking is not passed;
the verification of the configuration information, in one embodiment, includes configuration of multifaceted specifications required for pipeline verification, and the specifications include, but are not limited to, a branch naming specification, a branch synchronization specification, a branch merging specification, a development flow specification, a release flow specification, a message notification specification, and the like. Each of the specifications, using one or more configuration items as described above, defines a corresponding rule for performing a corresponding verification task.
For example, a branch naming rule may be defined by combining a wildcard and a matching rule, and the branch naming rule is used to detect whether each development branch meets the branch naming specification, so that the branch naming specification is suitable for checking whether the name of the development branch is legal. For another example, any one or any multiple configuration items may be adopted to define a branch synchronization rule for detecting whether each development branch belongs to a synchronization version, so that the branch synchronization specification is suitable for checking the version coordination relationship between the development branches. For another example, a branch merging rule may be defined by combining a matching rule and a verification capability, and is used to detect whether each development branch is suitable for being merged with each other, so that the branch merging specification is suitable for verifying compatibility between the development branches.
In a similar manner, the development process specification, the release process specification, the message notification specification, and the like may be set in the verification configuration information, and corresponding configuration items are predefined for corresponding rules thereof, so as to finally form the verification configuration information to serve the operation of the pipeline.
After the latest version of the verification program is started, the verification configuration information can be read to obtain the rules corresponding to various specifications, and then the corresponding verification is carried out on each development branch according to the rules.
In one embodiment, referring to fig. 2, the verification may be performed by a process including the following steps:
step S1210, the verification program verifies the names of the development branches submitted to the test environment by each user according to branch naming rules in the verification configuration information, and when the verification fails, the exception is thrown out and the current pipeline is interrupted;
the checking program reads the configuration item corresponding to the branch naming specification from the checking configuration information, analyzes and obtains the branch naming rule, then detects the name of the development branch submitted to the testing environment by each user to judge whether the name accords with the branch naming rule, when the name accords with the branch naming rule, the checking is passed, and the subsequent steps can be continued; when the branch name rule is not met, the verification is not passed, the problem that the name of the corresponding development branch is incorrect is represented, so that the exception is directly thrown out, and the operation of the current pipeline is interrupted, so that the pipeline is restarted after the corresponding user corrects the exception.
Step S1220, the verification program verifies the version information of the development branch submitted to the test environment by each user according to the branch synchronization rule in the verification configuration information, when the development branch is behind the main branch in the verification configuration information, the verification is determined not to pass, an exception is thrown out, and the current pipeline is interrupted;
the verification program reads configuration items corresponding to the branch synchronization rules from the verification configuration information, analyzes the configuration items to obtain the branch synchronization rules, then identifies the version information of each development branch submitted to the test environment by each user, usually, the version number of one development branch is compared with the version number determined as a main branch, when the former lags behind the latter, the verification fails, a notification message can be sent to the development user of the former, so that the development user synchronizes the main branch to the local thereof to perform correction processing to resubmit the corresponding development branch, and at the moment, the exception can be thrown out and the current pipeline is relayed. When the check passes, the subsequent steps may be continued. By checking whether the current development branch lags behind the principal branch, the development branch can be ensured not to lag behind the principal branch, thereby avoiding subsequent serious version conflicts.
Step S1230, the verification program performs verification on compatibility between development branches submitted to the test environment by each user according to the branch merging rule in the verification configuration information, determines that the verification fails when there is an incompatible development branch, throws an exception, and interrupts the current pipeline.
The verification program reads the configuration items corresponding to the branch merging rules from the verification configuration information, analyzes and obtains the branch merging rules, and then verifies whether the development branches submitted to the test environment by each user are allowed to be merged with each other, specifically, whether each development branch is suitable for being merged to a target branch or is suitable for being merged with other branches according to a correct sequence is verified, if the development branches are not allowed to be merged with each other or cannot be merged according to a preset merging sequence, the verification is failed, a corresponding notification message is sent to the user of the corresponding development branch, an exception is thrown, and the current pipeline is interrupted. When the check passes, the subsequent steps are allowed to continue.
According to the embodiment corresponding to the exemplary implementation verification, the embodiment sequentially carries out deep layer-by-layer verification on each development branch through the branch naming rule, the branch synchronization rule and the branch merging rule, the legality of the development branches is systematically detected, each development branch entering the test environment is guaranteed to be a legal branch, the test environment is guaranteed to obtain effective development branch implementation tests, and therefore smooth production of software projects is guaranteed.
Step S1300, when the verification is passed, comparing the pre-issued branch list with the development branches submitted to the test environment by each user, determining a difference branch list, and acquiring the updated version of the development branches in the difference branch list to enable all the development branches to form a legal branch set of the software project;
in practice, even if a user successfully completes a test in a test environment, due to the absence or imperfection of a verification mechanism, a development branch consistent with the test environment cannot be obtained in a subsequent pre-release environment, so that in the automatic detection method, the step is added for performing consistency verification on the development branches of the pre-release environment and the test environment.
The method comprises the steps of obtaining a pre-release branch list corresponding to a pre-release environment, obtaining development branch sets submitted by users in the test environment, comparing the pre-release branch list with the development branch sets, finding out development branches with differences, generating difference information corresponding to the development branches, namely the difference branch lists, and obtaining update versions of the development branches required by the pre-release environment aiming at the difference branch lists again, wherein the update versions can be submitted by corresponding research and development users or by management users, and development branches which are not submitted to the pre-release environment in the test environment can be directly specified and submitted to the pre-release environment to realize version update. In the process, whether the update versions arrive is monitored by the checking program of the application, and when the update versions of all the differential development branches in the differential branch list arrive, a legal branch set required for constructing the software project is obtained for the pre-release environment.
It is easy to understand that a checking link is arranged between the test environment and the pre-release environment, so that the effects of checking defects and repairing leakage of necessary components of the pre-release environment can be realized, the development branch composition in the pre-release environment is consistent with the test environment, the assembly line can transfer all the development branches passing the test in the test environment to the pre-release environment for correct release, and the assembly line is ensured to smoothly assemble a computer program product of a corresponding software project.
And step S1400, responding to the branch merging request, merging all development branches in the legal branch set, and obtaining a code set corresponding to the software project.
After the verification of the development branch of the pre-release environment is completed, the draft of the merging request can be automatically generated according to the configuration item which is set in the verification configuration information and used for indicating the draft of the automatic creation merging request, so that research and development staff can clearly see the merging draft in the management information of the assembly line, and can confirm the merging draft subsequently to trigger the branch merging request.
When a branch merging request is triggered, in response to the request, the pipeline merges all development branches in the legal branch set, so that a code set corresponding to the software project is obtained, and a corresponding computer program product can be generated according to the code set.
In one embodiment, in order to complete the release of the software project, on the basis of the above embodiment, the following steps are further increased:
and S1500, generating a computer program product corresponding to the code set, and submitting the computer program product to an application store to realize program release.
Specifically, the code set may be compiled by calling a coding program, a corresponding computer program product is generated, the version information of the computer program product is marked, and then the computer program product is submitted to a release interface of a predetermined application store in the verification configuration information, and the computer program product is released to the corresponding application store, so that the computer program product is open to the public, and any user can download and install the computer program product from the application commodity conveniently.
From the above embodiments, it will be appreciated that the present application has a number of advantages, including but not limited to:
firstly, the verification program is implanted in the pipeline for program development and assembly of different development branches in advance to execute a verification link, so that multi-aspect standard full-process automatic detection of multiple development branches of a software project is realized, the assembly process of the software project is ensured to be smoother through the automatic pipeline, and the software assembly efficiency is improved.
Secondly, by implanting detection on development branches under two conditions of a test environment and a pre-release environment in the automatic detection process, the difference branches of the development side and the user side are effectively found, the updated versions of the corresponding development branches are obtained in time, the consistency of the pre-release branches and the test branches is ensured, the user experience is ensured, and unnecessary debugging time cost is avoided being lost.
In addition, the automatic detection process has universality, can be universally used in various software engineering scenes, and can improve the development efficiency of software engineering.
On the basis of any embodiment of the present application, referring to fig. 3, comparing a pre-release branch list with development branches submitted to a test environment by respective users, determining a difference branch list, and obtaining an updated version of the development branches in the difference branch list includes:
step 1310, responding to a pre-release instruction corresponding to a pre-release environment, and acquiring a pre-release branch list, wherein the pre-release branch list comprises the specified information of a plurality of development branches expected to be released;
usually, a pre-release branch list is maintained by a research and development agent, wherein the pre-release branch list comprises the specified information of each development branch to be released, and when the software project of the application needs to be released, a corresponding pre-release instruction can be issued to start a pre-release link of a production line.
In response to the pre-issued instruction, the checking program of the present application may directly read the pre-issued branch list, so as to perform corresponding checking on the pre-issued branch list.
Step S1320, searching a difference branch list formed by all difference branches which are not added to the pre-release branch list but are released to the test branch list corresponding to the test environment, and sending an update notification message to the user corresponding to each development branch in the difference branch list;
when the pre-release branch list is verified, the pre-release branch list is mainly compared with a development branch set formed by all development branches submitted to the test environment, that is, a test branch list, to find out a difference branch therein, where the difference branch, in this embodiment, refers to a development branch which has been released to the test environment but is not released to the pre-release branch list, that is, a development branch which passes the test but is not merged into the pre-release environment is found out, so as to obtain the difference branch list.
For each development branch in the difference branch list, an update notification message is sent to the development user corresponding to each development branch to notify each development user to confirm that the development branch is submitted with the update version, which may generally be determined to be the update version by the development branch version which has been submitted to the test environment and passed the test.
Step S1330, acquiring the development branch corresponding to the difference branch submitted in response to the update notification message as an updated version, and updating the corresponding development branch in the pre-release branch list, so that all the development branches form a legal branch set of the software project.
When a development user of a development branch in the difference branch list receives the update notification message and submits the corresponding difference branch corresponding to a specific development branch as an update version to the pre-release environment in response to the update notification message, the specified information of the update version is added to the pre-release branch list to complete the development branches in the pre-release branch list, and finally, after the update versions corresponding to the difference branches all arrive, all the development branches specified in the pre-release branch list of the pre-release environment form a legal branch set required by the software project and can be used for producing the code set corresponding to the software project.
According to the embodiment, the difference information of the development branches of the pre-release environment and the test environment is verified through the pre-release link of the verification program in the assembly line, the pre-release development branches can be checked for defects and omissions, disorder caused by the fact that the development branches of the test link and the release link are not unified is avoided, and the unification of the test effect and the user experience is ensured.
On the basis of any embodiment of the present application, referring to fig. 4, in response to a branch merging request, merging all development branches in the legal branch set to obtain a code set corresponding to a software project, includes:
step 1410, creating a merged draft according to the draft creation identifier contained in the verification configuration information;
the verification configuration information may be preset with a draft creation identifier for indicating that a merged draft is automatically generated after all development branches required by the pre-release environment pass verification of the verification program of the present application, and the merged draft is description information corresponding to an instruction for generating a merge request.
After the program of the application completes the verification of the pre-release branch list of the pre-release environment, the program recognizes that the draft creation identification is stored in the verification configuration information, and then automatically generates a combined draft according to the draft creation identification.
And step S1420, responding to the user confirmation instruction of the merged draft, merging all the development branches in the legal branch set, and obtaining a code set corresponding to the software project.
The merged draft can be browsed and confirmed by users with corresponding management authorities, when one user agrees to the description of the merged draft for confirmation, a corresponding user confirmation instruction is issued, the pipeline is responsible for merging all development branches in the legal branch set in response to the instruction, codes of all development branches belonging to the side branches flow to the main branch, the main branch and the related development branches are merged to obtain a code set corresponding to the software project, and the code set can be used for generating a corresponding computer program product.
According to the embodiment, the combined draft can be automatically generated after a series of verification is completed, the relevant users only need to execute the confirmation operation, the assembly of the code set can be automatically completed by the control pipeline, the labor cost required to be consumed is extremely low, and the software engineering implementation efficiency is greatly improved.
Referring to fig. 5, a software pipeline automatic detection apparatus adapted to one of the objectives of the present application is provided, which is a functional implementation of the software pipeline automatic detection method of the present application, and the apparatus includes: a verification start module 1100, configured to start a latest version of the verification program in response to a pipeline verification event; a verification execution module 1200, configured to implement, by the verification program, verification on development branches submitted to the test environment by each user in the corresponding pipeline according to the verification configuration information, send a notification message to the user of the corresponding development branch when verification fails, and interrupt the pipeline for merging codes of all development branches; the release verification module 1300 is configured to, when passing the verification, compare the pre-release branch list with development branches submitted to the test environment by each user, determine a difference branch list, obtain an updated version of the development branches in the difference branch list, and enable all the development branches to form a legal branch set of the software project; and the merge execution module 1400 is configured to respond to the branch merge request, merge all development branches in the legal branch set, and obtain a code set corresponding to the software project.
On the basis of any embodiment of the present application, the verification start module 1100 includes: the response starting unit is used for responding to a pipeline checking event and starting a checking program, wherein the pipeline checking event is any one of a development branch submitting event, a merging request submitting event and a timing task triggering event; and the detection updating unit is used for detecting the version of the checking program, downloading the latest version when the version is laggard, and automatically starting the checking program after the latest version is installed.
On the basis of any embodiment of the present application, the verification execution module 1200 includes: the first checking unit is used for checking the names of development branches submitted to the test environment by each user according to branch naming rules in the checking configuration information by the checking program, and throwing an exception and interrupting the current assembly line when the checking fails; the second checking unit is used for checking the version information of the development branch submitted to the test environment by each user according to the branch synchronization rule in the checking configuration information by the checking program, determining that the checking fails when the development branch lags behind the main branch in the checking configuration information, throwing an exception and interrupting the current production line; and the third checking unit is used for checking the compatibility of development branches submitted to the test environment by each user according to branch merging rules in the checking configuration information by the checking program, determining that the checking is not passed when incompatible development branches exist, throwing an exception and interrupting the current pipeline.
On the basis of any embodiment of the present application, the release verification module 1300 includes: the instruction response unit is used for responding to a pre-issued instruction corresponding to a pre-issued environment and acquiring a pre-issued branch list, wherein the pre-issued branch list comprises the specified information of a plurality of development branches expected to be issued; the difference searching unit is used for searching a difference branch list which is not added to the pre-release branch list but is released to all difference branches of the test branch list corresponding to the test environment, and sending an updating notification message to users corresponding to all development branches in the difference branch list; and the updating processing unit is used for acquiring the development branches corresponding to the difference branches submitted in response to the updating notification message as updating versions, updating the corresponding development branches in the pre-release branch list, and enabling all the development branches to form a legal branch set of the software project.
On the basis of any embodiment of the present application, the merge execution module 1400 includes: a draft creating unit, configured to create a merged draft according to a draft creating identifier included in the verification configuration information; and the project merging unit is used for responding to the user confirmation instruction of the merged draft, merging all the development branches in the legal branch set and obtaining a code set corresponding to the software project.
On the basis of any embodiment of the present application, the merge execution module 1400 includes: and the project release module is used for generating a computer program product corresponding to the code set and submitting the computer program product to an application store to realize program release.
In order to solve the technical problem, an embodiment of the present application further provides a computer device. As shown in fig. 6, the computer device includes a processor, a computer-readable storage medium, a memory, and a network interface connected by a system bus. The computer readable storage medium of the computer device stores an operating system, a database and computer readable instructions, the database can store control information sequences, and the computer readable instructions, when executed by the processor, can enable the processor to realize a commodity search category identification method. The processor of the computer device is used for providing calculation and control capability and supporting the operation of the whole computer device. The memory of the computer device may have stored therein computer readable instructions that, when executed by the processor, may cause the processor to perform the software pipeline auto-detection method of the present application. The network interface of the computer device is used for connecting and communicating with the terminal. Those skilled in the art will appreciate that the architecture shown in fig. 6 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In this embodiment, the processor is configured to execute specific functions of each module and its sub-module in fig. 5, and the memory stores program codes and various data required for executing the modules or the sub-modules. The network interface is used for data transmission to and from a user terminal or a server. The memory in this embodiment stores program codes and data required for executing all modules/sub-modules in the software pipeline automatic detection device of the present application, and the server can call the program codes and data of the server to execute the functions of all sub-modules.
The present application also provides a storage medium storing computer-readable instructions which, when executed by one or more processors, cause the one or more processors to perform the steps of the software pipeline auto-detection method of any of the embodiments of the present application.
The present application also provides a computer program product comprising computer programs/instructions which, when executed by one or more processors, implement the steps of the method as described in any of the embodiments of the present application.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments of the present application can be implemented by a computer program, which can be stored in a computer-readable storage medium, and when the computer program is executed, the processes of the embodiments of the methods can be included. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), or other computer readable storage medium, or a Random Access Memory (RAM).
To sum up, the method and the system can improve the implementation efficiency of the software project, effectively verify multi-aspect information of relevant development branches forming the software project in the software project release process, ensure smooth operation of a production line for assembling the software project, obtain a high-quality computer program product and ensure user experience.

Claims (10)

1. An automatic detection method for a software pipeline is characterized by comprising the following steps:
responding to a pipeline checking event, and starting a checking program of the latest version;
the checking program carries out checking on the development branches submitted to the test environment by each user in the corresponding pipeline according to the checking configuration information, and sends a notification message to the users of the corresponding development branches and interrupts the pipeline for merging the codes of all the development branches when the checking is not passed;
when the software project passes the verification, comparing the pre-issued branch list with the development branches submitted to the test environment by each user, determining a difference branch list, acquiring the update version of the development branches in the difference branch list, and enabling all the development branches to form a legal branch set of the software project;
and responding to the branch merging request, merging all development branches in the legal branch set, and obtaining a code set corresponding to the software project.
2. The method of claim 1, wherein initiating a latest version of the verification procedure in response to a pipeline check event comprises:
responding to a pipeline checking event, and starting a checking program, wherein the pipeline checking event is any one of a development branch submitting event, a merging request submitting event and a timing task triggering event;
and detecting the version of the self-checking program by the checking program, downloading the latest version when the version is laggard, and automatically starting the system after the latest version is installed.
3. The method of claim 1, wherein the verifying, by the verification program, the development branch submitted to the test environment by each user in the corresponding pipeline according to the verification configuration information comprises:
the verification program carries out verification on the names of development branches submitted to the test environment by each user according to branch naming rules in the verification configuration information, and when the verification fails, an exception is thrown out and the current pipeline is interrupted;
the verification program verifies the version information of the development branch submitted to the test environment by each user according to the branch synchronization rule in the verification configuration information, when the development branch is behind the main branch in the verification configuration information, the verification is determined to be failed, an exception is thrown out, and the current production line is interrupted;
and the verification program verifies the compatibility among the development branches submitted to the test environment by each user according to the branch merging rule in the verification configuration information, determines that the verification fails when incompatible development branches exist, throws out an exception and interrupts the current pipeline.
4. The method of claim 1, wherein comparing the pre-release branch list with development branches submitted to the testing environment by respective users to determine a difference branch list, and obtaining updated versions of the development branches in the difference branch list comprises:
responding to a pre-release instruction corresponding to a pre-release environment, and acquiring a pre-release branch list, wherein the pre-release branch list comprises specified information of a plurality of development branches expected to be released;
searching a difference branch list formed by all difference branches which are not added to the pre-release branch list but are released to a test branch list corresponding to the test environment, and sending an update notification message to a user corresponding to each development branch in the difference branch list;
and acquiring the development branches corresponding to the difference branches submitted in response to the update notification message as update versions, and updating the corresponding development branches in the pre-release branch list to enable all the development branches to form a legal branch set of the software project.
5. The method of claim 1, wherein in response to a branch merge request, merging all development branches in the legal branch set to obtain a code set corresponding to a software project, comprises:
creating a combined draft according to the draft creating identification contained in the verification configuration information;
and responding to the user confirmation instruction of the merged draft, merging all the development branches in the legal branch set, and obtaining a code set corresponding to the software project.
6. The method for automatically detecting the software pipeline according to any one of claims 1 to 5, wherein after obtaining the code set corresponding to the software item, the method comprises the following steps:
and generating a computer program product corresponding to the code set, and submitting the computer program product to an application store to realize program release.
7. An automatic detection device for a software assembly line is characterized by comprising:
the check starting module is used for responding to the pipeline checking event and starting the check program with the latest version;
the verification execution module is used for verifying the development branches submitted to the test environment by each user in the corresponding pipeline according to the verification configuration information by the verification program, sending a notification message to the users of the corresponding development branches when the verification is not passed, and interrupting the pipeline for merging the codes of all the development branches;
the release verification module is used for comparing the pre-release branch list with the development branches submitted to the test environment by each user when the software project passes the verification, determining a difference branch list, acquiring the update version of the development branches in the difference branch list, and enabling all the development branches to form a legal branch set of the software project;
and the merging execution module is used for responding to the branch merging request, merging all the development branches in the legal branch set, and obtaining a code set corresponding to the software project.
8. A computer device comprising a central processor and a memory, characterized in that the central processor is adapted to invoke execution of a computer program stored in the memory to perform the steps of the method according to any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that it stores a computer program implemented according to the method of any one of claims 1 to 6 in the form of computer-readable instructions, which, when invoked by a computer, performs the steps comprised by the corresponding method.
10. A computer program product comprising computer programs/instructions which, when executed by a processor, carry out the steps of the method of any one of claims 1 to 6.
CN202210893726.7A 2022-07-27 2022-07-27 Software production line automatic detection method and device, equipment, medium and product thereof Pending CN115203051A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210893726.7A CN115203051A (en) 2022-07-27 2022-07-27 Software production line automatic detection method and device, equipment, medium and product thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210893726.7A CN115203051A (en) 2022-07-27 2022-07-27 Software production line automatic detection method and device, equipment, medium and product thereof

Publications (1)

Publication Number Publication Date
CN115203051A true CN115203051A (en) 2022-10-18

Family

ID=83583802

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210893726.7A Pending CN115203051A (en) 2022-07-27 2022-07-27 Software production line automatic detection method and device, equipment, medium and product thereof

Country Status (1)

Country Link
CN (1) CN115203051A (en)

Similar Documents

Publication Publication Date Title
US20040060035A1 (en) Automated method and system for building, deploying and installing software resources across multiple computer systems
CN108829409B (en) Distributed system rapid deployment method and system
US9575739B2 (en) Performing unattended software installation
CN106708740B (en) Script testing method and device
CN107844343B (en) Upgrading system and method for complex server application system
CN112527349A (en) Dynamic deployment strategy optimization and continuous deployment service guarantee system
CN110096424B (en) Test processing method and device, electronic equipment and storage medium
CN111158708A (en) Task arrangement engine system
CN111580926A (en) Model publishing method, model deploying method, model publishing device, model deploying device, model publishing equipment and storage medium
CN112131315A (en) Database synchronization method and device under multi-task parallel development
CN113434158A (en) User-defined management method, device, equipment and medium for big data component
CN115203051A (en) Software production line automatic detection method and device, equipment, medium and product thereof
CN111831567A (en) Application test environment configuration method, device, system and medium
CN115437682B (en) Application development management system under ABAP development environment
CN112231231B (en) Cloud service debugging method, system and device
CN114385504A (en) Development and debugging method and device for microservice application
CN114936152A (en) Application testing method and device
CN113821228A (en) Method for building ROS or ROS-like project based on layered container mirror image
CN117130987B (en) Flight control management method for large-scale unmanned aerial vehicle cluster
CN114443292B (en) Client management method, device and system based on workflow task scheduling system
CN113672269B (en) Data processing method, system, electronic device and program product
CN112148463B (en) Business process control method and device
CN117149259A (en) Application configuration library creation method, application release method and device and electronic equipment
CN116974716A (en) Scheduling task issuing method and device, electronic equipment and storage medium
CN112286533A (en) Thermal restoration method and device for cloud service

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination