Assembly line configuration method and device, electronic equipment and storage medium

By providing a visual editor and a method for generating script files from templates for the Jenkins pipeline configuration interface, the problem of difficult configuration in the existing technology is solved, and intuitive configuration and efficient pipeline task management without the need for scripting are achieved.

CN120803434APending Publication Date: 2025-10-17CHINA UNICOM SMART CONNECTION TECH LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510896862.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-30
Publication Date
2025-10-17

AI Technical Summary

Technical Problem

The existing Jenkins pipeline configuration requires scripting, which makes configuration difficult and has a high learning threshold for non-developers, and lacks intuitive visual display.

Method used

Provides a pipeline configuration interface, displays the configuration interface through a visual editor, obtains pipeline configuration data and templates, generates script files, and simulates running in a virtual environment to detect errors, reducing user configuration difficulty and improving flexibility.

Benefits of technology

It eliminates the need for users to manually write scripts, reduces configuration difficulty, improves the flexibility and success rate of pipeline configuration, and provides intuitive configuration result feedback.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120803434A_ABST
    Figure CN120803434A_ABST
Patent Text Reader

Abstract

The invention discloses an assembly line configuration method and device, electronic equipment and a storage medium, and belongs to the technical field of computers. The assembly line configuration method comprises the steps of displaying an assembly line configuration interface in response to an assembly line configuration request; in response to a configuration operation of a user for the assembly line configuration interface, obtaining assembly line configuration data and a configuration template; generating a script file according to the assembly line configuration data and the configuration template; and running an assembly line task corresponding to the assembly line configuration request based on the script file. The assembly line configuration method can reduce the assembly line configuration difficulty of a user and improve the assembly line configuration flexibility.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer, in particular to a pipeline configuration method and device, electronic equipment and computer readable storage medium. BACKGROUND

[0002] At present, the Jenkins pipeline is usually configured in a "code as code" manner, and the developer needs to write a Jenkinsfile script in the repository. Although this configuration method can realize flexible configuration of the Jenkins pipeline, it has a high learning threshold for non-developers, and the configuration is difficult, and this configuration method cannot provide intuitive visual display. SUMMARY

[0003] Therefore, the present application provides a pipeline configuration method to solve the problem of high configuration difficulty caused by the need to write scripts in the prior art.

[0004] In order to achieve the above purpose, the first aspect of the present application provides a pipeline configuration method, which comprises: displaying a pipeline configuration interface in response to a pipeline configuration request; obtaining pipeline configuration data and a configuration template in response to a user's configuration operation on the pipeline configuration interface; generating a script file according to the pipeline configuration data and the configuration template; and running a pipeline task corresponding to the pipeline configuration request based on the script file.

[0005] Optionally, the pipeline configuration interface comprises a plurality of candidate touch controls, and the candidate touch controls correspond to configuration stages of a pipeline task corresponding to the pipeline configuration request; obtaining pipeline configuration data and a configuration template in response to a user's configuration operation on the pipeline configuration interface comprises: displaying a target configuration stage corresponding to a target touch control in the plurality of candidate touch controls on the pipeline configuration interface in response to the user's touch operation on the target touch control; displaying pipeline configuration data corresponding to the target configuration stage on the pipeline configuration interface in response to the user's data addition operation on the target configuration stage; and obtaining the target configuration stage and the pipeline configuration data corresponding to the target configuration stage, and generating a configuration template based on the target configuration stage, in the case of receiving a configuration completion instruction on the pipeline configuration interface.

[0006] Optionally, the pipeline configuration interface comprises a project type component for representing a project configuration type of a pipeline task supported by the pipeline configuration interface; in response to a configuration operation of a user on the pipeline configuration interface, the pipeline configuration data and the configuration template are obtained by: in response to a selection operation of the user on the project type component in the pipeline configuration interface, determining the project configuration type selected by the user; in response to a text editing operation of the user in the pipeline configuration interface, obtaining the text input by the user; analyzing the text to obtain the pipeline configuration data; and obtaining the configuration template from a template library according to the project configuration type and the pipeline configuration data.

[0007] Optionally, after displaying the pipeline configuration interface, the method further comprises: in response to a selection operation of a user on a project type component in the pipeline configuration interface, determining a project configuration type to which the pipeline task belongs; according to the project configuration type, obtaining a project code of a project to which the pipeline task belongs and a historical pipeline task associated with the project; according to the project code and the historical pipeline task, determining a to-be-recommended configuration stage and to-be-recommended configuration data; and displaying the to-be-recommended configuration stage and the to-be-recommended configuration data in the form of a touch control in the pipeline configuration interface.

