Disclosure of Invention
The embodiment of the invention provides a robot software online upgrade release method, a release device, release equipment and a computer readable storage medium, which can automatically perform online upgrade release operation of robot software and effectively improve the test and release efficiency of the robot software online upgrade release.
In a first aspect of the embodiments of the present invention, a robot software online upgrade issuing method is provided, including:
acquiring a source code of robot software to be upgraded;
automatically packaging the source codes into an upgrade package and then sending the upgrade package to a test environment;
performing a first test on the upgrade package in the test environment;
after the first test is passed, automatically synchronizing the upgrade package to a formal environment;
performing a second test on the upgrade package in the formal environment;
and automatically releasing the upgrade package on line after the second test is passed.
Further, the performing a second test on the upgrade package in the formal environment includes:
sending the upgrade package to part of robots to be upgraded in the formal environment;
and performing function test on the part of the robot to be upgraded after the upgrade package is upgraded to obtain a function test result.
Further, the obtaining of the source code of the robot software to be upgraded specifically includes:
and acquiring the source code of the robot software to be upgraded by calling a packaging interface which is provided by a specified server and corresponds to the robot software to be upgraded.
Preferably, after the automatic online publishing of the upgrade package, the method includes:
and the robot to be upgraded acquires the upgrade package through an upgrade interface of the formal environment so as to perform online upgrade on the corresponding robot software to be upgraded.
In a second aspect of the embodiments of the present invention, an online upgrade issuing apparatus for robot software is provided, including:
the code acquisition module is used for acquiring a source code of the robot software to be upgraded;
the packaging and sending module is used for automatically packaging the source codes into an upgrade package and then sending the upgrade package to a test environment;
the first testing module is used for carrying out first testing on the upgrading packet under the testing environment;
the automatic synchronization module is used for automatically synchronizing the upgrade package to a formal environment after the first test is passed;
the second testing module is used for carrying out second testing on the upgrade package under the formal environment;
and the automatic issuing module is used for automatically issuing the upgrade package on line after the second test is passed.
In a third aspect of the embodiments of the present invention, there is provided a robot software online upgrade issuing device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the steps of the robot software online upgrade issuing method in the foregoing first aspect when executing the computer program.
In a fourth aspect of embodiments of the present invention, a computer-readable storage medium is provided, where a computer program is stored, and when the computer program is executed by a processor, the steps of the robot software online upgrade issuing method according to the foregoing first aspect are implemented.
According to the technical scheme, the embodiment of the invention has the following advantages:
in the embodiment of the invention, after the source code of the robot software to be upgraded is obtained, the source code is automatically packaged into the upgrade package and then automatically sent to the test environment, the upgrade package is automatically synchronized to the formal environment after the first test is passed under the test environment, and the upgrade package is automatically released on line after the second test is passed under the formal environment, so that the automatic generation, automatic sending, automatic synchronization and automatic release operation of the upgrade package are completed, the release risk caused by manual operation errors is reduced, and the test and release efficiency of the robot software online upgrade release are effectively improved.
Detailed Description
The embodiment of the invention provides a robot software online upgrade release method, an online upgrade release device and a computer readable storage medium, which are used for automatically performing online upgrade release of robot software, improving the release efficiency of the robot software online upgrade release and reducing the release risk caused by manual misoperation.
In order to make the objects, features and advantages of the present invention more obvious and understandable, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is obvious that the embodiments described below are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, an embodiment of the present invention provides a robot software online upgrade publishing method, including:
step S110: acquiring a source code of robot software to be upgraded;
step S120: automatically packaging the source codes into an upgrade package and then sending the upgrade package to a test environment;
step S130: performing a first test on the upgrade package in the test environment;
step S140: after the first test is passed, automatically synchronizing the upgrade package to a formal environment;
step S150: performing a second test on the upgrade package in the formal environment;
step S160: and automatically releasing the upgrade package on line after the second test is passed.
In this embodiment, step S110: the method for acquiring the source code of the robot software to be upgraded specifically comprises the following steps: and acquiring the source code of the robot software to be upgraded by calling a packaging interface which is provided by a specified server and corresponds to the robot software to be upgraded.
In the field of robots, different robot software is often required to be carried in order to realize various task functions of a robot, and if various functions of the robot are desired to be optimized, different robot software needs to be upgraded, that is, various different software release flows are often required to be set to meet the upgrading requirements of different robot software, which is not beneficial to the unified management of robot software release and upgrading.
Therefore, in this embodiment, the WEB management system is connected to the packaging interface corresponding to the robot software to be upgraded, so that the WEB management system can obtain the source code of the robot software to be upgraded by calling the packaging interface, and further perform the release operation of the robot software to be upgraded according to the source code.
Specifically, in this embodiment, after completing the writing of the source code of the robot software to be upgraded, a research and development staff uploads the source code to a designated server, and simultaneously provides a packaging interface corresponding to the robot software to be upgraded in the designated server to the WEB management system, and the WEB management system can automatically acquire the source code by calling the packaging interface, that is, the WEB management system can acquire different source codes of the robot software to be upgraded by calling different packaging interfaces.
In step S120, the source code is automatically packaged into an upgrade package and then sent to a test environment.
In this embodiment, after obtaining the source code of the robot software to be upgraded, the WEB management system automatically packages the source code into an upgrade package, for example, automatically packages the code on gitlab into the upgrade package through jenkins, and sends the upgrade package to a test environment, for example, to a specified intranet server or a specified file server.
In step S130, a first test is performed on the upgrade package under the test environment.
In this embodiment, a testing robot performs a first test on the upgrade package by calling a test interface in the test environment, that is, tests a function or performance that the upgrade package should have, if a test result of the first test does not meet a preset first test requirement, a test result that does not meet the requirement is notified to a research and development worker, the research and development worker modifies the source code, after the modification is completed, the WEB management system re-acquires the modified source code, automatically packages the modified source code into a new upgrade package, sends the new upgrade package to the test environment, and performs the first test again in the test environment; and if the test result of the first test meets the first test requirement, automatically synchronizing the upgrade package to a formal environment.
That is, in step S140, after the first test is passed, the upgrade package is automatically synchronized to the formal environment.
After the upgrade package meets the first test requirement in the first test, that is, the function or performance of the upgrade package meets the requirement, the upgrade package is automatically synchronized to a formal environment, for example, the upgrade package is automatically uploaded to a cloud storage server, and version data of a robot software version corresponding to the upgrade package is automatically written into a formal database.
In this embodiment, in step S150, a second test is performed on the upgrade package in the formal environment.
Specifically, after the upgrade package is automatically synchronized to the formal environment, the integrity of the upgrade package is tested to ensure that the upgrade package is not lost in the automatic synchronization process, and meanwhile, the upgrade package is subjected to a function test or a performance test again in the formal environment to ensure that the function or performance of the upgrade package meets the use requirements of the formal environment. If the upgrade package is lost in the automatic synchronization process or the function or performance of the upgrade package is in a problem in the formal environment, the automatic synchronization process of the upgrade package needs to be performed again, or the processes of obtaining and packaging the source code, performing the first test, and performing the second test are performed again.
Further, in this embodiment, step S150: performing a second test on the upgrade package in the formal environment, further comprising:
sending the upgrade package to part of robots to be upgraded in the formal environment;
and performing function test on the part of the robot to be upgraded after the upgrade package is upgraded to obtain a function test result.
In this embodiment, the second test in the formal environment includes a gray scale test in addition to an integrity test, a function test, or a performance test. After the integrity test, the function test or the performance test of the upgrade package passes, the gray level test is performed on the upgrade package according to a preset gray level test rule. Specifically, a part of robots to be upgraded are selected, then the upgrade package is sent to the selected part of robots to be upgraded, so that the part of robots to be upgraded perform upgrade operation on the corresponding robot software to be upgraded, after the upgrade operation is completed, the upgraded functions or performances of the part of robots to be upgraded are tested, so as to obtain function test results, namely function feedback of the part of robots to be upgraded is obtained, and optimization and adjustment operations of the upgrade package are performed according to the function feedback, so that the upgrade risk is effectively controlled, some unpredictable conditions in the upgrade process are avoided, and the upgrade requirements of the robot software in a complex scene are met.
Here, the preset gray scale test rule in this embodiment may be determined by number limitation, serial number limitation, or area limitation, for example, selecting a robot to be upgraded in a specific area to perform a gray scale test, or selecting a robot to be upgraded with a specific serial number to perform a gray scale test, or selecting a specific number of robots to be upgraded to perform a gray scale test.
In step S160, after the second test is passed, the upgrade package is automatically released online.
In this embodiment, after the upgrade package passes all tests, the upgrade package is automatically issued on line, so that the robot to be upgraded, which has an upgrade requirement, can perform corresponding upgrade.
Further, in this embodiment, after the automatic online publishing of the upgrade package, the method further includes: and the robot to be upgraded acquires the upgrade package through an upgrade interface of the formal environment so as to perform online upgrade on the corresponding robot software to be upgraded.
In this embodiment, after the upgrade package is automatically distributed in the formal environment on line, an upgrade interface corresponding to the upgrade package is provided to the robot to be upgraded in the formal environment, and the robot to be upgraded can obtain the upgrade package by connecting the upgrade interface, so as to perform on-line upgrade on the corresponding robot software to be upgraded, thereby implementing optimization and improvement of the robot function.
Preferably, in this embodiment, the method for online upgrading and releasing robot software further includes: and detecting the upgrading state of the upgrading packet in the robot to be upgraded in real time, realizing the visibility control of the upgrading state, and adjusting the upgrading state in time so as to effectively control the upgrading risk. Specifically, the upgrade status includes an online status, an offline status, a disabled status, and an unlocked status. In an actual application scenario, when a serious bug of the upgrade patch is found, the upgrade patch can be adjusted to a forbidden state, so that the upgrade patch is forbidden in the robot to be upgraded, and the function of the robot to be upgraded is prevented from being affected.
Further, in this embodiment, the method for online upgrading and releasing robot software further includes: and configuring an upgrade description for the upgrade package, such as an upgrade rule, an upgrade mode, an update mode and the like for online upgrade of the robot software, for example, configuring the upgrade mode into a differential mode or a whole package mode, and configuring the update mode into a forced update and the like. And after the robot to be upgraded acquires the upgrade package, performing online upgrade on the robot software to be upgraded according to the upgrade description, if the robot software to be upgraded is subjected to online upgrade in a differential mode, and if the upgrade package is repaired, automatically and forcibly updating the repaired upgrade package to the robot to be upgraded.
In this embodiment, after the source code of the robot software to be upgraded is acquired, the source code is automatically packaged into an upgrade package and then automatically sent to a test environment, after the upgrade package is subjected to a first test under the test environment, the upgrade package is automatically synchronized to a formal environment, and after the upgrade package is subjected to a second test under the formal environment, the upgrade package is automatically issued on line, so that the automatic generation, automatic sending, automatic synchronization and automatic issuing operations of the upgrade package are completed, the issuing risk caused by manual operation errors is reduced, and the test and issuing efficiency of the robot software online upgrade issue are effectively improved.
It should be understood that, the sequence numbers of the steps in the foregoing embodiments do not imply an execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
The above mainly describes a robot software online upgrade publishing method, and a robot software online upgrade publishing device will be described in detail below.
Referring to fig. 2, a second embodiment of the present invention provides an online upgrade issuing apparatus for robot software, including:
a code obtaining module 210, configured to obtain a source code of the robot software to be upgraded;
a packaging sending module 220, configured to automatically package the source code into an upgrade package and send the upgrade package to a test environment;
a first testing module 230, configured to perform a first test on the upgrade package in the testing environment;
an automatic synchronization module 240, configured to automatically synchronize the upgrade package to a formal environment after the first test is passed;
a second testing module 250, configured to perform a second test on the upgrade package in the formal environment;
and the automatic issuing module 260 is configured to automatically issue the upgrade package on line after the second test is passed.
Further, the second testing module 250 includes:
the sending unit is used for sending the upgrade package to part of robots to be upgraded under the formal environment;
and the test unit is used for performing function test on the part of the robot to be upgraded after the upgrade package is upgraded to obtain a function test result.
Further, the code obtaining module 210 is specifically configured to obtain the source code of the robot software to be upgraded by calling a packaging interface provided by a specified server and corresponding to the robot software to be upgraded.
Preferably, the robot software online upgrade issuing device further includes:
and the online upgrading module is used for acquiring the upgrading packet by the robot to be upgraded through the upgrading interface of the formal environment after the upgrading packet is automatically released online so as to perform online upgrading on the corresponding robot software to be upgraded.
Fig. 3 is a schematic structural diagram of a robot software online upgrade issuing device according to a third embodiment of the present invention. As shown in fig. 3, the robot software online upgrade issuing apparatus 300 in the present embodiment includes: a processor 310, a memory 320, and a computer program 330, such as a robot software online upgrade publisher, stored in the memory 320 and operable on the processor 310. The processor 310 executes the computer program 330 to implement the steps in the above-mentioned robot software online upgrade issuing method embodiments, such as the steps S110 to S160 shown in fig. 1. Alternatively, the processor 310, when executing the computer program 330, implements the functions of each module/unit in the above-described device embodiments, such as the functions of the modules 210 to 260 shown in fig. 2.
Illustratively, the computer program 330 may be partitioned into one or more modules/units that are stored in the memory 320 and executed by the processor 310 to implement embodiments of the present invention. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution process of the computer program 330 in the robot software online upgrade issuing device 300. For example, the computer program 330 may be divided into a code acquiring module, a packaging sending module, a first testing module, an automatic synchronizing module, a second testing module, and an automatic publishing module, where the specific functions of the modules are as follows:
the code acquisition module is used for acquiring a source code of the robot software to be upgraded;
the packaging and sending module is used for automatically packaging the source codes into an upgrade package and then sending the upgrade package to a test environment;
the first testing module is used for carrying out first testing on the upgrading packet under the testing environment;
the automatic synchronization module is used for automatically synchronizing the upgrade package to a formal environment after the first test is passed;
the second testing module is used for carrying out second testing on the upgrade package under the formal environment;
and the automatic issuing module is used for automatically issuing the upgrade package on line after the second test is passed.
The robot software online upgrade issuing device 300 may be a desktop computer, a notebook, a palm computer, a cloud server, or other computing devices. The robot software online upgrade issuing device 300 may include, but is not limited to, a processor 310 and a memory 320. Those skilled in the art will appreciate that fig. 3 is merely an example of the robot software online upgrade issuing device 300, and does not constitute a limitation on the robot software online upgrade issuing device 300, and may include more or less components than those shown, or combine some components, or different components, for example, the robot software online upgrade issuing device 300 may further include an input-output device, a network access device, a bus, etc.
The Processor 310 may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component, etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The storage 320 may be an internal storage unit of the robot software online upgrade issuing apparatus 300, such as a hard disk or a memory of the robot software online upgrade issuing apparatus 300. The memory 320 may also be an external storage device of the robot software online upgrade issuing device 300, for example, a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash Card (Flash Card), or the like, which is provided on the robot software online upgrade issuing device 300. Further, the memory 320 may also include both an internal storage unit and an external storage device of the robot software online upgrade issuing device 300. The memory 320 is used for storing the computer program 330 and other programs and data required by the robot software online upgrade issuing device 300. The memory 320 may also be used to temporarily store data that has been output or is to be output.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art would appreciate that the modules, elements, and/or method steps of the various embodiments described in connection with the embodiments disclosed herein may be implemented as electronic hardware, or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, all or part of the flow of the method according to the embodiments of the present invention may also be implemented by a computer program, which may be stored in a computer-readable storage medium, and when the computer program is executed by a processor, the steps of the method embodiments may be implemented. . Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.