A server testing method and device
By automatically monitoring and re-initiating services that meet recovery standards, the manpower-intensive problem in video network server testing is solved, and testing efficiency and resource utilization are improved.
Patent Information
- Application Number
- CN202010437812.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-05-21
- Publication Date
- 2024-08-30
- Estimated Expiration
- 2040-05-21
AI Technical Summary
During the business load capacity testing process of existing video network servers, a large amount of manpower is required to manually screen and re-initiate failed services, resulting in low testing efficiency.
By automatically monitoring the status of failed services during server testing and reinitiating services when the service recovery records meet the standards, invalid recovery is avoided and testing efficiency is improved.
It realizes automated business recovery, saves labor costs, improves the efficiency of server testing, and avoids the disadvantages of invalid recovery taking up too much time and resources.
Smart Images

Figure CN111787368B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of communication technology, and in particular to a server testing method and device. Background Art
[0002] Visual networking is an important milestone in the development of the Internet. It is a more advanced form of the Internet and a real-time network that can achieve real-time transmission of high-definition video across the entire network, which is currently unavailable on the Internet. It will push many Internet applications towards high-definition video. Visual networking servers can provide users with a variety of services, such as multi-person ultra-high-definition online conferencing, video surveillance, etc. In order to provide users with stable visual networking services, it is necessary to understand the carrying capacity of visual networking servers for various business services in order to reasonably allocate the processing resources of visual networking servers.
[0003] In the process of testing the service load capacity of existing visual network servers, testers usually control the visual network servers to initiate thousands of large-scale services at the same time to perform stress testing. If a service failure occurs during the test, the testers need to manually screen the failed services and re-initiate the services one by one until the test is completed. This not only requires a lot of manpower, but also reduces the efficiency of server testing. Summary of the invention
[0004] In view of the above problems, embodiments of the present invention are proposed to provide a server testing method and device that overcome the above problems or at least partially solve the above problems.
[0005] In order to solve the above problem, a first aspect of an embodiment of the present invention discloses a server testing method, the method comprising:
[0006] In response to the received server test input, controlling the server to be tested to initiate a target service;
[0007] Acquire the service data of the target service in the server to be tested, wherein the service data at least includes: service status and service recovery record;
[0008] When the service status is a failure status and it is confirmed that the service recovery record meets the service recovery standard, controlling the server to be tested to re-initiate the target service;
[0009] When the service status is a success status, or the service recovery record does not meet the service recovery standard, the test result of the server to be tested is obtained according to the service data.
[0010] Optionally, in response to the received server test input, controlling the server to be tested to initiate a target service further includes:
[0011] Receive a server test input, wherein the server test input includes: a device identifier and a service identifier;
[0012] In response to the server test input, the server to be tested is controlled to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier.
[0013] Optionally, the server test input further includes: a success rate threshold, and the test result includes: a target success rate;
[0014] After obtaining the test result of the server to be tested according to the business data, the method further includes:
[0015] When the target success rate is less than the success rate threshold, obtaining an error type according to the business data;
[0016] The test strategy corresponding to the error type is adopted to control the server to be tested to re-initiate the target service until the target success rate is greater than or equal to the success rate threshold.
[0017] Optionally, the error reporting type includes: server overload type;
[0018] The adopting a test strategy corresponding to the error type to control the server under test to re-initiate the target service includes:
[0019] When the error type is a server overload type, reducing the number of target services;
[0020] The server to be tested is controlled to re-initiate the target service according to the reduced number of target services.
[0021] Optionally, the error reporting type also includes:
[0022] Equipment failure type;
[0023] The adopting a test strategy corresponding to the error type to control the server under test to re-initiate the target service includes:
[0024] When the error type is a client failure type, replacing the target device;
[0025] The server to be tested is controlled to re-initiate the target service to the replaced target device.
[0026] Optionally, the business recovery record includes: the number of business recovery times, and the confirmation that the business recovery record meets the business recovery standard includes:
[0027] When the number of business recovery times is less than the business recovery times threshold, it is confirmed that the business recovery record meets the business recovery standard.
[0028] Optionally, the historical business recovery record further includes: business recovery duration, and the confirmation that the business recovery record meets the business recovery standard includes:
[0029] When the service recovery duration is less than the service recovery duration threshold, it is confirmed that the service recovery record meets the service recovery standard.
[0030] Optionally, the core server is in a visual networking environment;
[0031] The controlling the server to be tested to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier comprises:
[0032] A test initiation instruction is sent to the protocol conversion server so that the protocol conversion server converts the test initiation instruction into a visual networking format and then forwards it to the server under test. The test initiation instruction is used to control the server under test to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier.
[0033] A second aspect of an embodiment of the present invention discloses a server testing device, the device comprising:
[0034] A first service module, configured to control the server to be tested to initiate a target service in response to a received server test input;
[0035] An acquisition module, used to acquire the service data of the target service in the server to be tested, wherein the service data at least includes: service status and service recovery record;
[0036] A first processing module is used to control the server to be tested to re-initiate the target service when the service status is a failure status and it is confirmed that the service recovery record meets the service recovery standard;
[0037] The second processing module is used to obtain the test result of the server to be tested according to the business data when the business status is a success status or the business recovery record does not meet the business recovery standard.
[0038] Optionally, the first business module is further used to:
[0039] Receive a server test input, wherein the server test input includes: a device identifier and a service identifier;
[0040] In response to the server test input, the server to be tested is controlled to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier.
[0041] Optionally, the server test input further includes: a success rate threshold, and the test result includes: a target success rate;
[0042] The device further comprises:
[0043] A third processing module, configured to obtain an error type according to the business data when the target success rate is less than the success rate threshold;
[0044] The second service module is used to control the server to be tested to re-initiate the target service by adopting a test strategy corresponding to the error type until the target success rate is greater than or equal to the success rate threshold.
[0045] Optionally, the error reporting type includes: server overload type;
[0046] The second business module is further used for:
[0047] When the error type is a server overload type, reducing the number of target services;
[0048] The server to be tested is controlled to re-initiate the target service according to the reduced number of target services.
[0049] Optionally, the error reporting type further includes: equipment failure type;
[0050] The second business module is further used for:
[0051] When the error type is a client failure type, replacing the target device;
[0052] The server to be tested is controlled to re-initiate the target service to the replaced target device.
[0053] Optionally, the service recovery record includes: the number of service recovery times, and the first processing module is further used to:
[0054] When the number of business recovery times is less than the business recovery times threshold, it is confirmed that the business recovery record meets the business recovery standard.
[0055] Optionally, the historical service recovery record further includes: service recovery duration, and the first processing module is further used to:
[0056] When the service recovery duration is less than the service recovery duration threshold, it is confirmed that the service recovery record meets the service recovery standard.
[0057] Optionally, the core server is in a visual networking environment;
[0058] The first business module is further used for:
[0059] A test initiation instruction is sent to the protocol conversion server so that the protocol conversion server converts the test initiation instruction into a visual networking format and then forwards it to the server under test. The test initiation instruction is used to control the server under test to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier.
[0060] The embodiments of the present invention include the following advantages:
[0061] A server testing method and device provided by an embodiment of the present invention automatically monitors failed services during server testing, and re-initiates service recovery only when the service recovery record of the failed service meets the service recovery standard. While ensuring that the failed service can be automatically recovered, it avoids the disadvantage of taking up too much time and resources due to invalid service recovery, thereby effectively improving the efficiency of server testing. BRIEF DESCRIPTION OF THE DRAWINGS
[0062] Figure 1 is a flow chart of steps of a server testing method of the present invention;
[0063] Figure 2 is a flow chart of steps of another server testing method of the present invention;
[0064] Figure 3 It is a flow chart of the steps of a server test strategy adjustment method of the present invention;
[0065] Figure 4 is a flow chart of steps of another server test strategy adjustment method of the present invention;
[0066] Figure 5 It is a logic flow chart of a server testing method in a visual networking business scenario of the present invention;
[0067] Figure 6 It is a structural block diagram of a server testing device of the present invention;
[0068] Figure 7 It is a networking schematic diagram of a visual network of the present invention;
[0069] Figure 8 It is a schematic diagram of the hardware structure of a node server of the present invention;
[0070] Fig. 9 It is a schematic diagram of the hardware structure of an access switch of the present invention;
[0071] Fig.10 It is a hardware structure diagram of an Ethernet protocol conversion gateway of the present invention. DETAILED DESCRIPTION
[0072] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.
[0073] Reference Figure 1 , shows a server testing method of the present invention, the method comprising:
[0074] Step 101: In response to a received server test input, control the server to be tested to initiate a target service.
[0075] In the embodiment of the present invention, the server to be tested refers to an electronic device with functions such as data storage, processing, and transmission. The server test input refers to the test personnel selecting the target service to be tested through the test client of the test system. Of course, the server test input can also specify the terminal device to be tested with the server to be tested, or the number of terminal devices to be tested. After receiving the server test input input by the user, the test system generates a service test instruction according to the server test input and sends it to the server to be tested to control the server to be tested to initiate the target service.
[0076] The embodiment of the present invention is applicable to the scenario of visual network server testing, wherein the server to be tested may refer to the core server in the visual network, which is used to provide visual network services to the connected terminal devices to test the business load capacity of the core server. After the user connects to the core server through the test client of the test system, he can log in to the core server through the pre-registered business account and initiate the target business to be tested by sending a business test instruction to the core server.
[0077] Step 102: Acquire the service data of the target service in the server to be tested, wherein the service data at least includes: service status and service recovery record.
[0078] In the embodiment of the present invention, the target service refers to various data services provided by the server under test to the connected terminal device, such as: high-definition live conference, monitoring data call, online business processing, etc. The service status refers to the current status of the target service initiated by the server under test to the terminal device, which can include a failure status and a success status. The failure status refers to the state in which the target service has error data and cannot run normally. Similarly, the success status refers to the state in which the target service is running normally. The service recovery record refers to the record data of the service recovery due to execution failure after the target service is first initiated.
[0079] The embodiment of the present invention is applicable to the scenario of testing the load capacity of various services for the visual network server. After the test system determines the server to be tested and the target service to be tested according to the input of the tester, it controls the server to be tested to initiate the target service to the connected terminal device. After the execution of the target service is completed, the test system will obtain the service data of the target service on each terminal device from the server to be tested to analyze which terminal devices need to re-initiate the target service and perform service recovery.
[0080] Step 103: When the service status is a failure status and it is confirmed that the service recovery record meets the service recovery standard, control the server to be tested to re-initiate the target service.
[0081] In an embodiment of the present invention, the test system can confirm the service status of the target service in each terminal device by analyzing the service data. Specifically, if the service data of the target service lacks a certain operation data or has error data, it can be confirmed that the execution of the target service on the terminal device has failed and the service status is a failure state. Otherwise, it can be confirmed that the service status is a success state. This is just an exemplary description. How to determine whether the target service is a success state or a failure state can be based on actual needs and the feasibility of the solution. No specific limitation is made here.
[0082] If the service status of the target service executed by the server to be tested to a certain terminal device is failed, the service recovery record of the terminal device for the target service is obtained from the server to be tested. If the target service is initiated for the terminal device for the first time, an initialized service recovery record is generated for the terminal device for use. Since the failure of the target service execution may be caused by various factors, factors that cannot be recovered only by re-initiating the service, such as excessive load of the server to be tested, or defects and failures of the terminal device itself. At this time, if the target service is re-initiated to the terminal device blindly, not only the target service cannot be restored to the terminal device, but also a large amount of equipment resources and time will be occupied, limiting the efficiency of the server test. Therefore, the present invention introduces a service recovery record mechanism here, and each time the server to be tested re-initiates the target service to the server to be tested for service recovery, the service recovery record of each terminal device is updated, so that before each service recovery, the service recovery number, time, performance parameters, etc. of the terminal device are judged according to the service recovery record of the terminal device to determine whether they meet the service recovery standard, so as to avoid too many invalid service recovery for a certain terminal device and avoid waste of equipment resources.
[0083] Specifically, when the test system confirms that the business status of the target device is a failure, it further determines whether the business recovery record of the target device meets the business recovery standards. If it meets the business recovery standards, it indicates that the target device can perform business recovery, thereby controlling the server under test to re-initiate the target business to the target device for business recovery. There is no need for manpower to screen and initiate one by one, saving the manpower cost of server testing.
[0084] Step 104, when the service status is a success status, or the service recovery record does not meet the service recovery standard, obtain the test result of the server to be tested according to the service data.
[0085] In an embodiment of the present invention, if the service status of a terminal device is a success status, there is no need to restore the target service of the terminal device, or if the service recovery record exceeds the limit of the service recovery standard, the target service of the terminal device is abandoned. The test system obtains the final service status of all target services initiated by the server under test, that is, a success status, or a failure status but the service recovery record does not meet the service recovery standard, thereby determining the test result of the server under test for the target service according to the service status corresponding to each terminal device. The test result can be the maximum load capacity of the server under test for the target service, the maximum load capacity under a specified success rate, the maximum load capacity under a specified response time, etc. It can be determined specifically according to actual needs and is not limited here.
[0086] A server testing method provided by an embodiment of the present invention automatically monitors services in failed states during server testing, and re-initiates service recovery only when the service recovery record of the failed service meets the service recovery criteria. While ensuring that failed services can be automatically recovered, it avoids the disadvantage of taking up too much time and resources due to ineffective service recovery of the equipment, thereby effectively improving the efficiency of server testing.
[0087] Reference Figure 2 , shows another server testing method of the present invention, the method comprising:
[0088] Step 201: receiving a server test input, wherein the server test input includes: a device identifier and a service identifier.
[0089] In the embodiment of the present invention, the server test input may include a device identifier and a service identifier input by a user through a test client of the test system. That is, the user may specify the test of a specific service by the server under test by inputting the device identifier. Of course, the user may also input the number of target services to be initiated, and the test system may automatically select a device identifier that meets the number of target services according to the usage of the terminal device connected to the server under test.
[0090] Step 202, in response to the server test input, sends a test initiation instruction to the protocol conversion server, so that the protocol conversion server converts the test initiation instruction into a visual networking format and forwards it to the server under test, and the test initiation instruction is used to control the server under test to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier.
[0091] In the embodiment of the present invention, since the test client of the test system can be set in the Internet environment, if the user needs to control the server to be tested in the visual networking environment through the test client to perform server testing, it is necessary to first send the service initiation instruction containing the device identification and service identification to the protocol conversion server for protocol conversion, and after obtaining the test initiation instruction in the visual networking format, the test initiation instruction in the visual networking format is transparently transmitted to the server to be tested. After receiving the initiation instruction to be tested, the server to be tested initiates the target service corresponding to the service identification to the target device corresponding to the device identification according to the service identification and device identification in the test initiation instruction, so as to initiate the server test.
[0092] Step 203: Acquire the service data of the target service in the server to be tested, wherein the service data at least includes: service status and service recovery record.
[0093] This step can refer to the detailed description of step 101 and will not be repeated here.
[0094] Step 204: When the service status is a failure status and the service recovery times are less than a service recovery times threshold, control the server to be tested to re-initiate the target service.
[0095] In an embodiment of the present invention, the number of service recovery times refers to the number of times the target service is re-initiated on the target device for service recovery. When the test system detects that the service status of a target device is a failed state, the test system determines the number of service recovery times for the target device. If the service recovery test is less than the service recovery times threshold, it indicates that the service recovery times for the target device are still within an acceptable range and service recovery can be performed. Therefore, the test system controls the server under test to re-initiate the target service to the target device, and each time the service of the target device is restored, the number of service recovery times for the target device is accumulated by 1. The service recovery times threshold can be determined according to actual needs, for example: 1 time, 5 times, etc., and is not specifically limited here. Of course, in order to take into account the overall test effect of the server under test, the server under test can also be controlled to re-initiate the target service to all connected target devices.
[0096] The embodiment of the present invention does not directly restore the service if the service execution fails during the server testing process, but re-initiates the target service on the corresponding target device or all target devices, thereby avoiding the situation where a large amount of data processing resources are occupied due to the inability to restore the target service of a certain device, and improving the efficiency of the server testing.
[0097] Step 205: When the service status is a failure status and the service recovery duration is less than a service recovery duration threshold, control the server to be tested to re-initiate the target service.
[0098] In an embodiment of the present invention, the service recovery duration refers to the total duration from the initiation to the successful execution of a target service on the server to be tested. If the service is recovered after the first initiation, and the target service is re-initiated, the duration after the target service is re-initiated belongs to the service recovery duration. It can be understood that due to problems such as network delays or equipment defects, the target service may not be successfully executed for a long time. At this time, if you still wait and recover the target service, it will take up a lot of time and processing resources. Therefore, before recovering the target service in a failed state, it is necessary to determine whether the service recovery duration of the target service exceeds the service recovery duration threshold. If it does not exceed, it indicates that the execution time of the target service is still within an acceptable range and the service recovery can be performed. Of course, in order to take into account the overall test effect of the server to be tested, the server to be tested can also be controlled to re-initiate the target service to all connected target devices.
[0099] The embodiment of the present invention improves the efficiency of server testing by re-initiating the target service that has failed to execute and whose service recovery time does not exceed the service recovery time threshold during the server testing process, thereby avoiding the situation where a large amount of data processing resources are occupied due to the target service of a certain target device being unable to execute successfully for a long time.
[0100] Step 206, when the service status is a success status, or the service recovery record does not meet the service recovery standard, obtain the test result of the server to be tested according to the service data.
[0101] This step can refer to the detailed description of step 103 and will not be repeated here.
[0102] Optionally, the server test input also includes: a success rate threshold, and the test result includes: a target success rate.
[0103] Step 207: When the target success rate is less than the success rate threshold, obtain an error type according to the business data.
[0104] In an embodiment of the present invention, the target success rate refers to the ratio of the number of services in a failed state on the server to be tested to the total number of services. The error type can be determined based on the error code in the service data, and the error codes corresponding to the errors occurring in different service nodes are different. Normally, the tester needs to know the maximum service load of the server to be tested at a specific success rate, so the server to be tested can be controlled to perform the test by specifying the target success rate. It can be understood that simply obtaining the maximum load of the server to be tested cannot guarantee that the success rate of the target service remains within an acceptable range for users. If the success rate is low, the target service cannot be used by too many users, affecting the user experience of the target service. Therefore, the tester can specify the required success rate threshold when the test is initiated.
[0105] After the target server test of the server to be tested is completed, if the target success rate is lower than the success rate threshold, the server to be tested needs to adjust the test strategy according to the error type.
[0106] Step 208: Use a test strategy corresponding to the error type to control the server under test to re-initiate the target service until the target success rate is greater than or equal to the success rate threshold.
[0107] In the embodiment of the present invention, different test strategies are required for different error types. For example, if the target device specified by the tester is occupied, the service on the target device needs to be suspended first, or the number of devices connected to the server to be tested cannot reach the number of devices specified by the user, the number of devices specified by the user needs to be reduced, or the number of target services is too large, resulting in insufficient data processing resources on the server to be tested, which may also lead to a decrease in the success rate. Therefore, the number of target services can also be reduced at this time. Of course, how to restore the target service on the server to be tested according to the error type can be determined according to actual needs and is not limited here.
[0108] Optionally, the error type includes: server overload type.
[0109] Reference Figure 3 , the step 208 comprises:
[0110] Sub-step 2081, when the error type is a server overload type, reducing the number of the target services.
[0111] In the embodiment of the present invention, the server overload type refers to the type in which the server under test has an error in providing the target service due to insufficient data processing resources of the server. In this case, the number of target services that need to be initiated by the server under test can be reduced so that the remaining target services can obtain sufficient data processing resources, thereby improving the target success rate of the target services.
[0112] Sub-step 2082: Control the server to be tested to re-initiate the target service according to the reduced number of target services.
[0113] In the embodiment of the present invention, during the server testing process, if the error type of the target business is a server overload type, the number of target businesses is reduced to alleviate the data processing pressure of the server to be tested, thereby improving the target success rate of the target business. There is no need for testers to manually adjust the number of target businesses, thereby improving the efficiency of server testing.
[0114] Optionally, the error reporting type further includes: equipment failure type;
[0115] Reference Figure 4 , the step 208 comprises:
[0116] Step 2083: When the error type is a client failure type, replace the target device.
[0117] In the embodiment of the present invention, the client failure type may be due to the client of the target device being occupied by other services, or the target device being a service failure type caused by a network failure, software failure, or hardware failure. In order to avoid wasting too many data processing resources by repeatedly initiating the target service to the target device and reduce the waiting time of the server test, the target device may be replaced and another idle device may be selected to re-initiate the target service.
[0118] Step 2084: Control the server to be tested to re-initiate the target service to the replaced target device.
[0119] Reference Figure 5 , showing a logical flow chart of a server testing method in a visual networking service scenario according to an embodiment of the present invention. The testing system includes a service recovery module and a service processing module, wherein the service recovery module is used to determine whether service recovery is required after the target service fails to execute, and the service processing module is used to interact with the core server and analyze the service data returned by the core server.
[0120] First, after receiving the user's server test input, the service processing module encapsulates the service test instruction according to the service identifier and device identifier in the server test input, and sends the service test instruction to the core server so that the core server initiates the target service and returns the service data;
[0121] The service processing module also adds the service test instruction to the service recovery module test queue in the form of a key-value pair for storage, wherein the device identifier and the service identifier are the key and the instruction is the value;
[0122] After obtaining the service data returned by the core server, the service processing module analyzes it and determines the service status of the target service in each terminal device participating in the test. If the service status is a failure status, it determines whether the device ID of the terminal device where the service execution failed exists in the failed service set. If not, the device ID and the service ID of the target service are added to the failed service set; if the service status is a success status, it determines whether the device ID of the terminal device where the service execution succeeded exists in the failed service set. If so, the device ID of the terminal device and the corresponding service ID are removed from the service failure set.
[0123] The service recovery module monitors the failed service set in real time, and generates a corresponding service test instruction when a key value consisting of a device identifier and a service identifier exists in the failed service set. Then, a key value with the device identifier and the service identifier as the key and the service recovery times or service recovery duration as the value is obtained from the service recovery set;
[0124] The service recovery module will remove the key value corresponding to the device identifier whose service recovery times exceed the service recovery times threshold or the service recovery duration exceeds the service recovery duration threshold from the failed service set, so as to stop re-initiating the target service to the terminal device corresponding to the device identifier and stop service recovery;
[0125] For the key value of the device identifier whose service recovery times do not exceed the service recovery times threshold and service recovery duration does not exceed the service recovery duration threshold, the service recovery module will send the service identifier and the service test instruction of the service identifier to the core server to control the core server to re-initiate the target service to the terminal device corresponding to the device identifier. And the service recovery module will update the service recovery times and service recovery duration corresponding to the device identifier in the service recovery set.
[0126] The embodiment of the present invention improves the efficiency of server testing by automatically replacing the target device if it is detected during the server testing process that the target service whose execution fails is caused by a client failure of the target device, without the need for manual reconfiguration by the tester, thereby avoiding the waste of excessive data processing resources due to repeated initiation of the target service to the target device with a client failure, etc.
[0127] Another server testing device provided by an embodiment of the present invention automatically monitors the failed business during the server testing process, and only re-initiates the business recovery when the business recovery record of the failed business meets the business recovery standard. While ensuring that the failed business can be automatically recovered, it avoids the disadvantage of taking up too much time and resources due to invalid business recovery of the equipment, thereby effectively improving the efficiency of server testing. When it is detected that the test results do not meet the expected requirements, the test strategy is automatically changed according to the test data, and the business test is re-initiated until the test results that meet the expectations are obtained, saving the labor cost required for the test personnel to adjust the test strategy, and further improving the efficiency of server testing.
[0128] Reference Figure 6 , shows a server testing device 30 of the present invention, the device comprising:
[0129] The first service module 301 is used to control the server to be tested to initiate a target service in response to a received server test input;
[0130] The acquisition module 302 is used to acquire the service data of the target service in the server to be tested, wherein the service data at least includes: service status and service recovery record;
[0131] The first processing module 303 is used to control the server to re-initiate the target service when the service status is a failure status and it is confirmed that the service recovery record meets the service recovery standard;
[0132] The second processing module 304 is used to obtain the test result of the server to be tested according to the business data when the business status is a success status or the business recovery record does not meet the business recovery standard.
[0133] Optionally, the first service module 303 is further configured to:
[0134] Receive a server test input, wherein the server test input includes: a device identifier and a service identifier;
[0135] In response to the server test input, the server to be tested is controlled to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier.
[0136] Optionally, the server test input further includes: a success rate threshold, and the test result includes: a target success rate;
[0137] The device further comprises:
[0138] The third processing module 305 is used to obtain the error type according to the business data when the target success rate is less than the success rate threshold;
[0139] The second service module 306 is configured to control the server to be tested to re-initiate the target service by adopting a test strategy corresponding to the error type until the target success rate is greater than or equal to the success rate threshold.
[0140] Optionally, the error reporting type includes: server overload type;
[0141] The second service module 306 is further configured to:
[0142] When the error type is a server overload type, reducing the number of target services;
[0143] The server to be tested is controlled to re-initiate the target service according to the reduced number of target services.
[0144] Optionally, the error reporting type further includes: equipment failure type;
[0145] The second service module 306 is further configured to:
[0146] When the error type is a client failure type, replacing the target device;
[0147] The server to be tested is controlled to re-initiate the target service to the replaced target device.
[0148] Optionally, the service recovery record includes: the number of service recovery times, and the first processing module 303 is further used to:
[0149] When the number of business recovery times is less than the business recovery times threshold, it is confirmed that the business recovery record meets the business recovery standard.
[0150] Optionally, the historical service recovery record further includes: service recovery duration, and the first processing module 303 is further used to:
[0151] When the service recovery duration is less than the service recovery duration threshold, it is confirmed that the service recovery record meets the service recovery standard.
[0152] Optionally, the core server is in a visual networking environment;
[0153] The first business module 301 is further used for:
[0154] A test initiation instruction is sent to the protocol conversion server so that the protocol conversion server converts the test initiation instruction into a visual networking format and then forwards it to the server under test. The test initiation instruction is used to control the server under test to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier.
[0155] A server testing device provided by an embodiment of the present invention automatically monitors services in failed states during server testing, and re-initiates service recovery only when the service recovery record of the failed service meets the service recovery standard. While ensuring that failed services can be automatically recovered, it avoids the disadvantage of taking up too much time and resources due to ineffective service recovery of the equipment, thereby effectively improving the efficiency of server testing.
[0156] As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0157] In order to better illustrate the solution of the present invention, the visual network is described in detail below:
[0158] The visual Internet is an important milestone in the development of the Internet. It is a real-time network that can realize real-time transmission of high-definition video and push many Internet applications towards high-definition video and high-definition face-to-face communication.
[0159] The visual network adopts real-time high-definition video exchange technology. It can integrate the required services such as high-definition video conferencing, video monitoring, intelligent monitoring analysis, emergency command, digital radio and television, delayed TV, online teaching, live broadcast, VOD on demand, TV mail, personalized recording (PVR), intranet (self-operated) channels, intelligent video broadcast control, information release and dozens of other video, voice, picture, text, communication, data and other services on a single system platform, and realize high-definition quality video playback through TV or computer.
[0160] In order to enable those skilled in the art to better understand the embodiments of the present invention, the visual network is introduced as follows:
[0161] Some of the technologies used in the visual Internet of Things are as follows:
[0162] Network Technology
[0163] The network technology innovation of visual networking improves the traditional Ethernet to cope with the huge potential video traffic on the network. Different from simple network packet switching or network circuit switching, visual networking technology uses packet switching to meet streaming needs. Visual networking technology has the flexibility, simplicity and low price of packet switching, and the quality and security guarantee of circuit switching, realizing the seamless connection of the whole network switching virtual circuit and data format.
[0164] Switching Technology
[0165] Visual networking uses the two advantages of Ethernet: asynchronism and packet switching. It eliminates Ethernet defects under the premise of full compatibility, and has seamless end-to-end connection across the entire network, directly connects to user terminals, and directly carries IP data packets. User data does not require any format conversion within the entire network. Visual networking is a more advanced form of Ethernet and a real-time switching platform that can achieve large-scale real-time transmission of high-definition video across the entire network, which is currently unattainable on the Internet, and pushes many network video applications towards high definition and unification.
[0166] Server Technology
[0167] The server technology on the visual network and unified video platform is different from the traditional server. Its streaming media transmission is based on connection-oriented. Its data processing capability is independent of traffic and communication time. A single network layer can include signaling and data transmission. For voice and video services, the complexity of streaming media processing on the visual network and unified video platform is much simpler than data processing, and its efficiency is more than 100 times higher than that of traditional servers.
[0168] Storage Technology
[0169] The ultra-high-speed storage technology of the unified video platform adopts the most advanced real-time operating system to adapt to the media content with ultra-large capacity and ultra-large flow, mapping the program information in the server command to the specific hard disk space. The media content no longer passes through the server, but is directly delivered to the user terminal in an instant. The user generally waits for less than 0.2 seconds. The optimized sector distribution greatly reduces the mechanical movement of the hard disk head seeking, and the resource consumption accounts for only 20% of the same level of IP Internet, but it generates 3 times more concurrent traffic than the traditional hard disk array, and the overall efficiency is improved by more than 10 times.
[0170] Network Security Technology
[0171] The structural design of the visual network completely eradicates the network security issues that plague the Internet through separate licensing for each service and complete isolation of equipment and user data. Generally, anti-virus programs and firewalls are not required, and attacks by hackers and viruses are eliminated, providing users with a structurally worry-free and secure network.
[0172] Service Innovation Technology
[0173] The unified video platform integrates services and transmission. Whether it is a single user, a private network user or a network, it is just an automatic connection. User terminals, set-top boxes or PCs are directly connected to the unified video platform to obtain rich and colorful multimedia video services in various forms. The unified video platform uses a "recipe-style" table configuration mode to replace traditional complex application programming. Complex applications can be implemented with very little code, realizing "unlimited" new business innovation.
[0174] The networking of the visual network is as follows:
[0175] Visual networking is a centrally controlled network structure. The network can be a tree network, star network, ring network, etc., but on this basis, there needs to be a centralized control node in the network to control the entire network.
[0176] like Figure 7 As shown in the figure, the visual network is divided into two parts: access network and metropolitan area network.
[0177] The equipment in the access network can be divided into three categories: node server, access switch, and terminal (including various set-top boxes, encoding boards, storage, etc.). The node server is connected to the access switch, and the access switch can be connected to multiple terminals and can be connected to Ethernet.
[0178] The node server is a node in the access network that performs centralized control functions and can control access switches and terminals. The node server can be directly connected to the access switch or directly connected to the terminal.
[0179] Similarly, the devices in the metropolitan area network can also be divided into three categories: metropolitan area servers, node switches, and node servers. The metropolitan area servers are connected to the node switches, and the node switches can be connected to multiple node servers.
[0180] The node server is a node server of the access network part, that is, the node server belongs to both the access network part and the metropolitan area network part.
[0181] The metropolitan area server is a node with centralized control function in the metropolitan area network, which can control the node switch and node server. The metropolitan area server can be directly connected to the node switch or the node server.
[0182] It can be seen from this that the entire visual network is a hierarchical and centrally controlled network structure, and the network controlled by the node server and the metropolitan area server can be various structures such as tree, star, and ring.
[0183] Figuratively speaking, the access network part can form a unified video platform (the part in the dotted circle), and multiple unified video platforms can form a visual network; each unified video platform can be interconnected through the metropolitan area and wide area visual networks.
[0184] Visual networking equipment classification
[0185] 1.1 The devices in the visual network of the embodiment of the present invention can be mainly divided into three categories: servers, switches (including Ethernet gateways), terminals (including various set-top boxes, encoding boards, storage devices, etc.). The visual network as a whole can be divided into a metropolitan area network (or a national network, a global network, etc.) and an access network.
[0186] 1.2 The equipment in the access network can be mainly divided into three categories: node server, access switch (including Ethernet gateway), terminal (including various set-top boxes, encoding boards, storage, etc.).
[0187] The specific hardware structure of each access network device is as follows:
[0188] Node server:
[0189] like Figure 8 As shown, it mainly includes a network interface module 501, a switching engine module 502, a CPU module 503, and a disk array module 504;
[0190] Among them, the packets coming from the network interface module 501, the CPU module 503, and the disk array module 504 all enter the switching engine module 502; the switching engine module 502 performs an operation of checking the address table 505 on the incoming packets, thereby obtaining the packet's guidance information; and according to the packet's guidance information, the packet is stored in the queue of the corresponding packet buffer 506; if the queue of the packet buffer 506 is close to full, it is discarded; the switching engine module 502 polls all packet buffer queues, and forwards if the following conditions are met: 1) the port sending buffer is not full; 2) the queue packet counter is greater than zero. The disk array module 504 mainly implements the control of the hard disk, including the initialization, reading and writing of the hard disk; the CPU module 503 is mainly responsible for the protocol processing between the access switch and the terminal (not shown in the figure), the configuration of the address table 505 (including the downstream protocol packet address table, the upstream protocol packet address table, and the data packet address table), and the configuration of the disk array module 504.
[0191] Access switch:
[0192] like Fig. 9 As shown, it mainly includes a network interface module (a downlink network interface module 601, an uplink network interface module 602), a switching engine module 603 and a CPU module 604;
[0193] Among them, the packet (uplink data) coming from the downlink network interface module 601 enters the packet detection module 605; the packet detection module 605 detects whether the destination address (DA), source address (SA), data packet type and packet length of the packet meet the requirements. If they meet the requirements, the corresponding stream identifier (stream-id) is allocated and enters the switching engine module 603, otherwise it is discarded; the packet (downlink data) coming from the uplink network interface module 602 enters the switching engine module 603; the data packet coming from the CPU module 604 enters the switching engine module 603; the switching engine module 603 processes the incoming packet The address table 606 is looked up to obtain the packet's guidance information; if the packet entering the switching engine module 603 is from the downstream network interface to the upstream network interface, the packet is stored in the queue of the corresponding packet buffer 607 in combination with the stream identifier (stream-id); if the queue of the packet buffer 607 is nearly full, it is discarded; if the packet entering the switching engine module 603 is not from the downstream network interface to the upstream network interface, the data packet is stored in the queue of the corresponding packet buffer 607 according to the packet's guidance information; if the queue of the packet buffer 607 is nearly full, it is discarded.
[0194] The switching engine module 603 polls all packet buffer queues. In the embodiment of the present invention, there are two situations:
[0195] If the queue is from the downlink network interface to the uplink network interface, it is forwarded if the following conditions are met: 1) the port send buffer is not full; 2) the queue packet counter is greater than zero; 3) a token generated by the bit rate control module is obtained;
[0196] If the queue is not going from the downstream network interface to the upstream network interface, it is forwarded if the following conditions are met: 1) the port send buffer is not full; 2) the queue packet counter is greater than zero.
[0197] The code rate control module 608 is configured by the CPU module 604 to generate tokens for all packet buffer queues from the downstream network interface to the upstream network interface within a programmable interval to control the code rate of the upstream forwarding.
[0198] The CPU module 604 is mainly responsible for protocol processing with the node server, configuration of the address table 606 , and configuration of the bit rate control module 608 .
[0199] Ethernet protocol conversion gateway :
[0200] like Fig.10 As shown, it mainly includes a network interface module (a downlink network interface module 701, an uplink network interface module 702), a switching engine module 703, a CPU module 704, a packet detection module 705, an address table 706, a packet buffer 707, a bit rate control module 708, a MAC adding module 709, and a MAC deleting module 710.
[0201] The data packet from the downlink network interface module 701 enters the packet detection module 705; the packet detection module 705 detects whether the Ethernet MAC DA, Ethernet MAC SA, Ethernet length or frame type, visual network destination address DA, visual network source address SA, visual network data packet type and packet length of the data packet meet the requirements, and if they meet the requirements, the corresponding stream identifier (stream-id) is assigned; then, the MAC deletion module 710 subtracts the MAC DA, MAC SA, length or frame type (2 bytes) and enters the corresponding receiving buffer, otherwise it is discarded;
[0202] The downlink network interface module 701 detects the sending buffer of the port. If there is a packet, it obtains the Ethernet MAC DA of the corresponding terminal based on the visual network destination address DA of the packet, adds the Ethernet MAC DA of the terminal, the MACSA of the Ethernet protocol conversion gateway, and the Ethernet length or frametype, and sends it.
[0203] The functions of other modules in the Ethernet protocol conversion gateway are similar to those of the access switch.
[0204] terminal:
[0205] It mainly includes network interface module, business processing module and CPU module; for example, the set-top box mainly includes network interface module, audio and video encoding and decoding engine module, CPU module; the encoding board mainly includes network interface module, audio and video encoding engine module, CPU module; the memory mainly includes network interface module, CPU module and disk array module.
[0206] 1.3 The equipment in the metropolitan area network can be divided into two categories: node server, node switch, and metropolitan area server. Among them, the node switch mainly includes network interface module, switching engine module and CPU module; the metropolitan area server mainly includes network interface module, switching engine module and CPU module.
[0207] 2. Definition of Visual Network Data Packet
[0208] 2.1 Access Network Data Packet Definition
[0209] The data packet of the access network mainly includes the following parts: destination address (DA), source address (SA), reserved bytes, payload (PDU), and CRC.
[0210] As shown in the following table, the data packet of the access network mainly includes the following parts:
[0211] DA SA Reserved Payload CRC
[0212] in:
[0213] The destination address (DA) consists of 8 bytes. The first byte indicates the type of data packet (such as various protocol packets, multicast data packets, unicast data packets, etc.), with a maximum of 256 possibilities. The second to sixth bytes are the metropolitan area network address, and the seventh and eighth bytes are the access network address.
[0214] The source address (SA) is also composed of 8 bytes and has the same definition as the destination address (DA).
[0215] The reserved bytes consist of 2 bytes;
[0216] The payload part has different lengths depending on the type of datagram. If it is a protocol packet, it is 64 bytes. If it is a single multicast data packet, it is 32+1024=1056 bytes. Of course, it is not limited to the above two types.
[0217] CRC consists of 4 bytes and its calculation method follows the standard Ethernet CRC algorithm.
[0218] 2.2 Definition of Metropolitan Area Network Data Packet
[0219] The topology of the metropolitan area network is a graph. There may be two or more connections between two devices, that is, there may be more than two connections between a node switch and a node server, a node switch and a node switch, and a node switch and a node server. However, the metropolitan area network address of a metropolitan area network device is unique. In order to accurately describe the connection relationship between metropolitan area network devices, a parameter: a label is introduced in the embodiment of the present invention to uniquely describe a metropolitan area network device.
[0220] The definition of labels in this manual is similar to the definition of labels in MPLS (Multi-Protocol Label Switch). Assuming that there are two connections between device A and device B, there are two labels for the data packet from device A to device B, and there are two labels for the data packet from device B to device A. Labels are divided into input labels and output labels. Assuming that the label of the data packet entering device A (input label) is 0x0000, the label of the data packet when leaving device A (output label) may become 0x0001. The access process of the metropolitan area network is a centralized access process, which means that the address allocation and label allocation of the metropolitan area network are dominated by the metropolitan area server, and the node switch and node server are only passively executed. This is different from the label allocation of MPLS, which is the result of mutual negotiation between the switch and the server.
[0221] As shown in the following table, the data packets of the metropolitan area network mainly include the following parts:
[0222] DA SA Reserved Label Payload CRC
[0223] That is, destination address (DA), source address (SA), reserved byte (Reserved), label, payload (PDU), CRC. The label format can refer to the following definition: the label is 32 bits, of which the upper 16 bits are reserved and only the lower 16 bits are used. It is located between the reserved bytes and payload of the data packet.
[0224] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0225] It will be appreciated by those skilled in the art that the embodiments of the present invention may be provided as methods, devices, or computer program products. Therefore, the embodiments of the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the embodiments of the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
[0226] The embodiments of the present invention are described with reference to the flowcharts and / or block diagrams of the methods, terminal devices (systems), and computer program products according to the embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0227] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0228] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0229] Although the preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present invention.
[0230] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or terminal device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or terminal device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or terminal device including the elements.
[0231] The above is a detailed introduction to a transaction management method and a transaction management device provided by the present invention. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea; at the same time, for general technical personnel in this field, according to the idea of the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.
Claims
1. A server testing method, It is characterized in that The method comprises: In response to the received server test input, controlling the server to be tested to initiate a target service; Obtaining the service data of the target service in the server under test, the service data at least including: service status and service recovery record; the service status is the current status of the target service initiated by the server under test to the terminal device; the service recovery record refers to the record data of service recovery due to execution failure after the target service is initiated for the first time; When the service status is a failure status and it is confirmed that the service recovery record meets the service recovery standard, controlling the server to be tested to re-initiate the target service; When the service status is a success status, or the service recovery record does not meet the service recovery standard, the test result of the server to be tested is obtained according to the service data.
2. The method according to claim 1, It is characterized in that The step of controlling the server to be tested to initiate a target service in response to the received server test input further includes: Receive a server test input, wherein the server test input includes: a device identifier and a service identifier; In response to the server test input, the server to be tested is controlled to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier.
3. The method according to claim 2, It is characterized in that The server test input also includes: a success rate threshold, and the test result includes: a target success rate; After obtaining the test result of the server to be tested according to the business data, the method further includes: When the target success rate is less than the success rate threshold, obtaining an error type according to the business data; The test strategy corresponding to the error type is adopted to control the server to be tested to re-initiate the target service until the target success rate is greater than or equal to the success rate threshold.
4. The method according to claim 3, It is characterized in that The error reporting types include: server overload type; The adopting a test strategy corresponding to the error type to control the server under test to re-initiate the target service includes: When the error type is a server overload type, reducing the number of target services; The server to be tested is controlled to re-initiate the target service according to the reduced number of target services.
5. The method according to claim 3, It is characterized in that The error types also include: Equipment failure type; The adopting a test strategy corresponding to the error type to control the server under test to re-initiate the target service includes: When the error type is a client failure type, replacing the target device; The server to be tested is controlled to re-initiate the target service to the replaced target device.
6. The method according to claim 1, It is characterized in that The business recovery record includes: the number of business recovery times, and the confirmation that the business recovery record meets the business recovery standard includes: When the number of business recovery times is less than the business recovery times threshold, it is confirmed that the business recovery record meets the business recovery standard.
7. The method according to claim 1, It is characterized in that The business recovery record also includes: business recovery duration, and the confirmation that the business recovery record meets the business recovery standard includes: When the service recovery duration is less than the service recovery duration threshold, it is confirmed that the service recovery record meets the service recovery standard.
8. The method according to claim 2, It is characterized in that The core server is in a visual networking environment; The controlling the server to be tested to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier comprises: A test initiation instruction is sent to the protocol conversion server so that the protocol conversion server converts the test initiation instruction into a visual networking format and then forwards it to the server under test. The test initiation instruction is used to control the server under test to initiate the target service corresponding to the service identifier to the target device corresponding to the device identifier.
9. A server testing device, It is characterized in that include: one or more processors; and One or more machine-readable media having instructions stored thereon, when executed by the one or more processors, cause the apparatus to perform one or more server testing methods as claimed in any one of claims 1 to 8.
10. A computer-readable storage medium, It is characterized in that The computer program stored therein enables the processor to execute the server testing method as claimed in any one of claims 1 to 8.
Citation Information
Patent Citations
Service disconnection and connection recovery test system and service disconnection and connection recovery test method
CN105487941A
Business service test method and device, storage medium and electronic device
CN111162934A