[0008] Optionally, the method further comprises: obtaining a running result of the pipeline task at a target configuration stage in a running process, wherein the target configuration stage is configured by the user in the pipeline configuration interface; and displaying the running result of the target configuration stage in a result visualization interface.

[0009] Optionally, after generating the script file according to the pipeline configuration data and the configuration template, the method further comprises: simulating running of the pipeline task in a virtual running environment based on the script file to obtain a simulation running result of the pipeline task; and determining configuration error data in the script file according to the simulation running result.

[0010] Optionally, after running the pipeline task corresponding to the pipeline configuration request based on the script file, the method further comprises: in the case that the pipeline task runs successfully, saving the configuration template to a template library.

[0011] Optionally, the pipeline task comprises any one of a micro-service task, a front-end application task and a build dependent library task.

[0012] In a second aspect, the present application provides a pipeline configuration apparatus, comprising: a display module configured to display a pipeline configuration interface in response to a pipeline configuration request; an acquisition module configured to acquire pipeline configuration data and a configuration template in response to a configuration operation of a user on the pipeline configuration interface; a generation module configured to generate a script file according to the pipeline configuration data and the configuration template; and a running module configured to run a pipeline task corresponding to the pipeline configuration request based on the script file.

[0013] In a third aspect, the present application provides an electronic device, comprising: one or more processors; a memory having one or more programs stored thereon, when the one or more programs are executed by the one or more processors, the one or more processors implement the pipeline configuration method; and one or more I / O interfaces connected between the processor and the memory, configured to implement information interaction between the processor and the memory.

[0014] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, when the computer program is executed by a processor, the pipeline configuration method is implemented.

[0015] The present application has the following advantages: in response to a pipeline configuration request initiated by a user, a pipeline configuration interface is provided and displayed for the user, so that the user can perform an operation on the pipeline configuration in the pipeline configuration interface. In response to a configuration operation of the user on the pipeline configuration interface, pipeline configuration data and a configuration template are acquired, so that a corresponding script file can be generated according to the pipeline configuration data and the configuration template, and a pipeline task corresponding to the pipeline configuration request is run based on the generated script file. By visually displaying the pipeline configuration interface for the user, the user can directly perform a visual configuration operation on the pipeline configuration interface, and a script file is generated, without the user having to write a script, thereby reducing the difficulty of the user configuring the pipeline and improving the flexibility of configuring the pipeline.

[0016] It should be understood that the content described in this part is not intended to identify key or important features of the embodiments of the present application, nor to limit the scope of the present application. Other features of the present application will become apparent from the following description. BRIEF DESCRIPTION OF DRAWINGS

[0017] The accompanying drawings are included to provide a further understanding of the present application, and constitute a part of the specification, illustrate embodiments of the present application, and are used to explain the present application, and do not constitute a limitation of the present application. The above and other features and advantages will become more apparent from the description of the detailed example embodiments, with reference to the accompanying drawings, in which:

[0018] Figure 1 A schematic diagram of an application of a pipeline configuration method provided by an embodiment of the present invention;

[0019] Figure 2 A flowchart of a pipeline configuration method provided by an embodiment of the present invention;

[0020] Figure 3 A block diagram of a pipeline configuration device provided by an embodiment of the present invention;

[0021] Figure 4 A block diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0022] The following describes the specific embodiments of the present invention in detail with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are only used to illustrate and explain the present invention and are not intended to limit the present invention.

[0023] As used herein, the term "and / or" includes any and all combinations of one or more of the associated listed items.

[0024] The terms used in the present invention are only used to describe specific embodiments and are not intended to limit the present invention. As used in the present invention, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.

[0025] When the terms "comprising" and / or "made of..." are used in the present invention, it specifies the existence of the stated features, integers, steps, operations, elements and / or components, but does not preclude the existence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof.

[0026] Unless otherwise defined, all terms (including technical and scientific terms) used in the present invention have the same meaning as commonly understood by those skilled in the art. It will also be understood that terms such as those defined in commonly used dictionaries should be interpreted as having a meaning consistent with their meaning in the context of the relevant art and the present invention, and will not be interpreted as having an idealized or overly formal meaning unless expressly defined in the present invention.

