CN112699044B - Pressure testing method, equipment and storage medium - Google Patents
Pressure testing method, equipment and storage medium Download PDFInfo
- Publication number
- CN112699044B CN112699044B CN202110009149.6A CN202110009149A CN112699044B CN 112699044 B CN112699044 B CN 112699044B CN 202110009149 A CN202110009149 A CN 202110009149A CN 112699044 B CN112699044 B CN 112699044B
- Authority
- CN
- China
- Prior art keywords
- stress test
- test script
- code
- script
- stress
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Prevention of errors by analysis, debugging or testing of software
- G06F11/3668—Testing of software
- G06F11/3672—Test management
- G06F11/3688—Test management for test execution, e.g. scheduling of test suites
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Prevention of errors by analysis, debugging or testing of software
- G06F11/3698—Environments for analysis, debugging or testing of software
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Debugging And Monitoring (AREA)
- Test And Diagnosis Of Digital Computers (AREA)
Abstract
Description
技术领域technical field
本申请涉及软件测试技术领域,尤其涉及一种压力测试方法、设备及存储介质。The present application relates to the technical field of software testing, in particular to a pressure testing method, equipment and storage medium.
背景技术Background technique
压力测试可模拟实际应用的软硬件环境及用户使用过程的系统负荷,长时间或超大负荷地运行压力测试脚本,来测试应用程序的性能。Stress testing can simulate the actual software and hardware environment of the application and the system load of the user's use process, and run the stress test script for a long time or with a large load to test the performance of the application.
在压力测试脚本开发过程中,经常会依赖现有代码库,这样可减少开发工作量。在进行压力测试时,需要先将压力测试脚本依赖的代码从代码库中下载到本地,再将编写完成的压力测试脚本和依赖包手动上传至压力测试环境中,进行压力测试,整个过程耗时较长,压力测试效率低。During the development of stress test scripts, existing code bases are often relied upon, which reduces the development effort. When performing a stress test, it is necessary to download the code that the stress test script depends on from the code base to the local, and then manually upload the completed stress test script and dependent packages to the stress test environment for stress testing. The whole process is time-consuming Longer, less efficient stress testing.
发明内容Contents of the invention
本申请的多个方面提供一种压力测试方法、设备及存储介质,用以缩短压力测试时间,提高压力测试效率。Various aspects of the present application provide a stress testing method, equipment, and storage medium, which are used to shorten stress testing time and improve stress testing efficiency.
本申请实施例提供一种压力测试方法,适用于计算机设备,包括:An embodiment of the present application provides a stress testing method suitable for computer equipment, including:
获取压力测试脚本;Get the stress test script;
在压力测试环境中执行所述压力测试脚本;Execute the stress test script in the stress test environment;
在执行所述压力测试脚本的过程中,将所述压力测试脚本依赖的代码从代码库中下载至所述压力测试环境中;During the process of executing the stress test script, the code that the stress test script depends on is downloaded from the code library into the stress test environment;
在所述压力测试环境中执行所述压力测试脚本依赖的代码,以进行压力测试。Execute the codes that the stress test script depends on in the stress test environment to perform the stress test.
本申请实施例还提供一种计算机设备,包括:存储器和处理器;其中,所述存储器,用于存储计算机程序;The embodiment of the present application also provides a computer device, including: a memory and a processor; wherein, the memory is used to store a computer program;
所述处理器耦合至所述存储器,用于执行所述计算机程序以用于执行上述压力测试方法中的步骤。The processor is coupled to the memory for executing the computer program for performing the steps in the above stress testing method.
本申请实施例还提供一种存储有计算机指令的计算机可读存储介质,当所述计算机指令被一个或多个处理器执行时,致使所述一个或多个处理器执行上述压力测试方法中的步骤。The embodiment of the present application also provides a computer-readable storage medium storing computer instructions. When the computer instructions are executed by one or more processors, the one or more processors are caused to execute the above stress testing method. step.
在本申请实施例中,在压力测试环境中执行压力测试脚本;并在执行压力测试脚本的过程中,直接将压力测试脚本依赖的代码从代码库中下载至压力测试环境中;并在压力测试环境中执行压力测试脚本依赖的代理,以进行压力测试。这种压力测试方式,在执行压力测试脚本的过程中,直接将压力测试脚本依赖的代码从代码库中下载至压力测试环境中,相较于先把压力测试脚本依赖的代码下载至本地,再从本地上传至压力测试环境中进行压力测试的过程,可省略将压力测试脚本依赖的代码从本地上传至压力测试环境的过程,减少了压力测试脚本依赖的代码的上传时间,进而有助于减少压力测试时间,提高压力测试效率。In the embodiment of the present application, the stress test script is executed in the stress test environment; and in the process of executing the stress test script, the code that the stress test script depends on is directly downloaded from the code base to the stress test environment; and in the stress test The agent on which the stress test script depends is executed in the environment for stress testing. In this stress test method, in the process of executing the stress test script, the code that the stress test script depends on is directly downloaded from the code base to the stress test environment, compared with first downloading the code that the stress test script depends on to the local, and then The process of uploading from the local to the stress test environment for stress testing can omit the process of uploading the code that the stress test script depends on from the local to the stress test environment, reducing the upload time of the code that the stress test script depends on, thereby helping to reduce Stress test time, improve stress test efficiency.
附图说明Description of drawings
此处所说明的附图用来提供对本申请的进一步理解,构成本申请的一部分,本申请的示意性实施例及其说明用于解释本申请,并不构成对本申请的不当限定。在附图中:The drawings described here are used to provide a further understanding of the application and constitute a part of the application. The schematic embodiments and descriptions of the application are used to explain the application and do not constitute an improper limitation to the application. In the attached picture:
图1为本申请实施例提供的压力测试方法的流程示意图;Fig. 1 is a schematic flow chart of the stress testing method provided by the embodiment of the present application;
图2为本申请实施例提供的计算机设备的结构示意图。FIG. 2 is a schematic structural diagram of a computer device provided by an embodiment of the present application.
具体实施方式Detailed ways
为使本申请的目的、技术方案和优点更加清楚,下面将结合本申请具体实施例及相应的附图对本申请技术方案进行清楚、完整地描述。显然,所描述的实施例仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。In order to make the purpose, technical solution and advantages of the present application clearer, the technical solution of the present application will be clearly and completely described below in conjunction with specific embodiments of the present application and corresponding drawings. Apparently, the described embodiments are only some of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in this application, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts belong to the scope of protection of this application.
针对现有压力测试耗时长、效率低的技术问题,本申请实施例提供一种解决方案,基本思路是:在压力测试环境中执行压力测试脚本;并在执行压力测试脚本的过程中,直接将压力测试脚本依赖的代码从代码库中下载至压力测试环境中;并在压力测试环境中执行压力测试脚本依赖的代理,以进行压力测试。这种压力测试方式,在执行压力测试脚本的过程中,直接将压力测试脚本依赖的代码从代码库中下载至压力测试环境中,相较于先把压力测试脚本依赖的代码下载至本地,再从本地上传至压力测试环境中进行压力测试的过程,可省略将压力测试脚本依赖的代码从本地上传至压力测试环境的过程,减少了压力测试脚本依赖的代码的上传时间,进而有助于减少压力测试时间,提高压力测试效率。Aiming at the technical problems of long time-consuming and low efficiency of the existing stress test, the embodiment of the present application provides a solution, the basic idea is: execute the stress test script in the stress test environment; and in the process of executing the stress test script, directly The code that the stress test script depends on is downloaded from the code library to the stress test environment; and the agent that the stress test script depends on is executed in the stress test environment to perform the stress test. In this stress test method, in the process of executing the stress test script, the code that the stress test script depends on is directly downloaded from the code base to the stress test environment, compared with first downloading the code that the stress test script depends on to the local, and then The process of uploading from the local to the stress test environment for stress testing can omit the process of uploading the code that the stress test script depends on from the local to the stress test environment, reducing the upload time of the code that the stress test script depends on, thereby helping to reduce Stress test time, improve stress test efficiency.
以下结合附图,详细说明本申请各实施例提供的技术方案。The technical solutions provided by various embodiments of the present application will be described in detail below in conjunction with the accompanying drawings.
应注意到:相同的标号在下面的附图以及实施例中表示同一物体,因此,一旦某一物体在一个附图或实施例中被定义,则在随后的附图和实施例中不需要对其进行进一步讨论。It should be noted that the same reference numerals represent the same object in the following drawings and embodiments, therefore, once a certain object is defined in one drawing or embodiment, it does not need to be defined in subsequent drawings and embodiments It is discussed further.
图1为本申请实施例提供的压力测试方法的流程示意图。如图1所示,该方法包括:FIG. 1 is a schematic flowchart of a stress testing method provided in an embodiment of the present application. As shown in Figure 1, the method includes:
101、获取压力测试脚本。101. Obtain the stress test script.
102、在压力测试环境中执行压力测试脚本。102. Execute the stress test script in the stress test environment.
103、在执行压力测试脚本的过程中,将压力测试脚本依赖的代码从代码库中下载至压力测试环境中。103. During the process of executing the stress test script, download the code that the stress test script depends on from the code base to the stress test environment.
104、在压力测试环境中执行压力测试脚本依赖的代码,以进行压力测试。104. Execute the code that the stress test script depends on in the stress test environment, so as to perform the stress test.
在程序开发过程中,为了减少开发工作量,开发人员在开发过程中,可引用他人开发的源代码,这种引用关系,也可称为依赖关系,即实现开发人员开发的程序功能的实现依赖于他人开发的源代码。例如,可引用代码库中的源代码等。在本实施例中,压力测试脚本是指对待测软件进行压力测试的脚本。待测软件可为APP、客户端、小程序或Web网页等。In the process of program development, in order to reduce the development workload, the developer can refer to the source code developed by others during the development process. This kind of reference relationship can also be called dependency relationship, that is, the implementation dependency of the program function developed by the developer. source code developed by others. For example, source code in a code repository, etc. may be referenced. In this embodiment, the stress test script refers to a script for stress testing the software to be tested. The software to be tested can be an APP, a client, a small program or a web page, etc.
其中,压力测试脚本可为不依赖他人开发的代码的脚本,也可为依赖他人开发的代码的脚本。针对不依赖他人开发的代码的压力测试脚本,可直接将压力测试脚本上传至压力测试环境中,进行压力测试。因此,本申请实施例中重点对依赖有他人开发的代码的压力测试脚本进行压力测试的过程进行说明。Wherein, the stress test script may be a script that does not rely on codes developed by others, or may be a script that relies on codes developed by others. For stress test scripts that do not rely on code developed by others, you can directly upload the stress test script to the stress test environment for stress testing. Therefore, in the embodiment of the present application, the process of performing stress testing relying on a stress testing script developed by others will be focused on.
在步骤101中,可获取压力测试脚本。可选地,可响应于针对测试脚本的上传操作,获取上传至压力测试环境中的脚本,作为压力测试脚本。其中,压力测试环境可为对待测软件的生产环境进行模拟的软件环境。In
在本实施例中,计算机设备可提供人机交互界面,该界面可包括上传控件。用户可通过该上传控件,将压力测试脚本上传至压力测试环境中。相应地,可响应于针对上传控件的触发操作,显示文件选择界面;响应于针对文件的选择操作,将被选中的文本中的代码作为压力测试脚本。In this embodiment, the computer device may provide a human-computer interaction interface, and the interface may include an upload control. Users can upload stress test scripts to the stress test environment through the upload control. Correspondingly, in response to the trigger operation on the upload control, a file selection interface can be displayed; in response to the selection operation on the file, the code in the selected text can be used as a stress test script.
进一步,在步骤102中,可在压力测试环境中执行压力测试脚本。Further, in
可选地,可利用所述压力测试脚本,生成压力测试脚本对应的Git工程;并将压力测试脚本对应的Git工程集成至Jenkins平台。在Jenkins平台内可实现不同Git工程及压力测试脚本的一体化。在本实施例中,Jenkins平台与压力测试环境连通。相应地,可通过Jenkins平台将所述压力测试脚本对应的Git工程传入压力测试环境;进一步,可响应于针对压力测试脚本的执行事件,在压力测试环境中执行压力测试脚本对应的Git工程,以执行压力测试脚本。Optionally, the stress test script can be used to generate a Git project corresponding to the stress test script; and the Git project corresponding to the stress test script can be integrated into the Jenkins platform. The integration of different Git projects and stress test scripts can be realized in the Jenkins platform. In this embodiment, the Jenkins platform communicates with the stress testing environment. Correspondingly, the Git project corresponding to the stress test script can be imported into the stress test environment through the Jenkins platform; further, in response to an execution event for the stress test script, the Git project corresponding to the stress test script is executed in the stress test environment, to execute the stress test script.
在本申请实施例中,不限定执行事件的具体实现形式。在一些实施例中,可提供人机交互界面。该界面可包括运行控件。用户可触发运行控件,控制代码执行。相应地,可响应于针对运行控件的触发操作所产生的执行事件,在压力测试环境中执行压力测试脚本对应的Git工程,以在压力测试环境中执行压力测试脚本。In this embodiment of the application, the specific implementation form of the execution event is not limited. In some embodiments, a human-computer interface may be provided. The interface may include operational controls. Users can trigger the run control to control code execution. Correspondingly, the Git project corresponding to the stress test script can be executed in the stress test environment in response to the execution event generated by the trigger operation on the running control, so as to execute the stress test script in the stress test environment.
进一步,在步骤103中,在执行压力测试脚本的过程中,可将压力测试脚本依赖的代码从代码库中下载至压力测试环境中。接着,在步骤104中,在压力测试环境中执行压力测试脚本依赖的代码,来进行压力测试。Further, in
在本申请实施例中,不限定代码库的部署位置。可选地,部署代码库的设备与执行压力测试方法的计算机设备处于同一内网环境中。这样,在从代码库中下载压力测试脚本依赖的代码时,可提高代码下载速度,有助于进一步提高压力测试效率。In this embodiment of the application, the deployment location of the code library is not limited. Optionally, the device for deploying the code library and the computer device for executing the stress testing method are in the same intranet environment. In this way, when the code that the stress test script depends on is downloaded from the code library, the code download speed can be improved, which helps to further improve the stress test efficiency.
在本实施例中,可在压力测试环境中执行压力测试脚本;并在执行压力测试脚本的过程中,直接将压力测试脚本依赖的代码从代码库中下载至压力测试环境中;并在压力测试环境中执行压力测试脚本依赖的代码,以进行压力测试。这种压力测试方式,在执行压力测试脚本的过程中,直接将压力测试脚本依赖的代码从代码库中下载至压力测试环境中,相较于先把压力测试脚本依赖的代码下载至本地,再从本地上传至压力测试环境中进行压力测试的过程,可省略将压力测试脚本依赖的代码从本地上传至压力测试环境的过程,减少了压力测试脚本依赖的代码的上传时间,进而有助于减少压力测试时间,提高压力测试效率。In this embodiment, the stress test script can be executed in the stress test environment; and in the process of executing the stress test script, directly download the code that the stress test script depends on from the code library to the stress test environment; and in the stress test Execute the code that the stress test script depends on in the environment for stress testing. In this stress test method, in the process of executing the stress test script, the code that the stress test script depends on is directly downloaded from the code base to the stress test environment, compared with first downloading the code that the stress test script depends on to the local, and then The process of uploading from the local to the stress test environment for stress testing can omit the process of uploading the code that the stress test script depends on from the local to the stress test environment, reducing the upload time of the code that the stress test script depends on, thereby helping to reduce Stress test time, improve stress test efficiency.
尤其针对压力测试脚本依赖的代码比较大的情况,如一些压力测试脚本依赖的代码可能为几十M,甚至上百M,利用先把压力测试脚本依赖的代码下载至本地,再从本地上传至压力测试环境中进行压力测试的方案,压力测试脚本依赖的代码上传至压力测试环境的过程耗时很长,导致压力测试效率低。而本实施例提供的压力测试方式,在执行压力测试脚本的过程中,直接将压力测试脚本依赖的代码从代码库中下载至压力测试环境中,减少了压力测试脚本依赖的代码的上传时间,进而有助于减少压力测试时间,提高压力测试效率。Especially for the situation where the code that the stress test script depends on is relatively large. For example, the code that some stress test scripts depend on may be tens of M, or even hundreds of M. First, download the code that the stress test script depends on to the local, and then upload it from the local to In the stress test solution in the stress test environment, the process of uploading the code that the stress test script depends on to the stress test environment takes a long time, resulting in low stress test efficiency. However, in the stress test method provided by this embodiment, during the execution of the stress test script, the code that the stress test script depends on is directly downloaded from the code base to the stress test environment, which reduces the upload time of the code that the stress test script depends on. This in turn helps to reduce stress testing time and improve stress testing efficiency.
可选地,在执行压力测试脚本的过程中,在压力测试脚本执行至需要调用代码库中的代码的情况下,可获取待调用的函数名;并将待调用的函数名提供给代码库。相应地,代码库可获取待调用的函数名对应的代码,并将获取的待调用的函数对应的代码返回给执行压力测试脚本的计算机设备。Optionally, in the process of executing the stress test script, when the stress test script executes to the point where the code in the code library needs to be called, the name of the function to be called can be obtained; and the name of the function to be called can be provided to the code library. Correspondingly, the code library can acquire the code corresponding to the function name to be called, and return the acquired code corresponding to the function to be called to the computer device executing the stress test script.
进一步,针对执行压力测试脚本的计算机设备,可获取待调用的函数名对应的代码作为压力测试脚本依赖的代码;并将压力测试脚本依赖的代码下载至压力测试环境中。Further, for the computer equipment that executes the stress test script, the code corresponding to the function name to be called can be obtained as the code that the stress test script depends on; and the code that the stress test script depends on is downloaded to the stress test environment.
本申请实施例提供的压力测试方法可适用于对底层接口进行压力测试。底层接口可为DSF接口、DUBBO接口或HTTP接口等,但不限于此。The stress testing method provided in the embodiment of the present application can be applied to stress testing the bottom interface. The underlying interface may be a DSF interface, a DUBBO interface, or an HTTP interface, but is not limited thereto.
相应地,在执行所述压力测试脚本的过程中,还可控制用户并发请求数、执行测试时间以及底层接口请求的启动和禁止元素,以对底层接口进行压力测试。其中,底层接口请求的启动和禁止元素可理解为:启动底层接口请求的条件和禁止底层接口请求的条件等。Correspondingly, during the process of executing the stress test script, the number of concurrent user requests, the execution time of the test, and the enabling and disabling elements of the underlying interface requests can also be controlled, so as to perform stress testing on the underlying interface. Wherein, the start and stop elements of the bottom interface request can be understood as: the conditions for starting the bottom interface request, the conditions for prohibiting the bottom interface request, and the like.
进一步,还可获取压力测试的测试结果数据。可选地,还可根据测试结果数据,生成反映测试结果的可视化数据看板;并显示可视化数据看板,进行直观的测试结果展示,有助于用户直观了解测试结果。其中,可视化数据看板是指:以方便直接的可视化的形式显示数据的看板。可选地,可视化数据看板可以为图形化看板、列表看板等,但不限于于此。其中,图形化看板可为曲线图看板、直方图看板、饼图看板等等。Further, the test result data of the stress test can also be obtained. Optionally, a visual data dashboard reflecting the test results can also be generated based on the test result data; and the visualized data dashboard can be displayed for an intuitive display of the test results, which helps users to intuitively understand the test results. Among them, the visualized data kanban refers to a kanban that displays data in a convenient and direct visual form. Optionally, the visual data Kanban can be a graphical Kanban, a list Kanban, etc., but is not limited thereto. Wherein, the graphic Kanban can be a graph Kanban, a histogram Kanban, a pie chart Kanban and so on.
需要说明的是,上述实施例所提供方法的各步骤的执行主体均可以是同一设备,或者,该方法也由不同设备作为执行主体。比如,步骤101和102的执行主体可以为设备A;又比如,步骤101的执行主体可以为设备A,步骤102的执行主体可以为设备B;等等。It should be noted that the subject of execution of each step of the method provided in the foregoing embodiments may be the same device, or the method may also be executed by different devices. For example, the execution subject of
另外,在上述实施例及附图中的描述的一些流程中,包含了按照特定顺序出现的多个操作,但是应该清楚了解,这些操作可以不按照其在本文中出现的顺序来执行或并行执行,操作的序号如101、102等,仅仅是用于区分开各个不同的操作,序号本身不代表任何的执行顺序。另外,这些流程可以包括更多或更少的操作,并且这些操作可以按顺序执行或并行执行。In addition, in some of the processes described in the above embodiments and accompanying drawings, multiple operations appearing in a specific order are included, but it should be clearly understood that these operations may not be executed in the order in which they appear herein or executed in parallel , the serial numbers of the operations, such as 101, 102, etc., are only used to distinguish different operations, and the serial numbers themselves do not represent any execution order. Additionally, these processes can include more or fewer operations, and these operations can be performed sequentially or in parallel.
相应地,本申请实施例还提供一种存储有计算机指令的计算机可读存储介质,当计算机指令被一个或多个处理器执行时,致使一个或多个处理器执行上述压力测试方法中的步骤。Correspondingly, the embodiment of the present application also provides a computer-readable storage medium storing computer instructions, when the computer instructions are executed by one or more processors, one or more processors are caused to execute the steps in the above stress testing method .
图2为本申请实施例提供的计算机设备的结构示意图。如图2所示,计算机设备包括:存储器20a和处理器20b;其中,存储器20a,用于存储计算机程序。FIG. 2 is a schematic structural diagram of a computer device provided by an embodiment of the present application. As shown in FIG. 2 , the computer device includes: a
处理器20b耦合至存储器20a,用于执行计算机程序以用于:获取压力测试脚本;在压力测试环境中执行压力测试脚本;在执行压力测试脚本的过程中,通过通信组件20c将压力测试脚本依赖的代码从代码库中下载至压力测试环境中;并在压力测试环境中执行压力测试脚本依赖的代码,以进行压力测试。The
可选地,部署代码库的设备与计算机设备处于同一内网环境中。Optionally, the device on which the code library is deployed is in the same intranet environment as the computer device.
在一些实施例中,处理器20bb在压力测试环境中执行压力测试脚本时,具体用于:利用压力测试脚本,生成压力测试脚本对应的Git工程;并将压力测试脚本对应的Git工程集成至Jenkins平台;通过Jenkins平台将压力测试脚本对应的Git工程传入压力测试环境;以及,响应于针对压力测试脚本的执行事件,在压力测试环境中执行压力测试脚本对应的Git工程,以执行压力测试脚本。In some embodiments, when the processor 20bb executes the stress test script in the stress test environment, it is specifically used to: use the stress test script to generate a Git project corresponding to the stress test script; and integrate the Git project corresponding to the stress test script into Jenkins Platform; pass the Git project corresponding to the stress test script into the stress test environment through the Jenkins platform; and, in response to an execution event for the stress test script, execute the Git project corresponding to the stress test script in the stress test environment to execute the stress test script .
可选地,处理器20b在压力测试环境中执行压力测试脚本对应的Git工程时,具体用于:响应于针对屏幕20d上运行控件的触发操作所产生的执行事件,在压力测试环境中执行压力测试脚本对应的Git工程。Optionally, when the
在另一些实施例中,处理器20b在将压力测试脚本依赖的代码从代码库中下载至压力测试环境中时,具体用于:在压力测试脚本执行至需要调用代码库中的代码的情况下,获取待调用的函数名;通过通信组件20c将待调用的函数名提供给代码库,以供代码库返回待调用的函数名对应的代码;通过通信组件20c获取待调用的函数名对应的代码作为压力测试脚本依赖的代码;并将压力测试脚本依赖的代码下载至压力测试环境中。In some other embodiments, when the
在又一些实施例中,处理器20b还用于:在执行压力测试脚本的过程中,控制用户并发请求数、执行测试时间以及底层接口请求的启动和禁止元素,以对底层接口进行压力测试。In some other embodiments, the
可选地,底层接口为DSF接口、DUBBO接口或HTTP接口。Optionally, the underlying interface is a DSF interface, a DUBBO interface or an HTTP interface.
可选地,处理器20b还用于:获取压力测试的测试结果数据;以及,根据测试结果数据,生成反映测试结果的可视化数据看板;并在屏幕20d显示可视化数据看板。Optionally, the
在一些可选实施方式中,如图2所示,该计算机设备还可以包括:电源组件20e、音频组件20f等组件。图2中仅示意性给出部分组件,并不意味着计算机设备必须包含图2所示全部组件,也不意味着计算机设备只能包括图2所示组件。In some optional implementation manners, as shown in FIG. 2 , the computer device may further include: a
在本申请实施例中,存储器用于存储计算机程序,并可被配置为存储其它各种数据以支持在其所在设备上的操作。其中,处理器可执行存储器中存储的计算机程序,以实现相应控制逻辑。存储器可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器(SRAM),电可擦除可编程只读存储器(EEPROM),可擦除可编程只读存储器(EPROM),可编程只读存储器(PROM),只读存储器(ROM),磁存储器,快闪存储器,磁盘或光盘。In the embodiment of the present application, the memory is used to store computer programs, and may be configured to store other various data to support operations on the device where it is located. Wherein, the processor can execute the computer program stored in the memory to realize the corresponding control logic. The memory can be realized by any type of volatile or non-volatile storage devices or their combination, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable Read Only Memory (EPROM), Programmable Read Only Memory (PROM), Read Only Memory (ROM), Magnetic Memory, Flash Memory, Magnetic or Optical Disk.
在本申请实施例中,处理器可以为任意可执行上述方法逻辑的硬件处理设备。可选地,处理器可以为中央处理器(Central Processing Unit,CPU)、图形处理器(GraphicsProcessing Unit,GPU)或微控制单元(Microcontroller Unit,MCU);也可以为现场可编程门阵列(Field-Programmable Gate Array,FPGA)、可编程阵列逻辑器件(ProgrammableArray Logic,PAL)、通用阵列逻辑器件(General Array Logic,GAL)、复杂可编程逻辑器件(Complex Programmable Logic Device,CPLD)等可编程器件;或者为先进精简指令集(RISC)处理器(Advanced RISC Machines,ARM)或系统芯片(System on Chip,SOC)等等,但不限于此。In the embodiment of the present application, the processor may be any hardware processing device capable of executing the logic of the above method. Optionally, the processor can be a central processing unit (Central Processing Unit, CPU), a graphics processing unit (Graphics Processing Unit, GPU) or a micro control unit (Microcontroller Unit, MCU); it can also be a field programmable gate array (Field- Programmable Gate Array (FPGA), Programmable Array Logic (PAL), General Array Logic (GAL), Complex Programmable Logic Device (CPLD) and other programmable devices; or It is an advanced reduced instruction set (RISC) processor (Advanced RISC Machines, ARM) or a system chip (System on Chip, SOC), etc., but not limited thereto.
在本申请实施例中,通信组件被配置为便于其所在设备和其他设备之间有线或无线方式的通信。通信组件所在设备可以接入基于通信标准的无线网络,如WiFi,2G或3G,4G,5G或它们的组合。在一个示例性实施例中,通信组件经由广播信道接收来自外部广播管理系统的广播信号或广播相关信息。在一个示例性实施例中,所述通信组件还可基于近场通信(NFC)技术、射频识别(RFID)技术、红外数据协会(IrDA)技术、超宽带(UWB)技术、蓝牙(BT)技术或其他技术来实现。In the embodiment of the present application, the communication component is configured to facilitate wired or wireless communication between the device where it is located and other devices. The device where the communication component is located can access a wireless network based on communication standards, such as WiFi, 2G or 3G, 4G, 5G or a combination thereof. In one exemplary embodiment, the communication component receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component may also be based on Near Field Communication (NFC) technology, Radio Frequency Identification (RFID) technology, Infrared Data Association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology or other techniques to achieve.
在本申请实施例中,屏幕可以包括液晶显示器(LCD)和触摸面板(TP)。如果屏幕包括触摸面板,屏幕可以被实现为触摸屏,以接收来自用户的输入信号。触摸面板包括一个或多个触摸传感器以感测触摸、滑动和触摸面板上的手势。所述触摸传感器可以不仅感测触摸或滑动动作的边界,而且还检测与所述触摸或滑动操作相关的持续时间和压力。In the embodiment of the present application, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may not only sense a boundary of a touch or swipe action, but also detect duration and pressure associated with the touch or swipe action.
在本申请实施例中,电源组件被配置为其所在设备的各种组件提供电力。电源组件可以包括电源管理系统,一个或多个电源,及其他与为电源组件所在设备生成、管理和分配电力相关联的组件。In the embodiment of the present application, the power supply component is configured to provide power to various components of the device where it is located. A power supply component may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the device in which the power supply component resides.
在本申请实施例中,音频组件可被配置为输出和/或输入音频信号。例如,音频组件包括一个麦克风(MIC),当音频组件所在设备处于操作模式,如呼叫模式、记录模式和语音识别模式时,麦克风被配置为接收外部音频信号。所接收的音频信号可以被进一步存储在存储器或经由通信组件发送。在一些实施例中,音频组件还包括一个扬声器,用于输出音频信号。例如,对于具有语言交互功能的设备,可通过音频组件实现与用户的语音交互等。In the embodiment of the present application, the audio component may be configured to output and/or input audio signals. For example, the audio component includes a microphone (MIC), which is configured to receive an external audio signal when the device on which the audio component is located is in an operation mode, such as a calling mode, a recording mode, and a speech recognition mode. The received audio signal may be further stored in a memory or sent via a communication component. In some embodiments, the audio component further includes a speaker for outputting audio signals. For example, for a device with a language interaction function, the voice interaction with the user can be realized through the audio component.
本实施例提供的计算机设备,可在压力测试环境中执行压力测试脚本;并在执行压力测试脚本的过程中,直接将压力测试脚本依赖的代码从代码库中下载至压力测试环境中;并在压力测试环境中执行压力测试脚本依赖的代理,以进行压力测试。这种压力测试方式,在执行压力测试脚本的过程中,直接将压力测试脚本依赖的代码从代码库中下载至压力测试环境中,相较于先把压力测试脚本依赖的代码下载至本地,再从本地上传至压力测试环境中进行压力测试的过程,可省略将压力测试脚本依赖的代码从本地上传至压力测试环境的过程,减少了压力测试脚本依赖的代码的上传时间,进而有助于减少压力测试时间,提高压力测试效率。The computer equipment provided by this embodiment can execute the stress test script in the stress test environment; and in the process of executing the stress test script, directly download the code that the stress test script depends on from the code base to the stress test environment; and In the stress test environment, execute the agent that the stress test script depends on for stress testing. In this stress test method, in the process of executing the stress test script, the code that the stress test script depends on is directly downloaded from the code base to the stress test environment, compared with first downloading the code that the stress test script depends on to the local, and then The process of uploading from the local to the stress test environment for stress testing can omit the process of uploading the code that the stress test script depends on from the local to the stress test environment, reducing the upload time of the code that the stress test script depends on, thereby helping to reduce Stress test time, improve stress test efficiency.
需要说明的是,本文中的“第一”、“第二”等描述,是用于区分不同的消息、设备、模块等,不代表先后顺序,也不限定“第一”和“第二”是不同的类型。It should be noted that the descriptions of "first" and "second" in this article are used to distinguish different messages, devices, modules, etc. are different types.
本领域内的技术人员应明白,本申请的实施例可提供为方法、系统、或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。Those skilled in the art should understand that the embodiments of the present application may be provided as methods, systems, or computer program products. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
本申请是参照根据本申请实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present application is described with reference to flowcharts and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the present application. It should be understood that each procedure and/or block in the flowchart and/or block diagram, and a combination of procedures and/or blocks in the flowchart and/or block diagram can be realized by computer program instructions. These computer program instructions may be provided to a general purpose computer, special purpose computer, embedded processor, or processor of other programmable data processing equipment to produce a machine such that the instructions executed by the processor of the computer or other programmable data processing equipment produce a An apparatus for realizing the functions specified in one or more procedures of the flowchart and/or one or more blocks of the block diagram.
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to operate in a specific manner, such that the instructions stored in the computer-readable memory produce an article of manufacture comprising instruction means, the instructions The device realizes the function specified in one or more procedures of the flowchart and/or one or more blocks of the block diagram.
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded onto a computer or other programmable data processing device, causing a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process, thereby The instructions provide steps for implementing the functions specified in the flow chart or blocks of the flowchart and/or the block or blocks of the block diagrams.
在一个典型的配置中,计算设备包括一个或多个处理器(CPU)、输入/输出接口、网络接口和内存。In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
内存可能包括计算机可读介质中的非永久性存储器,随机存取存储器(RAM)和/或非易失性内存等形式,如只读存储器(ROM)或闪存(flash RAM)。内存是计算机可读介质的示例。Memory may include non-permanent storage in computer readable media, in the form of random access memory (RAM) and/or nonvolatile memory such as read only memory (ROM) or flash RAM. Memory is an example of computer readable media.
计算机可读介质包括永久性和非永久性、可移动和非可移动媒体可以由任何方法或技术来实现信息存储。信息可以是计算机可读指令、数据结构、程序的模块或其他数据。计算机的存储介质的例子包括,但不限于相变内存(PRAM)、静态随机存取存储器(SRAM)、动态随机存取存储器(DRAM)、其他类型的随机存取存储器(RAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、快闪记忆体或其他内存技术、只读光盘只读存储器(CD-ROM)、数字多功能光盘(DVD)或其他光学存储、磁盒式磁带,磁盘存储或其他磁性存储设备或任何其他非传输介质,可用于存储可以被计算设备访问的信息。按照本文中的界定,计算机可读介质不包括暂存电脑可读媒体(transitory media),如调制的数据信号和载波。Computer-readable media, including both permanent and non-permanent, removable and non-removable media, can be implemented by any method or technology for storage of information. Information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read only memory (ROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Flash memory or other memory technology, Compact Disc Read-Only Memory (CD-ROM), Digital Versatile Disc (DVD) or other optical storage, A magnetic tape cartridge, disk storage or other magnetic storage device or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media excludes transitory computer-readable media, such as modulated data signals and carrier waves.
还需要说明的是,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、商品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、商品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、商品或者设备中还存在另外的相同要素。It should also be noted that the term "comprises", "comprises" or any other variation thereof is intended to cover a non-exclusive inclusion such that a process, method, article, or apparatus comprising a set of elements includes not only those elements, but also includes Other elements not expressly listed, or elements inherent in the process, method, commodity, or apparatus are also included. Without further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of additional identical elements in the process, method, article or apparatus comprising said element.
以上所述仅为本申请的实施例而已,并不用于限制本申请。对于本领域技术人员来说,本申请可以有各种更改和变化。凡在本申请的精神和原理之内所作的任何修改、等同替换、改进等,均应包含在本申请的权利要求范围之内。The above descriptions are only examples of the present application, and are not intended to limit the present application. For those skilled in the art, various modifications and changes may occur in this application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included within the scope of the claims of the present application.
Claims (8)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110009149.6A CN112699044B (en) | 2021-01-05 | 2021-01-05 | Pressure testing method, equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110009149.6A CN112699044B (en) | 2021-01-05 | 2021-01-05 | Pressure testing method, equipment and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112699044A CN112699044A (en) | 2021-04-23 |
CN112699044B true CN112699044B (en) | 2023-02-24 |
Family
ID=75514780
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110009149.6A Active CN112699044B (en) | 2021-01-05 | 2021-01-05 | Pressure testing method, equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112699044B (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113220586A (en) * | 2021-05-31 | 2021-08-06 | 五八到家有限公司 | Automatic interface pressure test execution method, device and system |
CN114003442B (en) * | 2021-09-26 | 2023-09-12 | 苏州浪潮智能科技有限公司 | Pressure test method, device, equipment and medium of ARM server |
CN114817074A (en) * | 2022-05-31 | 2022-07-29 | 中国工商银行股份有限公司 | Stress testing evaluation methods, devices, equipment, media and procedural products |
Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101137170A (en) * | 2007-09-04 | 2008-03-05 | 深圳市中兴移动通信有限公司 | Software automatic testing instrument and method of embedded equipment |
US7721265B1 (en) * | 2003-11-10 | 2010-05-18 | Cisco Technology, Inc. | Source code debugging method and apparatus for use in script testing environment |
CN102567516A (en) * | 2011-12-28 | 2012-07-11 | 华为技术有限公司 | Script loading method and device |
CN104503784A (en) * | 2014-12-16 | 2015-04-08 | 珠海金山网络游戏科技有限公司 | Method and system for controlling micro-client downloading by using script |
CN106201862A (en) * | 2015-05-25 | 2016-12-07 | 阿里巴巴集团控股有限公司 | Web services method for testing pressure and device |
CN107992422A (en) * | 2017-12-08 | 2018-05-04 | 郑州云海信息技术有限公司 | A kind of ameliorative way and device of software compatibility test |
CN110109817A (en) * | 2019-03-13 | 2019-08-09 | 深圳壹账通智能科技有限公司 | Automatic interface testing method, device, equipment and storage medium |
CN110362294A (en) * | 2019-05-27 | 2019-10-22 | 深圳壹账通智能科技有限公司 | Development task executes method, apparatus, electronic equipment and storage medium |
CN110659022A (en) * | 2019-08-19 | 2020-01-07 | 浙江邦盛科技有限公司 | Method for automatically calling Python script based on Java |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8028205B2 (en) * | 2009-03-30 | 2011-09-27 | Hartford Fire Insurance Company | System for providing performance testing information to users |
CN105320589B (en) * | 2014-07-14 | 2017-12-22 | 上海计算机软件技术开发中心 | The automatic resolution system of test script and its implementation in cloud test environment |
CN109446047B (en) * | 2018-10-30 | 2022-03-25 | 武汉斗鱼网络科技有限公司 | Performance test platform script storage method, device, equipment and storage medium |
CN109522173A (en) * | 2018-11-02 | 2019-03-26 | 郑州云海信息技术有限公司 | A kind of OPA network card testing method, device, terminal and storage medium |
-
2021
- 2021-01-05 CN CN202110009149.6A patent/CN112699044B/en active Active
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7721265B1 (en) * | 2003-11-10 | 2010-05-18 | Cisco Technology, Inc. | Source code debugging method and apparatus for use in script testing environment |
CN101137170A (en) * | 2007-09-04 | 2008-03-05 | 深圳市中兴移动通信有限公司 | Software automatic testing instrument and method of embedded equipment |
CN102567516A (en) * | 2011-12-28 | 2012-07-11 | 华为技术有限公司 | Script loading method and device |
CN104503784A (en) * | 2014-12-16 | 2015-04-08 | 珠海金山网络游戏科技有限公司 | Method and system for controlling micro-client downloading by using script |
CN106201862A (en) * | 2015-05-25 | 2016-12-07 | 阿里巴巴集团控股有限公司 | Web services method for testing pressure and device |
CN107992422A (en) * | 2017-12-08 | 2018-05-04 | 郑州云海信息技术有限公司 | A kind of ameliorative way and device of software compatibility test |
CN110109817A (en) * | 2019-03-13 | 2019-08-09 | 深圳壹账通智能科技有限公司 | Automatic interface testing method, device, equipment and storage medium |
CN110362294A (en) * | 2019-05-27 | 2019-10-22 | 深圳壹账通智能科技有限公司 | Development task executes method, apparatus, electronic equipment and storage medium |
CN110659022A (en) * | 2019-08-19 | 2020-01-07 | 浙江邦盛科技有限公司 | Method for automatically calling Python script based on Java |
Also Published As
Publication number | Publication date |
---|---|
CN112699044A (en) | 2021-04-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112699044B (en) | Pressure testing method, equipment and storage medium | |
US10921952B2 (en) | Dynamic button with visual indication of application action result | |
US9430207B1 (en) | Automated cross-platform native mobile application generation with cloud driven user interface and workflow synthesis | |
US10210591B2 (en) | Optimizing compilation of shaders | |
US20120317555A1 (en) | Application development enviroment for portable electronic devices | |
CN111459818B (en) | Visual test method and device | |
CN106126424B (en) | A kind of visual automated testing method of script, device and mobile terminal | |
CN111190825A (en) | Automatic test method, system and robot | |
KR102398315B1 (en) | Electronic device and method for reproduction of sound in the electronic device | |
CN112306447A (en) | An interface navigation method, device, terminal and storage medium | |
CN113296777B (en) | Dependency analysis and program compilation method, apparatus, and storage medium | |
US20170161047A1 (en) | Electronic device and method for improviing installation speed of theme package | |
CN104580972A (en) | Methods and systems for providing media content collected by sensors of a device | |
CN113419941A (en) | Evaluation method and apparatus, electronic device, and computer-readable storage medium | |
CN114840214A (en) | Program compilation and startup method, device and storage medium | |
US20240078072A1 (en) | Method and apparatus for displaying message box, terminal device and non-transitory computer-readable storage medium | |
CN112069503A (en) | Task management method, device and storage medium | |
CN112052146A (en) | Page frame rate testing method, application installation file generating method and device | |
CN111381892B (en) | Data processing method, device, equipment and machine-readable medium | |
CN110945478B (en) | Manage software components for software application development | |
US11586338B2 (en) | Systems and methods for animated computer generated display | |
CN114489721A (en) | DSL description file management method, apparatus, system, device and medium | |
CN114764296A (en) | Machine learning model training method and device, electronic equipment and storage medium | |
CN114840162B (en) | First screen page presentation method, device, electronic device and storage medium | |
CN109684191A (en) | Using packet construction method, device, equipment and readable storage medium storing program for executing |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |