WO2017185883A1 - Dynamic expansion software-process method and system - Google Patents

Dynamic expansion software-process method and system Download PDF

Info

Publication number
WO2017185883A1
WO2017185883A1 PCT/CN2017/076208 CN2017076208W WO2017185883A1 WO 2017185883 A1 WO2017185883 A1 WO 2017185883A1 CN 2017076208 W CN2017076208 W CN 2017076208W WO 2017185883 A1 WO2017185883 A1 WO 2017185883A1
Authority
WO
WIPO (PCT)
Prior art keywords
script
executable program
engine
action
feature value
Prior art date
Application number
PCT/CN2017/076208
Other languages
French (fr)
Chinese (zh)
Inventor
邬春会
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2017185883A1 publication Critical patent/WO2017185883A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/20Software design
    • G06F8/22Procedural
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/72Code refactoring

Definitions

  • the present disclosure relates to the field of computer software technologies, and in particular, to a method and system for dynamically extending a software flow.
  • the communication network includes two parts: the network element entity and the network management software.
  • the operation processes in the network management software are basically fixed and difficult to dynamically expand.
  • the user's needs are also variable. For example, during the version upgrade process, users want to add a comparison of performance indicators.
  • scripting method is to compile the script file into a part of the system and run the script logic through techniques such as the class loader. This method is performed before the software is released. It has high skill requirements for scripting, and the number of supported scripting languages is limited. It cannot be integrated with heterogeneous systems, and the flexibility of expansion is not high.
  • the main purpose of the present disclosure is to propose a method and system for dynamically expanding a software process, which aims to solve the problem of high skill in writing scripts when flexibly customizing processes and sub-processes, and the number of supported scripting languages is limited, and cannot be integrated with heterogeneous systems.
  • Technical problem is to propose a method and system for dynamically expanding a software process, which aims to solve the problem of high skill in writing scripts when flexibly customizing processes and sub-processes, and the number of supported scripting languages is limited, and cannot be integrated with heterogeneous systems.
  • a method for dynamically extending a software flow including:
  • For each action in the action sequence obtain a script file corresponding to the current action, and extract a script feature value according to the prefix, suffix, and/or information in the file header of the script file;
  • the script executable program corresponding to the current action further includes:
  • the server script engine warehouse is queried according to the script feature value to query the script engine installation package and the script engine installer corresponding to the current action, and the queryed script engine installation package and script engine are downloaded and installed locally. Installer.
  • monitoring and analyzing the error stream and standard output stream of the script executable program further comprises:
  • the above method further comprises:
  • the script engine installation package and script engine installer are installed locally, and the script feature values, script executable program names, and their paths are stored locally.
  • the method further includes: sending a script feature value to the server script engine warehouse, and corresponding script may be Execute the program name, script engine installation package, and script engine installer.
  • a system for dynamically expanding a software flow includes:
  • a receiving module configured to receive a sequence of actions customized by the user and a script file written for the action
  • a storage module configured to store a user-customized sequence of actions and a script file written for the action
  • the script engine repository is set to associate the stored script feature values with the corresponding executable program names and their paths;
  • a scheduling module configured to perform each action in the sequence of actions to the script execution body
  • the execution module is configured to obtain a script file corresponding to the current action, and extract a script feature value according to the prefix, suffix, and/or information in the file header of the script file; and find a script executable program corresponding to the current action according to the script feature value; If successful, construct an operating system command to start the script executable program, and the operating system command carries the script executable program name and its path, script file name and parameters;
  • the monitoring module is configured to monitor and analyze the error stream and the standard output stream of the script executable program, and feed the execution result as an input parameter of the next action to the scheduling module.
  • the execution module comprises:
  • a first acquiring unit configured to acquire a script file corresponding to the current action, and extract a script feature value according to the prefix, the suffix, and/or the information in the file header of the script file;
  • a second obtaining unit configured to search for a script executable program corresponding to the current action according to the script feature value
  • the startup unit is configured to, when the search is successful, construct an operating system command to start a script executable program, and the operating system command carries the script executable program name and its path, the script file name and parameters;
  • the second obtaining unit is configured to: according to the script feature value, find a script executable program corresponding to the current action in the local script engine repository; if the search fails, query the server script engine warehouse according to the script feature value to query the current action corresponding to the script.
  • the script engine installation package and the script engine installer download and locally install the queried script engine installation package and script engine installer.
  • the monitoring module is configured to: monitor an error flow of the script executable program, if there is an error message, determine that the execution result is a failure feedback to the scheduling module; monitor the standard output stream of the executable program, and extract the execution result information feedback therein Give the scheduling module.
  • the system further includes an engine storage module, configured to: receive a customized script feature value, and a corresponding script executable program name, a script engine installation package, and a script engine installer; The engine installation package and script engine installer, and locally store the script feature values and script executable program names.
  • an engine storage module configured to: receive a customized script feature value, and a corresponding script executable program name, a script engine installation package, and a script engine installer; The engine installation package and script engine installer, and locally store the script feature values and script executable program names.
  • the engine warehousing module is further configured to: send the script feature value to the script engine warehouse of the server, and the corresponding script executable program name, the script engine installation package, and the script engine installer.
  • the method and system for dynamically expanding software flow provided by the embodiments of the present disclosure can quickly customize the process requirements according to the needs of any scripting language that is familiar to the user.
  • information can be transmitted between different scripts, and multiple scripts can be quickly integrated.
  • Form a script processing chain that integrates with heterogeneous systems and increases the flexibility of the custom process.
  • FIG. 1 is a flowchart of a method for dynamically expanding a software flow according to Embodiment 1 of the present disclosure
  • FIG. 2 is a flowchart of a method for acquiring a script executable program according to Embodiment 1 of the present disclosure
  • FIG. 3 is a flowchart of a method for extending a software flow of a base station version upgrade according to Embodiment 2 of the present disclosure
  • FIG. 4 is a schematic structural diagram of a module of a dynamic extended software system according to Embodiment 3 of the present disclosure
  • FIG. 5 is a schematic structural diagram of another dynamic extended software system according to Embodiment 3 of the present disclosure.
  • a method for dynamically expanding a software flow includes the following steps:
  • the user can customize the action sequence through the human-machine interface, and customize the function to be implemented by the customized action through the script file.
  • each action is sequentially scheduled according to the sequence of the action sequence
  • the scheduling function may be an application client or a scheduling process of the computer system.
  • the corresponding script executable program may be searched from the local script engine warehouse, or the corresponding script executable program may be searched from the script engine warehouse of the server.
  • the step S30 further includes: searching for the current action in the local script engine repository according to the script feature value.
  • Corresponding script executable program if the search fails, querying the server script engine warehouse according to the script feature value to query the script engine installation package and the script engine installer corresponding to the current action, downloading and locally installing the queryed script engine installation package And the script engine installer.
  • step S30 specifically includes:
  • step S302. Determine whether the search is successful. If yes, the process ends, otherwise step S303 is performed.
  • the script engine installation package is usually a tar.gz compressed package that requires a scripting engine installer to handle it, including unpacking and running the compiler (optional). Run the script engine installer to copy the script engine installation package to the specified path of the operating system, the path can be specified in the script engine installer, and register environment variables and so on.
  • the startup script executable program starts the script engine process, and the process carries parameters, including input parameters and output parameters, and can pass complex information by using a Json string, thereby being able to pass input parameters and output parameters required by the script file.
  • the error flow of the script executable program is monitored, and if there is an error message, the execution result is determined to be a failure; the standard output stream of the monitoring script executable program is extracted, and the execution result information therein is extracted. For example, look for a special tag that represents the execution result, and extract the subsequent information as the execution result.
  • step S60 Determine whether the execution result fails. If yes, go to step S70, otherwise go to step S90.
  • step S70 Determine whether the current action is the last action. If yes, go to step S90, otherwise go to step S80.
  • the method further includes the step of loading the engine warehouse into the storage, specifically:
  • the script engine installation package and script engine installer are installed locally, and the script feature values, script executable program names, and their paths are stored locally.
  • the method further includes: Script engine repository sends script feature values, and corresponding script executable program names, script references Engine installation package and script engine installer.
  • the download path of the script engine installation package and the script engine installer (such as the URL path) is generated by the server's script engine repository, and the script feature value, the executable program name and its script engine installation package download path, and the script engine installer download path are generated. Associate storage so that other users can share it.
  • the user can quickly customize the process requirements according to the need of any scripting language that is familiar to the user, and by monitoring the script processing process, information can be transmitted between different scripts, and multiple scripts can be quickly integrated to form A script processing chain that integrates with heterogeneous systems to increase the flexibility of the custom process.
  • the second embodiment of the present disclosure takes the base station software version upgrade process in the field of communication technology as an example.
  • the basic process of software version upgrade includes: software download, pre-activation and activation.
  • users often have various needs. For example, a certain office wants to compare the pre-upgrade alarm with the upgraded alarm situation. If the performance indicator is added, follow the steps below to upgrade:
  • the user-defined alarm collection action includes a script file, which can be written in any scripting language familiar to the user, and implements the function of collecting current alarms and generating alarm data files. After the customization is successful, the script file and its feature values are stored locally.
  • the user customized alarm comparison action also includes a script file, which compares two alarm data files and saves the result as a data file.
  • the script file and its feature values are also stored locally.
  • the user customizes the upgrade action in the operation interface.
  • the action includes: 1. collecting the alarm, 2. downloading the version, 3. pre-activating the version, 4. activating the version, 5. collecting the alarm, and 6. comparing the alarm. .
  • the system first performs the collection alarm action: acquiring a script file for collecting the alarm action, extracting the script feature value according to the type of the script file, and searching for the corresponding script executable program from the local script engine warehouse according to the script feature value, if the search succeeds, Constructing an operating system command starts the script executable program. If the search is unsuccessful, it further issues a query request to the server's script engine repository, downloads the installation package file through the returned script engine installation package path, and locally installs the script executable program. Starting the script executable program starts the script engine process, which carries parameters.
  • the descriptions of the input parameters are as follows:
  • the alarm comparison script enters the parameter: alarm data file name 1, alarm data file name 2;
  • Alarm comparison script result Normal end (alarm comparison data file name), abnormal end (failure).
  • the input and output parameters exchange information between the collection alarm script and the alarm comparison script, and each action is sequentially executed, thereby forming a script processing chain and completing the action sequence.
  • the method for upgrading the base station version software provided by the embodiment of the present disclosure can customize the upgrade process in the field by using a script file familiar to the user, thereby improving the flexibility of the version upgrade.
  • the embodiment of the present disclosure provides a system for dynamically expanding a software flow, including a receiving module 10, a storage module 20, a scripting engine warehouse 30, a scheduling module 40, an executing module 50, and a monitoring module 60.
  • the receiving module 10 is configured to receive a sequence of actions customized by the user and a script file written for the action.
  • the receiving module 10 receives the action sequence customized by the user through the human machine interface and the script file of the function to be implemented by the customized action.
  • the storage module 20 is configured to store a sequence of actions customized by the user and a script file written for the action.
  • the script engine repository 30 is used to associate the name and path of the stored script feature values and their script executables.
  • the scheduling module 40 is configured to perform each action in the sequence of actions to the script execution body.
  • the scheduling module 40 sequentially schedules each action according to the sequence of the action sequence, and the scheduling module may be an application client or a scheduling process of the computer.
  • the execution module 50 is configured to obtain a script file corresponding to the current action, and extract a script feature value according to the prefix, suffix, and/or information in the file header of the script file; and find a script executable program corresponding to the current action according to the script feature value; If the search is successful, the operating system command is started to execute the script executable program, and the operating system command carries the script executable program name and its path, the script file name, and the parameters.
  • the execution module 50 further includes a first obtaining unit 501, a first obtaining unit 502, and a starting unit 503, where:
  • the first obtaining unit 501 is configured to acquire a script file corresponding to the current action, and extract a script feature value according to the prefix, the suffix, and/or the information in the file header of the script file.
  • the second obtaining unit 502 is configured to search for a script executable program corresponding to the current action according to the script feature value.
  • the startup unit 503 is configured to: when the search succeeds, construct an operating system command to start the script executable program, where the operating system command carries the script executable program name and its path, the script file name, and the parameter.
  • the second obtaining unit 502 is specifically configured to: according to the script feature value, find a script executable program corresponding to the current action in the local script engine repository; if the search fails, send a query request to the script engine warehouse; The script engine installation package download path, the script engine installer download path, and the script executable program name returned by the script engine repository; download and install the script engine installation package and the script engine installer locally; storing the script feature values and scripts locally Execute the program name.
  • the monitoring module 40 is configured to monitor and analyze the error flow and the standard output stream of the script executable program, and feed the execution result as an input parameter of the next action to the scheduling module.
  • the monitoring module 40 is specifically configured to: monitor an error flow of the script executable program, and if there is error information, determine that the execution result is a failure feedback to the scheduling module; monitor the standard output stream of the executable program, and extract the execution result thereof. Information is fed back to the scheduling module.
  • the system further includes an engine storage module 50, specifically configured to: receive a customized script feature value, and a corresponding script executable program name, a script engine installation package, and a script.
  • the engine installer installs the script engine installation package and the script engine installer locally, and stores the script feature values and script executable program names locally.
  • the engine warehousing module 50 is further configured to: send a script feature value received by the user to the script engine warehouse of the server, and a corresponding script executable program name, a script engine installation package, and a script engine.
  • the script engine installation package and the script engine installer download path are generated by the server's script engine repository, and the script feature value, the script executable program name and its script engine installation package download path, and the script engine installer download path are generated. Associate storage so that multiple user-customized script file types can be shared.
  • the user can quickly customize the process requirements according to the need of any scripting language that is familiar to the user, and can monitor the script processing process, and the information can be transmitted between different scripts, and the multiple scripts can be quickly integrated.
  • a script processing chain that integrates with heterogeneous systems to increase the flexibility of the custom process.
  • the present disclosure is applicable to the field of computer software technology, so that the user can quickly customize the process requirements according to the need of any scripting language that is familiar with the user.
  • information can be transmitted between different scripts, and multiple scripts can be quickly integrated to form a script processing.
  • Chains that integrate with heterogeneous systems increase the flexibility of custom processes.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