[0027] In a first aspect, an embodiment of the present invention provides a pipeline configuration method, see Figure 1 , Figure 1 The application diagram of a pipeline configuration method provided by an embodiment of the present invention is shown in FIG. The pipeline configuration method provided by an embodiment of the present invention can be applied to Figure 1The system shown includes a visual editor, a template library, a template engine module, a pipeline generation module and a preview debugging module. The visual editor is available for users to perform visual editing operations for realizing visual configuration of the pipeline; the template library is used to store configuration templates, the configuration templates are used to generate script files corresponding to the pipeline, the configuration templates are composed of a plurality of reusable function modules, and the function modules include but are not limited to code checkout modules, compiling modules, testing modules, scanning modules, image building modules and the like; the template engine module is used to obtain pipeline configuration data and configuration templates, and generate script files based on the pipeline configuration data and the configuration templates; the pipeline generation module is used to run pipeline tasks based on the script files; the preview debugging module is used to obtain running results in different configuration stages in the running process of the pipeline tasks, and feed back the running results to the user, and provide a virtual running environment to simulate running of the generated script files, determine configuration error data existing in the script files, and facilitate debugging of the script files. The pipeline configuration method provided in the embodiment of the application can be applied to a continuous integration / continuous delivery scene, for example, a configuration scene of a Jenkins pipeline. Jenkins is a Java-based open source automation server, and is used to build, test and deploy software projects.

[0028] The embodiment of the application can provide and display a pipeline configuration interface for the user through the visual editor, so that the user can perform visual configuration operations in the pipeline configuration interface, and can also recommend corresponding configuration templates for the user from the template library, obtain pipeline configuration data configured by the user through the template engine module, and generate script files according to the pipeline configuration data and the configuration templates. The pipeline generation module can run pipeline tasks based on the script files. In this process, the user does not need to manually write script files, thereby reducing the difficulty of pipeline configuration for the user. Further, the running results in different configuration stages in the running process of the pipeline tasks can be obtained based on the preview debugging module, and the running results are fed back to the user, so that the user can know the running results of the pipeline tasks in real time.

[0029] Referring to Figure 2 , Figure 2 A flowchart of a pipeline configuration method provided by the embodiment of the application is shown, and specifically includes the following steps:

[0030] Step 202: In response to a pipeline configuration request, a pipeline configuration interface is displayed.

[0031] The pipeline configuration request is a request initiated by a user for displaying a pipeline configuration interface on a user terminal. The pipeline configuration interface is a visual interface for user-defined configuration of a configuration stage of a pipeline task and pipeline configuration data. A plurality of candidate touch controls are displayed in a side panel of the pipeline configuration interface, and the candidate touch controls correspond to the configuration stage or the pipeline configuration data of the pipeline task corresponding to the pipeline configuration request. The user can configure the configuration stage or the pipeline configuration data by clicking or dragging the candidate touch controls. The pipeline configuration interface further includes a project type component, which represents a project configuration type of a pipeline task supported by the pipeline configuration interface. The user can select a project configuration type of a project to which the pipeline task belongs through the project type component.

[0032] In actual applications, the pipeline task includes any one of a micro-service task, a front-end application task, and a build dependent library task.

[0033] Specifically, the user can initiate a pipeline configuration request for displaying a pipeline configuration interface on a user terminal. The system (such as a server) displays a pipeline configuration interface through a visual editor in response to the pipeline configuration request initiated by the user. Figure 1

[0034] Further, after displaying the pipeline configuration interface for the user, the configuration stage and the pipeline configuration data available for pipeline configuration of the user need to be further displayed in a side panel of the pipeline configuration interface. The specific implementation manner is as follows:

[0035] In a specific embodiment provided by the present application, after displaying the pipeline configuration interface, the method further includes:

[0036] In response to a selection operation of the user on the project type component in the pipeline configuration interface, determining a project configuration type to which the pipeline task belongs;

[0037] According to the project configuration type, obtaining project code of a project to which the pipeline task belongs and a historical pipeline task associated with the project;

[0038] According to the project code and the historical pipeline task, determining to-be-recommended configuration stages and to-be-recommended configuration data;

[0039] Displaying the to-be-recommended configuration stages and the to-be-recommended configuration data in the pipeline configuration interface in the form of touch controls.

[0040] ​The historical pipeline task refers to a historical pipeline task of the same project configuration type as the pipeline task corresponding to the pipeline configuration request. The to-be-recommended configuration stage refers to a configuration stage generated by the system for recommending use to the user. The to-be-recommended configuration data refers to pipeline configuration data generated by the system for recommending use to the user. The pipeline configuration data includes a configuration name of the configuration stage, an agent environment, an execution condition, a stage step, a warehouse address, and the like.

[0041] Specifically, after displaying the pipeline configuration interface, the user can perform a selection operation on the project type component in the pipeline configuration interface to select the project configuration type of the pipeline task to be configured. The system determines the project configuration type to which the pipeline task to be configured belongs in response to the selection operation of the user on the project type component, obtains the project code of the project to which the pipeline task belongs and the historical pipeline task associated with the project according to the project configuration type. The historical pipeline task can be one or multiple, which is determined according to actual application conditions. The project code of the project and the historical pipeline task are parsed to obtain the configuration stage and the pipeline configuration data contained in the project code and the historical pipeline task, and the configuration stage and the pipeline configuration data determined to meet the configuration of the current pipeline task are recommended to the user as the to-be-recommended configuration stage and the to-be-recommended configuration data, and are displayed in the pipeline configuration interface in the form of a touch control.

