CN107733735B - Script recording system and method implanted in pressure measurement device - Google Patents

Script recording system and method implanted in pressure measurement device Download PDF

Info

Publication number
CN107733735B
CN107733735B CN201710863080.7A CN201710863080A CN107733735B CN 107733735 B CN107733735 B CN 107733735B CN 201710863080 A CN201710863080 A CN 201710863080A CN 107733735 B CN107733735 B CN 107733735B
Authority
CN
China
Prior art keywords
pressure measurement
pressure
script
task
app
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
Application number
CN201710863080.7A
Other languages
Chinese (zh)
Other versions
CN107733735A (en
Inventor
殷晋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Cloudwise Beijing Technology Co Ltd
Original Assignee
Cloudwise Beijing Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Cloudwise Beijing Technology Co Ltd filed Critical Cloudwise Beijing Technology Co Ltd
Publication of CN107733735A publication Critical patent/CN107733735A/en
Application granted granted Critical
Publication of CN107733735B publication Critical patent/CN107733735B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/50Testing arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/51Discovery or management thereof, e.g. service location protocol [SLP] or web services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3684Test management for test design, e.g. generating new test cases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/14Network analysis or design
    • H04L41/145Network analysis or design involving simulating, designing, planning or modelling of a network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72403User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality
    • H04M1/72406User interfaces specially adapted for cordless or mobile telephones with means for local support of applications that increase the functionality by software upgrading or downloading
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01LMEASURING FORCE, STRESS, TORQUE, WORK, MECHANICAL POWER, MECHANICAL EFFICIENCY, OR FLUID PRESSURE
    • G01L1/00Measuring force or stress, in general

Abstract

A script recording system and method, the system includes: the system comprises a back-end server and a server, wherein the back-end server is provided with a plurality of external ports for connecting android equipment and an ADB tool for directly managing the android equipment; and the front-end WEB browser controls and specifies the installation, operation and uninstallation of the APP of the android device. The front end realizes a mobile phone simulator, image information of the android device is sent to the front end mobile phone simulator through Socket, the action on the APP in the mobile phone simulator is sent to the rear end server through Socket, and the rear end server operates the android device through the ADB. The user can select the APK that will produce the script at the front end, and android device is installed with it to the rear end server, and the user passes through cell-phone simulator operation APP at the front end, and android device gathers script access request and sends for the rear end server, and the rear end server sends the access request for the front end show in real time again. The invention can conveniently and quickly record the script by means of the APP network request recording (grabbing) mode, thereby greatly reducing the workload.

Description

Script recording system and method implanted in pressure measurement device
Technical Field
The invention belongs to the field of software system performance test, in particular to a script recording system and a script recording method, which mainly aim at the performance test of a mobile phone program.
Background
In order to perform performance testing on software, a corresponding script needs to be prepared.
In the past, when preparing the script of the APP terminal, the request is either completely written manually or captured in an agent mode.
However, the former requires a very large amount of work, and the latter requires a relatively complicated preparation work.
For example, if a user needs to perform a stress test on the backend performance of his own APP, it needs to prepare a test script for the APP to access the backend. In the process, research and development personnel are required to cooperate with testing personnel to provide the contents of addresses, parameters and the like of all links, the testing personnel debug according to the script, the period may need more than one week, and after the script is debugged, the testing personnel also need to utilize other tools to perform the back-end capability test.
Therefore, no convenient and quick software performance test scheme, particularly a script recording scheme, exists at present.
Disclosure of Invention
In order to solve the above problems in the prior art, the present invention provides a script recording system, which can record scripts conveniently and quickly, and can greatly reduce the workload of a user in the process of preparing scripts.
The invention also provides a script recording method, which can conveniently and quickly record the script and greatly reduce the workload of a user in the process of preparing the script.
In order to achieve the purpose, the invention adopts the main technical scheme that:
a script recording system, comprising:
the system comprises a back-end server and a server, wherein the back-end server is provided with a plurality of external ports for connecting Android equipment and an ADB tool (ADB is short for Android Debug Bridge, is one tool in Android SDK (Android SDK is an Android dedicated software development kit) for directly managing the Android equipment, and can directly operate and manage real Android equipment);
a front-end WEB browser which controls the installation, operation and uninstallation of APP of the designated Android equipment,
the method comprises the steps that a mobile phone simulator is realized at the front end, image information of Android equipment connected with a back-end server is sent to the front-end mobile phone simulator through a Socket, actions on an APP in the mobile phone simulator are sent to the back-end server through the Socket, and the Android equipment is operated by the back-end server through an ADB.
Therefore, the user only needs to upload the APK (the APK is an abbreviation of an Android Package, namely, the Android installation Package) to the front-end WEB browser, and can complete the network request recording of the APP by operating the APP through the mouse through the simulation environment provided by the front-end WEB browser, so that the workload of the user in the process of preparing the script is greatly reduced.
And the actions on the APP in the mobile phone simulator comprise clicking and dragging.
The script recording system comprises a login interface for a user to login and enter the script recording system.
The script recording system can be embedded or embedded in other software, for example, can be embedded in a pressure measurement device.
A script recording method includes the steps that an APK needing to generate a script is selected at the front end of the script recording system by means of the script recording system, a command is sent to a rear-end server, the APK is installed on preset Android equipment by the rear-end server, a user can open the installed APP through a mobile phone simulator at the front end, when the APP is operated by the user, the Android equipment collects a script access request, request information is sent to the rear-end server, and the rear-end server sends the access request to the front end to be displayed in real time.
Therefore, the user only needs to upload the APK (the APK is an abbreviation of an Android Package, namely, the Android installation Package) to the front-end WEB browser, and can complete the network request recording of the APP by operating the APP through the mouse through the simulation environment provided by the front-end WEB browser, so that the workload of the user in the process of preparing the script is greatly reduced.
The APK can be customized in the Android device and used for the Android device to acquire a script access request.
In one embodiment of the present invention, the method mainly comprises the following steps:
s3, uploading the APK file to a front-end WEB browser through a script recording system;
s4, recording a script on an APP interface in real time;
s5, editing and debugging scripts;
and S6, saving the script.
The operation on the APP interface comprises clicking and dragging.
Step S2 is further included before step S3, and the interface enters the script recording system.
Step S1 is further included before step S2, and a pressure measurement interface is logged in.
The invention has the beneficial effects that:
according to the script recording system, by means of a simple APP network request recording (grabbing) mode, a user only needs to upload APK (APK is an abbreviation of Android Package, namely Android installation Package) to a front-end WEB browser, and can complete network request recording of the APP by operating the APP through a mouse through a simulation environment provided by the front-end WEB browser, so that scripts can be recorded conveniently and quickly, and the workload of the user in the process of preparing the scripts is greatly reduced.
According to the script recording method, by means of a simple APP network request recording (grabbing) mode, a user only needs to upload APK (APK is an abbreviation of Android Package, namely Android installation Package) to a front-end WEB browser, and can complete network request recording of the APP by operating the APP through a mouse through a simulation environment provided by the front-end WEB browser, so that scripts can be recorded conveniently and quickly, and the workload of the user in the process of preparing the scripts is greatly reduced.
Drawings
Fig. 1 is a schematic structural diagram of a script recording system according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating a script recording method according to an embodiment of the present invention.
Fig. 3 is a schematic overall flow chart of the resource management system of the distributed cloud pressure measuring machine according to an embodiment of the present invention;
fig. 4 is a schematic overall structure diagram of a resource management method for a distributed cloud pressure tester according to an embodiment of the present invention;
fig. 5 is a schematic diagram of a reservation algorithm in an embodiment of the present invention.
Detailed Description
For the purpose of better explaining the present invention and to facilitate understanding, the present invention will be described in detail by way of specific embodiments with reference to the accompanying drawings.
Referring to fig. 1, a script recording system according to an embodiment of the present invention includes a back-end server having a plurality of external ports for connecting to Android devices and an ADB tool for directly managing the Android devices;
a front-end WEB browser which controls the installation, operation and uninstallation of APP of the designated Android equipment,
the method comprises the steps that a mobile phone simulator is realized at the front end, image information of Android equipment connected with a back-end server is sent to the front-end mobile phone simulator through a Socket, actions (such as clicking, dragging and the like) on an APP in the mobile phone simulator are sent to the back-end server through the Socket, and the Android equipment is operated by the back-end server through an ADB.
Therefore, the user only needs to upload the APK to the front-end WEB browser, the APP can be operated by the mouse through the simulation environment provided by the front-end WEB browser, the network request recording of the APP can be completed, and the workload of the user in the script preparation process is greatly reduced.
The user may record the script according to the following method: the method comprises the steps that an APK needing to generate a script is selected at the front end of a script recording system, a command is sent to a back-end server, the back-end server installs the APK to preset Android equipment, a user can open the installed APP through a mobile phone simulator at the front end, when the user operates the APP, the Android equipment collects a script access request, request information is sent to the back-end server, and the back-end server sends the access request to the front end for real-time display.
In specific implementation, the script can be recorded according to the following steps:
s2, entering a script recording system interface;
s3, uploading the APK file to a front-end WEB browser;
s4, recording a script on an APP interface in real time;
s5, editing and debugging scripts;
and S6, saving the script.
Therefore, by utilizing the script recording system, the user only needs two steps to record the APP script, the workload required in the same working process in the past is greatly reduced, the preparation time from hours or even days is shortened to within 1 hour, and even several minutes can be completed.
In practical application, the script recording system of the present invention can be embedded in other software, such as pressure measurement software, and can be various existing pressure measurement software.
During implementation, the script recording system can be used as a module to be embedded into pressure testing software, so that the script recording system also has an APP testing function on the basis of pressure testing.
The following is an example of a pressure tester:
it may be arranged that, in operation, the pressure measurement treasure is logged first, that is, before step S2, step S1, logging the pressure measurement treasure interface, is executed.
Specifically, referring to fig. 3, the pressure measurement device is a resource management system of a distributed cloud pressure measurement machine, and compared with existing pressure measurement software, the pressure measurement device can implement dynamic planning of resources, can simulate real pressure more accurately, and can obtain a more accurate pressure measurement result. The dynamic start-stop can be realized, and the waste of the pressure measuring machine resource is avoided; in addition, when a problem occurs in the pressure measurement process, the error can be automatically corrected, the pressure measurement resource can be planned again, the interruption of the pressure measurement task can not be caused, and the purpose of pressure measurement can be smoothly achieved.
The resource management system of the distributed cloud pressure measuring machine comprises:
the service management system is used as an operation terminal for the user to perform pressure measurement management;
the system comprises a pressure boosting system, a pressure measurement execution end and a data processing system, wherein the pressure boosting system is deployed in a distributed mode based on a software as a service (SaaS) mode and is used for executing pressure measurement as the pressure measurement execution end;
and the service scheduling system is arranged between the service management system and the boosting system and used for realizing dynamic planning of the pressure measurement resources according to the requirements of the pressure measurement tasks.
Therefore, dynamic planning of the pressure measurement resources can be achieved, a real service scene and user behaviors can be simulated better, and the pressure measurement is more accurate.
Wherein, the service management system includes:
the task reservation module is used for reserving tasks by a user;
and the reservation resource algorithm module is used for selecting the pressure measuring points meeting the preset requirements according to the requirements of the reservation tasks.
Wherein, the service management system further comprises:
and the reservation judging module is used for judging whether the preset pressure measuring point can be reserved or not.
Wherein, the service management system further comprises:
and the return error prompt module is used for returning an error prompt when the preset pressure measuring point cannot be reserved.
Wherein, the service management system further comprises:
and the result real-time display module is used for displaying the pressure measurement result in real time.
Wherein, the boost system includes:
a plurality of pressure measuring machines, each pressure measuring machine is provided with any one or more of the following modules:
the starting module is used for starting the pressure measuring machine by the service scheduling system;
the heartbeat sending module is used for sending the heartbeat of the pressure measuring machine to the service scheduling system;
the pressure measurement task execution module is used for executing a pressure measurement task;
the index acquisition module is used for acquiring pressure measurement indexes (the pressure measurement indexes comprise pressure measurement results);
and the storage module is used for storing the pressure measurement result.
Wherein, the pressure measurement task execution module comprises:
the pressure measurement request module is used for sending a pressure measurement request;
and the load generation module is used for generating a load.
The service scheduling system comprises:
and the resource management algorithm module is used for calculating how the pressure measurement resources are dynamically planned according to the requirements of the pressure measurement tasks and the resource condition of the pressure boosting system.
Wherein, the service scheduling system further comprises:
and the pressure measuring machine selecting module is used for selecting a proper pressure measuring machine.
Wherein, the service scheduling system further comprises:
and the pressure measuring machine stopping module is used for stopping or deleting the pressure measuring machine.
Wherein, the service scheduling system further comprises:
and the task decomposition module is used for decomposing the pressure measurement task into a plurality of subtasks.
Wherein, the service scheduling system further comprises:
and the task allocation module is used for allocating the pressure measurement tasks or subtasks to the pressure measurement machine.
Wherein, the service scheduling system further comprises:
and the task preparation module is used for preparing a pressure measurement task.
Wherein, the service scheduling system further comprises:
and the pressure measuring machine task prejudging module is used for judging whether the pressure measuring machine has a new pressure measuring task within a certain time after the pressure measuring task is finished. For example, the determination can be made before or when the pressure measurement task is completed, so as to improve the execution efficiency of the pressure measurement task and avoid wasting resources.
Wherein, the service scheduling system further comprises:
and the pressure measuring machine state monitoring module is used for monitoring the state of the pressure measuring machine. For example, when an abnormality of the pressure measuring machine is detected, the pressure measuring machine is deleted.
The resource management system of the distributed cloud pressure measuring machine further comprises an OLAP system used for analyzing and processing the pressure measuring result, and the processed data can be displayed in real time through a result real-time display module (for example, on a Web page).
With the adoption of the structure, the resource management system of the distributed cloud pressure measuring machine can realize dynamic planning of resources, can simulate real pressure more accurately, can obtain more accurate pressure test results, and is favorable for solving problems more thoroughly. For example, the cloud host can be automatically started according to the pressure measurement task, and the pressure measurement task is distributed; the state of the cloud host is monitored in real time, when a problem occurs in pressure measurement, the task can be redistributed, and the pressure measurement task can be correctly executed; after the pressure measurement is finished, the cloud host can be automatically closed or a new pressure measurement task can be distributed to the cloud host.
Referring to fig. 4, the resource management of the distributed cloud pressure measuring machine can be realized by the following method, which specifically includes the following steps:
s11, creating a pressure measurement task;
s12, constructing a dynamic pressure measurement platform, comprising: selecting a proper pressure measuring mechanism from the alternative pressure measuring machines to establish a dynamic pressure measuring platform;
and S13, executing the pressure measurement task, and executing the pressure measurement task by using the dynamic pressure measurement platform.
By means of dynamic planning of pressure measurement resources, a proper pressure measurement platform can be dynamically constructed according to the requirements of pressure measurement tasks, so that real pressure can be simulated more accurately, pressure test results can be more accurate, and problems can be solved more thoroughly.
Wherein, step S11 includes: any one or several of the following parameters are set when creating the pressure measurement task: pressure measurement start time, pressure to be simulated, and requirements on a pressure measuring machine.
Preferably, the desired simulated pressure comprises any one or any several of the following parameters: a desired simulated pressure for a predetermined time, a desired simulated pressure per unit time, a change in the desired simulated pressure over the time axis.
Wherein the requirements for the pressure measuring machine include any one or several of the following parameters: the overall performance of the press, the network location where the press is located.
Preferably, any one or any several of the following parameters are included: the performance parameters of each pressure measuring machine, the distribution condition of each pressure measuring machine on the network and the number of the pressure measuring machines.
In step S12, the alternative pressure measuring machines may be distributed at predetermined locations in the country or may be distributed at predetermined locations worldwide.
In step S12, the selecting of the pressure measuring machine includes determining whether the heartbeat of the pressure measuring machine meets a predetermined requirement. Therefore, the pressure measurement resources are more reasonably planned, and a better dynamic pressure measurement platform is constructed.
In step S12, the selecting of the pressure measuring machine includes determining whether the task execution state of the pressure measuring machine meets a predetermined requirement. Therefore, the pressure measurement resources are more reasonably planned, and a better dynamic pressure measurement platform is constructed.
In step S12, the selecting of the pressure tester includes determining whether the task performance capability of the selected pressure tester meets a predetermined requirement. Therefore, the real pressure can be simulated more accurately, and the pressure test result can be more accurate. Such as the configuration of each press.
In step S12, the selecting of the pressure tester includes determining whether the network location of the selected pressure tester meets a predetermined requirement. Therefore, the real pressure can be simulated more accurately, and the pressure test result can be more accurate.
In step S12, the dynamic pressure measurement platform is constructed according to the requirement of the pressure measurement task to be created. Therefore, the real pressure can be simulated more accurately, and the pressure test result can be more accurate.
Preferably, the construction of the dynamic pressure measurement platform comprises new pressurization measurement and deletion of the pressure measurement.
Step S12 includes step S122 of determining whether the predetermined pressure point can be reserved.
In step S122, if the determination result is yes, step S13 is executed.
In step S122, if the determination result is negative, step S123 is executed, and an error prompt is returned.
In step S12, the method further includes step S121, selecting an appropriate pressure measurement point as a predetermined pressure measurement point according to the resource reservation algorithm.
The basic idea of step S121 is to determine whether it is appropriate according to the free time of the pressure measurement point and the matching degree of the reservation task. For example, referring to fig. 5, a specific manner may be: and acquiring the reserved task in the time period according to the starting time and the ending time of the reserved task, judging whether the resources at each time point are sufficient according to the starting time and the ending time of the reserved task, and if the resources are sufficient, taking the pressure measuring point as a preset pressure measuring point to indicate that a new task can be distributed to the pressure measuring point.
Step S13 includes step S131, a task decomposition, that is, the pressure measurement task is decomposed into a plurality of small subtasks, so as to improve the task execution efficiency.
The resource management method of the distributed cloud pressure measuring machine further comprises the step S14 of storing results.
For example, each pressure tester samples the test result in real time and can compress and store the test result.
The resource management method of the distributed cloud pressure measuring machine further comprises a step S15 of displaying results in real time.
For example, the pressure measurement result data may be processed by the OLAP system and presented on a web page in real time.
The resource management method of the distributed cloud pressure measuring machine further comprises the step S16 of stopping the pressure measuring machine after the task is finished. Therefore, resources can be saved, and the utilization rate of the pressure measuring machine can be improved.
The resource management method of the distributed cloud pressure measuring machine further comprises the step S17 of distributing a new task for the pressure measuring machine after the task is finished. Therefore, resources can be saved, the utilization rate of the pressure measuring machine is improved, a series of preparation works such as state monitoring and execution capacity monitoring of the newly started pressure measuring machine can be reduced, and the pressure measuring efficiency is improved.
The resource management method of the distributed cloud pressure measuring machine further comprises a step S18 of judging whether the pressure measuring machine is reused within a predetermined time period after the pressure measuring task is finished, so as to determine whether to retain or delete the pressure measuring machine. Therefore, resources can be saved, and the execution efficiency of the pressure measurement task can be improved.
The resource management method of the distributed cloud pressure measurement machine further comprises the step S19 of monitoring the state of the pressure measurement machine of the dynamic pressure measurement platform. So as to realize the dynamic management of the pressure measuring machine.
The resource management method of the distributed cloud pressure measuring machine further comprises a step S100 of reallocating the pressure measuring tasks when the pressure measuring machine cannot execute the pressure measuring tasks according to the preset requirements, so that the pressure measuring tasks can be correctly executed.
Any one of the above distributed cloud pressure measurement machine resource management methods is a distributed deployment mode based on SaaS simulation, and creates and controls a test through a browser, generates a load from one or more cloud pressure measurement points, simulates a real service scene and user behavior, and performs a pressure test.
By means of the scheme, dynamic planning of resources can be achieved, real pressure can be simulated more accurately, pressure test results can be more accurate, and the problem can be solved more thoroughly. For example, the cloud host can be automatically started according to the pressure measurement task, and the pressure measurement task is distributed; the state of the cloud host is monitored in real time, when a problem occurs in pressure measurement, the task can be redistributed, and the pressure measurement task can be correctly executed; after the pressure measurement is finished, the cloud host can be automatically closed or a new pressure measurement task can be distributed to the cloud host.
The following describes in detail resource management of the distributed cloud pressure measuring machine with a specific application example:
when a certain mother-infant e-commerce website needs to be promoted, customers mainly have wide north (wherein Beijing accounts for 40%, Shanghai accounts for 30%, Guangdong accounts for 30%) and need to simulate a pressure test when 4w users participate in promotion.
A pressure measurement task is reserved and established, a 4W user needs to be simulated to visit a website, wherein a Beijing cloud pressure measurement point needs to simulate a 1.6W user, and Shanghai and Guangdong respectively need to simulate a 1.2W user. The optimal plan obtained through calculation is that 300 users can be simulated by each cloud host 2 core 8G of IaaS in Beijing, 54 cloud hosts are started, and 400 users can be simulated by each cloud host 4 core 8G of IaaS in Shanghai and Guangdong, and 40 cloud hosts are started respectively. The service scheduling system starts the cloud hosts 30 minutes in advance, and decomposes the pressure measurement task into a plurality of subtasks, namely, how many users each cloud host needs to simulate, what target website to visit, and what operation to execute are sent to each cloud host.
When the pressure measurement task starts, each cloud host starts to send a request to a target website according to the requirements of the subtasks, pressure measurement indexes, namely information of the request, return results, time consumed by the request and the like are collected, the information is compressed and sent to the OLAP system, and result data processed by the OLAP system is displayed through a pressure measurement result real-time display interface.
In the pressure measurement process, after the real-time display interface can see that the simulated pressure is generated for a period of time, the response time of one complete access request begins to be prolonged, and an error response begins to appear.
Through analysis and processing of the pressure measurement result, the problems of the DNS, the database, the shopping cart interface and the like of the mother-infant e-commerce website are finally found, so that the problems can be solved in advance, and the adverse effect possibly caused after the product is on line is avoided.
In summary, the invention enables the user to upload the APK to the front-end WEB browser only by means of a simple APP network request recording (capturing) mode, and can complete the network request recording of the APP by operating the APP with the mouse through the simulation environment provided by the front-end WEB browser, so that the script can be recorded conveniently and quickly, and the workload of the user in the script preparation process is greatly reduced.

Claims (7)

1. A script recording system implanted in a pressure measurement appliance, comprising:
the system comprises a back-end server and a server, wherein the back-end server is provided with a plurality of external ports for connecting Android equipment and an ADB tool for directly managing the Android equipment;
a front-end WEB browser which controls the installation, operation and uninstallation of APP of the designated Android equipment,
wherein, the front end realizes a mobile phone simulator, the image information of the Android device connected with the back end server is sent to the front end mobile phone simulator through Socket, the action on the APP in the mobile phone simulator is sent to the back end server through Socket, the back end server operates the Android device through ADB to complete the network request recording of the APP,
the pressure measurement treasured is a distributed cloud pressure measurement machine resource management system, the distributed cloud pressure measurement machine resource management system includes:
the business management system is used as an operation terminal for a user to perform pressure measurement management, wherein the business management system comprises:
a task reservation module for reserving a task for a user,
a reservation resource algorithm module used for selecting the pressure measuring points meeting the preset requirements according to the requirements of the reservation tasks,
the reservation judging module is used for judging whether the preset pressure measuring point can be reserved or not;
the system comprises a pressure boosting system, a pressure measurement execution end and a data processing system, wherein the pressure boosting system is deployed in a distributed mode based on a software as a service (SaaS) mode and is used for executing pressure measurement as the pressure measurement execution end, and the pressure boosting system comprises a plurality of pressure measurement machines;
the service scheduling system is arranged between the service management system and the boosting system and used for realizing dynamic planning of the pressure measurement resources according to the requirements of the pressure measurement tasks, wherein the service scheduling system comprises:
the resource management algorithm module is used for calculating how to dynamically plan the pressure measurement resources according to the requirements of the pressure measurement task and the resource condition of the pressure boosting system,
a task decomposition module for decomposing the pressure measurement task into a plurality of subtasks,
and the pressure measuring machine task prejudging module is used for judging whether the pressure measuring machine has a new pressure measuring task within a certain time after the pressure measuring task is finished so as to determine whether to reserve or delete the pressure measuring machine.
2. The script recording system of claim 1, wherein: the actions of the APP in the mobile phone simulator comprise clicking and dragging.
3. The script recording system of claim 1, wherein: the script recording system comprises a login interface for a user to login and enter the script recording system.
4. A script recording method is characterized in that a distributed deployment mode based on SaaS simulation is used, a test is established and controlled through a browser, the method comprises the step S1 of logging in a pressure test treasure interface, the step S2 is executed, the script recording system interface is entered, an APK needing to generate a script is selected at the front end of the script recording system by means of the script recording system and is sent to a back-end server, the APK is installed on preset Android equipment by the back-end server, a user can open the installed APP through a mobile phone simulator at the front end, when the user operates the APP, the Android equipment collects a script access request, request information is sent to the back-end server, and the back-end server sends the access request to the front end for real-time display, wherein the step S1 comprises the following steps:
s11, creating a pressure measurement task;
s12, constructing a dynamic pressure measurement platform, comprising: selecting a proper pressure measuring mechanism from the alternative pressure measuring machines to establish a dynamic pressure measuring platform;
s13, executing a pressure measurement task, and executing the pressure measurement task by using the dynamic pressure measurement platform;
s18, determining whether the press will be reused within a predetermined time period after the end of its press task, thereby determining whether to retain or delete the press,
in step S12, the method includes the steps of:
s121, selecting a proper pressure measuring point as a preset pressure measuring point according to a reserved resource algorithm,
s122, judging whether the preset pressure point can be reserved or not, if so, executing the step S13,
step S13 includes step S131, task decomposition, that is, the pressure measurement task is decomposed into a plurality of small subtasks.
5. The script recording method according to claim 4, wherein the APK can be customized in the Android device for the Android device to acquire the script access request.
6. The script recording method of claim 4, wherein the step S2 is followed by the steps of:
s3, uploading the APK file to a front-end WEB browser through a script recording system;
s4, operating the APP interface recording script in real time to complete the network request recording of the APP;
s5, editing and debugging scripts;
and S6, saving the script.
7. The script recording method of claim 6, wherein: the operation on the APP interface comprises clicking and dragging.
CN201710863080.7A 2017-06-01 2017-09-22 Script recording system and method implanted in pressure measurement device Active CN107733735B (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710403507 2017-06-01
CN2017104035075 2017-06-01

Publications (2)

Publication Number Publication Date
CN107733735A CN107733735A (en) 2018-02-23
CN107733735B true CN107733735B (en) 2022-03-04

Family

ID=61173273

Family Applications (2)

Application Number Title Priority Date Filing Date
CN201710863126.5A Active CN107707638B (en) 2017-06-01 2017-09-22 Distributed cloud pressure measuring machine resource management system and method
CN201710863080.7A Active CN107733735B (en) 2017-06-01 2017-09-22 Script recording system and method implanted in pressure measurement device

Family Applications Before (1)

Application Number Title Priority Date Filing Date
CN201710863126.5A Active CN107707638B (en) 2017-06-01 2017-09-22 Distributed cloud pressure measuring machine resource management system and method

Country Status (1)

Country Link
CN (2) CN107707638B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110677321B (en) * 2019-09-25 2021-09-17 广州通导信息技术服务有限公司 Elastically-telescopic cloud pressure measuring method, device, equipment and storage medium
CN111193642A (en) * 2019-12-30 2020-05-22 支付宝(杭州)信息技术有限公司 Pressure measurement method, pressure measurement platform, electronic device and readable storage medium
CN112115118B (en) * 2020-08-20 2023-09-22 北京水滴科技集团有限公司 Database pressure measurement optimization method and device, storage medium and electronic equipment
CN112306837A (en) * 2020-11-10 2021-02-02 光大兴陇信托有限责任公司 Cloud pressure testing method and platform, equipment and readable storage medium
CN114465927B (en) * 2022-04-12 2022-08-02 鹏城实验室 DNS server pressure testing method, electronic equipment and readable storage medium
CN115277202A (en) * 2022-07-28 2022-11-01 四川封面传媒科技有限责任公司 Automatic data acquisition system and method for android APP

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106649088A (en) * 2016-10-09 2017-05-10 网易(杭州)网络有限公司 Distributed pressure test method and system
CN106713484A (en) * 2017-01-10 2017-05-24 微梦创科网络科技(中国)有限公司 Performance pressure measurement implementation method, system and server

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101241466B (en) * 2007-02-08 2010-09-29 深圳迈瑞生物医疗电子股份有限公司 Embedded software test method and system
CN101620564B (en) * 2008-06-30 2011-10-19 福建升腾资讯有限公司 Method for automatically testing recording playback mode of terminal system
JP5330302B2 (en) * 2010-03-26 2013-10-30 株式会社富士通エフサス Operation recording program and apparatus
US20130227127A1 (en) * 2010-08-23 2013-08-29 Hitachi, Ltd. Schedule management method and schedule management server
CN101958808B (en) * 2010-10-18 2012-05-23 华东交通大学 Cluster task dispatching manager used for multi-grid access
CN105279087B (en) * 2015-10-21 2018-02-06 北京软件产品质量检测检验中心 Apply method of testing and test system in test software
CN106776313B (en) * 2016-12-13 2020-06-23 广州品唯软件有限公司 Method and device for simulating service and centralized management platform

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106649088A (en) * 2016-10-09 2017-05-10 网易(杭州)网络有限公司 Distributed pressure test method and system
CN106713484A (en) * 2017-01-10 2017-05-24 微梦创科网络科技(中国)有限公司 Performance pressure measurement implementation method, system and server

Also Published As

Publication number Publication date
CN107707638A (en) 2018-02-16
CN107733735A (en) 2018-02-23
CN107707638B (en) 2022-10-21

Similar Documents

Publication Publication Date Title
CN107733735B (en) Script recording system and method implanted in pressure measurement device
CN102567203B (en) A kind of method and system of test distributed file system performance
EP2572294B1 (en) System and method for sql performance assurance services
US7640459B2 (en) Performing computer application trace with other operations
US8028200B2 (en) Tracing operations in multiple computer systems
CN111124850A (en) MQTT server performance testing method, system, computer equipment and storage medium
CN110162471A (en) A kind of method for testing pressure and system based on container cloud
CN108959059B (en) Test method and test platform
CN106933729A (en) A kind of method of testing and system based on cloud platform
CN106850330B (en) Intelligent cloud desktop performance test system and method
CN105426278A (en) Client equipment performance test method and system
CN102693183A (en) Method and system for realizing automatic software testing
CN104461856A (en) Performance test method, device and system based on cloud computing platform
CN108600311B (en) Method and device for simulating interface data by client
WO2015006137A1 (en) Cloud services load testing and analysis
CN104246702A (en) Workflow compilation
CN103246606A (en) Method and system for testing performances of ESB (enterprises service bus) platform
CN110569154B (en) Chip interface function testing method, system, terminal and storage medium
CN109597764A (en) A kind of test method and relevant apparatus of catalogue quota
CN114610597A (en) Pressure testing method, device, equipment and storage medium
CN112199273A (en) Virtual machine pressure/performance testing method and system
CN115248782B (en) Automatic testing method and device and computer equipment
CN114297961A (en) Chip test case processing method and related device
CN112346994A (en) Test information correlation method and device, computer equipment and storage medium
CN109995617A (en) Automated testing method, device, equipment and the storage medium of Host Administration characteristic

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