Provided are a dynamic expansion software-process method and system, belonging to the technical field of software. The method comprises: receiving and storing a user-customized action sequence and a script file written for the action (S10); for every action in the action sequence, obtaining the script file for the current action and extracting a feature value according to the prefix and suffix of the script file and/or information in the file header (S20); according to the script feature value, searching for a program that may be executed by the script corresponding to the current action (S30); if the search is successful, then constructing an operating-system command to launch the script and execute the program (S40); monitoring and analyzing the error stream and standard output stream of the script-executable program (S50), and taking the result of execution of the current action to be an input parameter. Using the method, a user may use any scripting language to quickly customize a process and transfer information between different scripts by means of monitoring the script execution result; a plurality of scripts are quickly merged to form a processing chain, which may be integrated with a heterogeneous system, thus improving flexibility.

Description

一种动态扩展软件流程的方法和***Method and system for dynamically expanding software flow 技术领域Technical field
本公开涉及计算机软件技术领域,尤其涉及一种动态扩展软件流程的方法和***。The present disclosure relates to the field of computer software technologies, and in particular, to a method and system for dynamically extending a software flow.
背景技术Background technique
各行各业的计算机信息***都存在工作流程,比如,通讯网络包括网元实体和网管软件两部分,网管软件中的操作流程都基本是固定的,很难动态扩展。但用户的需求又是多变的,例如在版本升级的过程中,用户希望加入对性能指标的对比。There are workflows in the computer information systems of all walks of life. For example, the communication network includes two parts: the network element entity and the network management software. The operation processes in the network management software are basically fixed and difficult to dynamically expand. However, the user's needs are also variable. For example, during the version upgrade process, users want to add a comparison of performance indicators.
目前,计算机信息***也可以执行用户编写的脚本,从而组合运行这些脚本,达到灵活定制子流程和流程的目的。然而,执行脚本方式是将脚本文件编译成***的一部分,通过类加载器等技术运行脚本逻辑。这种方法是在软件发布之前进行,对编写脚本的人员技能要求较高,且支持的脚本语言数量有限,不能与异构***集成,扩展的灵活性不高。At present, computer information systems can also execute user-written scripts to combine these scripts to achieve flexible customization of sub-processes and processes. However, the scripting method is to compile the script file into a part of the system and run the script logic through techniques such as the class loader. This method is performed before the software is released. It has high skill requirements for scripting, and the number of supported scripting languages is limited. It cannot be integrated with heterogeneous systems, and the flexibility of expansion is not high.
发明内容Summary of the invention
本公开的主要目的在于提出一种动态扩展软件流程的方法和***,旨在解决对用户灵活定制流程和子流程时对编写脚本技能要求高,且支持的脚本语言数量有限,不能与异构***集成的技术问题。The main purpose of the present disclosure is to propose a method and system for dynamically expanding a software process, which aims to solve the problem of high skill in writing scripts when flexibly customizing processes and sub-processes, and the number of supported scripting languages is limited, and cannot be integrated with heterogeneous systems. Technical problem.
根据本公开的一个方面,提供的一种动态扩展软件流程的方法包括:According to an aspect of the present disclosure, a method for dynamically extending a software flow is provided, including:
接收并存储用户定制的动作序列以及针对动作编写的脚本文件;Receiving and storing user-customized action sequences and script files written for actions;
针对动作序列中的每一个动作,获取当前动作对应的脚本文件,根据脚本文件的前缀、后缀和/或文件头中的信息提取脚本特征值;For each action in the action sequence, obtain a script file corresponding to the current action, and extract a script feature value according to the prefix, suffix, and/or information in the file header of the script file;
根据脚本特征值,查找当前动作对应的脚本可执行程序;Find a script executable program corresponding to the current action according to the script feature value;
如果查找成功,则构造操作***命令启动脚本可执行程序,操作***命令携带脚本可执行程序名称及其路径、脚本文件名称和参数;If the search is successful, construct an operating system command to start the script executable program, and the operating system command carries the script executable program name and its path, the script file name and parameters;
监测并分析脚本可执行程序的错误流和标准输出流,将执行结果作为下一个动作的输入参数。Monitor and analyze the error stream and standard output stream of the script executable, and use the execution result as the input parameter for the next action.
优选的,根据脚本特征值,查找当前动作对应的脚本可执行程序进一步包括:Preferably, according to the script feature value, the script executable program corresponding to the current action further includes:
根据脚本特征值,在本地脚本引擎仓库查找当前动作对应的脚本可执行程序;Find the script executable program corresponding to the current action in the local script engine repository according to the script feature value;
如果查找失败,如果查找失败,则根据所述脚本特征值向服务器脚本引擎仓库查询当前动作对应的脚本引擎安装包和脚本引擎安装程序,下载并在本地安装查询到的脚本引擎安装包和脚本引擎安装程序。If the search fails, if the search fails, the server script engine warehouse is queried according to the script feature value to query the script engine installation package and the script engine installer corresponding to the current action, and the queryed script engine installation package and script engine are downloaded and installed locally. Installer.
优选的,监测并分析脚本可执行程序的错误流和标准输出流进一步包括:Preferably, monitoring and analyzing the error stream and standard output stream of the script executable program further comprises:
监测脚本可执行程序的错误流,如果有错误信息,则判定执行结果为失败; Monitoring the error stream of the script executable program, and if there is an error message, determining that the execution result is a failure;
监测脚本可执行程序的标准输出流,提取其中的执行结果信息。Monitor the standard output stream of the script executable program and extract the execution result information from it.
优选的,上述方法还包括:Preferably, the above method further comprises:
接收用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序;Receiving user-customized script feature values, and corresponding script executable program names, script engine installation packages, and script engine installers;
在本地安装脚本引擎安装包和脚本引擎安装程序,并在本地关联存储脚本特征值、脚本可执行程序名称及其路径。The script engine installation package and script engine installer are installed locally, and the script feature values, script executable program names, and their paths are stored locally.
优选的,上述接收用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序之后还包括:向服务器的脚本引擎仓库发送脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序。Preferably, after receiving the customized script feature value and the corresponding script executable program name, the script engine installation package, and the script engine installer, the method further includes: sending a script feature value to the server script engine warehouse, and corresponding script may be Execute the program name, script engine installation package, and script engine installer.
根据本公开的另一个方面,提供一种动态扩展软件流程的***包括:According to another aspect of the present disclosure, a system for dynamically expanding a software flow includes:
接收模块,设置为接收用户定制的动作序列以及针对动作编写的脚本文件;a receiving module, configured to receive a sequence of actions customized by the user and a script file written for the action;
存储模块,设置为存储用户定制的动作序列以及针对动作编写的脚本文件;a storage module configured to store a user-customized sequence of actions and a script file written for the action;
脚本引擎仓库,设置为关联存储脚本特征值及对应的可执行程序名称及其路径;The script engine repository is set to associate the stored script feature values with the corresponding executable program names and their paths;
调度模块,设置为向脚本执行体调度执行动作序列中的每一个动作;a scheduling module, configured to perform each action in the sequence of actions to the script execution body;
执行模块,设置为获取当前动作对应的脚本文件,根据脚本文件的前缀、后缀和/或文件头中的信息提取脚本特征值;根据脚本特征值,查找当前动作对应的脚本可执行程序;如果查找成功,则构造操作***命令启动脚本可执行程序,操作***命令携带脚本可执行程序名称及其路径、脚本文件名称和参数;The execution module is configured to obtain a script file corresponding to the current action, and extract a script feature value according to the prefix, suffix, and/or information in the file header of the script file; and find a script executable program corresponding to the current action according to the script feature value; If successful, construct an operating system command to start the script executable program, and the operating system command carries the script executable program name and its path, script file name and parameters;
监测模块,设置为监测并分析脚本可执行程序的错误流和标准输出流,将执行结果作为下一个动作的输入参数反馈给调度模块。The monitoring module is configured to monitor and analyze the error stream and the standard output stream of the script executable program, and feed the execution result as an input parameter of the next action to the scheduling module.
优选的,执行模块包括:Preferably, the execution module comprises:
第一获取单元,设置为获取当前动作对应的脚本文件,根据脚本文件的前缀、后缀和/或文件头中的信息提取脚本特征值;a first acquiring unit, configured to acquire a script file corresponding to the current action, and extract a script feature value according to the prefix, the suffix, and/or the information in the file header of the script file;
第二获取单元,设置为根据脚本特征值,查找当前动作对应的脚本可执行程序;a second obtaining unit, configured to search for a script executable program corresponding to the current action according to the script feature value;
启动单元,设置为当查找成功时,构造操作***命令启动脚本可执行程序,操作***命令携带脚本可执行程序名称及其路径、脚本文件名称和参数;The startup unit is configured to, when the search is successful, construct an operating system command to start a script executable program, and the operating system command carries the script executable program name and its path, the script file name and parameters;
其中,第二获取单元设置为:根据脚本特征值,在本地脚本引擎仓库查找当前动作对应的脚本可执行程序;如果查找失败,则根据所述脚本特征值向服务器脚本引擎仓库查询当前动作对应的脚本引擎安装包和脚本引擎安装程序,下载并在本地安装查询到的脚本引擎安装包和脚本引擎安装程序。The second obtaining unit is configured to: according to the script feature value, find a script executable program corresponding to the current action in the local script engine repository; if the search fails, query the server script engine warehouse according to the script feature value to query the current action corresponding to the script The script engine installation package and the script engine installer download and locally install the queried script engine installation package and script engine installer.
优选的,监测模块设置为:监测脚本可执行程序的错误流,如果有错误信息,则判定执行结果为失败反馈给调度模块;监测脚本可执行程序的标准输出流,提取其中的执行结果信息反馈给调度模块。Preferably, the monitoring module is configured to: monitor an error flow of the script executable program, if there is an error message, determine that the execution result is a failure feedback to the scheduling module; monitor the standard output stream of the executable program, and extract the execution result information feedback therein Give the scheduling module.
优选的,上述***还包括引擎入库模块,设置为:接收用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序;在本地安装脚本引 擎安装包和脚本引擎安装程序,并本地关联存储脚本特征值和脚本可执行程序名称。Preferably, the system further includes an engine storage module, configured to: receive a customized script feature value, and a corresponding script executable program name, a script engine installation package, and a script engine installer; The engine installation package and script engine installer, and locally store the script feature values and script executable program names.
优选的,引擎入库模块还设置为:向服务器的脚本引擎仓库发送脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序。Preferably, the engine warehousing module is further configured to: send the script feature value to the script engine warehouse of the server, and the corresponding script executable program name, the script engine installation package, and the script engine installer.
本公开实施例提供的动态扩展软件流程的方法和***,用户能根据需要采用自己熟悉的任意脚本语言快速定制流程需求,通过监控脚本处理过程,不同脚本间可传递信息,快速融合多个脚本,形成脚本处理链,能与异构***集成,提升了定制流程的灵活性。The method and system for dynamically expanding software flow provided by the embodiments of the present disclosure can quickly customize the process requirements according to the needs of any scripting language that is familiar to the user. By monitoring the script processing process, information can be transmitted between different scripts, and multiple scripts can be quickly integrated. Form a script processing chain that integrates with heterogeneous systems and increases the flexibility of the custom process.
附图说明DRAWINGS
图1为本公开实施例一提供的一种动态扩展软件流程的方法的流程图;FIG. 1 is a flowchart of a method for dynamically expanding a software flow according to Embodiment 1 of the present disclosure;
图2为本公开实施例一提供的一种获取脚本可执行程序的方法的流程图;2 is a flowchart of a method for acquiring a script executable program according to Embodiment 1 of the present disclosure;
图3为本公开实施例二提供的一种基站版本升级的扩展软件流程的方法的流程图;3 is a flowchart of a method for extending a software flow of a base station version upgrade according to Embodiment 2 of the present disclosure;
图4为本公开实施例三提供的一种动态扩展软件***的模块结构示意图;4 is a schematic structural diagram of a module of a dynamic extended software system according to Embodiment 3 of the present disclosure;
图5为本公开实施例三提供的另一种动态扩展软件***的模块结构示意图。FIG. 5 is a schematic structural diagram of another dynamic extended software system according to Embodiment 3 of the present disclosure.
本公开目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。The implementation, functional features and advantages of the present disclosure will be further described with reference to the accompanying drawings.
具体实施方式detailed description
应当理解,此处所描述的具体实施例仅仅用以解释本公开,并不用于限定本公开。It is understood that the specific embodiments described herein are merely illustrative of the disclosure and are not intended to limit the disclosure.
实施例一Embodiment 1
如图1所示,本公开实施例提供的一种动态扩展软件流程的方法包括以下步骤:As shown in FIG. 1 , a method for dynamically expanding a software flow provided by an embodiment of the present disclosure includes the following steps:
S10、接收并存储用户定制的动作序列以及针对动作编写的脚本文件。S10. Receive and store a user-customized action sequence and a script file written for the action.
具体的,用户可以通过人机界面定制动作序列,并通过脚本文件定制其中自定义的动作要实现的功能。Specifically, the user can customize the action sequence through the human-machine interface, and customize the function to be implemented by the customized action through the script file.
S20、针对动作序列中的每一个动作,获取当前动作对应的脚本文件,根据脚本文件的前缀、后缀和/或文件头中的信息提取脚本特征值。S20. For each action in the action sequence, obtain a script file corresponding to the current action, and extract a script feature value according to the prefix, suffix, and/or information in the file header of the script file.
具体的,按照动作序列中顺序,依次调度每一个动作,调度功能可以是应用程序客户端,也可以是计算机***的一个调度进程。Specifically, each action is sequentially scheduled according to the sequence of the action sequence, and the scheduling function may be an application client or a scheduling process of the computer system.
S30、根据脚本特征值,查找当前动作对应的脚本可执行程序。S30. Search for a script executable program corresponding to the current action according to the script feature value.
具体的,本步骤S30可以从本地的脚本引擎仓库查找对应的脚本可执行程序,也可以从服务器的脚本引擎仓库查找对应的脚本可执行程序。作为一种优选方案,为了既能提高执行效率,又能在本地没有配置脚本引擎时能共享各用户的脚本引擎仓库,本步骤S30进一步包括:根据脚本特征值,在本地脚本引擎仓库查找当前动作对应的脚本可执行程序;如果查找失败,则根据所述脚本特征值向服务器脚本引擎仓库查询当前动作对应的脚本引擎安装包和脚本引擎安装程序,下载并在本地安装查询到的脚本引擎安装包和脚本引擎安装程序。Specifically, in this step S30, the corresponding script executable program may be searched from the local script engine warehouse, or the corresponding script executable program may be searched from the script engine warehouse of the server. As a preferred solution, in order to improve the execution efficiency and share the script engine warehouse of each user when the script engine is not configured locally, the step S30 further includes: searching for the current action in the local script engine repository according to the script feature value. Corresponding script executable program; if the search fails, querying the server script engine warehouse according to the script feature value to query the script engine installation package and the script engine installer corresponding to the current action, downloading and locally installing the queryed script engine installation package And the script engine installer.
请参考图2,本步骤S30具体包括: Referring to FIG. 2, step S30 specifically includes:
S301、根据脚本特征值,在本地脚本引擎仓库查找当前动作对应的脚本可执行程序。S301. Search for a script executable program corresponding to the current action in the local script engine repository according to the script feature value.
S302、判断查找是否成功,如果是,则结束流程,否则执行步骤S303。S302. Determine whether the search is successful. If yes, the process ends, otherwise step S303 is performed.
S303、向脚本引擎仓库发出查询请求,其中,该查询请求中携带脚本特征值。S303. Issue a query request to the script engine warehouse, where the query request carries the script feature value.
S304、接收脚本引擎仓库返回的脚本引擎安装包下载路径、脚本引擎安装程序下载路径和脚本可执行程序名称。S304. Receive a script engine installation package download path, a script engine installer download path, and a script executable program name returned by the script engine repository.
S305、下载并在本地安装脚本引擎安装包和脚本引擎安装程序。S305. Download and install the script engine installation package and the script engine installer locally.
具体的,脚本引擎安装包通常是tar.gz格式的压缩包,需要一个脚本引擎安装程序处理它,包括解压,运行编译程序(可选)。运行脚本引擎安装程序将脚本引擎安装包拷贝到操作***的指定路径,路径可以都在脚本引擎安装程序中指定,并注册环境变量等。Specifically, the script engine installation package is usually a tar.gz compressed package that requires a scripting engine installer to handle it, including unpacking and running the compiler (optional). Run the script engine installer to copy the script engine installation package to the specified path of the operating system, the path can be specified in the script engine installer, and register environment variables and so on.
S306、在本地关联存储脚本特征值、脚本可执行程序名称及其路径。S306. Store the script feature value, the script executable program name, and a path thereof locally.
S307、结束流程。S307, the process ends.
S40、如果查找成功,则构造操作***命令启动脚本可执行程序,其中,操作***命令携带脚本可执行程序路径及名称、脚本文件路径及名称、参数。S40. If the search is successful, construct an operating system command to start a script executable program, where the operating system command carries a script executable program path and name, a script file path and a name, and a parameter.
具体的,启动脚本可执行程序即启动了脚本引擎进程,该进程携带参数,包括输入参数和输出参数,可以采用Json字符串传递复杂信息,从而能够传递脚本文件需要的输入参数和输出参数。Specifically, the startup script executable program starts the script engine process, and the process carries parameters, including input parameters and output parameters, and can pass complex information by using a Json string, thereby being able to pass input parameters and output parameters required by the script file.
S50、监测并分析脚本可执行程序的错误流和标准输出流。S50. Monitor and analyze the error stream and standard output stream of the script executable program.
具体的,监测脚本可执行程序的错误流,如果有错误信息,则判定执行结果为失败;监测脚本可执行程序的标准输出流,提取其中的执行结果信息。比如,查找其中的表示执行结果的特殊标记,提取其后的信息作为执行结果。Specifically, the error flow of the script executable program is monitored, and if there is an error message, the execution result is determined to be a failure; the standard output stream of the monitoring script executable program is extracted, and the execution result information therein is extracted. For example, look for a special tag that represents the execution result, and extract the subsequent information as the execution result.
S60、判断执行结果是否失败,如果是,执行步骤S70,否则执行步骤S90。S60. Determine whether the execution result fails. If yes, go to step S70, otherwise go to step S90.
S70、判断当前动作是否是最后一个动作,如果是,执行步骤S90,否则执行步骤S80。S70. Determine whether the current action is the last action. If yes, go to step S90, otherwise go to step S80.
S80、将当前动作的执行结果作为下一动作的参数,返回步骤S20。S80. The execution result of the current operation is used as a parameter of the next operation, and the process returns to step S20.
具体的,由于各动作不是孤立存在的,各动作之间会存在关联,故将当前动作的执行结果(错误流或输出参数)作为下一个动作的输入参数,从而在不同的脚本文件之间传递信息、快速融合多个脚本,形成脚本处理链。Specifically, since each action does not exist in isolation, there is an association between the actions, so the execution result (error stream or output parameter) of the current action is used as an input parameter of the next action, thereby being transmitted between different script files. Information, quickly integrate multiple scripts to form a script processing chain.
S90、结束流程。S90, the end of the process.
在一些优选的方案中,上述方法还包括引擎仓库入库的步骤,具体包括:In some preferred embodiments, the method further includes the step of loading the engine warehouse into the storage, specifically:
接收用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序;Receiving user-customized script feature values, and corresponding script executable program names, script engine installation packages, and script engine installers;
在本地安装脚本引擎安装包和脚本引擎安装程序,并在本地关联存储脚本特征值、脚本可执行程序名称及其路径。The script engine installation package and script engine installer are installed locally, and the script feature values, script executable program names, and their paths are stored locally.
在另一些优选的方案中,为了充分共享脚本引擎仓库,接收用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序之后,该方法还包括:向服务器的脚本引擎仓库发送脚本特征值、以及对应的脚本可执行程序名称、脚本引 擎安装包和脚本引擎安装程序。由服务器的脚本引擎仓库生成脚本引擎安装包和脚本引擎安装程序的下载路径(比如URL路径),并将脚本特征值、可执行程序名称及其脚本引擎安装包下载路径、脚本引擎安装程序下载路径进行关联存储,从而让其他用户可以共享。In another preferred solution, in order to fully share the script engine repository, after receiving the customized script feature value, and the corresponding script executable program name, the script engine installation package, and the script engine installer, the method further includes: Script engine repository sends script feature values, and corresponding script executable program names, script references Engine installation package and script engine installer. The download path of the script engine installation package and the script engine installer (such as the URL path) is generated by the server's script engine repository, and the script feature value, the executable program name and its script engine installation package download path, and the script engine installer download path are generated. Associate storage so that other users can share it.
通过本公开实施例提供的动态扩展软件流程的方法,用户能根据需要采用自己熟悉的任意脚本语言快速定制流程需求,通过监控脚本处理过程,不同脚本间可传递信息,快速融合多个脚本,形成脚本处理链,能与异构***集成,提升了定制流程的灵活性。Through the method of dynamically expanding the software flow provided by the embodiment of the present disclosure, the user can quickly customize the process requirements according to the need of any scripting language that is familiar to the user, and by monitoring the script processing process, information can be transmitted between different scripts, and multiple scripts can be quickly integrated to form A script processing chain that integrates with heterogeneous systems to increase the flexibility of the custom process.
实施例二Embodiment 2
本公开实施例二以通讯技术领域的基站软件版本升级流程为例,软件版本升级基本流程包括:软件下载、预激活和激活3个主要流程环节。在现场,用户经常有各种需求,例如,某局希望将升级前的告警和升级后的告警情况做一次对比,即加入性能指标对比,则按以下步骤升级:The second embodiment of the present disclosure takes the base station software version upgrade process in the field of communication technology as an example. The basic process of software version upgrade includes: software download, pre-activation and activation. At the site, users often have various needs. For example, a certain office wants to compare the pre-upgrade alarm with the upgraded alarm situation. If the performance indicator is added, follow the steps below to upgrade:
S201、接收用户定制告警采集动作的脚本文件S201. Receive a script file of a user customized alarm collection action.
具体的,用户定制告警采集动作包含一个脚本文件,该脚本文件可以采用用户熟悉的任何脚本语言进行编写,实现采集当前告警,生成告警数据文件的功能。定制成功后,将脚本文件及其特征值存储到本地。Specifically, the user-defined alarm collection action includes a script file, which can be written in any scripting language familiar to the user, and implements the function of collecting current alarms and generating alarm data files. After the customization is successful, the script file and its feature values are stored locally.
S202、接收用户定制告警比对动作的脚本文件S202. Receive a script file of a user customized alarm comparison action
具体的,用户定制告警比对动作也包括一个脚本文件,实现比对两个告警数据文件,并将结果保存为数据文件。定制成功后也将其脚本文件及其特征值存储到本地。Specifically, the user customized alarm comparison action also includes a script file, which compares two alarm data files and saves the result as a data file. After the customization is successful, the script file and its feature values are also stored locally.
S203、接收用户定制的升级动作序列S203. Receive a customized update action sequence.
具体的,用户在操作界面中定制升级动作,本实施例中包括动作(1.采集告警,2.下载版本,3.预激活版本,4.激活版本,5.采集告警,6.对比告警)。Specifically, the user customizes the upgrade action in the operation interface. In this embodiment, the action includes: 1. collecting the alarm, 2. downloading the version, 3. pre-activating the version, 4. activating the version, 5. collecting the alarm, and 6. comparing the alarm. .
S204、按顺序调度升级动作序列中的动作。S204. Schedule the actions in the upgrade action sequence in sequence.
具体的,***首先执行采集告警动作:获取采集告警动作的脚本文件,根据脚本文件的类型提取脚本特征值,根据脚本特征值从本地脚本引擎仓库查找对应的脚本可执行程序,如果查找成功,则构造操作***命令启动该脚本可执行程序,如果查找不成功,再进一步向服务器的脚本引擎仓库发出查询请求,通过返回的脚本引擎安装包路径下载安装包文件,在本地进行安装脚本可执行程序。启动脚本可执行程序即启动了脚本引擎进程,该进程携带参数,关于输入参数的说明分别如下:Specifically, the system first performs the collection alarm action: acquiring a script file for collecting the alarm action, extracting the script feature value according to the type of the script file, and searching for the corresponding script executable program from the local script engine warehouse according to the script feature value, if the search succeeds, Constructing an operating system command starts the script executable program. If the search is unsuccessful, it further issues a query request to the server's script engine repository, downloads the installation package file through the returned script engine installation package path, and locally installs the script executable program. Starting the script executable program starts the script engine process, which carries parameters. The descriptions of the input parameters are as follows:
采集告警脚本的入参:告警数据文件名;Collect the entry of the alarm script: the name of the alarm data file;
采集告警脚本的结果:正常结束(成功),异常结束(失败);The result of collecting the alarm script: normal end (success), abnormal end (failure);
告警对比脚本入参:告警数据文件名1,告警数据文件名2;The alarm comparison script enters the parameter: alarm data file name 1, alarm data file name 2;
告警对比脚本结果:正常结束(告警对比数据文件名),异常结束(失败)。Alarm comparison script result: Normal end (alarm comparison data file name), abnormal end (failure).
如此,通过监控脚本处理结果,在输入和输出参数在采集告警脚本和告警比对脚本之间交互信息,依次执行每个动作,从而形成脚本处理链,完成动作序列。 In this way, by monitoring the result of the script processing, the input and output parameters exchange information between the collection alarm script and the alarm comparison script, and each action is sequentially executed, thereby forming a script processing chain and completing the action sequence.
本公开实施例提供的基站版本软件升级的方法,可以在现场采用用户熟悉的脚本文件定制升级流程,提高了版本升级的灵活性。The method for upgrading the base station version software provided by the embodiment of the present disclosure can customize the upgrade process in the field by using a script file familiar to the user, thereby improving the flexibility of the version upgrade.
实施例三Embodiment 3
如图3所示,本公开实施例提供一种动态扩展软件流程的***,包括接收模块10、存储模块20、脚本引擎仓库30、调度模块40、执行模块50和监测模块60。As shown in FIG. 3, the embodiment of the present disclosure provides a system for dynamically expanding a software flow, including a receiving module 10, a storage module 20, a scripting engine warehouse 30, a scheduling module 40, an executing module 50, and a monitoring module 60.
接收模块10,用于接收用户定制的动作序列以及针对动作编写的脚本文件。The receiving module 10 is configured to receive a sequence of actions customized by the user and a script file written for the action.
具体的,接收模块10接收用户通过人机界面定制的动作序列以及自定义的动作要实现的功能的脚本文件。Specifically, the receiving module 10 receives the action sequence customized by the user through the human machine interface and the script file of the function to be implemented by the customized action.
存储模块20,用于存储用户定制的动作序列以及针对动作编写的脚本文件。The storage module 20 is configured to store a sequence of actions customized by the user and a script file written for the action.
脚本引擎仓库30,用于关联存储脚本特征值及其脚本可执行程序的名称和路径。The script engine repository 30 is used to associate the name and path of the stored script feature values and their script executables.
调度模块40,用于向脚本执行体调度执行动作序列中的每一个动作。The scheduling module 40 is configured to perform each action in the sequence of actions to the script execution body.
具体的,调度模块40,按照动作序列中顺序,依次调度每一个动作,调度模块可以是应用程序客户端,也可以是计算机的一个调度进程。Specifically, the scheduling module 40 sequentially schedules each action according to the sequence of the action sequence, and the scheduling module may be an application client or a scheduling process of the computer.
执行模块50,用于获取当前动作对应的脚本文件,根据脚本文件的前缀、后缀和/或文件头中的信息提取脚本特征值;根据脚本特征值,查找当前动作对应的脚本可执行程序;如果查找成功,则构造操作***命令启动脚本可执行程序,操作***命令携带脚本可执行程序名称及其路径、脚本文件名称和参数。The execution module 50 is configured to obtain a script file corresponding to the current action, and extract a script feature value according to the prefix, suffix, and/or information in the file header of the script file; and find a script executable program corresponding to the current action according to the script feature value; If the search is successful, the operating system command is started to execute the script executable program, and the operating system command carries the script executable program name and its path, the script file name, and the parameters.
具体的,执行模块50进一步包括第一获取单元501、第一获取单元502和启动单元503,其中:Specifically, the execution module 50 further includes a first obtaining unit 501, a first obtaining unit 502, and a starting unit 503, where:
第一获取单元501,用于获取当前动作对应的脚本文件,根据脚本文件的前缀、后缀和/或文件头中的信息提取脚本特征值。The first obtaining unit 501 is configured to acquire a script file corresponding to the current action, and extract a script feature value according to the prefix, the suffix, and/or the information in the file header of the script file.
第二获取单元502,用于根据脚本特征值,查找当前动作对应的脚本可执行程序。The second obtaining unit 502 is configured to search for a script executable program corresponding to the current action according to the script feature value.
启动单元503,用于当查找成功时,构造操作***命令启动脚本可执行程序,操作***命令携带脚本可执行程序名称及其路径、脚本文件名称和参数。The startup unit 503 is configured to: when the search succeeds, construct an operating system command to start the script executable program, where the operating system command carries the script executable program name and its path, the script file name, and the parameter.
作为一种优选的方案,第二获取单元502具体用于:根据脚本特征值,在本地脚本引擎仓库查找当前动作对应的脚本可执行程序;如果查找失败,则向脚本引擎仓库发出查询请求;接收脚本引擎仓库返回的脚本引擎安装包下载路径、脚本引擎安装程序下载路径和脚本可执行程序名称;下载并在本地安装脚本引擎安装包和脚本引擎安装程序;在本地关联存储脚本特征值和脚本可执行程序名称。As a preferred solution, the second obtaining unit 502 is specifically configured to: according to the script feature value, find a script executable program corresponding to the current action in the local script engine repository; if the search fails, send a query request to the script engine warehouse; The script engine installation package download path, the script engine installer download path, and the script executable program name returned by the script engine repository; download and install the script engine installation package and the script engine installer locally; storing the script feature values and scripts locally Execute the program name.
监测模块40,用于监测并分析脚本可执行程序的错误流和标准输出流,将执行结果作为下一个动作的输入参数反馈给调度模块。The monitoring module 40 is configured to monitor and analyze the error flow and the standard output stream of the script executable program, and feed the execution result as an input parameter of the next action to the scheduling module.
优选的,监测模块40具体用于:监测脚本可执行程序的错误流,如果有错误信息,则判定执行结果为失败反馈给调度模块;监测脚本可执行程序的标准输出流,提取其中的执行结果信息反馈给调度模块。 Preferably, the monitoring module 40 is specifically configured to: monitor an error flow of the script executable program, and if there is error information, determine that the execution result is a failure feedback to the scheduling module; monitor the standard output stream of the executable program, and extract the execution result thereof. Information is fed back to the scheduling module.
如图4所示,在一些优选实施例中,上述***还包括引擎入库模块50,具体用于:接收用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序;在本地安装脚本引擎安装包和脚本引擎安装程序,并本地关联存储脚本特征值和脚本可执行程序名称。As shown in FIG. 4, in some preferred embodiments, the system further includes an engine storage module 50, specifically configured to: receive a customized script feature value, and a corresponding script executable program name, a script engine installation package, and a script. The engine installer; installs the script engine installation package and the script engine installer locally, and stores the script feature values and script executable program names locally.
在另一些优选实施例中,上述引擎入库模块50还用于:向服务器的脚本引擎仓库发送接收到用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序之后,由服务器的脚本引擎仓库生成脚本引擎安装包和脚本引擎安装程序的下载路径,并将脚本特征值、脚本可执行程序名称及其脚本引擎安装包下载路径、脚本引擎安装程序下载路径进行关联存储,从而能共享多个用户定制的脚本文件类型。In another preferred embodiment, the engine warehousing module 50 is further configured to: send a script feature value received by the user to the script engine warehouse of the server, and a corresponding script executable program name, a script engine installation package, and a script engine. After the program is installed, the script engine installation package and the script engine installer download path are generated by the server's script engine repository, and the script feature value, the script executable program name and its script engine installation package download path, and the script engine installer download path are generated. Associate storage so that multiple user-customized script file types can be shared.
本公开实施例的***是与上述方法相对应的,方法实施例中的技术特征在本***实施例中均能对应适用,这里不再重述。The system of the embodiment of the present disclosure is corresponding to the foregoing method, and the technical features in the method embodiment can be correspondingly applied in the embodiment of the system, and are not repeated herein.
通过本公开实施例提供的动态扩展软件流程的***,用户能根据需要采用自己熟悉的任意脚本语言快速定制流程需求,通过监控脚本处理过程,不同脚本间可传递信息,快速融合多个脚本,形成脚本处理链,能与异构***集成,提升了定制流程的灵活性。Through the system for dynamically expanding the software flow provided by the embodiment of the present disclosure, the user can quickly customize the process requirements according to the need of any scripting language that is familiar to the user, and can monitor the script processing process, and the information can be transmitted between different scripts, and the multiple scripts can be quickly integrated. A script processing chain that integrates with heterogeneous systems to increase the flexibility of the custom process.
需要说明的是,在本文中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者装置不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者装置所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者装置中还存在另外的相同要素。It is to be understood that the term "comprises", "comprising", or any other variants thereof, is intended to encompass a non-exclusive inclusion, such that a process, method, article, or device comprising a series of elements includes those elements. It also includes other elements that are not explicitly listed, or elements that are inherent to such a process, method, article, or device. An element that is defined by the phrase "comprising a ..." does not exclude the presence of additional equivalent elements in the process, method, item, or device that comprises the element.
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本公开的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本公开各个实施例所述的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the foregoing embodiment method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be through hardware, but in many cases, the former is better. Implementation. Based on such understanding, portions of the technical solutions of the present disclosure that contribute substantially or to the prior art may be embodied in the form of a software product stored in a storage medium (eg, ROM/RAM, disk, The optical disc includes a number of instructions for causing a terminal device (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to perform the methods described in various embodiments of the present disclosure.
以上仅为本公开的优选实施例,并非因此限制本公开的专利范围,凡是利用本公开说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本公开的专利保护范围内。The above is only a preferred embodiment of the present disclosure, and is not intended to limit the scope of the patents of the present disclosure, and the equivalent structure or equivalent process transformations made by the present disclosure and the contents of the drawings may be directly or indirectly applied to other related technical fields. The same is included in the scope of patent protection of the present disclosure.
工业实用性Industrial applicability
本公开适用于计算机软件技术领域,用以使得用户能根据需要采用自己熟悉的任意脚本语言快速定制流程需求,通过监控脚本处理过程,不同脚本间可传递信息,快速融合多个脚本,形成脚本处理链,能与异构***集成,提升了定制流程的灵活性。 The present disclosure is applicable to the field of computer software technology, so that the user can quickly customize the process requirements according to the need of any scripting language that is familiar with the user. By monitoring the script processing process, information can be transmitted between different scripts, and multiple scripts can be quickly integrated to form a script processing. Chains that integrate with heterogeneous systems increase the flexibility of custom processes.

Claims (11)

  1. 一种动态扩展软件流程的方法,包括:A method of dynamically extending a software process, comprising:
    接收并存储用户定制的动作序列以及针对动作编写的脚本文件;Receiving and storing user-customized action sequences and script files written for actions;
    针对所述动作序列中的每一个动作,获取当前动作对应的脚本文件,根据所述脚本文件的前缀、后缀和/或文件头中的信息提取脚本特征值;Obtaining, according to each action in the action sequence, a script file corresponding to the current action, and extracting a script feature value according to the prefix, the suffix, and/or the information in the file header of the script file;
    根据所述脚本特征值,查找当前动作对应的脚本可执行程序;Finding a script executable program corresponding to the current action according to the script feature value;
    如果查找成功,则构造操作***命令启动脚本可执行程序,所述操作***命令携带脚本可执行程序名称及其路径、脚本文件名称和参数;If the search is successful, constructing an operating system command to start a script executable program, the operating system command carrying the script executable program name and its path, script file name and parameters;
    监测并分析所述脚本可执行程序的错误流和标准输出流,将执行结果作为下一个动作的输入参数。The error stream and standard output stream of the script executable program are monitored and analyzed, and the execution result is used as an input parameter of the next action.
  2. 根据权利要求1所述的动态扩展软件流程的方法,其中,所述根据所述脚本特征值,查找当前动作对应的脚本可执行程序进一步包括:The method of dynamically expanding a software flow according to claim 1, wherein the finding a script executable program corresponding to the current action according to the script feature value further comprises:
    根据所述脚本特征值,在本地脚本引擎仓库查找当前动作对应的脚本可执行程序;Searching, according to the script feature value, a script executable program corresponding to the current action in the local script engine repository;
    如果查找失败,则根据所述脚本特征值向服务器脚本引擎仓库查询当前动作对应的脚本引擎安装包和脚本引擎安装程序,下载并在本地安装查询到的脚本引擎安装包和脚本引擎安装程序。If the search fails, the server script engine warehouse is queried according to the script feature value to query the script engine installation package and the script engine installer corresponding to the current action, and the queried script engine installation package and the script engine installer are downloaded and installed locally.
  3. 根据权利要求1所述的动态扩展软件流程的方法,其中,所述监测并分析所述脚本可执行程序的错误流和标准输出流进一步包括:The method of dynamically expanding a software flow according to claim 1, wherein said monitoring and analyzing the error stream and the standard output stream of said script executable program further comprises:
    监测所述脚本可执行程序的错误流,如果有错误信息,则判定执行结果为失败;Monitoring the error flow of the script executable program, and if there is an error message, determining that the execution result is a failure;
    监测所述脚本可执行程序的标准输出流,提取其中的执行结果信息。The standard output stream of the script executable program is monitored, and the execution result information therein is extracted.
  4. 根据权利要求1所述的动态扩展软件流程的方法,其中,所述方法还包括:The method of dynamically expanding a software flow according to claim 1, wherein the method further comprises:
    接收用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序;Receiving user-customized script feature values, and corresponding script executable program names, script engine installation packages, and script engine installers;
    在本地安装所述脚本引擎安装包和脚本引擎安装程序,并在本地关联存储所述脚本特征值、脚本可执行程序名称及其路径。The script engine installation package and the script engine installer are installed locally, and the script feature values, script executable program names, and paths thereof are stored locally.
  5. 根据权利要求4所述的动态扩展软件流程的方法,其中,所述接收用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序之后,该方法还包括:The method of dynamically expanding a software flow according to claim 4, wherein after the receiving the customized script feature value, and the corresponding script executable program name, the script engine installation package, and the script engine installer, the method further includes :
    向服务器的脚本引擎仓库发送脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序。Send script feature values to the server's scripting engine repository, along with the corresponding script executable program name, script engine installation package, and script engine installer.
  6. 一种动态扩展软件流程的***,包括:A system for dynamically extending software processes, including:
    接收模块,设置为接收用户定制的动作序列以及针对动作编写的脚本文件;a receiving module, configured to receive a sequence of actions customized by the user and a script file written for the action;
    存储模块,设置为存储用户定制的动作序列以及针对动作编写的脚本文件;a storage module configured to store a user-customized sequence of actions and a script file written for the action;
    脚本引擎仓库,设置为关联存储脚本特征值及对应的可执行程序名称及其路径; The script engine repository is set to associate the stored script feature values with the corresponding executable program names and their paths;
    调度模块,设置为向脚本执行体调度执行所述动作序列中的每一个动作;a scheduling module, configured to perform each action in the sequence of actions to the script execution body;
    执行模块,设置为获取当前动作对应的脚本文件,根据所述脚本文件的前缀、后缀和/或文件头中的信息提取脚本特征值;根据所述脚本特征值,查找当前动作对应的脚本可执行程序;如果查找成功,则构造操作***命令启动脚本可执行程序,所述操作***命令携带脚本可执行程序名称及其路径、脚本文件名称和参数;An execution module is configured to obtain a script file corresponding to the current action, and extract a script feature value according to the prefix, the suffix, and/or the information in the file header of the script file; and according to the script feature value, find a script corresponding to the current action executable a program; if the search is successful, constructing an operating system command to start a script executable program, the operating system command carrying a script executable program name and its path, a script file name, and a parameter;
    监测模块,设置为监测并分析所述脚本可执行程序的错误流和标准输出流,将执行结果作为下一个动作的输入参数反馈给所述调度模块。The monitoring module is configured to monitor and analyze the error stream and the standard output stream of the script executable program, and feed back the execution result to the scheduling module as an input parameter of the next action.
  7. 根据权利要求6所述的动态扩展软件流程的***,其中,所述执行模块包括:The system of dynamically expanding a software flow according to claim 6, wherein the execution module comprises:
    第一获取单元,设置为获取当前动作对应的脚本文件,根据所述脚本文件的前缀、后缀和/或文件头中的信息提取脚本特征值;a first acquiring unit, configured to acquire a script file corresponding to the current action, and extract a script feature value according to the prefix, the suffix, and/or the information in the file header of the script file;
    第二获取单元,设置为根据所述脚本特征值,查找当前动作对应的脚本可执行程序;a second acquiring unit, configured to search for a script executable program corresponding to the current action according to the script feature value;
    启动单元,设置为当查找成功时,构造操作***命令启动脚本可执行程序,所述操作***命令携带脚本可执行程序名称及其路径、脚本文件名称和参数;a boot unit, configured to, when the lookup is successful, construct an operating system command to start a script executable program, the operating system command carrying a script executable program name and its path, a script file name, and a parameter;
    其中,所述第二获取单元设置为:根据所述脚本特征值,在本地脚本引擎仓库查找当前动作对应的脚本可执行程序;如果查找失败,则根据所述脚本特征值向服务器脚本引擎仓库查询当前动作对应的脚本引擎安装包和脚本引擎安装程序,下载并在本地安装查询到的脚本引擎安装包和脚本引擎安装程序。The second obtaining unit is configured to: according to the script feature value, find a script executable program corresponding to the current action in the local script engine warehouse; if the search fails, query the server script engine warehouse according to the script feature value. The script engine installation package and script engine installer corresponding to the current action download and locally install the queried script engine installation package and script engine installer.
  8. 根据权利要求6所述的动态扩展软件流程的***,其中,所述监测模块设置为:A system for dynamically expanding a software flow according to claim 6, wherein said monitoring module is configured to:
    监测所述脚本可执行程序的错误流,如果有错误信息,则判定执行结果为失败反馈给调度模块;监测所述脚本可执行程序的标准输出流,提取其中的执行结果信息反馈给所述调度模块。Monitoring the error flow of the script executable program, if there is error information, determining that the execution result is a failure feedback to the scheduling module; monitoring the standard output stream of the script executable program, extracting the execution result information therein and feeding back to the scheduling Module.
  9. 根据权利要求6所述的动态扩展软件流程的***,其中,该***还包括引擎入库模块,设置为:接收用户定制的脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序;在本地安装所述脚本引擎安装包和脚本引擎安装程序,并本地关联存储所述脚本特征值、脚本可执行程序名称及其路径。The system for dynamically expanding a software flow according to claim 6, wherein the system further comprises an engine warehousing module configured to: receive a customized script feature value, and a corresponding script executable program name, a script engine installation package, and a script engine installer; the script engine installation package and the script engine installer are installed locally, and the script feature value, the script executable program name, and a path thereof are stored locally.
  10. 根据权利要求9所述的动态扩展软件流程的***,其中,所述引擎入库模块还设置为:向服务器的脚本引擎仓库发送脚本特征值、以及对应的脚本可执行程序名称、脚本引擎安装包和脚本引擎安装程序。The system for dynamically expanding a software flow according to claim 9, wherein the engine warehousing module is further configured to: send a script feature value to a script engine repository of the server, and a corresponding script executable program name, a script engine installation package. And the script engine installer.
  11. 一种计算机存储介质,所述计算机存储介质存储有执行指令,所述执行指令用于执行权利要求1至5中任一项所述的方法。 A computer storage medium storing execution instructions for performing the method of any one of claims 1 to 5.
PCT/CN2017/076208 2016-04-26 2017-03-09 Dynamic expansion software-process method and system WO2017185883A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201610264336.8A CN107315576A (en) 2016-04-26 2016-04-26 A kind of method and system of dynamic expansion software flow
CN201610264336.8 2016-04-26

Publications (1)

Publication Number Publication Date
WO2017185883A1 true WO2017185883A1 (en) 2017-11-02

Family

ID=60160691

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/076208 WO2017185883A1 (en) 2016-04-26 2017-03-09 Dynamic expansion software-process method and system

Country Status (2)

Country Link
CN (1) CN107315576A (en)
WO (1) WO2017185883A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114371808A (en) * 2022-01-10 2022-04-19 百融至信(北京)征信有限公司 Scheduling system based flow node parameter transmission method and system

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108647028B (en) * 2018-05-09 2024-02-09 广州腾讯科技有限公司 Application information processing method and device
CN111414212B (en) * 2020-03-27 2023-06-23 中国平安财产保险股份有限公司 Global process control method, device, computer equipment and storage medium
CN114625093B (en) * 2022-03-25 2023-05-02 佛山市博顿光电科技有限公司 Process control method, device and industrial control system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1972296A (en) * 2006-12-05 2007-05-30 北京邮电大学 Method for generating service combined with various communication means based on XPL and its system
US20100305997A1 (en) * 2009-01-27 2010-12-02 Direct Response Medicine, Llc Workflow management system and method
CN101969383A (en) * 2010-09-27 2011-02-09 深圳市共济科技有限公司 Monitoring equipment and visual control method and device thereof
CN102708271A (en) * 2011-02-21 2012-10-03 通用电气公司 Methods and apparatus for dynamic customization of clinical workflows
CN103974101A (en) * 2014-06-03 2014-08-06 王军明 Video-related task routing scheduling method

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1329818C (en) * 2002-11-14 2007-08-01 中兴通讯股份有限公司 Implement method of the man machine command based on plain text command script files
JP2007304998A (en) * 2006-05-12 2007-11-22 Hitachi Software Eng Co Ltd Source code generation method, device, and program
CN100520718C (en) * 2007-09-28 2009-07-29 华为技术有限公司 Script order registration method, method and device for calling source program code
CN101847118B (en) * 2009-03-24 2012-09-12 迈普通信技术股份有限公司 Automatic test system
KR101264615B1 (en) * 2011-06-17 2013-05-27 (주)네오위즈게임즈 Device and method for executing and managing job file of game server
US8910166B2 (en) * 2011-09-09 2014-12-09 Microsoft Corporation Automatic transcoding and semantic adaptation between scripting and workflow systems
CN103197947A (en) * 2012-01-04 2013-07-10 中兴通讯股份有限公司 Script processing method and device
CN103092817A (en) * 2013-01-18 2013-05-08 五八同城信息技术有限公司 Data collection method and data collection device based on script engine
CN104133676A (en) * 2014-07-18 2014-11-05 珠海市君天电子科技有限公司 Function execution method and function execution device based on scripts

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1972296A (en) * 2006-12-05 2007-05-30 北京邮电大学 Method for generating service combined with various communication means based on XPL and its system
US20100305997A1 (en) * 2009-01-27 2010-12-02 Direct Response Medicine, Llc Workflow management system and method
CN101969383A (en) * 2010-09-27 2011-02-09 深圳市共济科技有限公司 Monitoring equipment and visual control method and device thereof
CN102708271A (en) * 2011-02-21 2012-10-03 通用电气公司 Methods and apparatus for dynamic customization of clinical workflows
CN103974101A (en) * 2014-06-03 2014-08-06 王军明 Video-related task routing scheduling method

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114371808A (en) * 2022-01-10 2022-04-19 百融至信(北京)征信有限公司 Scheduling system based flow node parameter transmission method and system

Also Published As

Publication number Publication date
CN107315576A (en) 2017-11-03

Similar Documents

Publication Publication Date Title
US9038059B2 (en) Automatically targeting application modules to individual machines and application framework runtimes instances
CN111625839A (en) Third-party component vulnerability detection method, device, equipment and computer storage medium
WO2017185883A1 (en) Dynamic expansion software-process method and system
US20180196665A1 (en) Managing, using, and updating application resources
CN105657191B (en) Application increment upgrading method and system based on Android system
US9092286B2 (en) System to automatically process components on a device
US20050227683A1 (en) Apparatus and method for over the air software repair
CN111381858B (en) Application program upgrading method, server and terminal equipment
US9817655B1 (en) Managing software assets installed in an integrated development environment
CN108540509B (en) Processing method and device of terminal browser, server and intelligent terminal
CN109492181B (en) Page jump method, device, computer equipment and storage medium
CN111897570A (en) Multi-dependency file extraction method and device based on Maven plug-in
CN112083951A (en) Software package unified management method and system supporting multiple operating system platforms
US8510320B2 (en) Silent migration of business process binaries
CN113835713B (en) Source code packet downloading method, device, computer equipment and storage medium
CN110908670A (en) Method and device for automatically publishing service
CN112860282A (en) Upgrading method and device of cluster plug-in and server
CN114968406B (en) Plug-in management method and device, electronic equipment and storage medium
US9411618B2 (en) Metadata-based class loading using a content repository
CN106502685B (en) Method and system for upgrading database
CN109032641B (en) Application version updating method and device
CN112732265A (en) Data processing method and related device
CN115729590A (en) Service deployment method, device, equipment and computer readable storage medium
US7895267B2 (en) Extensible method and system for performing management operations on known and unknown targets
CN111949268B (en) Project compiling method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
NENP Non-entry into the national phase

Ref country code: DE

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17788538

Country of ref document: EP

Kind code of ref document: A1

122 Ep: pct application non-entry in european phase

Ref document number: 17788538

Country of ref document: EP

Kind code of ref document: A1