[0042] It should be noted that the to-be-recommended configuration stage and the to-be-recommended configuration data can be the parsed configuration stage and pipeline configuration data, or the configuration stage and pipeline configuration data generated according to the parsed configuration stage and pipeline configuration data.

[0043] The embodiment of the application determines the project configuration type of the pipeline task corresponding to the pipeline configuration requirement, obtains the project code of the project to which the pipeline task belongs and the historical pipeline task associated with the project, determines the to-be-recommended configuration stage and the to-be-recommended configuration data by parsing the project code and the historical pipeline task, and displays the to-be-recommended configuration stage and the to-be-recommended configuration data in the pipeline configuration interface in the form of a touch control, thereby realizing visual configuration of the pipeline task by the user based on the pipeline configuration interface and improving user experience.

[0044] Step 204: In response to the configuration operation of the user on the pipeline configuration interface, pipeline configuration data and a configuration template are obtained.

[0045] After displaying the pipeline configuration interface, the user can configure the pipeline task based on the user's own needs. In the embodiment of the application, the user can perform self-defined configuration in the pipeline configuration interface, including configuring the configuration stage of the pipeline task and the pipeline configuration data corresponding to the configuration stage; the user can also input the configuration requirements related to the pipeline task in the input box in the pipeline configuration interface, and the template engine module can match the configuration template meeting the user's needs in the template library according to the content input by the user and feed back to the user, so that the user further configures the pipeline configuration data based on the matched configuration template. The two implementation manners are as follows:

[0046] In a specific embodiment provided by the application, the pipeline configuration interface includes a plurality of candidate touch controls, and the candidate touch controls correspond to the configuration stage of the pipeline task corresponding to the pipeline configuration request;

[0047] In response to the configuration operation of the user on the pipeline configuration interface, the pipeline configuration data and the configuration template are obtained, including:

[0048] In response to the touch operation of the user on the target touch control in the plurality of candidate touch controls, the target configuration stage corresponding to the target touch control is displayed on the pipeline configuration interface;

[0049] In response to the data addition operation of the user on the target configuration stage, the pipeline configuration data corresponding to the target configuration stage is displayed on the pipeline configuration interface;

[0050] In the case of receiving the configuration completion instruction for the pipeline configuration interface, the target configuration stage and the pipeline configuration data corresponding to the target configuration stage are obtained, and the configuration template is generated based on the target configuration stage.

[0051] Wherein, the target touch control refers to the touch control in the plurality of candidate touch controls which is executed by the user. The number of target touch controls is usually multiple, which is determined according to the actual configuration. The configuration completion instruction refers to the instruction initiated by the user to indicate that the pipeline task configuration is completed. The configuration completion instruction can be initiated by the user clicking the corresponding control in the pipeline configuration interface, for example, the user clicks the “save” control in the pipeline configuration interface to initiate the configuration completion instruction, and for example, the user clicks the “generate” control in the pipeline configuration interface to initiate the configuration completion instruction, etc. The initiation of the configuration completion instruction is determined according to the actual configuration of the pipeline configuration interface, which is not limited in the application.

[0052] Specifically, the user can select a target touch control from multiple candidate touch controls in the side panel of the pipeline configuration interface and perform a touch operation, such as clicking or dragging. In response to the user's touch operation on the target touch control, the visual editor displays the target configuration stage corresponding to the target touch control in the pipeline configuration interface. Furthermore, the user can directly add data to the target configuration stage in the pipeline configuration interface. For example, the user can add pipeline configuration data such as the configuration name, proxy environment, execution conditions, stage steps, repository address, branch, and build command for each target configuration stage. In response to the user's data addition operation on the target configuration stage, the visual editor displays the added pipeline configuration data in the pipeline configuration interface. This allows the user to intuitively view the target configuration stage of the pipeline task and the pipeline configuration data corresponding to the target configuration stage in the pipeline configuration interface. After the user completes configuring the target configuration stage and pipeline configuration data, a configuration completion command is issued. In response to the configuration completion command, the template engine module obtains the user-configured target configuration stage and the pipeline configuration data corresponding to the target configuration stage, and generates a configuration template based on the target configuration stage.

[0053] In addition, the side panel of the pipeline configuration interface also includes candidate touch controls corresponding to the pipeline configuration data. Users can also perform touch operations on the candidate touch controls corresponding to the pipeline configuration data to add pipeline configuration data to the target configuration stage.

