Network Data Processing Method, Apparatus, Electronic Device, and Storage Medium
By independently stress testing of each sub-service, the problem of low efficiency in service capacity assessment in the prior art is solved, and more efficient network data processing is achieved.
Patent Information
- Application Number
- CN202310036367.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-01-09
- Publication Date
- 2025-06-10
- Estimated Expiration
- 2043-01-09
AI Technical Summary
In the existing service capacity evaluation method, each stress test requires mobilization of all nodes in the tree structure for target data processing, resulting in low evaluation efficiency.
By generating test tasks for target services, stress tests are performed on each sub-service independently, target data sets and candidate instance sets of sub-services are obtained, and service capacity of sub-services is determined based on single instance service capacity and total number of instances.
There is no need to link stress testing of other subservices, and no need to test all instances, which improves the network data processing efficiency of subservices.
Smart Images

Figure CN116094959B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of server testing, and in particular, to a network data processing method, apparatus, electronic device, and storage medium. Background Art
[0002] In a server cluster, service capacity evaluation needs to be performed for various types of services to obtain the service capacity results of the cluster system for each type of service.
[0003] In the current service capacity evaluation method, the cluster system usually adopts a stress test method to determine the service capacity result for the service. Specifically, during the stress test, each node is included in the tree-structured test model, and each node corresponds to a sub-service included in the processing service. When a service fuse occurs at a certain node, the service capacity result of the sub-service corresponding to the node is determined. Then, the service capacity of the node is increased to ensure that the node does not interfere with the stress test process, and this execution process is repeated to determine the service capacity results of the sub-services corresponding to all nodes, and this stress test is ended.
[0004] However, in the current service capacity evaluation method, during each stress test process, all nodes in the tree structure need to be mobilized to process target data, and then, the service capacity of each type of sub-service is determined one by one, resulting in low evaluation efficiency of the service capacity. Summary of the Invention
[0005] The present disclosure provides a network data processing method, apparatus, electronic device, and storage medium to at least solve the problem of low network data processing efficiency in related technologies. The technical solution of the present disclosure is as follows:
[0006] According to a first aspect of an embodiment of the present disclosure, there is provided a network data processing method, the method including:
[0007] Responding to a stress test configuration operation triggered for a target service, generating a test task corresponding to the target service; the test task includes test information corresponding to each sub-service in the target service;
[0008] According to each piece of test information, obtaining a target data set and a candidate instance set corresponding to the sub-service; the candidate instance set is created by the cluster system and is used to provide resources for executing the sub-service;
[0009] Performing a stress test on a target instance in the candidate instance set according to the target data set to obtain the single-instance service capacity of the target instance;
[0010] Based on the single-instance service capacity and the total number of instances in the candidate instance set, determining the service capacity of the cluster system for the sub-service.
[0011] In an exemplary embodiment, obtaining the target data set corresponding to the sub-service includes:
[0012] Obtaining the target data corresponding to the sub-service;
[0013] Invoking a preset data processing interface to process the target data corresponding to the sub-service, obtaining the target data set corresponding to the sub-service, and the target data set includes multiple pieces of the target data.
[0014] In an exemplary embodiment, performing a stress test on the target instances in the candidate instance set according to the target data set to obtain the single-instance service capacity of the target instances includes:
[0015] Determining a preset number of target instances in the candidate instance set according to a preset instance screening strategy;
[0016] Based on the target data set corresponding to the sub-service and a preset stress test step size, performing a stress test on each target instance to obtain the single-instance service capacity of each target instance for the sub-service; the stress test step size represents the change amount of the data transmission amount for sending the target data to the target instance each time.
[0017] In an exemplary embodiment, based on the target data set corresponding to the sub-service and a preset stress test step size, performing a stress test on each target instance to obtain the single-instance service capacity of each target instance for the sub-service includes:
[0018] Sending the target data in the target data set to the target instance according to a preset data transmission amount;
[0019] During the process of the target instance processing the target data, if the target instance does not have a service fuse, updating the data transmission amount according to the current preset stress test step size, and executing the step of sending the target data in the target data set to the target instance based on the updated data transmission amount;
[0020] If the target instance has a service fuse, determining the target service fuse result corresponding to the target instance under the condition of meeting the preset service fuse condition according to the preset stress test step size, the service fuse callback strategy, and the current data transmission amount; using the target service fuse result as the single-instance service capacity of the target instance for the sub-service.
[0021] In an exemplary embodiment, determining the service capacity of the cluster system for the sub-service based on the single-instance service capacity and the total number of instances in the candidate instance set includes:
[0022] Sort the single-instance service capacities corresponding to each target instance in ascending order to obtain a single-instance service capacity sequence;
[0023] In the single-instance service capacity sequence, determine the target single-instance service capacity that meets the preset quantile condition;
[0024] Based on the target single-instance service capacity and the total number of instances in the candidate instance set, determine the service capacity of the cluster system for the sub-service.
[0025] In an exemplary embodiment, the method further includes:
[0026] Obtain the total number of instances in the candidate instance set corresponding to the sub-service, the required service capacity of the sub-service, and the peak single-instance service capacity of the target instance during the stress test;
[0027] According to the required service capacity of the sub-service by the cluster system and a preset redundancy parameter value, determine the planned service capacity of the cluster system for the sub-service;
[0028] According to the total number of instances in the candidate instance set, the peak single-instance service capacity, and the planned service capacity, determine the resource configuration result of the cluster system for the sub-service;
[0029] Based on the resource configuration result, perform resource configuration management on the total number of instances in the candidate instance set in the cluster system.
[0030] In an exemplary embodiment, the determining the resource configuration result of the cluster system for the sub-service according to the total number of instances in the candidate instance set, the peak single-instance service capacity, and the planned service capacity includes:
[0031] According to the ratio of the planned service capacity to the peak single-instance service capacity, determine the required number of target instances;
[0032] According to the difference between the total number of instances in the candidate instance set and the required number of target instances, determine the resource configuration result of the cluster system for the sub-service.
[0033] In an exemplary embodiment, after determining the resource configuration result of the cluster system for the sub-service, the method further includes:
[0034] If the resource configuration result of the cluster system for the sub-service indicates insufficient resource configuration, generate and output a prompt message for insufficient resource configuration.
[0035] According to a second aspect of the embodiments of the present disclosure, a network data processing device is provided, and the device includes:
[0036] A generating unit, configured to execute a stress test configuration operation triggered in response to a target service, and generate a test task corresponding to the target service; the test task includes test information corresponding to each sub-service in the target service;
[0037] A first obtaining unit, configured to execute according to each piece of test information, obtain a target data set and a candidate instance set corresponding to the sub-service; the candidate instance set is created by a cluster system and is used to provide resources for executing the sub-service;
[0038] A testing unit, configured to execute a stress test on a target instance in the candidate instance set according to the target data set, and obtain the single-instance service capacity of the target instance;
[0039] A first determining unit, configured to execute based on the single-instance service capacity and the total number of instances in the candidate instance set, determine the service capacity of the cluster system for the sub-service.
[0040] In an exemplary embodiment, the first obtaining unit includes:
[0041] An obtaining subunit, configured to execute obtaining target data corresponding to the sub-service;
[0042] A processing subunit, configured to execute calling a preset data processing interface to process the target data corresponding to the sub-service, and obtain a target data set corresponding to the sub-service.
[0043] In an exemplary embodiment, the testing unit includes:
[0044] A determining subunit, configured to execute determining a preset number of target instances in the candidate instance set according to a preset instance screening strategy;
[0045] A processing subunit, configured to execute a stress test on each target instance based on the target data set corresponding to the sub-service and a preset stress test step size, and obtain the single-instance service capacity of each target instance for the sub-service; the stress test step size represents the change amount of the data sending amount for sending target data to the target instance each time.
[0046] In an exemplary embodiment, the processing subunit is specifically configured to send the target data in the target data set to the target instance according to a preset data sending amount;
[0047] During the process of the target instance processing the target data, if the target instance does not have service fuse, update the data transmission volume according to the current preset stress test step size, and execute the step of sending the target data in the target data set to the target instance based on the updated data transmission volume;
[0048] If the target instance has service fuse, determine the target service fuse result corresponding to the target instance under the condition of meeting the preset service fuse condition according to the preset stress test step size, service fuse callback policy and the current data transmission volume; use the target service fuse result as the single instance service capacity of the target instance for the sub-service.
[0049] In an exemplary embodiment, the first determination unit includes:
[0050] A sorting sub-unit, configured to perform sorting processing on the single instance service capacities corresponding to each target instance in ascending order to obtain a single instance service capacity sequence;
[0051] A first determination sub-unit, configured to perform determining a target single instance service capacity that meets the preset quantile condition in the single instance service capacity sequence;
[0052] A second determination sub-unit, configured to perform determining the service capacity of the cluster system for the sub-service based on the target single instance service capacity and the total number of instances in the candidate instance set.
[0053] In an exemplary embodiment, the apparatus further includes:
[0054] A second acquisition unit, configured to perform acquiring the total number of instances in the candidate instance set corresponding to the sub-service, the required service capacity of the sub-service, and the peak value of the single instance service capacity of the target instance during the stress test;
[0055] A second determination unit, configured to perform determining the planned service capacity of the cluster system for the sub-service according to the required service capacity of the cluster system for the sub-service and the preset redundancy parameter value;
[0056] A third determination unit, configured to perform determining the resource configuration result of the cluster system for the sub-service according to the total number of instances in the candidate instance set, the peak value of the single instance service capacity, and the planned service capacity;
[0057] A configuration management unit, configured to perform resource configuration management on the total number of instances in the candidate instance set in the cluster system based on the resource configuration result.
[0058] In an exemplary embodiment, the third determination unit is specifically configured to determine the number of target instance requirements according to the ratio of the planned service capacity to the peak value of the single-instance service capacity;
[0059] Determine the resource configuration result of the cluster system for the sub-service according to the difference between the total number of instances in the candidate instance set and the number of target instance requirements.
[0060] In an exemplary embodiment, the apparatus further includes:
[0061] A prompt unit configured to generate and output a prompt message indicating insufficient resource configuration if the resource configuration result of the cluster system for the sub-service indicates insufficient resource configuration.
[0062] According to a third aspect of the embodiments of the present disclosure, there is provided an electronic device, including:
[0063] A processor;
[0064] A memory for storing instructions executable by the processor;
[0065] Wherein, the processor is configured to execute the instructions to implement the network data processing method according to any one of the above first aspects.
[0066] According to a fourth aspect of the embodiments of the present disclosure, there is provided a computer-readable storage medium, when the instructions in the computer-readable storage medium are executed by a processor of an electronic device, enabling the electronic device to execute the network data processing method according to any one of the above first aspects.
[0067] According to a fifth aspect of the embodiments of the present disclosure, there is provided a computer program product, when the instructions are executed by a processor of an electronic device, enabling the electronic device to execute the network data processing method according to any one of the above first aspects.
[0068] The technical solutions provided by the embodiments of the present disclosure at least bring the following beneficial effects:
[0069] Using this method, the cluster system generates a test task corresponding to the target service in response to a stress test configuration operation triggered for the target service. In each test task, each sub-service included in the target service corresponds to test information. For each piece of test information, a stress test is independently performed on each sub-service in the target service to determine the single-instance service capacity of the sub-service for the target instance. Based on the single-instance service capacity of the sub-service and the total number of instances in the candidate instance set, the service capacity of the cluster system for the sub-service is determined. During the process of performing the stress test on the sub-service, it is not necessary to link the stress tests of other sub-services in the target service, and it is not necessary to test all the instances in the candidate instance set, which improves the network data processing efficiency of the sub-service.
[0070] It should be understood that the above general description and the following detailed description are only exemplary and explanatory, and do not limit the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0071] The accompanying drawings herein are incorporated into the specification and form a part of the specification, showing embodiments consistent with the present disclosure, and are used together with the specification to explain the principles of the present disclosure and do not constitute an improper limitation of the present disclosure.
[0072] Figure 1 It is a structural diagram of a cluster system for a network data processing method shown according to an exemplary embodiment.
[0073] Figure 2 It is a flowchart of a network data processing method shown according to an exemplary embodiment.
[0074] Figure 3 It is a flowchart of a method for obtaining a target data set shown according to an exemplary embodiment.
[0075] Figure 4 It is a flowchart of a stress test method for a target instance shown according to an exemplary embodiment.
[0076] Figure 5 It is a flowchart of a method for determining the single-instance service capacity of a target instance shown according to an exemplary embodiment.
[0077] Figure 6 It is an exemplary flowchart of a method for determining the single-instance service capacity shown according to an exemplary embodiment.
[0078] Figure 7 It is a flowchart of a method for determining the service capacity of a sub-service shown according to an exemplary embodiment.
[0079] Figure 8 It is a flowchart of a method for managing the resource configuration of a cluster system shown according to an exemplary embodiment.
[0080] Figure 9 It is a flowchart of a method for managing resource configuration of a cluster system shown according to an exemplary embodiment.
[0081] Figure 10 It is a block diagram of a network data processing device shown according to an exemplary embodiment.
[0082] Figure 11 It is a block diagram of an electronic device shown according to an exemplary embodiment. Detailed implementation manners
[0083] In order to enable those of ordinary skill in the art to better understand the technical solutions of the present disclosure, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
[0084] It should be noted that the terms "first", "second", etc. in the specification and claims of the present disclosure and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that such used data may be interchanged under appropriate circumstances so that the embodiments of the present disclosure described herein can be implemented in an order other than those illustrated or described herein. The implementation manners described in the following exemplary embodiments do not represent all implementation manners consistent with the present disclosure. On the contrary, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.
[0085] It should also be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for display, data for analysis, etc.) involved in the present disclosure are all information and data authorized by the user or fully authorized by all parties.
[0086] The network data processing method provided by the present disclosure can be applied to, for example Figure 1In the cluster system shown. The cluster system includes four levels: a user layer, a policy layer, a dependency layer, and a storage layer. Among them, the user layer is used to configure the test tasks (also known as network data processing tasks) for the stress test of each target service, to mobilize the relevant configuration information of other levels, and to perform information queries during the processing of the test tasks. The policy layer is used to store stress test strategies, stress test rules for various types of target services, and analyze the stress test results (service capacity), etc. The dependency layer includes a data dependency module and a platform dependency module. Among them, the data dependency module is used to provide data support for the cluster system. For example, the relevant metric information of each instance resource in the cluster system. The present disclosure embodiment does not limit the types and numbers of data in the data dependency module. The platform dependency module is used to provide an interface for calling a third-party platform (for example, the interface of the processing platform) to complete the online stress test service. The storage layer is used to store the data during the stress test. For example, the service capacity of each single instance during the stress test. The present disclosure embodiment does not limit this.
[0087] Figure 2 is a flowchart of a network data processing method shown according to an exemplary embodiment, as Figure 2 shown. This network data processing method is used in a cluster system to be tested. The method includes the following steps.
[0088] In step S210, in response to a stress test configuration operation triggered for a target service, a test task corresponding to the target service is generated.
[0089] Among them, the test task contains the test information corresponding to each sub-service in the target service.
[0090] In implementation, the user triggers a stress test configuration operation for the target service through the service capacity configuration interface provided by the cluster system. The cluster system generates a test task corresponding to the target service in response to the stress test configuration operation triggered for the target service. Since the types of target data are different, for each type of target data, there is a sub-service in the target service corresponding to the target data. The test task generated by the cluster system contains the test information corresponding to multiple sub-services in the target service.
[0091] In step S220, according to each test information, a target data set and a candidate instance set corresponding to the sub-service are obtained.
[0092] Among them, the candidate instance set is created by the cluster system and is used to provide virtual resources for executing the sub-service corresponding to the candidate instance set. Specifically, the candidate instance set contains at least one instance. Each instance can be used as a virtual computing server on the cloud for executing the sub-service and provides virtual resources for executing the sub-service.
[0093] In implementation, target data required for each type of sub-service is pre-stored in the cluster system, and a candidate instance set is pre-created for each type of sub-service in the cluster system. The cluster system obtains the target data set corresponding to the sub-service and the candidate instance set corresponding to the sub-service according to the test information corresponding to each sub-service. The target data set contains the target data corresponding to the sub-service. Specifically, the construction method of the target data set will be described in detail below and will not be elaborated here.
[0094] In step S230, according to the target data set, a stress test is performed on the target instances in the candidate instance set to obtain the single-instance service capacity of the target instances.
[0095] In implementation, the cluster system screens out a preset number of target instances from the candidate instance set, uses these preset number of target instances as the instance representatives in the candidate instance set, and performs a stress test on each target instance for the sub-service, so as to determine the service capacity of the candidate instance set for the sub-service according to the single-instance service capacity of each target instance for the sub-service. Specifically, the cluster system sends the target data in the target data set to the target instances according to a preset data transmission volume. The target instances process the target data. During the data processing, the cluster system continuously adjusts the size of the data transmission volume through a preset stress test step size until the target instance experiences service fuse when sending the target data to the target instance at a certain adjusted data transmission volume size. The cluster system determines the single-instance service capacity of the target instance for the sub-service.
[0096] In step S240, based on the single-instance service capacity and the total number of instances in the candidate instance set, the service capacity of the cluster system for the sub-service is determined.
[0097] In implementation, after determining the single-instance service capacity of each target instance for the sub-service, the cluster system sorts the determined single-instance service capacities to obtain a single-instance service capacity sequence. In the single-instance service capacity sequence, based on a preset quantile condition, the single-instance service capacity that meets the preset quantile condition is determined as the target single-instance service capacity. This target single-instance service capacity can be used as an estimated value of the service capacity of any instance in the candidate instance set. Then, the cluster system determines the service capacity of the cluster system for the sub-service based on the total number of instances included in the candidate instance set and the target single-instance service capacity.
[0098] In the above network data processing method, the cluster system generates a test task corresponding to the target service in response to a stress test configuration operation triggered for the target service. The test task includes test information corresponding to each sub-service in the target service. Then, the cluster system obtains a target data set and a candidate instance set corresponding to the sub-service according to each test information. The cluster system performs a stress test on the target instances in the candidate instance set according to the target data set, and obtains the single-instance service capacity of the target instances. Then, the cluster system determines the service capacity of the cluster system for the sub-service based on the single-instance service capacity and the total number of instances in the candidate instance set. By using this method, through the pre-configured test tasks, the sub-services in each target service are separated, and stress tests are respectively performed on the target instances of each sub-service to obtain the single-instance service capacity. Then, based on the single-instance service capacity and the total number of instances in the candidate instance set of the sub-service, the service capacity of the cluster system for the sub-service is determined. Therefore, in the process of performing a stress test on the sub-service, there is no need to link the stress test processes of other sub-services in the target service, and it is not necessary for all instances of various types of sub-services in the cluster system to participate in the stress test to determine the service capacity, which improves the efficiency of network data processing.
[0099] In an exemplary embodiment, as Figure 3 shown, to obtain the target data set corresponding to the sub-service in step S220, it can be specifically implemented through the following steps:
[0100] In step S221, obtain the target data corresponding to the sub-service.
[0101] Among them, for each type of sub-service included in the target service, each type of sub-service corresponds to the target data of that type of sub-service. For example, the target data of different types of sub-services may include: display object target data, recommendation information target data, etc. The embodiments of the present disclosure do not limit the type of target data.
[0102] In implementation, the cluster system obtains the target data corresponding to the sub-service to be currently stress-tested. For example, for sub-service A, the cluster system obtains the display object target data based on the correspondence between sub-service type A and the target data.
[0103] In step S222, call a preset data processing interface to process the target data corresponding to the sub-service, and obtain a target data set corresponding to the sub-service.
[0104] Among them, the target data set contains multiple target data. For example, the target data can be, but is not limited to, traffic data, and the target data set is a data set containing a large amount of traffic data.
[0105] In implementation, the cluster system schedules a preset data processing interface to process the target data corresponding to the sub-service, and obtains a target data set corresponding to the sub-service. The target data set is used to provide test data samples during the stress testing of the target instance.
[0106] In this embodiment, by processing the target data corresponding to the sub-service, a target data set corresponding to the sub-service is obtained, so as to perform stress testing on the target instance based on sufficient target data in the target data set.
[0107] In an exemplary embodiment, as Figure 4 shown, in step S230, according to the target data set, stress testing is performed on the target instance in the candidate instance set, and the specific processing process for obtaining the single-instance service capacity of the target instance includes:
[0108] In step S402, according to a preset instance screening policy, a preset number of target instances are determined in the candidate instance set.
[0109] In implementation, an instance screening policy for screening target instances is pre-stored in the cluster system, and the instance screening policy can be but is not limited to a random screening policy. Specifically, the cluster system randomly selects a preset number of instances in the candidate instance set according to the random selection policy as the target instances. Among them, the target instances serve as representative instances in the candidate instance set and are used to participate in stress testing. Optionally, the preset number of target instances screened by the cluster system can form a target instance list. In this target instance list, the cluster system processes each target instance in a loop to complete the stress testing process of each target instance.
[0110] Optionally, the screening methods in the random selection policy can be but are not limited to including random sampling methods, stratified sampling methods, cluster sampling methods, etc. The present disclosure embodiment does not limit the specific selection method of the random selection policy.
[0111] Optionally, the instance screening policy pre-stored in the cluster system can be configured as other types of screening policies in addition to the random selection policy. For example, a targeted instance selection policy is set according to the performance differences between instances. Therefore, the present disclosure embodiment does not limit the specific policy content of the instance screening policy.
[0112] In step S404, based on the target data set corresponding to the sub-service and a preset stress testing step size, stress testing is performed on the target instance to obtain the single-instance service capacity of each target instance for the sub-service.
[0113] Among them, the stress testing step size represents the change amount of the data sending amount for sending target data to the target instance each time.
[0114] In implementation, for each target instance, the cluster system sends target data to the target instance each time according to a data transmission volume. The initial data transmission volume can be equal to or greater than a preset stress test step size. The service capacity of the target instance is stress-tested by sending the target data through the initial data transmission volume. During the test, if the target instance does not experience service fusing, the cluster system updates the initial data transmission volume according to the stress test step size, continuously increasing the size of the initial data transmission volume until the target instance experiences service fusing. When the cluster system detects that the target instance has experienced service fusing, it determines whether the current service fusing of the target instance meets the preset service fusing conditions. If the target instance meets the current service fusing conditions, the cluster system uses the stress test result of the current target instance under the service fusing conditions as the single-instance service capacity of the target instance for the sub-service.
[0115] In this embodiment, a preset number of target instances are determined from the candidate instance set based on a preset instance screening strategy. The target instance serves as a representative instance of each instance in the candidate instance set and participates in the stress test to determine the single-instance service capacity of the target instance. The single-instance service capacity result is used to estimate the service capacity size of the overall candidate instance set of the cluster system for the sub-service, improving the efficiency of evaluating the service capacity of the sub-service.
[0116] In an exemplary embodiment, during the process of stress-testing each target instance, the embodiment of the present disclosure adopts a step-size callback method of the dichotomy method to determine the single-instance service capacity of each target instance. Specifically, as Figure 5 shown, in step S404, based on the target data set corresponding to the sub-service and a preset stress test step size, each target instance is stress-tested to obtain the single-instance service capacity of each target instance for the sub-service. The specific processing process includes:
[0117] In step S502, the target data in the target data set is sent to the target instance according to a preset data transmission volume.
[0118] In implementation, at the start of the stress test, the cluster system sends the target data in the target data set to the target instance according to a preset data transmission volume (i.e., the initial data transmission volume). The preset data transmission volume is generally small and will not cause the target instance to directly experience service fusing.
[0119] In step S504, during the process of the target instance processing the target data, if the target instance does not experience service fusing, the data transmission volume is updated according to the current preset stress test step size, and the step of sending the target data in the target data set to the target instance is executed based on the updated data transmission volume.
[0120] In implementation, during the process of the target instance processing the target data, the cluster system detects the service availability of the target instance and determines whether the target instance has experienced service fusing. Among them, the service availability of the target instance can be 99% availability, that is, when the target instance undergoes 100 stress tests, it is available for 99 times. If it is determined based on the judgment of service availability that the target instance has not experienced service fusing, the cluster system monitors the QPS (Queries Per Second) metric of the target instance during the process of the target instance processing the target data. This Queries Per Second metric can reflect the current stress test situation of the target instance.
[0121] Then, when it is determined that the target instance can process the target data normally, the cluster system can update the initial data sending volume based on a preset stress test step size to obtain the updated data sending volume. Then, based on the updated data sending volume, it continues to send the target data in the target data set to the target instance and executes the stress test process for the target instance (that is, repeats step S502). Specifically, the target instance receives the target data sent in the size of the updated data sending volume and continues to process the target data, and the cluster system continues to monitor the stress test situation of the target instance. This processing process is similar to the process of the target instance processing the target data sent in the size of the initial data sending volume, except for the difference reflected in the stress test result of the target instance (the stress test result is the Queries Per Second). This embodiment of the present disclosure will not elaborate on the process of the cluster system continuously stress testing the target instance when the target instance has not experienced service fusing.
[0122] In step S506, if the target instance has experienced service fusing, then according to the preset stress test step size, service fusing callback policy, and the current data sending volume, the target service fusing result corresponding to the target instance is determined under the condition of meeting the preset service fusing condition.
[0123] Among them, the target service fusing result is used as the single-instance service capacity of the target instance for the sub-service.
[0124] In implementation, if the target instance has experienced service fusing, it indicates that sending the target data in the size of the current data sending volume has caused the target instance to experience service fusing. When the target instance has experienced service fusing, the cluster system then determines the target service fusing result corresponding to the target instance under the condition of meeting the preset service fusing condition according to the preset stress test step size, service fusing callback policy, and the current data sending volume.
[0125] Specifically, in the case where service fusing first occurs for a target instance, due to the large stress test step size, the interval of data transmission volume is large. Therefore, in the case of the first service fusing, the determined service fusing result may not be accurate. Thus, the cluster system will appropriately reduce the data transmission volume according to the step size callback strategy of the dichotomy method, and determine the target service fusing result under the critical condition of service fusing for the target instance, so as to use it as the single-instance service capacity of the target instance for the sub-service.
[0126] Optionally, in order to improve the efficiency of network data processing, the stress test step size set by the cluster system is generally large, so as to ensure that after as few limited updates as possible for the initial data transmission volume, the target data is transmitted based on the updated data transmission volume, which can cause service fusing for the target instance. However, at the same time, the stress test step size cannot be set too large, resulting in a direct failure in the processing process of the target instance after transmitting the target data with a large stress test step size. The stress test step size can be set according to the actual stress test requirements, and the embodiments of the present disclosure do not make any limitations.
[0127] In this embodiment, by performing stress tests on target instances, the single-instance service capacity of each target instance is determined, and the single-instance service capacity result is used to evaluate the overall service capacity of the candidate instance set created by the cluster system for the sub-service, improving the network data processing efficiency of the sub-service.
[0128] In an optional embodiment, as Figure 6 shown, an example of a single-instance stress test method is provided, which specifically includes the following steps:
[0129] Step S601: In response to a stress test configuration operation triggered for each target service, generate a test task corresponding to each target service.
[0130] Step S602: Process each test task concurrently. Each test task contains test information corresponding to each sub-service in the target service;
[0131] Step S603: According to the test information of each sub-service, obtain the target data set corresponding to the sub-service. Among them, the target data set is obtained by processing the target data through a data processing platform;
[0132] Step S604: Screen multiple target instances from the candidate instance set to form a target instance list, and obtain each target instance in the target instance list.
[0133] Step S605: Send the target data to the target instance based on the preset data transmission volume, perform data processing on the target data through the target instance, call the processing platform to replay the processed target data, and detect the stress test metric values of the target instance during the replay of the target data.
[0134] Step S606: Determine whether service fuse occurs for the target instance. If service fuse occurs, execute Step S607; if service fuse does not occur, update the size of the data transmission volume of the target data according to the preset stress test step length, and execute Step S605.
[0135] Step S607: Determine whether the preset callback times threshold is reached. If the preset callback times threshold is reached, execute Step S609. If the preset callback times threshold is not reached, execute Step S608.
[0136] Step S608: Based on the preset dichotomy, process the current stress test step length to determine the callback stress test step length. Use the difference between the current data transmission volume and the callback stress test step length as the updated data transmission volume, and execute Step S605 based on the updated data transmission volume.
[0137] Step S609: Determine the service fuse result corresponding to the current target instance, and generate a stress test record for the target instance.
[0138] In an exemplary embodiment, as Figure 7 shown, in Step S230, based on the single-instance service capacity and the total number of instances in the candidate instance set, determine the service capacity of the cluster system for the sub-service, specifically including the following processing steps:
[0139] In Step S701, sort the single-instance service capacities corresponding to each target instance in ascending order to obtain a single-instance service capacity sequence.
[0140] In practice, after determining the single-instance service capacity of each target instance for the sub-service, the cluster system sorts the determined single-instance service capacities in ascending order of service capacity value to obtain a single-instance service capacity sequence.
[0141] In Step S702, in the single-instance service capacity sequence, determine the target single-instance service capacity that meets the preset quantile condition.
[0142] In practice, in the single-instance service capacity sequence, based on the preset quantile condition, the cluster system determines the single-instance service capacity that meets the preset quantile condition as the target single-instance service capacity.
[0143] Optionally, when determining the target single-instance service capacity, the preset quantile condition can be the 90th percentile or the 50th percentile. The specific quantile condition can be determined based on the actual demand for the service capacity of the sub-service during the actual test process. The embodiments of the present disclosure do not limit the quantile condition for determining the target single-instance service capacity.
[0144] In step S703, based on the target single-instance service capacity and the total number of instances in the candidate instance set, determine the service capacity of the cluster system for the sub-service.
[0145] In implementation, the target single-instance service capacity can be used as an estimated value of the service capacity of any instance in the candidate instance set. Then, the cluster system determines the service capacity of the cluster system for the sub-service based on the total number of instances included in the candidate instance set and the target single-instance service capacity.
[0146] In this embodiment, the target single-instance service capacity is determined from the single-instance service capacities, and the overall service capacity of the candidate instance set created by the cluster system for the sub-service is evaluated based on the single-instance service capacity results, improving the network data processing efficiency of the sub-service.
[0147] In an exemplary embodiment, after determining the service capacity of the cluster system for the sub-service through stress testing, the cluster system can compare this service capacity (i.e., representing the actual demand service capacity) with the service capacity pre-configured in the cluster system to determine whether the resource configuration of the current cluster system is reasonable, ensuring that for this type of sub-service, the cluster system will not have a situation of insufficient service capacity, nor will it cause a large amount of waste of service resources due to excessive service capacity. Specifically, the method for the cluster system to perform resource configuration management is as Figure 8 shown, and this network data processing method further includes:
[0148] In step S802, obtain the total number of instances in the candidate instance set corresponding to the sub-service, the required service capacity of the sub-service, and the peak single-instance service capacity of the target instance during the stress test.
[0149] In implementation, the cluster system obtains the total number of instances in the candidate instance set corresponding to the sub-service, the required service capacity of the sub-service, and the peak single-instance service capacity of the target instance during the stress test. Specifically, the total number of instances in the candidate instance set represents the actual number of instances allocated by the current cluster system to the sub-service. The peak single-instance service capacity is the peak data in the service fuse results of each target instance determined by the cluster system when performing a stress test on each target instance in the candidate instance set, and is used to represent the best performance of the target instance. The required service capacity of the sub-service can be determined by the cluster system detecting the peak value of the actual service capacity of the sub-service during a historical time period. The present disclosure embodiment does not limit the duration of the historical time period, which can be one week, one month, or one quarter, etc.
[0150] In step S804, according to the required service capacity of the sub-service by the cluster system and a preset redundancy parameter value, the planned service capacity of the sub-service by the cluster system is determined.
[0151] In implementation, after determining the required service capacity of the sub-service by the cluster system, the cluster system appropriately redundancies the service capacity of the sub-service determined after the stress test according to the redundancy parameter value, that is, calculates the product of the service capacity of the sub-service and the preset redundancy parameter value to determine the planned service capacity of the sub-service by the cluster system. The planned service capacity represents the required resource amount of the sub-service after appropriate redundancy.
[0152] In step S806, according to the total number of instances in the candidate instance set, the peak single-instance service capacity, and the planned service capacity, the resource allocation result of the sub-service by the cluster system is determined.
[0153] In implementation, the cluster system determines the resource allocation result of the sub-service by the cluster system according to the total number of instances in the candidate instance set, the peak single-instance service capacity, and the planned service capacity. The value of the resource allocation result reflects the difference in the number of instances between the currently configured number of instances and the actually required number of instances. The difference in the number of instances carries sign information, where a negative sign indicates that the current service capacity is insufficient, and a positive sign indicates that the current service capacity is redundant. Therefore, the resource allocation result can be used to represent whether the service capacity of the sub-service in the current cluster system is sufficient or redundant.
[0154] In step S808, based on the resource allocation result, resource allocation management is performed on the candidate instance set in the cluster system.
[0155] In implementation, the corresponding relationship between the resource allocation result and the resource management policy is pre-stored in the cluster system. Specifically, the cluster system determines the target resource management policy in each corresponding relationship based on the resource allocation result, and based on the target resource management policy, performs resource allocation management on the candidate instance set in the cluster system.
[0156] In this embodiment, based on the total number of instances in the candidate instance set, the peak service capacity of a single instance, and the planned service capacity, the resource allocation result of the cluster system for the sub-service is determined. Based on this resource allocation result, the current resource allocation situation in the cluster system can be balanced and configured, which not only avoids the risk of insufficient resource allocation but also reduces the waste of resources caused by redundant instance numbers.
[0157] In an exemplary embodiment, as Figure 9 shown, in step S808, based on the total number of instances in the candidate instance set, the peak service capacity of a single instance, and the planned service capacity, the resource allocation result of the cluster system for the sub-service is determined. The specific processing process includes:
[0158] In step S902, according to the ratio of the planned service capacity to the peak service capacity of a single instance, the target instance demand number is determined.
[0159] In implementation, the cluster system determines the target instance demand number according to the ratio of the planned service capacity to the peak service capacity of a single instance. The planned service capacity represents the required service capacity of the sub-service. Furthermore, based on the calculation of the ratio between the required service capacity of the sub-service and the peak service capacity of a single instance, the target instance demand number of the sub-service can be determined.
[0160] In step S904, according to the difference between the total number of instances in the candidate instance set and the target instance demand number, the resource allocation result of the sub-service is determined.
[0161] In implementation, the cluster system obtains the resource allocation result of the sub-service according to the difference between the total number of instances in the candidate instance set and the target instance demand number. This resource allocation result is the specific value of the difference between the instance numbers, and this specific value can be a positive number, a negative number, or 0. When it is a positive number, it indicates that the current instances are redundant; when it is a negative number, it indicates that the current instances are insufficient; and the case of 0 indicates that the number of instances is reasonable, that is, neither too many nor too few.
[0162] In this embodiment, based on the total number of instances in the candidate instance set, the peak service capacity of a single instance, and the planned service capacity, the resource allocation result of the cluster system for the sub-service is determined. This resource allocation result is the difference between the actual total number of instances of the cluster system for the sub-service and the target instance demand number. Through this resource allocation result, resource management of the instances in the candidate instance set of the cluster system can be achieved.
[0163] In an exemplary embodiment, for the situation where the sub-service resources in the cluster system are insufficiently configured, in addition to adjusting the amount of resources corresponding to the sub-service through resource configuration management to increase the service capacity of the cluster system for the sub-service to the expected value, it is also possible to give an early warning about the insufficient resource configuration situation. After step S904, the method further includes:
[0164] When the resource configuration result of the cluster system for the sub-service indicates insufficient resource configuration, generate and output a prompt message for insufficient resource configuration.
[0165] In implementation, if the resource configuration result of the cluster system for the sub-service is insufficient resource configuration, the cluster system generates and outputs a prompt message for insufficient resource configuration.
[0166] In this embodiment, by adding a prompt message for insufficient resource configuration to prompt the user that the current cluster system cannot meet the resource requirements of the sub-service, an early warning of the operation risk of the cluster system is realized.
[0167] It should be understood that although Figures 2 - 9 the steps in the flowchart are shown in sequence according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise clearly stated in this article, there is no strict order limit for the execution of these steps, and these steps can be executed in other orders. Moreover, Figures 2 - 9 at least a part of the steps in
[0168] may include multiple steps or multiple stages. These steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be executed alternately or in turn with at least a part of other steps or steps or stages in other steps.
[0169] Figure 10 is a block diagram of a network data processing device shown according to an exemplary embodiment. Referring to Figure 10 , the device 1000 includes a generating unit 1002, an obtaining unit 1004, a testing unit 1006, and a determining unit 1008.
[0170] The generating unit 1002 is configured to generate a test task corresponding to the target service in response to a stress test configuration operation triggered for the target service; the test task includes test information corresponding to each sub-service in the target service.
[0171] The first acquisition unit 1004 is configured to acquire a target data set and a candidate instance set corresponding to a sub-service according to each test information; the candidate instance set is created by a cluster system and is used to provide resources for executing the sub-service.
[0172] The test unit 1006 is configured to perform a stress test on a target instance in the candidate instance set according to the target data set to obtain the single-instance service capacity of the target instance.
[0173] The first determination unit 1008 is configured to determine the service capacity of the cluster system for the sub-service based on the single-instance service capacity and the total number of instances in the candidate instance set.
[0174] In an exemplary embodiment, the first acquisition unit 1004 includes:
[0175] An acquisition subunit, configured to acquire target data corresponding to the sub-service;
[0176] A processing subunit, configured to call a preset data processing interface to process the target data corresponding to the sub-service to obtain a target data set corresponding to the sub-service.
[0177] In an exemplary embodiment, the test unit 1004 includes:
[0178] A determination subunit, configured to determine a preset number of target instances in the candidate instance set according to a preset instance screening policy;
[0179] A processing subunit, configured to perform a stress test on each target instance based on the target data set corresponding to the sub-service and a preset stress test step size to obtain the single-instance service capacity of each target instance for the sub-service; the stress test step size represents the change amount of the data sending amount for sending the target data to the target instance each time.
[0180] In an exemplary embodiment, the processing subunit is specifically configured to send the target data in the target data set to the target instance according to a preset data sending amount;
[0181] During the process of the target instance processing the target data, if the target instance does not have a service fuse, update the data sending amount according to the current preset stress test step size, and perform the step of sending the target data in the target data set to the target instance based on the updated data sending amount;
[0182] If the target instance has a service fuse, determine the target service fuse result corresponding to the target instance when meeting the preset service fuse condition according to the preset stress test step size, the service fuse callback policy, and the current data sending amount; use the target service fuse result as the single-instance service capacity of the target instance for the sub-service.
[0183] In an exemplary embodiment, the first determination unit 1006 includes:
[0184] A sorting subunit, configured to perform sorting processing on the single-instance service capacity corresponding to each target instance in ascending order to obtain a single-instance service capacity sequence;
[0185] A first determination subunit, configured to determine a target single-instance service capacity that meets a preset quantile condition in the single-instance service capacity sequence;
[0186] A second determination subunit, configured to determine the service capacity of the cluster system for the sub-service based on the target single-instance service capacity and the total number of instances in the candidate instance set.
[0187] In an exemplary embodiment, the apparatus 1000 further includes:
[0188] A second acquisition unit, configured to acquire the total number of instances in the candidate instance set corresponding to the sub-service, the required service capacity of the sub-service, and the peak value of the single-instance service capacity of the target instance during the stress test;
[0189] A second determination unit, configured to determine the planned service capacity of the cluster system for the sub-service according to the required service capacity of the cluster system for the sub-service and a preset redundancy parameter value;
[0190] A third determination unit, configured to determine the resource configuration result of the cluster system for the sub-service according to the total number of instances in the candidate instance set, the peak value of the single-instance service capacity, and the planned service capacity;
[0191] A configuration management unit, configured to perform resource configuration management on the total number of instances in the candidate instance set in the cluster system based on the resource configuration result.
[0192] In an exemplary embodiment, the third determination unit is specifically configured to determine the required number of target instances according to the ratio of the planned service capacity to the peak value of the single-instance service capacity;
[0193] Determine the resource configuration result of the cluster system for the sub-service according to the difference between the total number of instances in the candidate instance set and the required number of target instances.
[0194] In an exemplary embodiment, the apparatus 1000 further includes:
[0195] A prompt unit, configured to generate and output a prompt message indicating insufficient resource configuration if the resource configuration result of the cluster system for the sub-service indicates insufficient resource configuration.
[0196] Regarding the device in the above embodiments, the specific manner in which each module performs operations has been described in detail in the embodiments related to the method, and will not be elaborated herein.
[0197] Figure 11 FIG. 4 is a block diagram of an electronic device 1100 for network data processing according to an exemplary embodiment. For example, the electronic device 1100 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.
[0198] Referring to Figure 11 , the electronic device 1100 may include one or more of the following components: a processing component 1102, a memory 1104, a power supply component 1106, a multimedia component 1108, an audio component 1111, an input / output (I / O) interface 1112, a sensor component 1114, and a communication component 1116.
[0199] The processing component 1102 generally controls the overall operation of the electronic device 1100, such as operations associated with display, telephone calls, data communication, camera operations, and recording operations. The processing component 1102 may include one or more processors 1120 to execute instructions to complete all or part of the steps of the above method. In addition, the processing component 1102 may include one or more modules to facilitate the interaction between the processing component 1102 and other components. For example, the processing component 1102 may include a multimedia module to facilitate the interaction between the multimedia component 1108 and the processing component 1102.
[0200] The memory 1104 is configured to store various types of data to support the operation of the electronic device 1100. Examples of such data include instructions for any application or method operating on the electronic device 1100, contact data, phone book data, messages, pictures, videos, etc. The memory 1104 may be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disks, optical disks, or graphene memory.
[0201] The power supply component 1106 provides power to various components of the electronic device 1100. The power supply component 1106 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the electronic device 1100.
[0202] The multimedia component 1108 includes a screen that provides an output interface between the electronic device 1100 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen can be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors can sense not only the boundaries of touch or swipe actions but also detect the duration and pressure associated with the touch or swipe operations. In some embodiments, the multimedia component 1108 includes a front camera and / or a rear camera. When the electronic device 1100 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera can receive external multimedia data. Each of the front camera and the rear camera can be a fixed optical lens system or have a focal length and optical zoom capabilities.
[0203] The audio component 1111 is configured to output and / or input audio signals. For example, the audio component 1111 includes a microphone (MIC) that is configured to receive external audio signals when the electronic device 1100 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals can be further stored in the memory 1104 or transmitted via the communication component 1116. In some embodiments, the audio component 1111 further includes a speaker for outputting audio signals.
[0204] The I / O interface 1112 provides an interface between the processing component 1102 and a peripheral interface module, and the peripheral interface module can be a keyboard, a click wheel, buttons, etc. These buttons can include but are not limited to: a home button, a volume button, a power button, and a lock button.
[0205] The sensor component 1114 includes one or more sensors for providing an assessment of the status of various aspects of the electronic device 1100. For example, the sensor component 1114 can detect the on / off state of the electronic device 1100, the relative positioning of components, such as the display and the keypad of the electronic device 1100. The sensor component 1114 can also detect a change in the position of the electronic device 1100 or an electronic device 1100 component, the presence or absence of user contact with the electronic device 1100, the orientation or acceleration / deceleration of the device 1100, and a change in the temperature of the electronic device 1100. The sensor component 1114 can include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor component 1114 can also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor component 1114 can further include an acceleration sensor, a gyro sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
[0206] The communication component 1116 is configured to facilitate communication between the electronic device 1100 and other devices in a wired or wireless manner. The electronic device 1100 can access a communication standard-based wireless network, such as WiFi, a carrier network (such as 2G, 3G, 4G, or 5G), or a combination thereof. In an exemplary embodiment, the communication component 1116 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 1116 further includes a Near Field Communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on Radio Frequency Identification (RFID) technology, Infrared Data Association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
[0207] In an exemplary embodiment, the electronic device 1100 can be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components for performing the above method.
[0208] In an exemplary embodiment, a computer-readable storage medium including instructions is also provided, such as a memory 1104 including instructions, and the above instructions can be executed by a processor 1120 of the electronic device 1100 to complete the above method. For example, the computer-readable storage medium can be a ROM, Random Access Memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.
[0209] In an exemplary embodiment, a computer program product is also provided, and the computer program product includes instructions that can be executed by a processor 1120 of the electronic device 1100 to complete the above method.
[0210] It should be noted that the above-mentioned device, electronic device, computer-readable storage medium, computer program product, etc. may also include other implementation manners according to the description of the method embodiments. The specific implementation manners can refer to the description of the relevant method embodiments and will not be elaborated here one by one.
[0211] Those skilled in the art will readily conceive of other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include known common knowledge or conventional technical means in the technical field not disclosed by the present disclosure. The specification and embodiments are only to be considered as exemplary, and the true scope and spirit of the present disclosure are pointed out by the claims.
[0212] It should be understood that the present disclosure is not limited to the exact structures described above and shown in the drawings, and various modifications and changes can be made without departing from its scope. The scope of the present disclosure is limited only by the appended claims.
Claims
1. A network data processing method, characterized in that, the method includes: responding to a stress test configuration operation triggered for a target service, generating a test task corresponding to the target service; the test task contains test information corresponding to each sub-service in the target service; according to each piece of the test information, obtaining a target data set and a candidate instance set corresponding to the sub-service; the candidate instance set is created by a cluster system and is used to provide resources for executing the sub-service; the candidate instance set contains at least one instance, and each instance is a virtual computing server on the cloud for executing the sub-service; performing a stress test on the target instances in the candidate instance set according to the target data set to obtain the single-instance service capacity of the target instances; screening out a preset number of target instances to form a target instance list, and in the target instance list, processing each target instance in a loop to complete the stress test process for each of the target instances; determining the service capacity of the cluster system for the sub-service based on the single-instance service capacity and the total number of instances in the candidate instance set.
2. The network data processing method according to claim 1, characterized in that, the obtaining of the target data set corresponding to the sub-service includes: obtaining the target data corresponding to the sub-service; invoking a preset data processing interface to process the target data corresponding to the sub-service to obtain a target data set corresponding to the sub-service, and the target data set contains a plurality of the target data.
3. The network data processing method according to claim 1, characterized in that, the performing a stress test on the target instances in the candidate instance set according to the target data set to obtain the single-instance service capacity of the target instances includes: determining a preset number of target instances in the candidate instance set according to a preset instance screening strategy; performing a stress test on each target instance based on the target data set corresponding to the sub-service and a preset stress test step size to obtain the single-instance service capacity of each target instance for the sub-service; the stress test step size represents the change amount of the data transmission amount of sending the target data to the target instance each time.
4. The network data processing method according to claim 3, characterized in that, the performing a stress test on each target instance based on the target data set corresponding to the sub-service and a preset stress test step size to obtain the single-instance service capacity of each target instance for the sub-service includes: sending the target data in the target data set to the target instance according to a preset data transmission amount; during the process of the target instance processing the target data, if the target instance does not have a service fuse, updating the data transmission amount according to the current preset stress test step size, and executing the step of sending the target data in the target data set to the target instance based on the updated data transmission amount; If service fusing occurs for the target instance, then according to a preset stress testing step size, a service fusing callback policy, and the current data transmission volume, determine a target service fusing result corresponding to the target instance when the preset service fusing condition is satisfied; and use the target service fusing result as the single-instance service capacity of the target instance for the sub-service.
5. The network data processing method according to claim 1, wherein, the determining the service capacity of the cluster system for the sub-service based on the single-instance service capacity and the total number of instances in the candidate instance set includes: Sort the single-instance service capacities corresponding to each target instance in ascending order to obtain a single-instance service capacity sequence; In the single-instance service capacity sequence, determine a target single-instance service capacity that satisfies a preset quantile condition; Based on the target single-instance service capacity and the total number of instances in the candidate instance set, determine the service capacity of the cluster system for the sub-service.
6. The network data processing method according to claim 1, wherein, the method further includes: Obtain the total number of instances in the candidate instance set corresponding to the sub-service, the required service capacity of the sub-service, and the peak value of the single-instance service capacity of the target instance during the stress testing process; According to the required service capacity of the sub-service by the cluster system and a preset redundancy parameter value, determine the planned service capacity of the cluster system for the sub-service; According to the total number of instances in the candidate instance set, the peak value of the single-instance service capacity, and the planned service capacity, determine the resource configuration result of the cluster system for the sub-service; Based on the resource configuration result, perform resource configuration management on the total number of instances in the candidate instance set in the cluster system.
7. The network data processing method according to claim 6, wherein, the determining the resource configuration result of the cluster system for the sub-service according to the total number of instances in the candidate instance set, the peak value of the single-instance service capacity, and the planned service capacity includes: According to the ratio of the planned service capacity to the peak value of the single-instance service capacity, determine the required number of target instances; According to the difference between the total number of instances in the candidate instance set and the required number of target instances, determine the resource configuration result of the cluster system for the sub-service.
8. The network data processing method according to claim 6 or 7, wherein, after determining the resource configuration result of the cluster system for the sub-service, the method further includes: If the resource configuration result of the cluster system for the sub-service indicates insufficient resource configuration, generate and output a prompt message for insufficient resource configuration.
9. A network data processing device, wherein, the device includes: A generation unit, configured to execute a stress testing configuration operation triggered for a target service, and generate a test task corresponding to the target service; the test task includes test information corresponding to each sub-service in the target service; A first acquisition unit, configured to acquire a target data set and a candidate instance set corresponding to the sub-service according to each piece of the test information; the candidate instance set is created by a cluster system and is used to provide resources for executing the sub-service; the candidate instance set contains at least one instance, and each instance is a cloud virtual computing server for executing the sub-service. A test unit, configured to perform a stress test on a target instance in the candidate instance set according to the target data set to obtain the single-instance service capacity of the target instance; screen out a preset number of target instances to form a target instance list, and in the target instance list, loop through each target instance to complete the stress test process for each target instance. A first determination unit, configured to determine the service capacity of the cluster system for the sub-service based on the single-instance service capacity and the total number of instances in the candidate instance set.
10. An electronic device Characterized in that it includes: A processor; A memory for storing executable instructions of the processor; wherein, the processor is configured to execute the instructions to implement the network data processing method according to any one of claims 1 to 8.
11. A computer-readable storage medium Characterized in that when the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the network data processing method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Gateway access method, device and gateway equipment
CN113055199A
Pressure testing method and device and computer program product
CN114978944A