CN111651189A - Product delivery method and device of continuous integration system and electronic equipment - Google Patents

Product delivery method and device of continuous integration system and electronic equipment Download PDF

Info

Publication number
CN111651189A
CN111651189A CN202010350589.3A CN202010350589A CN111651189A CN 111651189 A CN111651189 A CN 111651189A CN 202010350589 A CN202010350589 A CN 202010350589A CN 111651189 A CN111651189 A CN 111651189A
Authority
CN
China
Prior art keywords
package
product
integration system
delivery
backup server
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.)
Granted
Application number
CN202010350589.3A
Other languages
Chinese (zh)
Other versions
CN111651189B (en
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 Shiyuan Electronics Thecnology Co Ltd
Guangzhou Shirui Electronics Co Ltd
Original Assignee
Guangzhou Shiyuan Electronics Thecnology Co Ltd
Guangzhou Shirui Electronics 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 Shiyuan Electronics Thecnology Co Ltd, Guangzhou Shirui Electronics Co Ltd filed Critical Guangzhou Shiyuan Electronics Thecnology Co Ltd
Priority to CN202010350589.3A priority Critical patent/CN111651189B/en
Publication of CN111651189A publication Critical patent/CN111651189A/en
Application granted granted Critical
Publication of CN111651189B publication Critical patent/CN111651189B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1458Management of the backup or restore process
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/362Software debugging
    • G06F11/3624Software debugging by performing operations on the source code, e.g. via a compiler
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/30Computing systems specially adapted for manufacturing

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Quality & Reliability (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Stored Programmes (AREA)

Abstract

The embodiment of the application relates to a product delivery method and device of a continuous integration system and electronic equipment. The product delivery method of the continuous integrated system in the embodiment of the application comprises the following steps: acquiring a delivery state of a program package constructed by a continuous integration system, wherein the delivery state is used for indicating whether the program package is successfully uploaded to a product library; uploading the package to a backup server when the delivery status indicates that the package was not successfully uploaded to the artifact repository; and when a preset trigger condition is met, uploading the program package from the backup server to the product library. According to the product delivery method of the continuous integration system, when the product library is in a maintenance state or a disconnection state, connection between the continuous integration system and the product library is interrupted, and uploading of the program package to the product library fails, developers do not need to reconstruct a compiling task, and development efficiency of a software program is improved.

Description

Product delivery method and device of continuous integration system and electronic equipment
Technical Field
The embodiment of the application relates to the technical field of computer software development, in particular to a product delivery method and device of a continuous integration system and electronic equipment.
Background
Continuous integration is a software development practice, and each integration is verified by automated build (including compilation, release, automated testing) to discover integration errors as quickly as possible. This process can greatly reduce integration issues, enabling development teams to develop cohesive software programs more quickly.
The continuous integration system constructs a compiling task according to a compiling strategy formulated by a user, pulls codes from a code warehouse for compiling, packs the compiled codes to form a program package, and uploads the program package to a product library. In the conventional technology, when the continuous integration system finishes building a program package and uploading a product library fails, the program package is regarded as failed to build, and a compiling task needs to be built again, so that the workload of developers is increased, the waste of time resources is caused, and the program development efficiency is low.
Disclosure of Invention
The embodiment of the application provides a product delivery method and device for a continuous integration system and electronic equipment, when a product library is in a maintenance state or a disconnection state and the like, connection between the continuous integration system and the product library is interrupted, and uploading of a program package to the product library fails, developers do not need to rebuild a compiling task, so that workload is reduced, time resources are saved, and development efficiency of a software program is improved.
In a first aspect, an embodiment of the present application provides a product delivery method for a persistent integration system, where the method includes:
acquiring a delivery state of a program package constructed by a continuous integration system, wherein the delivery state is used for indicating whether the program package is successfully uploaded to a product library;
uploading the package to a backup server when the delivery status indicates that the package was not successfully uploaded to the artifact repository;
and when a preset trigger condition is met, uploading the program package from the backup server to the product library.
Optionally, the uploading the program package to a backup server includes:
acquiring attribute information of the program package and a hierarchical relationship between different attribute information;
generating a first storage path according to the hierarchical relationship, and generating a file directory name of a corresponding hierarchy in the first storage path according to each attribute information;
and uploading the program package to a first storage path in the backup server.
Optionally, the attribute information includes at least one of:
customer name, product model, program version, code branching.
Optionally, the uploading the package from the backup server to the product library further includes:
carrying out recursive detection on the file directory of the backup server to obtain a first storage path;
analyzing the first storage path to obtain the file directory name of each hierarchy in the first storage path;
obtaining a second storage path according to the file directory name of each hierarchy;
uploading the package from the first storage path to the second storage path in the artifact library.
Optionally, the step of determining whether the trigger condition is satisfied includes:
and confirming whether a preset timing task is started or not.
Optionally, when the delivery status indicates that the package is successfully uploaded to the product library, the method further includes:
and generating a download connection, wherein the download connection is used for acquiring the program package from the product library.
Optionally, the backup server is an FTP server.
Optionally, the FTP server is configured in a docker container.
In a second aspect, an embodiment of the present application provides a product delivery apparatus for a persistent integration system, the apparatus including:
the delivery state acquisition module is used for acquiring the delivery state of the program package constructed by the continuous integration system, and the delivery state is used for indicating whether the program package is successfully uploaded to the product library;
the backup module is used for uploading the program package to a backup server when the delivery state indicates that the program package is not successfully uploaded to the product library;
and the return module is used for uploading the program package from the backup server to the product library when a preset trigger condition is met.
In a third aspect, an embodiment of the present application provides an electronic device, including:
at least one memory and at least one processor;
the memory for storing one or more programs;
when executed by the at least one processor, the one or more programs cause the at least one processor to implement the steps of the product delivery method for the persistent integration system according to the first aspect of the embodiment of the present application.
In a fourth aspect, the present application provides a computer-readable storage medium, which stores a computer program, and the computer program, when executed by a processor, implements the steps of the product delivery method of the persistent integration system according to the first aspect of the present application.
In the embodiment of the application, by arranging the backup server, when the situation that the continuous integration system is unsuccessfully uploaded to the product library is detected, the program package is transferred to the backup server, and when the triggering condition is met, the program package is automatically uploaded to the product library from the backup server, so that the connection between the continuous integration system and the product library is interrupted when the product library is in a maintenance state, a broken line state or the like, and when the program package is unsuccessfully uploaded to the product library, the program package is stored in the backup server and automatically transmitted back to the product library, developers do not need to reconstruct a compiling task, the workload is reduced, the time resource is saved, and the development efficiency of software programs is improved.
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Drawings
FIG. 1 is a diagram illustrating a scenario of program development of a persistent integration system in the prior art;
FIG. 2 is a flow diagram of a method for product delivery for a persistent integration system provided in an exemplary embodiment;
FIG. 3 is a schematic diagram of a backup server provided in an exemplary embodiment;
FIG. 4 is a flow diagram providing in one exemplary embodiment for uploading packages to a backup server;
FIG. 5 is a flow diagram providing in one exemplary embodiment for uploading packages to a backup server;
FIG. 6 is a flow chart of configuring an FTP server provided in an exemplary embodiment;
FIG. 7 is a flow chart of a method of product delivery for a persistent integration system provided in an exemplary embodiment;
FIG. 8 is a schematic illustration of a product delivery apparatus of a continuously integrated system in an exemplary embodiment;
fig. 9 is a schematic structural diagram of an electronic device provided in an exemplary embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more clear, embodiments of the present application will be described in further detail below with reference to the accompanying drawings.
It should be understood that the embodiments described are only some embodiments of the present application, and not all embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments in the present application without any creative effort belong to the protection scope of the embodiments in the present application.
The terminology used in the embodiments of the present application is for the purpose of describing particular embodiments only and is not intended to be limiting of the embodiments of the present application. As used in the examples of this application and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.
When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the application, as detailed in the appended claims. In the description of the present application, it is to be understood that the terms "first," "second," "third," and the like are used solely to distinguish one from another and are not necessarily used to describe a particular order or sequence, nor are they to be construed as indicating or implying relative importance. The specific meaning of the above terms in the present application can be understood by those of ordinary skill in the art as appropriate.
Further, in the description of the present application, "a plurality" means two or more unless otherwise specified. "and/or" describes the association relationship of the associated objects, meaning that there may be three relationships, e.g., a and/or B, which may mean: a exists alone, A and B exist simultaneously, and B exists alone. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship.
As shown in fig. 1, fig. 1 is a schematic diagram of a program development scenario of a persistent integration system in an example of a conventional technology. In fig. 1, a developer connects to a remote server 200 through a computer 100, wherein a persistent integration system is running in the remote server 200, and the persistent integration system is used for compiling a source code into an executable file and integrating each separately developed module into a complete system, and in this embodiment, the persistent integration system may be a Jenkins platform.
After the developer is connected to the persistent integration system running in the remote server 200 through the computer 100, the developer may formulate a compiling strategy in the persistent integration system, construct a compiling task, pull and compile codes from a code repository, package the compiled codes into a program package, and upload the program package to the product library 300. The product library 300 may be a dedicated server, or in other examples, the product library may be part of the storage space in the remote server 200.
After the persistent integration system successfully uploads the package to the product library 300, a download link is returned, and the developer can download the package from the product library through the download link. When the network connection between the remote server 200 and the product library 300 is unstable, or the product library 300 is in a development and maintenance state, etc., the process of continuously uploading the package to the product library 300 by the integration system may fail. However, in the conventional technology, after the persistent integration system fails to upload the package to the product library 300, the developer needs to reconstruct the compilation task and recompile the code to generate the package, which results in waste of time and resources.
To solve the technical problem, the present application provides a product delivery method of a persistent integration system, as shown in fig. 2, and in an exemplary embodiment, the method includes the following steps:
s201: acquiring the delivery status of the program package built by the continuous integration system, wherein the delivery status is used for indicating whether the program package is successfully uploaded to the product library.
For a general persistent integration system, the production process of the package generally includes the steps of source code acquisition, source code inspection, source code compilation, testing, deployment, and the like.
The persistent integration system is used for compiling a source code into an executable file, i.e. a program package, and integrating each separately developed module into a complete system, and generally comprises the following functional modules:
and a version checking module: for obtaining code and other necessary files.
A source code checking module: for static analysis of the source code, possible errors are checked.
A source code compiling module: the source files are compiled by a compiler and linker to produce an executable file or library.
A test module: and testing the compiled program package to obtain a test result.
A deployment module: if the test passes, the package is uploaded to the product library as a final product.
In the embodiment of the application, the detection that the built program package is uploaded to the product library by the continuous integration system is added, and if the uploading fails, the delivery state indicates that the continuous integration system fails to successfully upload the built program package to the product library.
In some examples, the persistent integration system may also generate a download link for downloading the build package from the artifact library if successful upload of the build package to the artifact library by the persistent integration system is detected.
In some examples, the detection function of the delivery status may be implemented in an intermediate script file built in the persistent integration system.
S202: uploading the package to a backup server when the delivery status indicates that the package was not successfully uploaded to the artifact library.
The product library is a server used for storing the result of each construction of the continuous integration system, and in the embodiment of the application, after the program package is failed to be uploaded to the product library, the continuous integration system uploads the program package to a backup server which is deployed in advance for storage. In one example, the product library is the JFrog binary software product repository.
The backup server is used for temporarily storing the program package, the backup server may be a part of the storage space in the remote server where the persistent integration system is located, or a cloud server, in some examples, as shown in fig. 3, the backup server 400 may also be a separate computer device, and the remote server 200 where the persistent integration system is located is connected to the backup server 400.
In a preferred example, the backup server is a File Transfer Protocol (FTP) server, which is a TCP-based Protocol that uses a client/server model for transferring files between two computers. Through the FTP protocol, a user can upload or download files in the FTP server.
In some examples, after uploading the package to the backup server, the persistent integration system may further generate a download link for downloading the package from the backup server according to a storage address of the package in the backup server.
S203: and when a preset trigger condition is met, uploading the program package from the backup server to the product library.
In the embodiment of the application, when the preset trigger condition is met, the program package temporarily stored in the backup server is also automatically uploaded to the product library. The program packages in the backup server may be uploaded to the product library periodically, that is, the preset trigger condition is a timed trigger, and the timed trigger may be implemented by building a timed task in the persistent integration system. In other examples, the preset trigger condition may also be a user manual trigger.
In some examples, the persistent integration system further detects a connection relationship between the remote server where the persistent integration system is located and the product library, and uploads the program package from the backup server to the product library when the connection relationship is detected to be normal, that is, when a preset trigger condition is met.
The program package can be uploaded from the backup server to the product library through the persistent integration system, or a trigger condition can be set in the backup server, and the program package is automatically uploaded from the backup server to the product library by the backup server.
In the embodiment of the application, by arranging the backup server, when the situation that the continuous integration system is unsuccessfully uploaded to the product library is detected, the program package is transferred to the backup server, and when the triggering condition is met, the program package is automatically uploaded to the product library from the backup server, so that the connection between the continuous integration system and the product library is interrupted when the product library is in a maintenance state, a broken line state or the like, and when the program package is unsuccessfully uploaded to the product library, the program package is stored in the backup server and automatically transmitted back to the product library, developers do not need to reconstruct a compiling task, the workload is reduced, the time resource is saved, and the development efficiency of software programs is improved.
In an embodiment, as shown in fig. 4, the uploading the package to the backup server specifically includes the following steps:
s401: and acquiring the attribute information of the program package and the hierarchical relationship between different attribute information.
S402: and generating a first storage path according to the hierarchical relationship, and generating a file directory name of a corresponding hierarchy in the first storage path according to each attribute information, wherein the first storage path indicates a storage address of the program package in the backup server.
S403: and uploading the program package to a first storage path in the backup server.
In order to conveniently store and identify different program packages built by the persistent integration system each time, in the embodiment of the application, a storage path of each program package is further built according to the attribute information of each program package and the hierarchy between different attribute information, and each program package is stored according to the determined storage path.
The attribute information of the package is used to distinguish the package from other packages, and in one example, the attribute information includes at least one of the following attributes of the package: customer name, product model, program version, code branching. The program package can be conveniently identified through the attribute information.
The hierarchical relationship is a preset corresponding relationship between different attribute information, and usually, the attribute information of a high level may correspond to one or more attribute information of a low level, for example, a customer name as the attribute information of a high level and may correspond to one or more product models.
In the embodiment of the present application, first, attribute information of the program package and a hierarchical relationship between different attribute information are identified, then, a file directory name of a corresponding hierarchy in the first storage path is generated according to each attribute information, that is, a hierarchy and a name of a file directory in the first storage path are determined according to the hierarchy and the name of the attribute information of the program package, and then, the hierarchy and the name are combined with a path identifier of the backup server to generate the first storage path.
In some examples, the first storage path is created in the backup server when the first storage path does not exist in the backup server.
In a specific example, when the backup server is an FTP server, the attribute information of the package includes a client name AA1, a product model BB2, a program version CC3, and a code branch DD4, and the hierarchy of the attribute information is sequentially reduced, the first storage path generated according to the attribute information and the hierarchy relationship may be:
FTP://AA1/BB2/CC3/DD4。
in other examples, the first storage path may also be formed by combining attribute information of the package with other parameters.
In one embodiment, as shown in fig. 5, the uploading the package from the backup server to the product library includes:
s501: and carrying out recursive detection on the file directory of the backup server to obtain a first storage path.
S502: and analyzing the first storage path to obtain the file directory name of each hierarchy in the first storage path.
S503: and obtaining a second storage path according to the file directory name of each hierarchy, wherein the second storage path indicates the storage address of the program package in the product library.
S504: uploading the package from the first storage path to the second storage path in the artifact library.
In order to conveniently store and identify different program packages constructed by the persistent integration system each time, in the embodiment of the application, when the program packages are uploaded to the product library from the backup server, a storage path of each program package is also constructed according to the attribute information of each program package and the hierarchy between different attribute information, and each program package is stored according to the determined storage path.
In the embodiment of the present application, the backup server is first subjected to recursive detection, that is, hierarchical scanning detection is performed on the storage directories in the backup server to determine whether a package exists in each storage directory. When detecting that the first storage path has the program package, analyzing the first storage path to obtain the file directory name of each hierarchy in the first storage path, then determining the hierarchy and the name of the file directory in the second storage path according to the file directory name of each hierarchy in the first storage path and the hierarchy relation of each file directory, and combining the hierarchy and the name with the path identifier of the product library to generate the second storage path. Corresponding to the first storage path in the above embodiment, the second storage path may be: HTTP:// AA1/BB2/CC3/DD 4.
In some examples, when the second storage path does not exist in the product library, then the second storage path is created in the backup server.
In other examples, the second storage path may also be formed by combining the attribute information of the package with other parameters.
In the embodiment of the present application, the above operation of uploading the package from the backup server to the product library may be performed by a remote server operated by the persistent integration system, or may be performed by a server host operated by an FTP server.
In one embodiment, the FTP server is configured on a Linux server host using a docker container so that the FTP server can be ported to different platforms and operating systems. As shown in fig. 6, the configuration process of the FTP server includes the following steps:
s601: and installing a docker tool and a docker-composition tool on the Linux server host, and modifying the configuration file of the vsftpd.
S602: based on the docker-vsftpd image, a Dockerfile is written, the configuration file is copied to the new image, and the 20/22/30000:30050 port is exposed.
S603: and writing a docker-composition template file for programming and arranging an FTP container for starting a new mirror image, mapping an 8080 port of the FTP container and an 8080 port of a Linux server host, and specifying a package storage path needing to be mounted in the FTP container.
S604: starting the FTP container and establishing connection with the continuous integration system.
As shown in fig. 7, in one specific example, the product delivery method of the persistent integration system includes the steps of:
s701: acquiring the delivery state of the program package constructed by the continuous integration system, if the delivery state indicates that the program package is successfully uploaded to the product library, executing step S702, otherwise executing step S703.
S702: a download link is generated for downloading the package from the product library.
S703: acquiring the attribute information of the program package and the hierarchical relationship between different attribute information, generating a first storage path according to the hierarchical relationship, and generating a file directory name of a corresponding hierarchy in the first storage path according to each attribute information.
S704: and uploading the program package to a first storage path in the backup server.
S705: and when the timing trigger condition is met, carrying out recursive detection on the file directory of the backup server to obtain a first storage path.
S706: analyzing the first storage path to obtain a file directory name of each hierarchy in the first storage path, and obtaining a second storage path according to the file directory name of each hierarchy, wherein the second storage path indicates a storage address of the program package in the product library.
S707: uploading the package from the first storage path to the second storage path in the artifact library.
Corresponding to the product delivery method of the continuous integrated system, the embodiment of the application further provides a product delivery device of the continuous integrated system, by setting the backup server, when it is detected that the continuous integrated system fails to successfully upload the constructed program package to the product library, the program package is transferred to the backup server, and when the trigger condition is met, the program package is automatically uploaded to the product library from the backup server, so that the connection between the continuous integrated system and the product library is interrupted when the product library is in a maintenance state, or a broken line state, and the like, and when the uploading of the program package to the product library fails, the program package is stored in the backup server and automatically uploaded back to the product library, developers do not need to reconstruct a compiling task, thereby reducing workload, saving time resources, and improving the development efficiency of software programs.
Fig. 8 is a schematic structural diagram of a product delivery apparatus of a persistent integrated system according to an embodiment of the present application, and as shown in fig. 8, the product delivery apparatus 800 of the persistent integrated system includes:
a delivery status acquiring module 801, configured to acquire a delivery status of a package built by a persistent integration system, where the delivery status is used to indicate whether the package is successfully uploaded to a product library;
a backup module 802 for uploading the package to a backup server when the delivery status indicates that the package was not successfully uploaded to the product library;
a back-up module 803, configured to upload the program package from the backup server to the product library when a preset trigger condition is met.
In an exemplary embodiment, the backhaul module 803 includes:
the attribute information acquisition unit is used for acquiring the attribute information of the program package and the hierarchical relationship between different attribute information;
the first path generation unit is used for generating a first storage path according to the hierarchical relationship and generating a file directory name of a corresponding hierarchy in the first storage path according to each attribute information;
and the first uploading unit uploads the program package to a first storage path in the backup server.
In an exemplary embodiment, the attribute information includes at least one of:
customer name, product model, program version, code branching.
In an exemplary embodiment, the backhaul module 803 further includes:
the path detection unit is used for carrying out recursive detection on the file directory of the backup server to obtain a first storage path;
the path analysis unit is used for analyzing the first storage path to obtain the file directory name of each hierarchy in the first storage path;
the second path generating unit is used for obtaining a second storage path according to the file directory name of each hierarchy;
a second uploading unit, configured to upload the package from the first storage path to the second storage path in the product library.
In an exemplary embodiment, the backhaul module 803 includes:
and the timing confirmation unit is used for confirming whether the preset timing task is started or not.
In an exemplary embodiment, the backhaul module 803 includes:
and the download link generation unit is used for generating a download connection, and the download connection is used for acquiring the program package from the product library.
In an exemplary embodiment, the backup server is an FTP server.
In an exemplary embodiment, the FTP server is configured in a docker container.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
Corresponding to the product delivery method of the continuous integration system, the embodiment of the present application further provides an electronic device, where the intelligent device may be a computer device such as a computer or a server.
As shown in fig. 9, fig. 9 is a block diagram of an electronic device according to an exemplary embodiment of the present disclosure.
The electronic device 900 includes a processor 910 and a memory 920. The number of the processors 910 in the main control chip may be one or more, and one processor 910 is taken as an example in fig. 9. The number of the memories 920 in the main control chip may be one or more, and one memory 920 is taken as an example in fig. 9.
The memory 920 is used as a computer-readable storage medium for storing software programs, computer-executable programs, and modules, such as the program of the delivery method of the persistent integration system according to any embodiment of the present application, and program instructions/modules (e.g., the delivery status acquiring module 801, the backup module 802, the returning module 803, etc.) corresponding to the delivery method of the persistent integration system according to any embodiment of the present application. The memory 920 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required for at least one function; the storage data area may store data created according to use of the device, and the like. Further, the memory 920 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some examples, the memory 920 may further include memory located remotely from the processor 910, which may be connected to devices over a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The processor 910 executes various functional applications and data processing of the device by executing software programs, instructions and modules stored in the memory 920, so as to implement the product delivery method of the persistent integration system described in any of the above embodiments.
Specifically, in an exemplary embodiment, when the processor 910 executes one or more programs stored in the memory 920, the following operations are implemented:
acquiring a delivery state of a program package constructed by a continuous integration system, wherein the delivery state is used for indicating whether the program package is successfully uploaded to a product library;
uploading the package to a backup server when the delivery status indicates that the package was not successfully uploaded to the artifact repository;
and when a preset trigger condition is met, uploading the program package from the backup server to the product library.
On the basis of the above embodiment, the uploading the package to the backup server includes:
acquiring attribute information of the program package and a hierarchical relationship between different attribute information;
generating a first storage path according to the hierarchical relationship, and generating a file directory name of a corresponding hierarchy in the first storage path according to each attribute information;
and uploading the program package to a first storage path in the backup server.
On the basis of the above embodiment, the attribute information includes at least one of:
customer name, product model, program version, code branching.
On the basis of the above embodiment, the uploading the package from the backup server to the product library further includes:
carrying out recursive detection on the file directory of the backup server to obtain a first storage path;
analyzing the first storage path to obtain the file directory name of each hierarchy in the first storage path;
obtaining a second storage path according to the file directory name of each hierarchy;
uploading the package from the first storage path to the second storage path in the artifact library.
On the basis of the above embodiment, the step of confirming whether the trigger condition is satisfied includes:
and confirming whether a preset timing task is started or not.
On the basis of the above embodiment, when the delivery status indicates that the package is successfully uploaded to the product library, the method further comprises:
and generating a download connection, wherein the download connection is used for acquiring the program package from the product library.
On the basis of the above embodiment, the backup server is an FTP server.
On the basis of the above embodiment, the FTP server is disposed in a docker container.
The present application further provides a computer-readable storage medium, on which a computer program is stored, and the computer program, when executed by a processor, implements the product delivery method of the persistent integration system according to any one of the above embodiments.
The present invention may take the form of a computer program product embodied on one or more storage media including, but not limited to, disk storage, CD-ROM, optical storage, and the like, having program code embodied therein. Computer readable storage media, which include both non-transitory and non-transitory, removable and non-removable media, may implement any method or technology for storage of information. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of the storage medium of the computer include, but are not limited to: phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transmission medium may be used to store information that may be accessed by a computing device.
It is to be understood that the embodiments of the present application are not limited to the precise arrangements described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the embodiments of the present application is limited only by the following claims.
The above-mentioned embodiments only express a few embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the invention. It should be noted that, for those skilled in the art, variations and modifications can be made without departing from the concept of the embodiments of the present application, and these embodiments are within the scope of the present application.

Claims (11)

1. A method of product delivery for a continuously integrated system, the method comprising:
acquiring a delivery state of a program package constructed by a continuous integration system, wherein the delivery state is used for indicating whether the program package is successfully uploaded to a product library;
uploading the package to a backup server when the delivery status indicates that the package was not successfully uploaded to the artifact repository;
and when a preset trigger condition is met, uploading the program package from the backup server to the product library.
2. The method for product delivery of a persistent integration system as claimed in claim 1, wherein said uploading the package to a backup server comprises:
acquiring attribute information of the program package and a hierarchical relationship between different attribute information;
generating a first storage path according to the hierarchical relationship, and generating a file directory name of a corresponding hierarchy in the first storage path according to each attribute information;
and uploading the program package to a first storage path in the backup server.
3. The product delivery method for a persistent integration system as claimed in claim 2, wherein the attribute information includes at least one of:
customer name, product model, program version, code branching.
4. The method for product delivery of a persistent integration system as claimed in claim 2, wherein said uploading said package from said backup server to said product library further comprises:
carrying out recursive detection on the file directory of the backup server to obtain a first storage path;
analyzing the first storage path to obtain the file directory name of each hierarchy in the first storage path;
obtaining a second storage path according to the file directory name of each hierarchy;
uploading the package from the first storage path to the second storage path in the artifact library.
5. The product delivery method for a persistent integration system as claimed in claim 1, wherein the step of confirming whether the trigger condition is satisfied comprises:
and confirming whether a preset timing task is started or not.
6. The method for product delivery of a persistent integration system as claimed in claim 1, wherein when the delivery status indicates successful upload of the package to the product library, the method further comprises:
and generating a download connection, wherein the download connection is used for acquiring the program package from the product library.
7. The product delivery method for a continuously integrated system as claimed in claim 1, wherein:
the backup server is an FTP server.
8. The product delivery method for a continuous integrated system as claimed in claim 7, wherein:
the FTP server is arranged in the docker container.
9. A product delivery apparatus for a continuously integrated system, the apparatus comprising:
the delivery state acquisition module is used for acquiring the delivery state of the program package constructed by the continuous integration system, and the delivery state is used for indicating whether the program package is successfully uploaded to the product library;
the backup module is used for uploading the program package to a backup server when the delivery state indicates that the program package is not successfully uploaded to the product library;
and the return module is used for uploading the program package from the backup server to the product library when a preset trigger condition is met.
10. An electronic device, comprising:
at least one memory and at least one processor;
the memory for storing one or more programs;
the one or more programs, when executed by the at least one processor, cause the at least one processor to perform the steps of the method for product delivery of a persistent integration system as claimed in any of claims 1 to 8.
11. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the method for product delivery of a persistent integration system as claimed in any one of claims 1 to 8.
CN202010350589.3A 2020-04-28 2020-04-28 Product delivery method and device of continuous integrated system and electronic equipment Active CN111651189B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010350589.3A CN111651189B (en) 2020-04-28 2020-04-28 Product delivery method and device of continuous integrated system and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010350589.3A CN111651189B (en) 2020-04-28 2020-04-28 Product delivery method and device of continuous integrated system and electronic equipment

Publications (2)

Publication Number Publication Date
CN111651189A true CN111651189A (en) 2020-09-11
CN111651189B CN111651189B (en) 2023-09-12

Family

ID=72346543

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010350589.3A Active CN111651189B (en) 2020-04-28 2020-04-28 Product delivery method and device of continuous integrated system and electronic equipment

Country Status (1)

Country Link
CN (1) CN111651189B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114416163A (en) * 2021-12-27 2022-04-29 中国民航信息网络股份有限公司 Product management method, system, storage medium and electronic equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106874050A (en) * 2017-02-20 2017-06-20 郑州云海信息技术有限公司 A kind of system automatically updating method
CN108089945A (en) * 2017-12-08 2018-05-29 四川金英科技有限责任公司 A kind of method and system to guarantee data integrity under the conditions of database failure
CN108241493A (en) * 2018-01-09 2018-07-03 政采云有限公司 The automation continuous integrating of distributed software system and delivery method, device and system
CN109814901A (en) * 2018-12-29 2019-05-28 中兴智能交通股份有限公司 A kind of O&M method that automatically dispose application may be implemented

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106874050A (en) * 2017-02-20 2017-06-20 郑州云海信息技术有限公司 A kind of system automatically updating method
CN108089945A (en) * 2017-12-08 2018-05-29 四川金英科技有限责任公司 A kind of method and system to guarantee data integrity under the conditions of database failure
CN108241493A (en) * 2018-01-09 2018-07-03 政采云有限公司 The automation continuous integrating of distributed software system and delivery method, device and system
CN109814901A (en) * 2018-12-29 2019-05-28 中兴智能交通股份有限公司 A kind of O&M method that automatically dispose application may be implemented

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114416163A (en) * 2021-12-27 2022-04-29 中国民航信息网络股份有限公司 Product management method, system, storage medium and electronic equipment

Also Published As

Publication number Publication date
CN111651189B (en) 2023-09-12

Similar Documents

Publication Publication Date Title
US10841185B2 (en) Platform-integrated IDE
CN106528224B (en) Content updating method, server and system for Docker container
CN107608710B (en) Software project construction task configuration method and device based on Jenkins tool
US11442830B2 (en) Establishing and monitoring programming environments
CN110851167B (en) Container environment updating method, device, equipment and storage medium
CN109445837B (en) Application program publishing method and device
CN110673923A (en) XWIKI system configuration method, system and computer equipment
CN110784348A (en) Firmware upgrading method and device, electronic equipment and storage medium
CN109558318B (en) Code management method and code warehouse distributed system
CN111651352B (en) Warehouse code merging method and device
CN105653261A (en) Development integration test method and system on the basis of cloud computing environment
CN111831567B (en) Application test environment configuration method, device, system and medium
CN112860282A (en) Upgrading method and device of cluster plug-in and server
CN116069341A (en) Automatic deployment method, equipment and storage medium for application program
CN114237754A (en) Data loading method and device, electronic equipment and storage medium
US10698666B2 (en) Automatically building software projects
CN111651189A (en) Product delivery method and device of continuous integration system and electronic equipment
CN111552494B (en) Method, device, system and medium for managing container group
CN114090434B (en) Code debugging method and device, computer equipment and storage medium
CN111629200A (en) Method and device for rapidly detecting differential packet reliability and readable storage medium
CN114996955A (en) Target range environment construction method and device for cloud-originated chaotic engineering experiment
CN114895916A (en) Code deployment method, device, storage medium and electronic equipment
CN111400243B (en) Development management system based on pipeline service and file storage method and device
CN113934405A (en) Plug-in processing method, device, equipment, storage medium and computer program product
CN114240265B (en) Product deployment method and device based on mixed environment

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
GR01 Patent grant
GR01 Patent grant