[0054] An embodiment of the present invention can provide multiple candidate touch controls in the side panel of the pipeline configuration interface. The user can select a target touch control from the multiple candidate touch controls to perform touch operations, thereby configuring the target configuration stage. The user can also add data to the target configuration stage by himself to configure the pipeline configuration data, complete the user's customized visual configuration based on the pipeline configuration interface, reduce the configuration difficulty of the pipeline task, and improve the flexibility of the pipeline task configuration.

[0055] Furthermore, in a specific embodiment provided by the present invention, the pipeline configuration interface includes a project type component, and the project type component is used to represent the project configuration type of the pipeline task supported by the pipeline configuration interface;

[0056] In response to a user's configuration operation on the pipeline configuration interface, obtaining pipeline configuration data and a configuration template includes:

[0057] In response to a user selecting the project type component on the pipeline configuration interface, determining the project configuration type selected by the user;

[0058] In response to a text editing operation performed by the user in the pipeline configuration interface, obtaining text input by the user;

[0059] analyzing the text to obtain pipeline configuration data;

[0060] obtaining a configuration template in a template library according to the project configuration type and the pipeline configuration data.

[0061] Specifically, the user can select a project configuration type of a pipeline task to be configured through a project type component in a pipeline configuration interface, and edit configuration requirements (including pipeline configuration data) of the pipeline task in an input box of the pipeline configuration interface. After the user finishes editing, the template engine module can obtain the text edited by the user, obtain pipeline configuration data by analyzing the text, and obtain a corresponding configuration template in the template library according to the project configuration type and the obtained pipeline configuration data.

[0062] In actual application, after the template engine module obtains the configuration template in the template library, the configuration template is displayed in the pipeline configuration interface, and the user can also make corresponding adjustments to the configuration template, and determine the configuration template adjusted by the user as a final configuration template.

[0063] The embodiment of the application only needs the user to provide a project configuration type of a project to which a pipeline task belongs and configuration requirements of the pipeline task, can obtain a configuration template from a template library and feed back to the user, does not need the user to make complex configuration operations on the pipeline task, improves the efficiency of the user in configuring the pipeline task, and avoids configuration errors.

[0064] The embodiment of the application can provide two different pipeline task configuration modes for the user, and the user can select a mode for configuring the pipeline task, improve the flexibility of the pipeline task configuration on the basis of reducing the difficulty of the pipeline task configuration.

[0065] Step 206: generating a script file according to the pipeline configuration data and the configuration template.

[0066] After obtaining the pipeline configuration data and the configuration template for configuring the pipeline task, the pipeline configuration data is filled into the configuration template to generate a script file corresponding to the pipeline task. The user can view the content of the script file in a visual interface.

[0067] The embodiment of the application can automatically generate a script file of the pipeline task based on the configuration operation of the user on the pipeline task, and does not need the user to write the script file.

[0068] Step 208: running the pipeline task corresponding to the pipeline configuration request based on the script file.

[0069] After the script file of the pipeline task is generated, the pipeline generation module can run the pipeline task corresponding to the pipeline configuration request based on the generated script file. Specifically, the pipeline generation module can import the generated script file into a specified Jenkins instance by calling an interface, such as a REST API (Representational State Transfer Application Programming Interface) or a pipeline job creation interface provided by Jenkins, and run the pipeline task.

[0070] Further, in a specific embodiment provided by the present application, the method further comprises:

[0071] obtaining a running result of the pipeline task in a target configuration stage in the running process, wherein the target configuration stage is configured by the user in the pipeline configuration interface;

[0072] displaying the running result of the target configuration stage in a result visualization interface.

[0073] The running result includes a running state and log information of the pipeline task in the target configuration stage. The running state includes running success or running failure.

[0074] Specifically, after the pipeline task is run, the preview and debugging module can obtain the running result of the pipeline task in different target configuration stages in the running process, and display the running result of the different target configuration stages in the result visualization interface, and replay the log information of the pipeline task in the target configuration stage in a time axis or keyword highlighting manner. The user can view the running result of each target configuration stage, i.e., whether the pipeline task runs successfully or fails in the target configuration stage, and the log information of the pipeline task in the target configuration stage, through the result visualization interface.

[0075] The embodiment of the present application obtains the running result of the pipeline task in different target configuration stages, and visualizes and displays the running result, so that the user can obtain the running result of the pipeline task in different target configuration stages in time without waiting for the entire pipeline task to run to the end.

[0076] To improve the probability of success of the pipeline task, the pipeline task can also be simulated and run before actually running the pipeline task, to verify the generated script file and find configuration error data in the script text in advance.

[0077] Based on this, in a specific embodiment provided by the present application, after the script file is generated according to the pipeline configuration data and the configuration template, the method further comprises:

