CN109921925A - A kind of dial testing method and device - Google Patents

A kind of dial testing method and device Download PDF

Info

Publication number
CN109921925A
CN109921925A CN201910116506.1A CN201910116506A CN109921925A CN 109921925 A CN109921925 A CN 109921925A CN 201910116506 A CN201910116506 A CN 201910116506A CN 109921925 A CN109921925 A CN 109921925A
Authority
CN
China
Prior art keywords
testing
server
testing server
terminal cluster
main
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.)
Granted
Application number
CN201910116506.1A
Other languages
Chinese (zh)
Other versions
CN109921925B (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.)
Beijing QIYI Century Science and Technology Co Ltd
Original Assignee
Beijing QIYI Century Science and 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 Beijing QIYI Century Science and Technology Co Ltd filed Critical Beijing QIYI Century Science and Technology Co Ltd
Priority to CN201910116506.1A priority Critical patent/CN109921925B/en
Publication of CN109921925A publication Critical patent/CN109921925A/en
Application granted granted Critical
Publication of CN109921925B publication Critical patent/CN109921925B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Telephonic Communication Services (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Test And Diagnosis Of Digital Computers (AREA)

Abstract

The embodiment of the invention provides a kind of dial testing method, device, main testing server, control server and systems, include: obtain current time corresponding current computer room to testing terminal cluster, according to the load information at the current time received, judge whether all online testing servers can treat testing terminal cluster and carry out testing;If it is not, then one standby server of selection, is configured to newly-increased testing server;Newly-increased testing server is determined as target testing server;Target testing server will be distributed to testing terminal cluster;Distribution information to testing terminal cluster is sent to control server, so that control server, distribution information is sent to target testing server, triggering target testing server treats testing terminal cluster and carries out testing, the accuracy of testing result can be improved to avoid the problem because of testing result inaccuracy caused by testing server overload.

Description

A kind of dial testing method and device
Technical field
The present invention relates to fields of communication technology, more particularly to a kind of dial testing method and device.
Background technique
Testing is as a kind of means of testing for verifying target terminal cluster operating status, process are as follows: in target terminal collection A test program is run in group judges above-mentioned operation knot after call-testing system receives the operation result that target terminal cluster returns Whether fruit is default result, if operation result is default result, target terminal cluster is in normal operating condition;If operation knot Fruit is non-default result or does not receive operation result, then target cluster is in abnormal operational conditions.
Currently, carrying out testing to terminal cluster using call-testing system.Referring to Fig. 1, Fig. 1 is answering for prior art call-testing system Use schematic diagram.As shown in Figure 1, the call-testing system of the prior art, includes multiple testing servers 110.Each testing server 110 It is fixedly connected with the computer room 120 in a region, each terminal cluster 130 corresponding to the computer room carries out testing.
Wherein, the quantity of terminal 130 is not fixed, with corresponding 130 quantity of terminal cluster of computer room 120 in the region Be continuously increased, be responsible for the area terminal cluster testing task testing server 110 load also can constantly increase, such as: CPU Utilization rate can constantly increase, and when load exceeds certain threshold value, that is, overloads, the operation result that some terminal clusters return can It can not can receive, testing server 100 can determine whether that these terminal clusters are in abnormal operational conditions at this time, that is, can incite somebody to action Originally normal operating status is mistaken for abnormal operational conditions to terminal cluster, and then leads to the problem of testing result inaccuracy.
Summary of the invention
The embodiment of the present invention is designed to provide a kind of dial testing method and device.Specific technical solution is as follows:
In a first aspect, being applied to corresponding with computer room in call-testing system the embodiment of the invention provides a kind of dial testing method Main testing server;The call-testing system also includes control server and standby server, wherein a computer room is one corresponding Main testing server and at least one standby server, the dial testing method, comprising:
Obtain current time corresponding current computer room to testing terminal cluster;
Load information acquisition request is sent to the control server;
Receive the negative of current computer room corresponding all online testing server current times that the control server returns Information carrying breath;The load information is that all online testing servers are regularly sent to the control server in the call-testing system 's;
According to the load information at the current time received, judge whether all online testing servers can be treated Testing terminal cluster carries out testing;
If it is not, then one standby server of selection, is configured to newly-increased testing server;
Newly-increased testing server is determined as target testing server;
Target testing server is distributed to testing terminal cluster by described;
The distribution information to testing terminal cluster is sent to the control server, so that the control services The distribution information is sent to the target testing server, triggers the target testing server to described to testing by device Terminal cluster carries out testing.
Further, it is described obtain current time corresponding current computer room to testing terminal cluster the step of, packet It includes:
Obtain all terminal cluster quantity of computer room described in current time;
The terminal cluster quantity is compared with the terminal cluster quantity of the last computer room, judges the terminal Whether number of clusters increases;
When the terminal cluster quantity increases, using newly-increased terminal cluster as to testing terminal cluster.
Further, the call-testing system further include: with the control server communicate to connect, and with the current computer room Corresponding non-master testing server;
Current computer room corresponding all online testing server current times that the control server returns are born In information carrying breath, include: the load information at each non-master testing server current time;
The load information at the current time that the basis receives judges that all online testing servers whether can Treat the step of testing terminal cluster carries out testing, comprising:
According to the load information at the current time received, the main testing server and each non-master testing service are judged Device be assigned with it is described after testing terminal cluster, if can overload;
If it is, all online testing servers, which can not treat testing terminal cluster, carries out testing.
Further, the main testing server is that the control server is corresponding each previously according to the current computer room The registration information that a testing server is sent conducts an election determining;
One standby server of the selection is configured to the step of increasing testing server newly, comprising:
From the physical machine database being arranged for current computer room, obtains idle spare physical machine and be determined as newly-increased testing service Device;
Establish and communicate to connect with the newly-increased testing server so that the newly-increased testing server load testing program and The client-side program communicated with the control server, Xiang Suoshu control server send registration information;
Described the step of newly-increased testing server is determined as target testing server, comprising:
After receiving the newly-increased registered notice of testing server that the control server is sent, newly-increased testing is taken Device be engaged in as target testing server.
Further, the method also includes:
If judging the main testing server and each non-master testing clothes according to the load information at the current time received Business device is being assigned with described after testing terminal cluster, will not overload;Then select the main testing server or non-that will not be overloaded Main testing server, as target testing server;
It executes described by described the step of distributing to target testing server to testing terminal cluster.
Further, the method also includes:
When the non-master testing server for receiving the control server transmission, which goes offline, to be notified, will go offline non-master testing clothes The corresponding terminal cluster of device of being engaged in is used as to testing terminal cluster, is executed described to control server transmission load information acquisition The step of request.
Further, the method also includes:
When the non-master testing server for receiving the control server transmission, which goes offline, to be notified, will go offline non-master testing clothes The corresponding terminal cluster of device of being engaged in is used as to testing terminal cluster, is executed one standby server of the selection, is configured to newly throw in more The step of surveying server.
Further, the control server is Zookeeper server;The main testing server and non-master testing clothes Zookeeper client is provided in business device;
The main testing server and non-master testing server, by the Zookeeper client with it is described Zookeeper server is communicated.
Second aspect, the embodiment of the invention provides a kind of dial testing methods, applied to the control server in call-testing system; The call-testing system also includes main testing server and standby server, wherein the corresponding main testing server of a computer room With at least one standby server;The dial testing method, comprising:
Receive the load information that the corresponding all online testing servers of each computer room are regularly sent;
When receiving the load information acquisition request that the corresponding main testing server of current computer room is sent, Xiang Suoshu Main testing server returns to the load information at current computer room corresponding all online testing server current times;So that the master Testing server judges whether all online testing servers can be treated and dials according to the load information at the current time received It surveys terminal cluster and carries out testing;If it is not, then one standby server of selection, is configured to newly-increased testing server;To newly it throw in more It surveys server and is determined as target testing server;Target testing server is distributed to testing terminal cluster by described;It will be described Distribution information to testing terminal cluster is sent to the control server;
Receive the distribution information to testing terminal cluster that the main testing server is sent;
The distribution information is sent to the target testing server, trigger the target testing server to it is described to Testing terminal cluster carries out testing.
Further, the call-testing system further include: with the control server communicate to connect, and with the current computer room Corresponding non-master testing server;
Described the step of receiving the load information that all online testing servers are regularly sent, comprising:
Receive the load information that the corresponding all online non-master testing servers of each computer room are regularly sent;
In the load information at the current time returned to the main testing server, include: corresponding with current computer room Each non-master testing server current time load information.
Further, the main testing server uses following steps, elects:
Receive the registration information that the corresponding each testing server of current computer room is sent;
According to the registration information, node corresponding with each testing server is generated respectively;
According to the sequencing that the node generates, the corresponding testing server of the node generated earliest is determined as described Main testing server.
Further, this method further includes:
If detecting, non-master testing server goes offline, and sends the non-master testing server that goes offline to the main testing server The notice that goes offline so that the main testing server, according to the load information at the current time, will go offline testing server pair The terminal cluster answered is used as and is allocated to testing terminal cluster;Or the main testing server is made to select an active service Device, is configured to newly-increased testing server, and the corresponding terminal cluster of testing server that will go offline is distributed as to testing terminal cluster To newly-increased testing server.
Further, this method further includes:
The registration information that newly-increased testing server is sent is received to be generated and the newly-increased testing according to the registration information The corresponding node of server;
The newly-increased registered notice of testing server is sent to the main testing server, so that the main testing server is held It goes the described the step of newly-increased testing server will be distributed to testing terminal cluster.
Further, this method further includes:
If detecting, the main testing server goes offline, the elder generation generated according to the non-master testing server corresponding node The corresponding non-master testing server of the node generated earliest is determined as new main testing server by sequence afterwards;
By according to the corresponding relationship of each the testing server and terminal cluster of the distribution information preservation having received, send To the new main testing server, so that the new main testing server is according to the corresponding relationship and all online testing services The load information at device current time is divided using the corresponding terminal cluster of the main testing server of original as to testing terminal cluster Match;Or new main testing server is made to select a standby server, it is configured to newly-increased testing server, by former main testing server Corresponding terminal cluster, which is used as, distributes to newly-increased testing server to testing terminal cluster.
Further, whether detection testing server goes offline in the following way:
Detection is when the timing reaches, if receives the load information that the testing server is sent;
If receiving the load information that the testing server is sent, it is determined that the testing server is online;
If not receiving the load information that the testing server is sent, it is determined that the testing server goes offline.
Further, the control server is Zookeeper server;The main testing server and non-master testing clothes Zookeeper client is provided in business device;
The main testing server and non-master testing server, by the Zookeeper client with it is described Zookeeper server is communicated.
The third aspect, the embodiment of the invention provides a kind of testing devices, are applied to corresponding with computer room in call-testing system Main testing server;The call-testing system also includes control server and standby server, wherein a computer room is one corresponding Main testing server and at least one standby server;Described device includes:
Obtain module to testing terminal cluster, for obtain current time corresponding current computer room to testing terminal Cluster;
Request sending module, for sending load information acquisition request to the control server;
First load information receiving module, for receive current computer room that the control server returns it is corresponding it is all The load information at line testing server current time;The load information be all online testing servers regularly send to The control server;
Judgment module judges all online testing services for the load information according to the current time received Whether device can treat testing terminal cluster and carry out testing;
When newly-increased testing server configuration module for the judging result in the judgment module is no, select one it is standby With server, it is configured to newly-increased testing server;
First object testing server determining module, for newly-increased testing server to be determined as target testing server;
Terminal cluster distribution module, for distributing to target testing server to testing terminal cluster for described;
Information sending module is distributed, the distribution information to testing terminal cluster is sent to the control server, So that the control server, is sent to the target testing server for the distribution information, the target testing clothes are triggered Business device carries out testing to testing terminal cluster to described.
Further, module is obtained to testing terminal cluster, comprising:
Quantity acquisition submodule, for obtaining current time by all terminal cluster quantity in testing network;
Acquisition submodule, for comparing the terminal cluster quantity and the last terminal cluster quantity for executing testing Compared with judging whether the terminal cluster quantity increases;When the terminal cluster quantity increase when, using newly-increased terminal cluster as to Testing terminal.
Further, the call-testing system further include: with the control server communicate to connect, and with the current computer room Corresponding non-master testing server;
Current computer room corresponding all online testing server current times that the control server returns are born In information carrying breath, include: the load information at each non-master testing server current time;
The judgment module judges the main testing clothes specifically for the load information according to the current time received Business device and each non-master testing server be assigned with it is described after testing terminal cluster, if can overload;If it is, institute There is online testing server that can not treat testing terminal cluster and carries out testing.
Further, the main testing server is that the control server is corresponding each previously according to the current computer room The registration information that a testing server is sent conducts an election determining;
The newly-increased testing server configuration module, is specifically used for: from the physical machine database being arranged for current computer room, It obtains idle spare physical machine and is determined as newly-increased testing server;It establishes and communicates to connect with the newly-increased testing server, so that Newly-increased client-side program testing server load testing program and communicated with the control server, takes to the control Business device sends registration information;
The first object testing server determining module, is specifically used for: receiving the institute that the control server is sent After stating the newly-increased registered notice of testing server, using newly-increased testing server as target testing server.
Further, described device further include:
Second target testing server determining module, if for the load information according to the current time received, judgement The main testing server and each non-master testing server are being assigned with described after testing terminal cluster, will not overload; The main testing server or non-master testing server that will not be overloaded then are selected, as target testing server;Trigger described first Terminal cluster distribution module.
Further, the request sending module is also used to when the non-master testing for receiving the control server transmission Server goes offline when notifying, the corresponding terminal of non-master testing server that will go offline is used as to testing terminal cluster, to the control Server sends load information acquisition request.
Further, the newly-increased testing server configuration module is also used to receive the control server and sends Non-master testing server go offline when notifying, the corresponding terminal cluster of non-master testing server that will go offline is used as to testing termination set Group, and the step of executing one standby server of the selection, being configured to newly-increased testing server.
Fourth aspect, the embodiment of the invention provides a kind of testing devices, applied to the control server in call-testing system; The call-testing system also includes main testing server and standby server, wherein the corresponding main testing server of a computer room With at least one standby server;Described device includes:
Second load information receiving module is regularly sent for receiving the corresponding all online testing servers of each computer room Load information;
Load information sending module, for when the load for receiving the corresponding main testing server transmission of current computer room When information acquisition request, current computer room corresponding all online testing server current times are returned to the main testing server Load information judge all online dial so that own load information of the main testing server according to the current time Survey whether server can treat the progress testing of testing terminal cluster;If it is not, then one standby server of selection, is configured to new Throw in more survey server;Newly-increased testing server is determined as target testing server;It is distributed to described to testing terminal cluster Target testing server;The distribution information to testing terminal cluster is sent to the control server;
Information receiving module is distributed, for receiving point described in the main testing server transmission to testing terminal cluster With information;
Second distribution information sending module, for the distribution information to testing terminal cluster to be sent to the target Testing server, so that the target testing server carries out testing to testing terminal cluster to described.
Further, the call-testing system further include: with the control server communicate to connect, and with the current computer room Corresponding non-master testing server;
The second load information receiving module is specifically used for receiving the corresponding all online non-master testing clothes of each computer room The load information that business device is regularly sent;
In the load information at the current time returned to the main testing server, include: corresponding with current computer room Each non-master testing server current time load information.
Further, further includes: main testing server determining module;
The main testing server determining module is specifically used for receiving the corresponding each testing server transmission of current computer room Registration information;According to the registration information, node corresponding with each testing server is generated respectively;According to the section The sequencing that point generates, is determined as the main testing server for the corresponding testing server of the node generated earliest.
The main testing server determining module includes: registration information receiving submodule, node generates submodule and master dials It surveys server and determines submodule;
The registration information receiving submodule, the registration sent for receiving the corresponding each testing server of current computer room Information;
The node generates submodule, for being generated and each testing server respectively according to the registration information Corresponding node;
The main testing server determines submodule, and the sequencing for being generated according to the node will generate earliest The corresponding testing server of node be determined as the main testing server.
Further, device further include: go offline and notify sending module;
Described go offline notifies sending module, if taking for detecting that non-master testing server goes offline to the main testing Business device sends the notice that goes offline for the non-master testing server that goes offline, so that the main testing server, according to the current time Load information, the corresponding terminal cluster of non-master testing server that will go offline are used as and are allocated to testing terminal cluster;Or make institute It states main testing server and selects a standby server, be configured to newly-increased testing server, the testing server that will go offline is corresponding Terminal cluster is used as to testing terminal distribution to newly-increased testing server.
Further, further includes: newly-increased testing server registration module;
The newly-increased testing server registration module receives the registration information that newly-increased testing server is sent, according to described Registration information generates node corresponding with the newly-increased testing server;Newly-increased testing clothes are sent to the main testing server The business registered notice of device, so that the main testing server execution is described will to distribute to the newly-increased testing to testing terminal cluster The step of server.
Further, further includes: main testing server redefines module and corresponding relationship sending module;
The main testing server redefines module, if for detecting that the main testing server goes offline, basis The sequencing that the non-master testing server corresponding node generates, by the corresponding non-master testing server of the node generated earliest It is determined as new main testing server;
The corresponding relationship sending module, each testing server of the distribution information preservation for basis to have received With the corresponding relationship of terminal cluster, it is sent to the new main testing server, so that the new main testing server is according to The load information of corresponding relationship and all online testing server current times, by the corresponding terminal cluster of the main testing server of original It is allocated as to testing terminal cluster;Or new main testing server is made to select a standby server, it is configured to newly throw in more Server is surveyed, gives newly-increased testing server using the corresponding terminal cluster of the main testing server of original as to testing terminal distribution.
Further, further includes: go offline detection module;
The detection module that goes offline, for detecting when the timing reaches, if receive the testing service The load information that device is sent;If receiving the load information that the testing server is sent, it is determined that the testing service exists Line;If not receiving the load information that the testing server is sent, it is determined that the testing service goes offline.
5th aspect, the embodiment of the invention provides a kind of main testing servers, including processor and memory, wherein
The memory, for storing computer program;
The processor, when for executing the program stored on the memory, realization is above-mentioned to be applied to be set by inspection Standby any dial testing method.
6th aspect, the embodiment of the invention provides a kind of control servers, including processor and memory, wherein
The memory, for storing computer program;
The processor when for executing the program stored on the memory, is realized any of the above-described applied to inspection The dial testing method of server.
7th aspect, the embodiment of the invention provides a kind of call-testing systems, including above-mentioned main testing server, control service Device and standby server.
Eighth aspect, it is described computer-readable to deposit the embodiment of the invention also provides a kind of computer readable storage medium Instruction is stored in storage media, when run on a computer, so that computer executes any of the above-described dial testing method.
A kind of dial testing method and device provided in an embodiment of the present invention, it is main to dial when needing testing terminal cluster in computer room Surveying server can be according to the load information at all online testing server current times obtained from control server, and judgement is all Whether online testing server can treat testing terminal cluster and carry out testing, if not can be carried out testing, selection one is spare Server is configured to newly-increased testing server, will distribute to testing terminal cluster to newly-increased testing server, with to above-mentioned wait dial It surveys terminal cluster and carries out testing, to realize the dynamic allocation of terminal cluster.It is fixed with one testing server of the prior art The fixed allocation mode of terminal cluster in a corresponding region computer room is compared, and in the embodiment of the present invention, in computer room, is arranged standby Standby server is selected when all online testing servers, which can not treat testing terminal cluster, carries out testing with server, And it is configured to newly-increased testing server, testing terminal cluster is treated with newly-increased testing server and carries out testing, realizes testing system The on-line rapid estimation of system is avoided due to which testing terminal cluster is excessive or the testing result inaccuracy of testing server caused by overloading The problem of, and then the accuracy of testing result can be improved.
Certainly, implement any of the products of the present invention or method it is not absolutely required at the same reach all the above excellent Point.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below There is attached drawing needed in technical description to be briefly described.
Fig. 1 is prior art call-testing system structural schematic diagram;
Fig. 2 is the structural schematic diagram of call-testing system provided in an embodiment of the present invention;
Fig. 3 is a kind of flow diagram that dial testing method provided in an embodiment of the present invention is applied to main testing server;
Fig. 4 is another flow diagram that dial testing method provided in an embodiment of the present invention is applied to main testing server;
Fig. 5 is a kind of flow diagram that dial testing method provided in an embodiment of the present invention is applied to control server;
Fig. 6 is a specific example interaction diagrams using dial testing method provided in an embodiment of the present invention;
Fig. 7 is a kind of structural schematic diagram of testing device provided in an embodiment of the present invention;
Fig. 8 is the structural schematic diagram of another testing device provided in an embodiment of the present invention;
Fig. 9 is a kind of structural schematic diagram of main testing server provided in an embodiment of the present invention;
Figure 10 is a kind of structural schematic diagram of control server provided in an embodiment of the present invention.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Site preparation description.
In order to improve the accuracy of testing result, set the embodiment of the invention provides a kind of dial testing method, device, by inspection Standby, patrol checking server and network system, are described in detail separately below.
To carry out testing to by all terminals in testing network, control is increased in call-testing system in the embodiment of the present invention Control server.As shown in Fig. 2, the call-testing system include: main testing server 100, non-master testing server 200 and with each group The control server 300 of server communication connection is surveyed, is separately installed in each testing server corresponding with control server 300 Control client, main testing server 100 is the registration letter that control server 300 is sent previously according to each testing server Breath conducts an election determining, and each computer room is corresponding with the testing server and non-master testing server of this computer room.
Further, above-mentioned call-testing system further include: terminal cluster database;
Terminal cluster database can be used for storing the interconnection of terminal in the quantity and each terminal cluster of all terminal clusters The information such as fidonetFido address.
Further, above-mentioned call-testing system further include: the corresponding physical machine database of each computer room;
The corresponding physical machine database of each computer room can be used for storing the load letter of all standby servers in the computer room Breath.
Referring to Fig. 3, Fig. 3 is that dial testing method provided in an embodiment of the present invention shows applied to a kind of process of main testing server It is intended to.
In the present embodiment, following dial testing methods can be periodically executed according to a certain preset duration, also can according to need not Following dial testing methods are periodically executed, about the trigger condition for executing this method, are not construed as limiting herein.
What the main testing server in the present embodiment can send for control server previously according to each testing server Registration information conducts an election determining.
The above method specifically comprises the following steps:
Step 301, obtain current time corresponding current computer room to testing terminal cluster.
It can obtain above-mentioned terminal cluster with the following method: obtain all of current time corresponding current computer room Terminal cluster quantity;Terminal cluster quantity is compared with the terminal cluster quantity of last computer room, judges terminal cluster number Whether amount increases;When terminal cluster quantity increases, using newly-increased terminal cluster as to testing terminal.
Step 302, load information acquisition request is sent to control server.
Load information in the present embodiment can be cpu busy percentage, memory usage etc., for the specific interior of load information Hold, is not construed as limiting.
Step 303, current computer room corresponding all online testing server current times that control server returns are received Load information.
Wherein, load information is that all online testing servers are regularly sent to control server.
In the present embodiment, can also include in call-testing system communicated to connect with control server, and with the current machine The corresponding non-master testing server in room, at this point, load information includes: the load letter at each non-master testing server current time Breath.
Step 304, according to the load information at the current time received, judge that all online testing servers whether can It treats testing terminal cluster and carries out testing.
It is corresponding with step 303, when further include in call-testing system with control server communication connection non-master testing server When, it can judge that main testing server and each non-master testing server exist according to the load information at the current time received It is assigned with after testing terminal cluster, if can overload.If it is, all online testing servers can not treat testing Terminal cluster carries out testing.
Step 305, if it is not, then one standby server of selection, is configured to newly-increased testing server.
A standby server is selected, the specific steps for being configured to newly-increased testing server may is that
From the physical machine database being arranged for current computer room, obtains idle spare physical machine and be determined as newly-increased testing service Device;
It establishes and communicates to connect with newly-increased testing server, so that newly-increased testing server loads testing program and takes with control The client-side program of business device communication, sends registration information to control server.
Step 306, newly-increased testing server is determined as target testing server.
Specifically, can be after the newly-increased registered notice of testing server for receiving control server transmission, it will be new Throw in more and surveys server as target testing server.
Step 307, target testing server will be distributed to testing terminal cluster.
Step 308, the distribution information to testing terminal cluster is sent to control server, so that control server, it will Distribution information is sent to target testing server, and triggering target testing server treats testing terminal cluster and carries out testing.
In the present embodiment, control server can be Zookeeper server;Main testing server and non-master testing service Zookeeper client is provided in device;Main testing server and non-master testing server, by Zookeeper client with Zookeeper server is communicated.
By the above embodiments as it can be seen that in embodiments of the present invention, in computer room, standby server is set, when it is all When line testing server can not treat the progress testing of testing terminal cluster, standby server is selected, and is configured to newly-increased testing Server treats testing terminal cluster with newly-increased testing server and carries out testing, realizes the on-line rapid estimation of call-testing system, avoid Due to testing terminal cluster is excessive or the problem of the testing result inaccuracy of testing server caused by overloading, and then can mention The accuracy of high testing result.
Referring to fig. 4, another process that Fig. 4 dial testing method provided in an embodiment of the present invention is applied to main testing server is shown It is intended to, specifically comprises the following steps:
Step 401, obtain current time corresponding current computer room to testing terminal cluster.
The method to testing terminal cluster for obtaining current time corresponding current computer room is identical as step 301, this In repeat no more.
Step 402, load information acquisition request is sent to control server.
Step 403, current computer room corresponding all online testing server current times that control server returns are received Load information.
Step 404, according to the load information at the current time received, judge that all online testing servers whether can It treats testing terminal cluster and carries out testing.If not, executing step 405;If so, executing step 408.
The content of step 401-404 is identical as step 301-304 respectively, and details are not described herein again.
Step 405, if not, from the physical machine database being arranged for current computer room, idle spare physical machine is obtained, really It is set to newly-increased testing server.
Step 406, establish and communicate to connect with newly-increased testing server so that newly-increased testing server load testing program and The client-side program communicated with control server sends registration information to control server.
Step 407, after the newly-increased registered notice of testing server for receiving control server transmission, newly-increased testing is taken Device be engaged in as target testing server.
Step 408, the main testing server or non-master testing server that will not be overloaded are selected, as target testing service Device.
Step 409, target testing server will be distributed to testing terminal cluster.
Step 410, the distribution information to testing terminal cluster is sent to control server, so that control server, it will Distribution information is sent to target testing server, and triggering target testing server treats testing terminal cluster and carries out testing.
Step 411, the non-master testing server for receiving control server transmission goes offline notice, and the non-master testing that will go offline takes The corresponding terminal cluster of device of being engaged in is used as the step for executing to testing terminal cluster and sending load information acquisition request to control server Suddenly.
During testing, when the non-master testing server for receiving control server transmission, which goes offline, to be notified, it will go offline The corresponding terminal cluster of non-master testing server is used as to testing terminal cluster, 402 is returned to step, thus non-master to going offline The corresponding terminal cluster of testing server carries out testing again.
In the present embodiment, control server can be Zookeeper server;Main testing server and non-master testing service Zookeeper client is provided in device;Main testing server and non-master testing server, by Zookeeper client with Zookeeper server is communicated.
In embodiments of the present invention, when needing testing terminal cluster, if all online testing servers can not be treated Testing terminal cluster carries out testing, selects standby server, and is configured to newly-increased testing server, with newly-increased testing server pair Testing is carried out to testing terminal cluster, if online testing server, which can treat testing terminal cluster, carries out testing, is selected not The main testing server or non-master testing server that can be overloaded treat testing terminal cluster and carry out testing, avoid due to testing end The problem of the testing result inaccuracy of testing server caused by holding cluster excessive or overloading, and then testing result can be improved Accuracy.When the non-master testing server for receiving control server transmission, which goes offline, to be notified, will go offline non-master testing server Corresponding terminal cluster is used as to testing terminal cluster, re-starts testing, avoid since non-master testing server goes offline and The problem of caused terminal cluster corresponding with the non-master testing server that goes offline can not be by testing.
Referring to Fig. 5, Fig. 5 is a kind of process signal that dial testing method provided in an embodiment of the present invention is applied to control server Figure,
Specifically comprise the following steps:
Step 501, the load information that the corresponding all online testing servers of each computer room are regularly sent is received.
In the present embodiment, call-testing system can also include: communicated to connect with control server, and with the current computer room Corresponding non-master testing server;Main testing is surveyed server and can be elected in the following way: it is corresponding to receive current computer room Each testing server send registration information;According to registration information, section corresponding with each testing server is generated respectively Point;According to the sequencing that node generates, the corresponding testing server of the node generated earliest is determined as main testing server.
The step of receiving the load information that the corresponding all online testing servers of each computer room are regularly sent, comprising: connect Receive the load information that the corresponding all online non-master testing servers of each computer room are regularly sent.
Step 502, when receiving the load information acquisition request that the corresponding main testing server of current computer room is sent, to Main testing server returns to the load information at current computer room corresponding all online testing server current times;So that main testing Server judges whether all online testing servers can treat testing end according to the load information at the current time received Cluster is held to carry out testing;If it is not, then one standby server of selection, is configured to newly-increased testing server;Newly-increased testing is taken Business device is determined as target testing server;Target testing server will be distributed to testing terminal cluster;It will be to testing termination set The distribution information of group is sent to control server.
When call-testing system includes the non-master testing server with control server communication connection, returned to main testing server In the load information at the current computer room corresponding all online testing server current times returned, it may include: each non-master group Survey the load information at server current time.
Step 503, the distribution information to testing terminal cluster that main testing server is sent is received.
Step 504, distribution information is sent to target testing server, triggering target testing server treats testing terminal Cluster carries out testing.
In the present embodiment, control server can be Zookeeper server;Main testing server and non-master testing service Zookeeper client is provided in device;Main testing server and non-master testing server, by Zookeeper client with Zookeeper server is communicated.
In embodiment shown in fig. 5, when needing testing terminal cluster, control server receives main testing server hair When the load information acquisition request sent, and the load information at all online testing server current times is sent to main testing and is taken Business device, so that own load information of the main testing server according to all online testing server current times, by newly-increased terminal As the target testing server to testing terminal distribution to load less than default load threshold, and then make target testing server Testing is carried out to newly-increased terminal, it can thus be avoided because to testing terminal excessively, testing result caused by testing server overload The problem of inaccuracy, and then the accuracy of testing result can be improved.
In order to embody the interaction flow in embodiment illustrated in fig. 2 between each equipment, referring to Fig. 6, Fig. 6 is real shown in Fig. 2 The interaction diagrams in example between each equipment are applied, specific interactive process includes:
Step 600, the corresponding each testing server of each computer room regularly sends load information to control server.
In this step, each corresponding main testing server of computer room and non-master testing server are periodically to control server Send the load information of itself.
Step 601, main testing server obtain current time corresponding computer room to testing terminal cluster.
Obtain the method and step 301 phase to testing terminal cluster of current time computer room corresponding with main testing server Together, which is not described herein again.
Step 602, main testing server sends load information acquisition request to control server.
Step 603, control server returns to the corresponding all online testing servers of current computer room to main testing server The load information at current time.
Step 604, main testing server judges according to the load information at the current computer room corresponding current time received Whether the current corresponding all online testing servers of computer room can treat testing terminal cluster and carry out testing.If not, executing Step 605;If so, executing step 610.
Judge whether the corresponding all online testing servers of current computer room can be corresponding to current computer room to testing end The method for holding cluster to carry out testing is identical as step 304, and details are not described herein again.
Step 605, main testing server selects a standby server.
Step 606, standby server is configured newly-increased testing server by main testing server.
The step of configuring newly-increased testing server may is that
From the physical machine database being arranged for current computer room, obtains idle spare physical machine and be determined as newly-increased testing service Device;
It establishes and communicates to connect with newly-increased testing server, so that newly-increased testing server loads testing program and takes with control The client-side program of business device communication.
Step 607, it increases testing server newly and sends registration information to control server.
In the present embodiment, main testing server corresponds to each testing server previously according to current computer room for control server The registration information of transmission conducts an election determining, and detailed process is as follows:
Receive the registration information that the corresponding each testing server of current computer room is sent;According to registration information, generate respectively Node corresponding with each testing server;According to the sequencing that node generates, by the corresponding testing of the node generated earliest Server determines to be main testing server.
In this step, control server, can also basis after receiving the registration information that newly-increased testing server is sent Registration information can generate node corresponding with newly-increased testing server.
Step 608, control server sends the newly-increased registered notice of testing server to main testing server.
Step 609, newly-increased testing server is determined as target testing server and executes step later by main testing server Rapid 611.
Step 610, the main testing server or non-master testing server that will not be overloaded are selected, as target testing service Device.
Step 611, main testing server will distribute to target testing server to testing terminal cluster.
Step 612, main testing server sends the distribution information to testing terminal cluster to control server.
Step 613, control server sends testing instruction to target testing server, so that target testing server is treated Testing terminal cluster carries out testing.
When target testing server is the main testing server that will not be overloaded or non-master testing server in step 610 When, then testing instruction is sent to the above-mentioned main testing server that will not be overloaded or non-master testing server;When target testing service When device is the newly-increased testing server in step 606, then testing instruction is sent to newly-increased testing server.
During testing, control server can detecte the state of each testing server, judge each testing service Whether device goes offline, and specific method can be with are as follows: detection is when timing reaches, if receives the load of testing server transmission Information;If receiving the load information of testing server transmission, it is determined that testing service online;If not receiving testing clothes The load information that business device is sent, it is determined that testing server goes offline.
Further, when control server detects that non-master testing server goes offline, step 614, control server to Main testing server sends non-master testing server and goes offline notice, to trigger to main testing server execution above-mentioned steps 604 Step, so that will go offline the corresponding terminal of testing server according to the load information at all online testing server current times Cluster is used as and is allocated to testing terminal;Or main testing server is made to select a standby server, it is configured to newly-increased testing Server, the corresponding terminal cluster of testing server that will go offline give newly-increased testing server as to testing terminal distribution.
When control server detects that main testing server goes offline, then generated according to non-master testing server corresponding node Sequencing, the corresponding non-master testing server of the node generated earliest is determined as new main testing server;It will be according to The corresponding relationship of each the testing server and terminal cluster of the distribution information preservation received is sent to new main testing service Device, so that newly main testing server, will be former according to the load information of corresponding relationship and all online testing server current times The corresponding terminal of main testing server to testing terminal cluster as being allocated;Or make new main testing server select one it is standby With server, it is configured to newly-increased testing server, using the corresponding terminal cluster of the main testing server of original as to testing termination set Group distributes to newly-increased testing server.
Control server in the present embodiment can be Zookeeper server;Main testing server and non-master testing clothes Zookeeper client is provided in business device;Main testing server and non-master testing server, pass through Zookeeper client It is communicated with Zookeeper server.
In embodiments of the present invention, when needing testing terminal cluster, if all online testing servers can not be treated Testing terminal cluster carries out testing, selects standby server, and is configured to newly-increased testing server, with newly-increased testing server pair Testing is carried out to testing terminal cluster, if online testing server, which can treat testing terminal cluster, carries out testing, is selected not The main testing server or non-master testing server that can be overloaded treat testing terminal cluster and carry out testing, avoid due to testing end The problem of the testing result inaccuracy of testing server caused by holding cluster excessive or overloading, and then testing result can be improved Accuracy;When non-master testing server goes offline, the corresponding terminal cluster of non-master testing server that will go offline was used as to testing end Cluster is held, testing is re-started;When main testing server goes offline, new main testing server is re-elected, new main testing clothes Business device redistributes the corresponding terminal of former main testing server, avoid caused by being gone offline due to testing server with The problem of corresponding terminal cluster of testing server that goes offline can not be by testing.
Based on the same inventive concept, the dial testing method provided according to that above embodiment of the present invention, correspondingly, the present invention one Embodiment additionally provides a kind of testing device, the main testing server corresponding with computer room in call-testing system, the testing System also includes control server and standby server, wherein a computer room corresponds to a main testing server and at least one Standby server, the structural schematic diagram of the device as shown in fig. 7, comprises:
Obtain module 701 to testing terminal cluster, for obtain current time corresponding current computer room to testing Terminal cluster;
Request sending module 702, for sending load information acquisition request to the control server;
First load information receiving module 703, the corresponding institute of current computer room returned for receiving the control server There is the load information at online testing server current time;The load information is that all online testing server timings are sent out It send to the control server;
Judgment module 704 judges all online testing clothes for the load information according to the current time received Whether business device can treat testing terminal cluster and carry out testing;
When newly-increased testing server configuration module 705 for the judging result in the judgment module is no, one is selected Standby server is configured to newly-increased testing server;
First object testing server determining module 706, for newly-increased testing server to be determined as target testing service Device;
Terminal cluster distribution module 707, for distributing to target testing server to testing terminal cluster for described;
Information sending module 708 is distributed, the distribution information to testing terminal cluster is sent to the control and is serviced Device, so that the control server, is sent to the target testing server for the distribution information, triggers the target testing Server carries out testing to testing terminal cluster to described.
Further, module 701 is obtained to testing terminal cluster, comprising:
Quantity acquisition submodule, for obtaining current time by all terminal quantities in testing network;
Acquisition submodule, for comparing the terminal cluster quantity and the last terminal cluster quantity for executing testing Compared with judging whether the terminal cluster quantity increases;When the terminal cluster quantity increase when, using newly-increased terminal cluster as to Testing terminal cluster.
Further, further includes: communicated to connect with the control server, and non-master group corresponding with the current computer room Survey server;
Current computer room corresponding all online testing server current times that the control server returns are born In information carrying breath, include: the load information at each non-master testing server current time;
The judgment module 704 judges the main testing specifically for the load information according to the current time received Server and each non-master testing server be assigned with it is described after testing terminal cluster, if can overload;If it is, All online testing servers can not treat testing terminal cluster and carry out testing.
Further, the main testing server is that the control server is corresponding each previously according to the current computer room The registration information that a testing server is sent conducts an election determining;
The newly-increased testing server configuration module 705, is specifically used for: from the physical machine database being arranged for current computer room In, it obtains idle spare physical machine and is determined as newly-increased testing server;It establishes and communicates to connect with the newly-increased testing server, with Make newly-increased client-side program testing server load testing program and communicated with the control server, to the control Server sends registration information;
The first object testing server determining module 706, is specifically used for: receiving what the control server was sent After the newly-increased registered notice of testing server, using newly-increased testing server as target testing server.
Further, described device further include:
Second target testing server determining module, if for the load information according to the current time received, judgement The main testing server and each non-master testing server are being assigned with described after testing terminal cluster, will not overload; The main testing server or non-master testing server that will not be overloaded then are selected, as target testing server;Trigger described first Terminal cluster distribution module.
Further, the request sending module 702 is also used to work as non-master group for receiving the control server transmission It surveys server to go offline when notifying, the corresponding terminal cluster of non-master testing server that will go offline is used as to testing terminal cluster, to institute It states control server and sends load information acquisition request.
Further, the newly-increased testing server configuration module 705 is also used to receive the control server hair The non-master testing server sent goes offline when notifying, the corresponding terminal cluster of non-master testing server that will go offline is used as to testing terminal Cluster, and the step of executing one standby server of the selection, being configured to newly-increased testing server.
In the embodiment of the present invention, in computer room, standby server is set, when all online testing servers can not be treated When testing terminal cluster carries out testing, standby server is selected, and is configured to newly-increased testing server, with newly-increased testing server It treats testing terminal cluster and carries out testing, realize the on-line rapid estimation of call-testing system, avoid due to excessive to testing terminal cluster Or the problem of the testing result inaccuracy of testing server caused by overloading, and then the accuracy of testing result can be improved.
Based on the same inventive concept, the dial testing method provided according to that above embodiment of the present invention, correspondingly, the present invention one Embodiment additionally provides a kind of testing device, the control server in call-testing system;The call-testing system is also dialled comprising main Survey server and standby server, wherein a corresponding main testing server of computer room and at least one standby server, it should The structural schematic diagram of device is as shown in Figure 8, comprising:
Second load information receiving module 801, for receiving the corresponding all online testing server timings of each computer room The load information of transmission;
Load information sending module 802 receives what the corresponding main testing server of current computer room was sent for working as When load information acquisition request, it is current that the corresponding all online testing servers of current computer room are returned to the main testing server The load information at moment so that own load information of the main testing server according to the current time, judge it is all Whether line testing server can treat testing terminal cluster and carry out testing;If it is not, then one standby server of selection, configuration To increase testing server newly;Newly-increased testing server is determined as target testing server;It will be described to testing terminal cluster point Dispensing target testing server;The distribution information to testing terminal cluster is sent to the control server;
Information receiving module 803 is distributed, for receiving described in the main testing server transmission to testing terminal cluster Distribution information;
Second distribution information sending module 804, it is described for the distribution information to testing terminal cluster to be sent to Target testing server, so that the target testing server carries out testing to testing terminal cluster to described.
Further, the call-testing system further include: with the control server communicate to connect, and with the current computer room Corresponding non-master testing server;
It is corresponding all non-master groups online to be specifically used for each computer room of reception for the second load information receiving module 801 Survey the load information that server is regularly sent;
In the load information at the current time returned to the main testing server, include: corresponding with current computer room Each non-master testing server current time load information.
Further, further includes: main testing server determining module;
The main testing server determining module is specifically used for receiving the corresponding each testing server transmission of current computer room Registration information;According to the registration information, node corresponding with each testing server is generated respectively;According to the section The sequencing that point generates, is determined as the main testing server for the corresponding testing server of the node generated earliest.
The main testing server determining module includes: registration information receiving submodule, node generates submodule and master dials It surveys server and determines submodule;
The registration information receiving submodule, the registration sent for receiving the corresponding each testing server of current computer room Information;
The node generates submodule, for being generated and each testing server respectively according to the registration information Corresponding node;
The main testing server determines submodule, and the sequencing for being generated according to the node will generate earliest The corresponding testing server of node be determined as the main testing server.
Further, device further include: go offline and notify sending module;
Described go offline notifies sending module, if taking for detecting that non-master testing server goes offline to the main testing Business device sends the notice that goes offline for the non-master testing server that goes offline, so that the main testing server, according to the current time Load information, the corresponding terminal cluster of non-master testing server that will go offline are used as and are allocated to testing terminal cluster;Or make institute It states main testing server and selects a standby server, be configured to newly-increased testing server, the testing server that will go offline is corresponding Terminal cluster, which is used as, distributes to newly-increased testing server to testing terminal cluster.
Further, further includes: newly-increased testing server registration module;
The newly-increased testing server registration module receives the registration information that newly-increased testing server is sent, according to described Registration information generates node corresponding with the newly-increased testing server;Newly-increased testing clothes are sent to the main testing server The business registered notice of device, so that the main testing server execution is described will to distribute to the newly-increased testing to testing terminal cluster The step of server.
Further, further includes: main testing server redefines module and corresponding relationship sending module;
The main testing server redefines module, if for detecting that the main testing server goes offline, basis The sequencing that the non-master testing server corresponding node generates, by the corresponding non-master testing server of the node generated earliest It is determined as new main testing server;
The corresponding relationship sending module, each testing server of the distribution information preservation for basis to have received With the corresponding relationship of terminal cluster, it is sent to the new main testing server, so that the new main testing server is according to The load information of corresponding relationship and all online testing server current times, by the corresponding terminal cluster of the main testing server of original It is allocated as to testing terminal cluster;Or new main testing server is made to select a standby server, it is configured to newly throw in more Server is surveyed, distributes to newly-increased testing service using the corresponding terminal cluster of the main testing server of original as to testing terminal cluster Device.
Further, further includes: go offline detection module;
The detection module that goes offline, for detecting when the timing reaches, if receive the testing service The load information that device is sent;If receiving the load information that the testing server is sent, it is determined that the testing service exists Line;If not receiving the load information that the testing server is sent, it is determined that the testing service goes offline.
In the embodiment of the present invention, when needing testing terminal cluster, dialled if all online testing servers can not be treated It surveys terminal cluster and carries out testing, select standby server, and be configured to newly-increased testing server, treated with newly-increased testing server Testing terminal cluster carries out testing, realizes the on-line rapid estimation of call-testing system, avoids due to which testing terminal cluster is excessive or mistake The problem of the testing result inaccuracy of testing server caused by carrying, and then the accuracy of testing result can be improved.
The embodiment of the invention also provides a kind of main testing servers, as shown in figure 9, including processor 901, communication interface 902, memory 903 and communication bus 904, wherein processor 901, communication interface 902, memory 903 pass through communication bus 904 complete mutual communication,
Memory 903, for storing computer program;
Processor 901 when for executing the program stored on memory 903, realizes following steps:
Obtain current time corresponding current computer room to testing terminal cluster;
Load information acquisition request is sent to the control server;
Receive the negative of current computer room corresponding all online testing server current times that the control server returns Information carrying breath;The load information is that all online testing servers are regularly sent to the control server in the call-testing system 's;
According to the load information at the current time received, judge whether all online testing servers can be treated Testing terminal cluster carries out testing;
If it is not, then one standby server of selection, is configured to newly-increased testing server;
Newly-increased testing server is determined as target testing server;
Target testing server is distributed to testing terminal cluster by described;
The distribution information to testing terminal cluster is sent to the control server, so that the control services The distribution information is sent to the target testing server, triggers the target testing server to described to testing by device Terminal cluster carries out testing.
The embodiment of the invention also provides a kind of control servers, as shown in Figure 10, including processor 1001, communication interface 1002, memory 1003 and communication bus 1004, wherein processor 1001, communication interface 1002, memory 1003 pass through communication Bus 1004 completes mutual communication,
Memory 1003, for storing computer program;
Processor 1001 when for executing the program stored on memory 1003, realizes following steps:
Receive the load information that the corresponding all online testing servers of each computer room are regularly sent;
When receiving the load information acquisition request that the corresponding main testing server of current computer room is sent, Xiang Suoshu Main testing server returns to the load information at current computer room corresponding all online testing server current times;So that the master Testing server judges whether all online testing servers can be treated and dials according to the load information at the current time received It surveys terminal cluster and carries out testing;
If it is not, then one standby server of selection, is configured to newly-increased testing server;
Newly-increased testing server is determined as target testing server;
Target testing server is distributed to testing terminal cluster by described;
The distribution information to testing terminal cluster is sent to the control server;
Receive the distribution information to testing terminal cluster that the main testing server is sent;
The distribution information is sent to the target testing server, trigger the target testing server to it is described to Testing terminal cluster carries out testing.
The communication bus that above-mentioned electronic equipment is mentioned can be Peripheral Component Interconnect standard (Peripheral Component Interconnect, abbreviation PCI) bus or expanding the industrial standard structure (Extended Industry Standard Architecture, abbreviation EISA) bus etc..The communication bus can be divided into address bus, data/address bus, control bus etc.. Only to be indicated with a thick line in figure, it is not intended that an only bus or a type of bus convenient for indicating.
Communication interface is for the communication between above-mentioned electronic equipment and other equipment.
Memory may include random access memory (Random Access Memory, abbreviation RAM), also may include Nonvolatile memory (non-volatile memory), for example, at least a magnetic disk storage.Optionally, memory may be used also To be storage device that at least one is located remotely from aforementioned processor.
Above-mentioned processor can be general processor, including central processing unit (Central Processing Unit, Abbreviation CPU), network processing unit (Network Processor, abbreviation NP) etc.;It can also be digital signal processor (Digital Signal Processing, abbreviation DSP), specific integrated circuit (Application Specific Integrated Circuit, abbreviation ASIC), field programmable gate array (Field-Programmable Gate Array, Abbreviation FPGA) either other programmable logic device, discrete gate or transistor logic, discrete hardware components.
In another embodiment provided by the invention, a kind of computer readable storage medium is additionally provided, which can It reads to be stored with instruction in storage medium, when run on a computer, so that computer executes any institute in above-described embodiment The dial testing method stated.
In another embodiment provided by the invention, a kind of computer program product comprising instruction is additionally provided, when it When running on computers, so that computer executes any dial testing method in above-described embodiment.
In the above-described embodiments, can come wholly or partly by software, hardware, firmware or any combination thereof real It is existing.When implemented in software, it can entirely or partly realize in the form of a computer program product.The computer program Product includes one or more computer instructions.When loading on computers and executing the computer program instructions, all or It partly generates according to process or function described in the embodiment of the present invention.The computer can be general purpose computer, dedicated meter Calculation machine, computer network or other programmable devices.The computer instruction can store in computer readable storage medium In, or from a computer readable storage medium to the transmission of another computer readable storage medium, for example, the computer Instruction can pass through wired (such as coaxial cable, optical fiber, number from a web-site, computer, server or data center User's line (DSL)) or wireless (such as infrared, wireless, microwave etc.) mode to another web-site, computer, server or Data center is transmitted.The computer readable storage medium can be any usable medium that computer can access or It is comprising data storage devices such as one or more usable mediums integrated server, data centers.The usable medium can be with It is magnetic medium, (for example, floppy disk, hard disk, tape), optical medium (for example, DVD) or semiconductor medium (such as solid state hard disk Solid State Disk (SSD)) etc..
It should be noted that, in this document, relational terms such as first and second and the like are used merely to a reality Body or operation are distinguished with another entity or operation, are deposited without necessarily requiring or implying between these entities or operation In any actual relationship or order or sequence.Moreover, the terms "include", "comprise" or its any other variant are intended to Non-exclusive inclusion, so that the process, method, article or equipment including a series of elements is not only wanted including those Element, but also including other elements that are not explicitly listed, or further include for this process, method, article or equipment Intrinsic element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that There is also other identical elements in process, method, article or equipment including the element.
Each embodiment in this specification is all made of relevant mode and describes, same and similar portion between each embodiment Dividing may refer to each other, and each embodiment focuses on the differences from other embodiments.Especially for device, For main testing server, control server and network system embodiment, since it is substantially similar to the method embodiment, so retouching That states is fairly simple, and the relevent part can refer to the partial explaination of embodiments of method.
The foregoing is merely illustrative of the preferred embodiments of the present invention, is not intended to limit the scope of the present invention.It is all Any modification, equivalent replacement, improvement and so within the spirit and principles in the present invention, are all contained in protection scope of the present invention It is interior.

Claims (20)

1. a kind of dial testing method, which is characterized in that be applied to main testing server corresponding with computer room in call-testing system;Described group Examining system also includes control server and standby server, wherein the corresponding main testing server and at least one of a computer room A standby server;The dial testing method, comprising:
Obtain current time corresponding current computer room to testing terminal cluster;
Load information acquisition request is sent to the control server;
Receive the load letter at current computer room corresponding all online testing server current times that the control server returns Breath;The load information is that all online testing servers are regularly sent to the control server in the call-testing system;
According to the load information at the current time received, judge whether all online testing servers can treat testing Terminal cluster carries out testing;
If it is not, then one standby server of selection, is configured to newly-increased testing server;
Newly-increased testing server is determined as target testing server;
Target testing server is distributed to testing terminal cluster by described;
The distribution information to testing terminal cluster is sent to the control server, so that the control server, it will The distribution information is sent to the target testing server, triggers the target testing server to described to testing termination set Group carries out testing.
2. the method according to claim 1, wherein
It is described obtain current time corresponding current computer room to testing terminal cluster the step of, comprising:
Obtain all terminal cluster quantity of computer room described in current time;
The terminal cluster quantity is compared with the terminal cluster quantity of the last computer room, judges the terminal cluster Whether quantity increases;
When the terminal cluster quantity increases, using newly-increased terminal cluster as to testing terminal cluster.
3. the method according to claim 1, wherein the call-testing system further include: with the control server Communication connection, and non-master testing server corresponding with the current computer room;
The load letter at the current computer room corresponding all online testing server current times that the control server returns In breath, include: the load information at each non-master testing server current time;
The load information at the current time that the basis receives, judges whether all online testing servers can be treated Testing terminal cluster carries out the step of testing, comprising:
According to the load information at the current time received, judge that the main testing server and each non-master testing server exist It is assigned with described after testing terminal cluster, if can overload;
If it is, all online testing servers, which can not treat testing terminal cluster, carries out testing.
4. according to the method described in claim 3, it is characterized in that,
The main testing server is the control server previously according to the corresponding each testing server of the current computer room The registration information of transmission conducts an election determining;
One standby server of the selection is configured to the step of increasing testing server newly, comprising:
From the physical machine database being arranged for current computer room, obtains idle spare physical machine and be determined as newly-increased testing server;
Establish and communicate to connect with the newly-increased testing server so that the newly-increased testing server load testing program and with institute The client-side program of control server communication is stated, Xiang Suoshu control server sends registration information;
Described the step of newly-increased testing server is determined as target testing server, comprising:
After receiving the newly-increased registered notice of testing server that the control server is sent, by newly-increased testing server As target testing server.
5. according to the method described in claim 3, it is characterized in that, the method also includes:
If judging the main testing server and each non-master testing server according to the load information at the current time received It is described after testing terminal cluster being assigned with, it will not overload;Then select the main testing server that will not be overloaded or non-master group Server is surveyed, as target testing server;
It executes described by described the step of distributing to target testing server to testing terminal cluster.
6. according to the method described in claim 5, it is characterized in that, the method also includes:
When the non-master testing server for receiving the control server transmission, which goes offline, to be notified, will go offline non-master testing server Corresponding terminal cluster is used as to testing terminal cluster, is executed described to control server transmission load information acquisition request The step of.
7. a kind of dial testing method, which is characterized in that applied to the control server in call-testing system;The call-testing system, is also wrapped Containing main testing server and standby server, wherein a corresponding main testing server of computer room and at least one spare clothes Business device;The dial testing method, comprising:
Receive the load information that the corresponding all online testing servers of each computer room are regularly sent;
When receiving the load information acquisition request that the corresponding main testing server of current computer room is sent, dialled to the master Survey the load information that server returns to current computer room corresponding all online testing server current times;So that the main testing Server judges whether all online testing servers can treat testing end according to the load information at the current time received Cluster is held to carry out testing;If it is not, then one standby server of selection, is configured to newly-increased testing server;Newly-increased testing is taken Business device is determined as target testing server;Target testing server is distributed to testing terminal cluster by described;It will be described wait dial The distribution information for surveying terminal cluster is sent to the control server;
Receive the distribution information to testing terminal cluster that the main testing server is sent;
The distribution information is sent to the target testing server, triggers the target testing server to described to testing Terminal cluster carries out testing.
8. the method according to the description of claim 7 is characterized in that the call-testing system further include: with the control server Communication connection, and non-master testing server corresponding with the current computer room;
Described the step of receiving the load information that all online testing servers are regularly sent, comprising:
Receive the load information that the corresponding all online non-master testing servers of each computer room are regularly sent;
In the load information at the current time returned to the main testing server, include: corresponding with current computer room each The load information at a non-master testing server current time.
9. according to the method described in claim 8, it is characterized in that,
The main testing server uses following steps, elects:
Receive the registration information that the corresponding each testing server of current computer room is sent;
According to the registration information, node corresponding with each testing server is generated respectively;
According to the sequencing that the node generates, the corresponding testing server of the node generated earliest is determined as the master and is dialled Survey server.
10. according to the method described in claim 9, it is characterized in that, this method further include:
If detecting, the main testing server goes offline, and is generated according to the non-master testing server corresponding node successive suitable The corresponding non-master testing server of the node generated earliest is determined as new main testing server by sequence;
By according to the corresponding relationship of each the testing server and terminal cluster of the distribution information preservation having received, it is sent to institute New main testing server is stated, so that the new main testing server is worked as according to the corresponding relationship and all online testing servers The load information at preceding moment is allocated using the corresponding terminal cluster of the main testing server of original as to testing terminal cluster;Or So that new main testing server is selected a standby server, is configured to newly-increased testing server, former main testing server is corresponding Terminal cluster be used as and to testing terminal cluster distribute to newly-increased testing server.
11. a kind of testing device, which is characterized in that be applied to main testing server corresponding with computer room in call-testing system;It is described Call-testing system also includes control server and standby server, wherein the corresponding main testing server of computer room and at least One standby server;Described device includes:
Obtain module to testing terminal cluster, for obtain current time corresponding current computer room to testing termination set Group;
Request sending module, for sending load information acquisition request to the control server;
First load information receiving module, it is all online groups corresponding for receiving the current computer room that the control server returns Survey the load information at server current time;The load information is that all online testing servers are regularly sent to described Control server;
Judgment module judges that all online testing servers are for the load information according to the current time received The no testing terminal cluster that can treat carries out testing;
When newly-increased testing server configuration module for the judging result in the judgment module is no, a spare clothes are selected Business device is configured to newly-increased testing server;
First object testing server determining module, for newly-increased testing server to be determined as target testing server;
Terminal cluster distribution module, for distributing to target testing server to testing terminal cluster for described;
Information sending module is distributed, the distribution information to testing terminal cluster is sent to the control server, so that The distribution information is sent to the target testing server, triggers the target testing server by the control server Testing is carried out to testing terminal cluster to described.
12. device according to claim 11, which is characterized in that obtain module to testing terminal cluster, comprising:
Quantity acquisition submodule, for obtaining current time by all terminal cluster quantity in testing network;
Acquisition submodule, for the terminal cluster quantity to be compared with the last terminal cluster quantity for executing testing, Judge whether the terminal cluster quantity increases;When the terminal cluster quantity increases, using newly-increased terminal cluster as wait dial Survey terminal.
13. device according to claim 11, which is characterized in that the call-testing system further include: serviced with the control Device communication connection, and non-master testing server corresponding with the current computer room;
The load letter at the current computer room corresponding all online testing server current times that the control server returns In breath, include: the load information at each non-master testing server current time;
The judgment module judges the main testing server specifically for the load information according to the current time received With each non-master testing server be assigned with it is described after testing terminal cluster, if can overload;If it is, it is all Line testing server can not treat testing terminal cluster and carry out testing.
14. device according to claim 13, which is characterized in that the main testing server is that the control server is pre- It is first conducted an election according to the registration information that the corresponding each testing server of the current computer room is sent determining;
The newly-increased testing server configuration module, is specifically used for: from the physical machine database being arranged for current computer room, obtaining Idle spare physical machine is determined as newly-increased testing server;It establishes and communicates to connect with the newly-increased testing server, so that described Newly-increased client-side program testing server load testing program and communicated with the control server, Xiang Suoshu control server Send registration information;
The first object testing server determining module, is specifically used for: receiving the described new of the control server transmission Throw in more after surveying the registered notice of server, using newly-increased testing server as target testing server.
15. device according to claim 14, which is characterized in that described device further include:
Second target testing server determining module, if for the load information according to the current time received, described in judgement Main testing server and each non-master testing server are being assigned with described after testing terminal cluster, will not overload;Then select The main testing server or non-master testing server that will not be overloaded are selected, as target testing server;Trigger the first terminal Cluster distribution module.
16. device according to claim 13, which is characterized in that the request sending module is also used to that institute ought be received The non-master testing server for stating control server transmission goes offline when notifying, will go offline the corresponding terminal conduct of non-master testing server To testing terminal cluster, Xiang Suoshu control server sends load information acquisition request.
17. a kind of testing device, which is characterized in that applied to the control server in call-testing system;The call-testing system, is also wrapped Containing main testing server and standby server, wherein a corresponding main testing server of computer room and at least one spare clothes Business device;Described device includes:
Second load information receiving module, it is negative for receive that the corresponding all online testing servers of each computer room regularly send Information carrying breath;
Load information sending module, for when the load information for receiving the corresponding main testing server transmission of current computer room When acquisition request, the negative of current computer room corresponding all online testing server current times is returned to the main testing server Information carrying breath, so that own load information of the main testing server according to the current time, judges all online testing clothes Whether business device can treat testing terminal cluster and carry out testing;If it is not, then one standby server of selection, is configured to newly throw in more Survey server;Newly-increased testing server is determined as target testing server;Target is distributed to testing terminal cluster by described Testing server;The distribution information to testing terminal cluster is sent to the control server;
Information receiving module is distributed, is believed for receiving the distribution described in the main testing server transmission to testing terminal cluster Breath;
Second distribution information sending module, for the distribution information to testing terminal cluster to be sent to the target testing Server, so that the target testing server carries out testing to testing terminal cluster to described.
18. device according to claim 17, which is characterized in that the call-testing system further include: serviced with the control Device communication connection, and non-master testing server corresponding with the current computer room;
The second load information receiving module is specifically used for receiving the corresponding all online non-master testing servers of each computer room The load information regularly sent;
In the load information at the current time returned to the main testing server, include: corresponding with current computer room each The load information at a non-master testing server current time.
19. device according to claim 18, which is characterized in that further include: main testing server determining module;
The main testing server determining module, the note sent specifically for receiving the corresponding each testing server of current computer room Volume information;According to the registration information, node corresponding with each testing server is generated respectively;It is raw according to the node At sequencing, the corresponding testing server of the node generated earliest is determined as the main testing server;
The main testing server determining module includes: registration information receiving submodule, node generates submodule and main testing takes Business device determines submodule;
The registration information receiving submodule, the registration letter sent for receiving the corresponding each testing server of current computer room Breath;
The node generates submodule, for generating respectively corresponding with each testing server according to the registration information Node;
The main testing server determines submodule, the sequencing for being generated according to the node, the section that will be generated earliest The corresponding testing server of point is determined as the main testing server.
20. device according to claim 19, which is characterized in that further include: main testing server redefine module and Corresponding relationship sending module;
The main testing server redefines module, if for detecting that the main testing server goes offline, according to The sequencing that non-master testing server corresponding node generates determines the corresponding non-master testing server of the node generated earliest For new main testing server;
The corresponding relationship sending module, each testing server of the distribution information preservation for basis to have received and end The corresponding relationship for holding cluster, is sent to the new main testing server, so that the new main testing server is according to the correspondence The load information of relationship and all online testing server current times, using the corresponding terminal cluster of former main testing server as It is allocated to testing terminal cluster;Or new main testing server is made to select a standby server, it is configured to newly-increased testing clothes Business device gives newly-increased testing server using the corresponding terminal cluster of the main testing server of original as to testing terminal distribution.
CN201910116506.1A 2019-02-15 2019-02-15 Dial testing method and device Active CN109921925B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910116506.1A CN109921925B (en) 2019-02-15 2019-02-15 Dial testing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910116506.1A CN109921925B (en) 2019-02-15 2019-02-15 Dial testing method and device

Publications (2)

Publication Number Publication Date
CN109921925A true CN109921925A (en) 2019-06-21
CN109921925B CN109921925B (en) 2022-04-22

Family

ID=66961558

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910116506.1A Active CN109921925B (en) 2019-02-15 2019-02-15 Dial testing method and device

Country Status (1)

Country Link
CN (1) CN109921925B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110932940A (en) * 2019-12-10 2020-03-27 北京奇艺世纪科技有限公司 Source address translation service monitoring method and device
CN110943887A (en) * 2019-11-29 2020-03-31 广州市百果园信息技术有限公司 Probe scheduling method, device, equipment and storage medium
CN111221714A (en) * 2020-01-02 2020-06-02 广州虎牙科技有限公司 Service dial testing method, device, system and storage medium
CN113342664A (en) * 2021-06-16 2021-09-03 北京奇艺世纪科技有限公司 Dial testing method and device, storage medium and computer equipment
CN114024876A (en) * 2021-10-15 2022-02-08 中国联合网络通信集团有限公司 Network dial testing method, device, equipment and storage medium
CN114448850B (en) * 2021-12-21 2023-11-03 天翼云科技有限公司 Dialing control method, electronic equipment and dialing control system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103118130A (en) * 2013-02-25 2013-05-22 汉柏科技有限公司 Cluster management method and cluster management system for distributed service
CN104714868A (en) * 2015-03-27 2015-06-17 上海新炬网络信息技术有限公司 Distributed computer automatic dial testing method
CN108683569A (en) * 2018-06-06 2018-10-19 国家计算机网络与信息安全管理中心 A kind of the business monitoring method and system of cloud service-oriented infrastructure
CN109005085A (en) * 2018-08-24 2018-12-14 北京奇艺世纪科技有限公司 A kind of service availability monitoring system, method, device and equipment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103118130A (en) * 2013-02-25 2013-05-22 汉柏科技有限公司 Cluster management method and cluster management system for distributed service
CN104714868A (en) * 2015-03-27 2015-06-17 上海新炬网络信息技术有限公司 Distributed computer automatic dial testing method
CN108683569A (en) * 2018-06-06 2018-10-19 国家计算机网络与信息安全管理中心 A kind of the business monitoring method and system of cloud service-oriented infrastructure
CN109005085A (en) * 2018-08-24 2018-12-14 北京奇艺世纪科技有限公司 A kind of service availability monitoring system, method, device and equipment

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110943887A (en) * 2019-11-29 2020-03-31 广州市百果园信息技术有限公司 Probe scheduling method, device, equipment and storage medium
CN110932940A (en) * 2019-12-10 2020-03-27 北京奇艺世纪科技有限公司 Source address translation service monitoring method and device
CN111221714A (en) * 2020-01-02 2020-06-02 广州虎牙科技有限公司 Service dial testing method, device, system and storage medium
CN113342664A (en) * 2021-06-16 2021-09-03 北京奇艺世纪科技有限公司 Dial testing method and device, storage medium and computer equipment
CN113342664B (en) * 2021-06-16 2023-09-01 北京奇艺世纪科技有限公司 Dial testing method, device, storage medium and computer equipment
CN114024876A (en) * 2021-10-15 2022-02-08 中国联合网络通信集团有限公司 Network dial testing method, device, equipment and storage medium
CN114448850B (en) * 2021-12-21 2023-11-03 天翼云科技有限公司 Dialing control method, electronic equipment and dialing control system

Also Published As

Publication number Publication date
CN109921925B (en) 2022-04-22

Similar Documents

Publication Publication Date Title
CN109921925A (en) A kind of dial testing method and device
CN109302346B (en) Method and device for transmitting data flow
CN109005085B (en) Service availability monitoring system, method, device and equipment
CN106302565B (en) Scheduling method and system of service server
CN108370341B (en) Resource allocation method, virtual network function manager and network element management system
CN109167812B (en) Method for evaluating service quality and determining adjustment strategy, server and storage medium
CN107800554B (en) Data acquisition method, device and system
CN102868770B (en) A kind of method of distribution interface, equipment and system
CN106656682A (en) Method, system and device for detecting cluster heartbeat
CN111934947B (en) Speed measurement method, speed measurement scheduling server, terminal equipment and readable storage medium
CN108234319B (en) Data transmission method and device
CN113067875B (en) Access method, device and equipment based on dynamic flow control of micro-service gateway
CN112491719A (en) Network node selection method, equipment and storage medium
CN110351311A (en) Load-balancing method and computer storage medium
CN109542627A (en) Node switching method, device, supervisor, node device and distributed system
CN112118151A (en) Network speed measuring method, device, system, electronic equipment and storage medium
CN110365517A (en) Data processing method, device, storage medium and computer equipment
CN116760655B (en) POP point method for providing CPE optimal access in SD-WAN application
CN108366102A (en) A kind of service discovery method, device and electronic equipment based on Consul
CN108512698B (en) Network disaster tolerance method and device and electronic equipment
CN115695435A (en) Method and device for dynamically adjusting node flow, electronic equipment and storage medium
CN112653601B (en) Distributed scanning method, device and equipment based on cloud computing system
CN108600308A (en) Data uploading method, device, storage medium and server
CN109661005B (en) Load sharing adjustment method and device of local access controller
CN103516738A (en) Message distribution method, device and system

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