[0078] simulate running the pipeline task in a virtual running environment based on the script file, to obtain a simulation running result of the pipeline task;

[0079] determine configuration error data in the script file according to the simulation running result.

[0080] The configuration error data refers to data configured incorrectly in the script file.

[0081] Specifically, after the script file is generated, the pipeline task can be simulated and run in a virtual running environment based on the script file, and a simulation running result of the pipeline task can be obtained. If the simulation running result is simulation running failure, configuration error data can be determined in the script file, and the script file can be modified and debugged in a timely manner. If the simulation running result is simulation running success, it indicates that there is no configuration error data in the script file.

[0082] The embodiment of the present application runs the pipeline task in a virtual running environment before actually running the pipeline task, to determine configuration error data existing in the script file in advance, and to improve the success rate of the pipeline task in actual running.

[0083] In a specific embodiment provided by the present application, after the pipeline task corresponding to the pipeline configuration request is run based on the script file, the method further comprises:

[0084] In the case that the pipeline task is run successfully, the configuration template is saved to a template library.

[0085] Specifically, in the case that the pipeline task is run successfully, and the configuration template used to generate the script file is not stored in the template library (that is, the configuration template is configured by the user), the configuration template can be saved to the template library, to be reused when other pipeline tasks are generated subsequently.

[0086] The pipeline configuration method provided by the embodiment of the present application comprises: displaying a pipeline configuration interface in response to a pipeline configuration request; acquiring pipeline configuration data and a configuration template in response to a configuration operation of a user on the pipeline configuration interface; generating a script file according to the pipeline configuration data and the configuration template; and running a pipeline task corresponding to the pipeline configuration request based on the script file.

[0087] The embodiment of the present application realizes that the user can directly perform visual configuration operation on the pipeline configuration interface and generate a script file without manually writing a script, so as to reduce the difficulty of pipeline configuration of the user and improve the flexibility of pipeline configuration; the running result of the pipeline task corresponding to different target configuration stages can be obtained and displayed to the user in a visual form; and the pipeline task can be simulated in a virtual running environment before actual running of the pipeline task, so as to determine the configuration error data existing in the script file in advance, modify the script file in time, and improve the success rate of the pipeline task in actual running.

[0088] The step division of the above various methods is only for clear description, and can be combined into one step or split some steps to be decomposed into multiple steps, as long as the same logical relationship is included, and all are within the protection scope of the present patent; adding irrelevant modification or introducing irrelevant design in the algorithm or flow, but not changing the core design of the algorithm and flow, are within the protection scope of the present patent.

[0089] In a second aspect, the embodiment of the present application provides a pipeline configuration device. Referring to Figure 3 , Figure 3 A block diagram of a pipeline configuration device provided by the embodiment of the present application is shown in the figure, and the device comprises:

[0090] The display module 302 is configured to display a pipeline configuration interface in response to a pipeline configuration request;

[0091] The acquisition module 304 is configured to acquire pipeline configuration data and a configuration template in response to a configuration operation of the user on the pipeline configuration interface;

[0092] The generation module 306 is configured to generate a script file according to the pipeline configuration data and the configuration template;

[0093] The running module 308 is configured to run a pipeline task corresponding to the pipeline configuration request based on the script file.

[0094] Optionally, the pipeline configuration interface comprises a plurality of candidate touch controls, and the candidate touch controls correspond to configuration stages of the pipeline task corresponding to the pipeline configuration request;

[0095] The acquisition module 304 is further configured to:

[0096] In response to a touch operation of a target touch control in the plurality of candidate touch controls by the user, a target configuration stage corresponding to the target touch control is displayed on the pipeline configuration interface;

[0097] In response to the data adding operation of the target configuration stage by the user, the pipeline configuration data corresponding to the target configuration stage is displayed on the pipeline configuration interface.

[0098] In a case where a configuration completion instruction for the pipeline configuration interface is received, the target configuration stage and the pipeline configuration data corresponding to the target configuration stage are acquired, and a configuration template is generated based on the target configuration stage.

[0099] Optionally, the pipeline configuration interface comprises a project type component, which is used to represent a project configuration type of a pipeline task supported by the pipeline configuration interface.

[0100] The acquisition module 304 is further configured to:

[0101] In response to a selection operation of the project type component by the user on the pipeline configuration interface, the project configuration type selected by the user is determined.

[0102] In response to a text editing operation of the user in the pipeline configuration interface, the text input by the user is acquired.

[0103] The text is analyzed to acquire pipeline configuration data.

[0104] According to the project configuration type and the pipeline configuration data, a configuration template is acquired from a template library.

[0105] Optionally, the apparatus further comprises a recommendation module configured to:

[0106] In response to a selection operation of the project type component by the user on the pipeline configuration interface, the project configuration type to which the pipeline task belongs is determined.

[0107] According to the project configuration type, a project code of a project to which the pipeline task belongs and a historical pipeline task associated with the project are acquired.

[0108] According to the project code and the historical pipeline task, a to-be-recommended configuration stage and to-be-recommended configuration data are determined.

[0109] The to-be-recommended configuration stage and the to-be-recommended configuration data are displayed in the form of a touch control on the pipeline configuration interface.

[0110] Optionally, the apparatus further comprises a result display module configured to:

[0111] An operation result of a target configuration stage in a running process of the pipeline task is acquired, wherein the target configuration stage is configured by the user in the pipeline configuration interface.

[0112] displaying a running result of the target configuration stage in a result visualization interface.

[0113] Optionally, the apparatus further comprises a simulation running module configured to:

[0114] simulate running the pipeline task in a virtual running environment based on the script file, to obtain a simulation running result of the pipeline task;

[0115] determine configuration error data in the script file according to the simulation running result.

[0116] Optionally, the apparatus further comprises a saving module configured to:

[0117] in a case where the pipeline task runs successfully, save the configuration template to a template library.

[0118] Optionally, the pipeline task comprises any one of a micro-service task, a front-end application task and a build dependent library task.

[0119] The pipeline configuration apparatus provided by the embodiment of the present application comprises: a display module configured to display a pipeline configuration interface in response to a pipeline configuration request; an acquisition module configured to acquire pipeline configuration data and a configuration template in response to a configuration operation of a user on the pipeline configuration interface; a generation module configured to generate a script file according to the pipeline configuration data and the configuration template; and a running module configured to run a pipeline task corresponding to the pipeline configuration request based on the script file.

[0120] The embodiment of the present application realizes that the pipeline configuration interface is visually displayed for a user, so that the user can directly perform a visual configuration operation on the pipeline configuration interface and generate a script file without manually writing a script, thereby reducing the difficulty of the user in configuring a pipeline and improving the flexibility of the pipeline configuration; the running result of the pipeline task corresponding to different target configuration stages can be acquired and displayed to the user in a visual form; the pipeline task can be simulated to run in a virtual running environment before actual running of the pipeline task, so that configuration error data existing in the script file can be determined in advance, the script file can be modified in time, and the success rate of the pipeline task in actual running can be improved.

[0121] The apparatus provided by the embodiment of the present application has the functions or comprises the modules which can be used to execute the method described in the method embodiment of the first aspect, and the specific implementation and technical effects can be referred to the description of the method embodiment, and for brevity, will not be described here.

[0122] It should be noted that each module involved in the embodiment of the present application is a logical module. In actual application, one logical unit can be one physical unit, or a part of one physical unit, or realized by combination of multiple physical units. In addition, in order to highlight the innovative part of the present application, units not closely related to solving the technical problems proposed by the present application are not introduced in the embodiment. However, this does not mean that there are no other units in the embodiment.

[0123] Referring to Figure 4 The embodiment of the present application provides an electronic device 400, which comprises:

[0124] one or more processors 401;

[0125] a memory 402, which stores one or more programs, when the one or more programs are executed by the one or more processors, so that the one or more processors implement the pipeline configuration method described above;

[0126] one or more I / O interfaces 403 connected between the processor and the memory, configured to realize information interaction of the processor and the memory.

[0127] The processor 401 is a device with data processing capability, including but not limited to central processing unit (CPU) and the like; the memory 402 is a device with data storage capability, including but not limited to random access memory (RAM, more specifically SDRAM, DDR, etc.), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory (FLASH); the I / O interface (read-write interface) 403 is connected between the processor 401 and the memory 402, and can realize information interaction of the processor 401 and the memory 402, including but not limited to data bus (Bus) and the like.

[0128] In some embodiments, the processor 401, the memory 402 and the I / O interface 403 are connected by a bus, and further connected with other components of the computing device.

[0129] The embodiment further provides a computer readable medium, which stores a computer program, and the program is executed by the processor to implement the pipeline configuration method provided by the embodiment. To avoid repeated description, the specific steps of the pipeline configuration method are not described here.

[0130] Those skilled in the art can understand that all or some of the steps in the method, the functional modules / units in the system and the device described above can be implemented by software, firmware, hardware, or a combination thereof. In the hardware implementation, the division between the functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component can have multiple functions, or one function or step can be performed by several physical components in cooperation. Some or all of the physical components can be implemented as software executed by a processor, such as a central processing unit, a digital signal processor, or a microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software can be distributed on computer-readable media, which can include computer storage media (or non-transitory media) and communication media (or transitory media). As is well known to those skilled in the art, the term computer storage media includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can be accessed by a computer. In addition, it is well known to those skilled in the art that communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and can include any information delivery media.

[0131] It should be noted that the terms "comprising", "including", or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements recited, but can also include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element preceded by "comprises a" does not, without more constraints, foreclose the existence of additional identical elements in the process, method, article, or apparatus that comprises the element.

[0132] Those skilled in the art can understand that although some embodiments described herein include certain features included in other embodiments but not others, the combination of features of different embodiments means that it is within the scope of the embodiments and forms different embodiments.

[0133] It is understood that the above embodiments are only exemplary for illustrating the principles of the present application, and the present application is not limited thereto. Various modifications and improvements can be made by those skilled in the art without departing from the spirit and scope of the present application, and these modifications and improvements are also considered as the protection scope of the present application.

Claims

1. A pipeline configuration method, characterized in that: include: In response to the pipeline configuration request, displaying the pipeline configuration interface; Responding to a user's configuration operation on the pipeline configuration interface, obtaining pipeline configuration data and a configuration template; Generate a script file according to the pipeline configuration data and the configuration template; The pipeline task corresponding to the pipeline configuration request is run based on the script file.

2. The method according to claim 1, wherein The pipeline configuration interface includes a plurality of candidate touch controls, and the candidate touch controls correspond to the configuration phase of the pipeline task corresponding to the pipeline configuration request; In response to a user's configuration operation on the pipeline configuration interface, pipeline configuration data and configuration templates are obtained, including: In response to a user's touch operation on a target touch control among the plurality of candidate touch controls, displaying a target configuration stage corresponding to the target touch control on the pipeline configuration interface; In response to the user adding data to the target configuration stage, displaying pipeline configuration data corresponding to the target configuration stage on the pipeline configuration interface; When a configuration completion instruction for the pipeline configuration interface is received, the target configuration stage and pipeline configuration data corresponding to the target configuration stage are acquired, and a configuration template is generated based on the target configuration stage.

3. The method according to claim 1, wherein The pipeline configuration interface includes a project type component, and the project type component is used to characterize the project configuration type of the pipeline task supported by the pipeline configuration interface; In response to a user's configuration operation on the pipeline configuration interface, pipeline configuration data and configuration templates are obtained, including: In response to a user selecting the project type component on the pipeline configuration interface, determining the project configuration type selected by the user; In response to a text editing operation performed by the user in the pipeline configuration interface, obtaining text input by the user; Analyzing the text to obtain pipeline configuration data; According to the project configuration type and the pipeline configuration data, a configuration template is obtained from a template library.

4. The method according to claim 1, wherein After displaying the pipeline configuration interface, the method further includes: In response to a user selecting a project type component on the pipeline configuration interface, determining a project configuration type to which the pipeline task belongs; According to the project configuration type, obtaining the project code of the project to which the pipeline task belongs and the historical pipeline tasks associated with the project; Determining a configuration stage to be recommended and configuration data to be recommended based on the project code and the historical pipeline tasks; The configuration stage to be recommended and the configuration data to be recommended are displayed on the pipeline configuration interface in the form of touch controls.

5. The method according to claim 1, wherein The method further comprises: Obtaining an operation result of a target configuration phase during the operation of the pipeline task, wherein the target configuration phase is configured by the user in the pipeline configuration interface; The running results of the target configuration phase are displayed in a result visualization interface.

6. The method according to claim 1, wherein After generating a script file according to the pipeline configuration data and the configuration template, the method further includes: Simulating the pipeline task in a virtual operating environment based on the script file to obtain a simulation operating result of the pipeline task; According to the simulation running result, configuration error data in the script file is determined.

7. The method according to claim 2, wherein After running the pipeline task corresponding to the pipeline configuration request based on the script file, the method further includes: When the pipeline task runs successfully, the configuration template is saved to the template library.

8. The method according to any one of claims 1 to 7, wherein: The pipeline task includes any one of a microservice task, a front-end application task, and a dependency library building task.

9. A pipeline configuration device, characterized in that: include: A display module is configured to display a pipeline configuration interface in response to a pipeline configuration request; an acquisition module configured to acquire pipeline configuration data and a configuration template in response to a user's configuration operation on the pipeline configuration interface; A generating module is configured to generate a script file according to the pipeline configuration data and the configuration template; The running module is configured to run the pipeline task corresponding to the pipeline configuration request based on the script file.

10. An electronic device, characterized in that: include: one or more processors; a memory having one or more programs stored thereon, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the pipeline configuration method according to any one of claims 1 to 8; One or more I / O interfaces are connected between the processor and the memory and configured to implement information interaction between the processor and the memory.