Flow data testing method and device, electronic equipment and readable storage medium
By converting the traffic indication information into a digital string, the problem of low efficiency of advertising traffic data analysis in the existing technology is solved, more efficient data acquisition and storage is achieved, and the analysis efficiency is improved.
Patent Information
- Application Number
- CN202410843680.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-27
- Publication Date
- 2024-10-01
AI Technical Summary
The analysis efficiency of advertising traffic data in the existing technology is low, mainly due to the use of complex string structures for storage and retrieval, resulting in low data acquisition efficiency.
By converting the traffic indication information into a digital string, and using the digital string to obtain and store the traffic data in the target database, the efficiency problems caused by string retrieval are avoided.
It improves the analysis efficiency of traffic data, reduces storage costs, and greatly improves data retrieval performance through the use of digital strings.
Smart Images

Figure CN118733461A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data processing technology, and in particular to a flow data testing method, device, electronic device and readable storage medium. Background Art
[0002] With the development of the Internet, more and more advertisements are also developing rapidly on the Internet. At present, the analysis method for advertising traffic data is generally through AB testing, and the effects of various advertisements are compared through AB testing. However, in the prior art, the test data is generally stored in real-time landing logs, or through the method of post-offline association of group information. The storage structure uses a Map-type data structure to map the test and control group information. This form generally uses a string retrieval mode to find the group information corresponding to the test, that is, each data corresponds to a separate string. The string refers to a Map-type data structure that includes a mixed form of numbers, letters, etc. This string structure is relatively complex, and additional computing power and algorithms are required to test it during retrieval, so the query data efficiency is low, which leads to the problem of low efficiency in analyzing traffic data. Summary of the invention
[0003] The purpose of the embodiments of the present application is to provide a flow data testing method, device, electronic device and readable storage medium to solve the problem of low flow data analysis efficiency in the prior art.
[0004] In a first aspect of the implementation of the present application, a method for testing flow data is first provided, the method comprising:
[0005] Acquiring test information, wherein the test information includes a plurality of flow indication information;
[0006] Determine a plurality of first digital strings according to the plurality of flow indication information, the plurality of first digital strings corresponding to the plurality of flow indication information one by one, the first digital strings being used to indicate storage information of flow data corresponding to each of the flow indication information;
[0007] Acquire a plurality of flow data in a target database according to the plurality of first digital strings, the plurality of flow data corresponding one-to-one to the plurality of first digital strings;
[0008] The multiple flow data are tested to obtain a test result, where the test result is used to indicate distinguishing information of the multiple flow data.
[0009] Optionally, determining a plurality of first digital strings according to the plurality of flow indication information includes:
[0010] For each flow indication information, determining a second digital string and a first character according to the flow indication information, wherein the second digital string is used to indicate a data number of flow data corresponding to the flow indication information, and the first character is used to indicate group information of the flow data corresponding to the flow indication information;
[0011] The first numeric string is generated according to the second numeric string and the first character.
[0012] Optionally, generating the first digital string according to the second digital string and the first character includes:
[0013] multiplying the second digital string by the first coefficient to obtain a third digital string;
[0014] Convert the first character according to a preset encoding rule to obtain a fourth digital string, wherein the first character is an English character;
[0015] The third digital string and the fourth digital string are numerically added according to the preset concatenation rule to generate the first digital string.
[0016] Optionally, acquiring a plurality of flow data in a target database according to the plurality of first digital strings comprises:
[0017] Decomposing the plurality of first digital strings to obtain a plurality of third digital strings and a plurality of fourth digital strings, wherein the plurality of third digital strings and the plurality of fourth digital strings correspond to each other one by one;
[0018] Determine a plurality of data numbers according to a plurality of the third digital strings, and determine a plurality of grouping information according to a plurality of the fourth digital strings;
[0019] The target database is queried based on the multiple data numbers and the multiple grouping information corresponding to the multiple data numbers to obtain the multiple flow data.
[0020] Optionally, the testing the multiple flow data to obtain a test result includes:
[0021] Determine a test type according to the test information;
[0022] Determining a target test model that matches the test type;
[0023] The plurality of flow data are input into the target test model, and the test result is output.
[0024] Optionally, determining a target test model according to the test type includes:
[0025] Determining a traffic division rule according to the test type;
[0026] Configuring the traffic division rule to determine a traffic division mode;
[0027] The target parameters of the preset test model are adjusted according to the traffic division rule and the traffic division mode to obtain the target test model, which is an AB test model.
[0028] Optionally, before acquiring a plurality of flow data in a target database according to the plurality of first digital strings, the method further comprises:
[0029] Acquire multiple target flow data to be stored;
[0030] Determine a plurality of data numbers and a plurality of grouping information corresponding to the plurality of target flow data, wherein the plurality of data numbers and the plurality of grouping information correspond to the target flow data one by one respectively;
[0031] Determine a plurality of fifth digital strings according to the plurality of data numbers, and determine a plurality of sixth digital strings according to the plurality of grouping information;
[0032] Adding the multiple fifth digital strings to the corresponding multiple sixth digital strings to obtain multiple seventh digital strings, wherein the multiple seventh digital strings correspond one-to-one to the multiple target flow data;
[0033] The plurality of seventh digital strings and the plurality of target flow data are stored in the target database.
[0034] In a second aspect of the present application, a flow data testing device is also provided, the device comprising:
[0035] A first acquisition module, used to acquire test information, wherein the test information includes a plurality of flow indication information;
[0036] A determination module, configured to determine a plurality of first digital strings according to the plurality of flow indication information, the plurality of first digital strings corresponding one-to-one to the plurality of flow indication information, the first digital strings being used to indicate storage information of flow data corresponding to each of the flow indication information;
[0037] A second acquisition module, configured to acquire a plurality of flow data in a target database according to the plurality of first digital strings, wherein the plurality of flow data corresponds one-to-one to the plurality of first digital strings;
[0038] The test module is used to test the multiple flow data to obtain a test result, wherein the test result is used to indicate the difference information of the multiple flow data.
[0039] In a third aspect of an embodiment of the present application, an electronic device is also provided, comprising a processor, a memory, and a program or instruction stored in the memory and executable on the processor, wherein when the program or instruction is executed by the processor, the steps of testing the flow data as described in any one of the first aspects are implemented.
[0040] In a fourth aspect of an embodiment of the present application, a test machine-readable storage medium is also provided, on which a program or instruction is stored. When the program or instruction is executed by a processor, the steps of testing the flow data as described in any one of the first aspects are implemented.
[0041] In a fifth aspect, an embodiment of the present application further provides a test machine program product, which is stored in a storage medium and is executed by at least one processor to implement the steps in the method described in the first aspect.
[0042] The embodiment of the present application provides a method, device, electronic device and readable storage medium for testing flow data, the method comprising: obtaining test information, the test information comprising a plurality of flow indication information; determining a plurality of first digital strings according to the plurality of flow indication information, the plurality of first digital strings corresponding one-to-one to the plurality of flow indication information, the first digital strings being used to indicate the storage information of the flow data corresponding to each of the flow indication information; obtaining a plurality of flow data in a target database according to the plurality of first digital strings, the plurality of flow data corresponding one-to-one to the plurality of first digital strings; testing the plurality of flow data to obtain a test result, the test result being used to indicate the distinguishing information of the plurality of flow data. The present application determines a plurality of flow indication information in the test information, determines a plurality of digital strings through the flow indication information, and obtains a plurality of stored flow data from the target database through the plurality of digital strings. Compared with the difficulty of retrieval caused by using a character string with a complex structure, the use of digital strings avoids the problem of low data acquisition efficiency caused by using character strings, thereby improving the analysis efficiency of flow data. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art are briefly introduced below.
[0044] Figure 1 A flow chart of a method for testing flow data in an embodiment of the present application;
[0045] Figure 2 This is one of the test schematic diagrams in the embodiment of the present application;
[0046] Figure 3 This is the second test schematic diagram in the embodiment of the present application;
[0047] Figure 4 This is the third test schematic diagram in the embodiment of this application;
[0048] Figure 5 This is the fourth test diagram in the embodiment of the present application;
[0049] Figure 6 This is a schematic diagram of the structure of a flow data testing device in an embodiment of the present application;
[0050] Figure 7 Schematic diagram of the structure of an electronic device in an embodiment of the present application. DETAILED DESCRIPTION
[0051] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0052] It should be mentioned before discussing the exemplary embodiments in more detail that some exemplary embodiments are described as processes or methods depicted as flow charts. Although the flow charts describe the steps as sequential processes, many of the steps therein can be implemented in parallel, concurrently or simultaneously. In addition, the order of the steps can be rearranged. The process can be terminated when its operation is completed, but can also have additional steps not included in the accompanying drawings. The process can correspond to a method, function, procedure, subroutine, subprogram, etc.
[0053] In addition, the terms "first", "second", etc. can be used in this article to describe various directions, actions, steps or elements, but these directions, actions, steps or elements are not limited by these terms. These terms are only used to distinguish a first direction, action, step or element from another direction, action, step or element. For example, without departing from the scope of the present application, the first speed difference can be referred to as the second speed difference, and similarly, the second speed difference can be referred to as the first speed difference. Both the first speed difference and the second speed difference are speed differences, but they are not the same speed difference. The terms "first", "second", etc. cannot be understood as indicating or implying relative importance or implicitly indicating the number of indicated technical features. Thus, the features defined as "first" and "second" can explicitly or implicitly include one or more of the features. In the description of the present application, the meaning of "multiple" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0054] The present application embodiment provides a method for testing flow data, such as Figure 1 As shown, the method includes:
[0055] Step 101: Acquire test information, where the test information includes a plurality of flow indication information.
[0056] In this embodiment, the test may be an AB test (A / B Test), which is a test format for comparing two different versions or variables, and can be used to understand user behavior and optimize the performance of products or services. AB testing is usually performed by testing specific variables (such as UI design, advertising text, product features, etc.) between two groups of users at the same time to compare their effects.
[0057] In this embodiment, multiple traffic data are analyzed through AB testing to determine the effects of different advertisements or videos. For example, the more traffic data there is, the more user attention the advertisement receives, and the lower the traffic data is, the less user attention the advertisement receives. This makes it possible to quickly determine the advertisements that are popular with users.
[0058] The traffic data is the traffic statistics corresponding to each user, such as the total traffic used by the user in a certain month, which is represented by a separate string of numbers and stored in the database. The traffic indication information is the indication information corresponding to the traffic data, such as indicating the grouping information, storage information, etc. of the traffic data.
[0059] By acquiring the test information that needs to be tested, multiple flow indication information is obtained in the test information. It should be noted that each flow indication information is associated with the flow data, so that the corresponding flow data can be obtained in the database storing the flow data through the flow indication information.
[0060] Step 102: determine a plurality of first digital strings according to the plurality of flow indication information, wherein the plurality of first digital strings correspond one-to-one to the plurality of flow indication information, and the first digital strings are used to indicate storage information of flow data corresponding to each of the flow indication information.
[0061] In this embodiment, the storage information of each flow data is determined through a plurality of flow indication information, and the storage information is the storage information of the flow data in the target database.
[0062] It should be noted that in the current prior art, traffic data is generally stored in the target database in the form of a string, where a string refers to a Map-type data structure that includes mixed forms of numbers, letters, etc., such as the form of "ABC1545231". This string form is relatively complex. Under this complex structure, since additional computing power and algorithms are required to test it during retrieval, it is generally impossible to use modern database indexes for optimization or there are fewer cases where optimization is required, and the efficiency of the query is also relatively low. In addition, the main reason for the slow retrieval of test reports is that the storage of complex structures of massive tests requires a large amount of test resources, which brings about performance loss. It is impossible to use the field indexes and parallel retrieval capabilities provided by modern OLAP databases, such as ClickHouse, Apache Doris, etc., so the key to improving test data query performance lies in the change of information structure.
[0063] Therefore, in this embodiment, the character string is replaced by a first digital string, wherein the digital string only includes numbers, such as the form of "10002268". Each first digital string corresponds to a different flow indication information, and each first digital string corresponds to storage information of a flow data, and the storage information may be a storage address. The flow data can be obtained from the database storing the flow data through the first digital string.
[0064] Step 103: Acquire a plurality of flow data in a target database according to the plurality of first digital strings, wherein the plurality of flow data correspond one-to-one to the plurality of first digital strings.
[0065] In this embodiment, the target database is used to store traffic data, and the storage location of each traffic data is indicated according to the first digital string. Each first digital string corresponds to a separate traffic data, for example, 100 first digital strings correspond to 100 traffic data. After all the first digital strings are determined in the above steps, all the first digital strings are obtained one by one in the target database to determine a plurality of traffic data.
[0066] Step 104: Test the plurality of flow data to obtain a test result, where the test result is used to indicate distinguishing information of the plurality of flow data.
[0067] In this embodiment, if Figure 2 As shown, multiple traffic data can be tested. Specifically, multiple traffic data can be input into the AB test system. First, the business personnel need to register the A / B test information in the test system and confirm the traffic division rules, that is, the grouping effectiveness mode. Generally, traffic is divided according to user ID. Then start to configure the grouping rules and the desired traffic division mode, such as Figure 3As shown, the test is divided into 4 groups in total. The rule names AB are test groups, and the rule names CD are control groups, that is, the AABB test mode of two test groups and two control groups. Specifically, AB is the experimental group, and the experimental data is kept the same. CD is the control group, and the experimental data is different from that of the AB group. For example, the AB experiment is used to find out the traffic data corresponding to different advertisements: the AB group is sports advertisements, and the CD group is product advertisements. Analyze which advertisement can attract more user attention, thereby increasing the user's click-through rate. Finally, the test results are obtained, which indicate the difference between multiple traffic data, such as the traffic data corresponding to sports advertisements and product advertisements are different. For example, the traffic data corresponding to advertisements played in different time periods can also be analyzed.
[0068] The embodiment of the present application provides a method, device, electronic device and readable storage medium for testing flow data, the method comprising: obtaining test information, the test information comprising a plurality of flow indication information; determining a plurality of first digital strings according to the plurality of flow indication information, the plurality of first digital strings corresponding one-to-one to the plurality of flow indication information, the first digital strings being used to indicate the storage information of the flow data corresponding to each of the flow indication information; obtaining a plurality of flow data in a target database according to the plurality of first digital strings, the plurality of flow data corresponding one-to-one to the plurality of first digital strings; testing the plurality of flow data to obtain a test result, the test result being used to indicate the distinguishing information of the plurality of flow data. The present application determines a plurality of flow indication information in the test information, determines a plurality of digital strings through the flow indication information, and obtains a plurality of stored flow data from the target database through the plurality of digital strings. Compared with the difficulty of retrieval caused by using a character string with a complex structure, the use of digital strings avoids the problem of low data acquisition efficiency caused by using character strings, thereby improving the analysis efficiency of flow data.
[0069] In some feasible implementations, step 102, determining a plurality of first digital strings according to the plurality of flow indication information, includes:
[0070] For each flow indication information, a second digital string and a first character are determined according to the flow indication information, wherein the flow indication information generally includes the first digital string, and the first digital string can be obtained by unpacking and parsing the flow indication information. The second digital string is used to indicate the data number of the flow data corresponding to the flow indication information, and the first character is used to indicate the grouping information of the flow data corresponding to the flow indication information;
[0071] The first numeric string is generated according to the second numeric string and the first character.
[0072] In this embodiment, for each piece of traffic indication information, it is composed of a second digital string and a first character, wherein the second digital string is used to indicate the data number of the traffic data, such as a data ID or a user ID, and the first character is used to indicate the grouping information of the traffic data, such as group A-group Z. Specifically, the first digital string can be the following examples: AB test ID: int type, grouping information corresponding to the test: string type AZ. A traffic exposure log will be distributed to multiple tests. As the system functions increase, hundreds or even thousands of orthogonal tests will be performed online at the same time. That is, the AB test information corresponding to an advertising exposure is, {id1:A, id2:D,…, idn:X}.
[0073] In this embodiment, when the second digital string and the first character generate the first digital string, since the first character is generally represented by "AZ" to represent a group, the first character needs to be converted. For example, the first character can be converted into a corresponding number, for example, AZ can correspond to the numbers 1-26, thereby completing the conversion of the first character.
[0074] By using multiple first digital strings to obtain multiple traffic data stored in the target database, the problem of low data acquisition efficiency caused by using character strings is avoided, which can greatly reduce storage costs and improve test data retrieval efficiency. The performance is improved by more than 30% through actual testing on the test software clickhouse.
[0075] Optionally, generating the first digital string according to the second digital string and the first character includes:
[0076] multiplying the second digital string by the first coefficient to obtain a third digital string;
[0077] Convert the first character according to a preset encoding rule to obtain a fourth digital string, wherein the first character is an English character;
[0078] The third digital string and the fourth digital string are numerically added according to the preset concatenation rule to generate the first digital string.
[0079] In this embodiment, when generating the first digital string, the second digital string and the first character are processed differently. Specifically, the second digital string is multiplied by the first coefficient to be amplified to obtain the third digital string. Since the grouping information is generally less than 100 groups, the first coefficient can be determined to be 100. The preset encoding rule can be the American Standard Code for Information Interchange (ASCII) code. The ASCII code is a coding system for representing English characters. It assigns a digital code from 0 to 127 to each letter, number and symbol. For example, the ASCII code of the uppercase letter "A" is 65, and the ASCII code of the lowercase letter "a" is 97. Since the grouping is generally AZ, and the ASCII code corresponding to AZ is exactly 65-90, the first digital string can be represented as RID=idn*100+ASCII (grouping character), and RID is uniformly int type, where the units digit + tens digit represents the test group 1, and the hundreds digit and above represent the test id information, that is, RID / 100=original test id, RID%100=test group. It can be seen that there is no need for a mapping table, and the original test information can be restored directly from the RID, and the original AB test system does not need to be modified. Logs are stored as array[int], storage space is reduced by 30%-50%, and query efficiency is increased by 2-5 times with the help of array indexes.
[0080] When testing in string form, the test results are as follows Figure 4 As shown in the figure, the current test information recording mode is in json format, which includes the test ID and the test group information corresponding to the current traffic. This traffic snapshot is used to display and analyze the subsequent AB test data report. This mode is recorded in string format, which takes up a lot of storage space. In addition, during the data analysis stage, the query engine has weak indexing capabilities for strings, and the query takes up a lot of CPU time for data parsing, which cannot provide efficient (second-level) data analysis services.
[0081] After the first numeric string represented by RID, for example, {"100022":"D"} is represented as RID=100022*100+68=10002268. Other test information is similar. After the overall conversion is completed, array storage is used. When searching in the database by numbers, since no characters are involved, the test resources and algorithms used do not need to consider the problem of characters. Therefore, compared with searching by character strings, fewer test resources and algorithms can be used, thereby improving the query efficiency of the database. Figure 5 As shown in the figure, the test result after the first digital string is represented by RID is shown. It can be seen that compared with Figure 4 , Figure 5All data in the data are represented in digital form, and the algorithm is simple, which can directly restore and identify the original information. Using int type array storage can greatly improve query efficiency, and data analysis reports can be produced in seconds. At the same time, the AB test system does not make any changes, only adding the RID conversion algorithm in the log recording module, and the data report module restores the test group information, and the modification is less invasive.
[0082] Optionally, step 103, obtaining a plurality of flow data in a target database according to the plurality of first digital strings, includes:
[0083] Decomposing the plurality of first digital strings to obtain a plurality of third digital strings and a plurality of fourth digital strings, wherein the plurality of third digital strings and the plurality of fourth digital strings correspond to each other one by one;
[0084] Determine a plurality of data numbers according to a plurality of the third digital strings, and determine a plurality of grouping information according to a plurality of the fourth digital strings;
[0085] The target database is queried based on the multiple data numbers and the multiple grouping information corresponding to the multiple data numbers to obtain the multiple flow data.
[0086] In this embodiment, after determining multiple first digital strings, it is necessary to query and obtain multiple traffic data in the target database through the multiple first digital strings. Specifically, when a digital string is input into the target database, it is necessary to decompose the first digital string to obtain the third digital string and the fourth digital string.
[0087] It should be noted that there is a one-to-one correspondence between the multiple third digital strings and the multiple fourth digital strings. When a first digital string is decomposed, a third digital string and a fourth digital string will be obtained. Specifically, the third digital string is idn*100 in RID=idn*100+ASCII, and the fourth digital string is ASCII. In this embodiment, the decomposition method is opposite to the method of generating the first digital string through the second digital string and the first character. Generally, the ASCII in the first digital string idn*100+ASCII is determined as the fourth digital string, and then the remaining third digital strings are determined.
[0088] Multiple data numbers are determined by multiple third digital strings, and multiple grouping information is determined according to multiple fourth digital strings. Multiple traffic data are queried in the target database through the data numbers and the grouping information. Specifically, different traffic data correspond to different data numbers and grouping information, so that separate traffic data can be queried through each data number and grouping information.
[0089] Optionally, step 104, testing the plurality of flow data to obtain a test result, includes:
[0090] Determining a test type according to the test information;
[0091] Determining a target test model that matches the test type;
[0092] The plurality of flow data are input into the target test model, and the test result is output.
[0093] In this embodiment, the test type refers to a test type that processes multiple traffic data. In this embodiment, the test types are all AB tests, so that the effects of different advertisements can be compared through AB tests, so that the advertising data can be analyzed intuitively, and it can also effectively avoid making wrong judgments on the data, which will lead to reduced exposure and even reduced conversions.
[0094] Optionally, the target test model is an AB test model. The AB test model needs to set parameters such as the number of tests, test parameters, and test time. Generally, the execution of the AB test model includes the following steps: Hypothesis setting: Determine the changes to be tested and establish a hypothesis, for example, "adding product recommendations will increase the average order value." Grouping: Randomly assign users to two different groups to ensure that each group is representative enough of the whole, which can reduce the influence of selection bias and other external factors. Implement changes: One group of users (control group) receives the original experience (version A), while the other group of users (test group) receives the changed experience (version B). Collect data: Measure and record the performance indicators of the two groups, such as click-through rate, conversion rate, etc. Analyze results: Use statistical methods to analyze the collected data to determine whether there are significant differences between the two versions, and whether these differences are due to random fluctuations or actual effect changes. Make decisions: Based on the test results, if it is found that version B is significantly better than version A, it can be considered to be promoted to the entire user group, otherwise it can be maintained or new changes can be explored.
[0095] By inputting a plurality of traffic data into a target test model, a test result is outputted, and the test result is used to indicate the difference information between the plurality of traffic data, so as to facilitate better pushing of advertisements with high traffic data to users.
[0096] Optionally, determining a target test model according to the test type includes:
[0097] Determining a traffic division rule according to the test type;
[0098] Configuring the traffic division rule to determine a traffic division mode;
[0099] The target parameters of a preset test model are adjusted according to the traffic division rule and the traffic division mode to obtain the target test model.
[0100] In this embodiment, the traffic division rule determines the grouping of different traffic flows, specifically, for example, including 26 groups corresponding to ASCII codes 65-90, so it is necessary to divide the acquired multiple traffic flows according to the traffic division rule, and generally, the traffic flows can be divided according to user IDs. Specifically, the division rules of different traffic flows can also be different, which is not specifically limited in this embodiment.
[0101] A traffic division pattern is determined according to the traffic division rules, wherein the traffic division pattern determines the grouping of the test, for example, how many test groups are set and how many control groups are set. Generally, two test groups and two control groups are set, which is the common AABB test pattern. There are other test patterns, which are not specifically limited in this embodiment.
[0102] The target parameters of the preset test model can be adjusted by determining the traffic division rules and traffic division patterns, thereby obtaining an adjusted target test mode, wherein the preset test mode is the AB test mode, but the relevant parameters therein have not yet been set. Therefore, it is necessary to make corresponding adjustments to the parameters included therein through the traffic division rules and traffic division patterns, thereby determining the required target test model.
[0103] Optionally, before step 103, obtaining a plurality of flow data in a target database according to the plurality of first digital strings to obtain a plurality of target flow data to be stored, the method further comprises:
[0104] Determine a plurality of data numbers and a plurality of grouping information corresponding to the plurality of target flow data, wherein the plurality of data numbers and the plurality of grouping information correspond to the target flow data one by one respectively;
[0105] Determine a plurality of fifth digital strings according to the plurality of data numbers, and determine a plurality of sixth digital strings according to the plurality of grouping information;
[0106] Adding the multiple fifth digital strings to the corresponding multiple sixth digital strings to obtain multiple seventh digital strings, wherein the multiple seventh digital strings correspond one-to-one to the multiple target flow data;
[0107] The plurality of seventh digital strings and the plurality of target flow data are stored in the target database.
[0108] In this embodiment, when storing multiple target quantity data in the target database, it is necessary to determine the grouping information and data number corresponding to each target flow data according to the multiple target flow data, thereby correspondingly determining the multiple grouping information as multiple fifth digital strings and determining multiple sixth digital strings according to the multiple grouping information, combining the fifth digital string with the corresponding sixth digital string, and finally obtaining multiple seventh digital strings corresponding to the multiple target flow data one by one, thereby realizing storing the multiple seventh digital strings and the multiple target flow data in the target database. It should be noted that the method of determining the multiple fifth digital strings through multiple grouping information and determining the multiple sixth digital strings according to the multiple grouping information can refer to the conversion method of the first digital string in the above embodiment.
[0109] When storing the target flow data in the target database, the fifth digital string and the target flow data can be stored in the target database. When searching, the target flow data can be retrieved in the target database by using the digital string used for searching, wherein the digital string used for searching consists of two digital strings, one corresponding to the grouping information and the other corresponding to the data number. The fifth digital string and the storage address of the target flow data can also be stored in the target database, and the storage address of the target flow data can be retrieved in the target database by using the digital string used for searching, so as to further obtain the target flow data.
[0110] By storing the traffic data in the form of data strings in the target database, a large number of algorithms and test resources consumed by string retrieval can be avoided, thereby improving retrieval efficiency and data acquisition efficiency.
[0111] The present application determines multiple flow indication information in the test information, and determines multiple digital strings through the flow indication information, and obtains multiple stored flow data from the target database through the multiple digital strings. Compared with the retrieval difficulty brought by the use of character strings with complex structures, the use of digital strings avoids the problem of low data acquisition efficiency caused by the use of character strings, thereby improving the analysis efficiency of flow data.
[0112] The present application also provides a flow data testing device, such as Figure 6 As shown, the flow data testing device 600 includes:
[0113] A first acquisition module 610 is used to acquire test information, where the test information includes a plurality of flow indication information;
[0114] A determination module 620, configured to determine a plurality of first digital strings according to the plurality of flow indication information, the plurality of first digital strings corresponding one-to-one to the plurality of flow indication information, the first digital strings being used to indicate storage information of flow data corresponding to each of the flow indication information;
[0115] A second acquisition module 630 is used to acquire a plurality of flow data in a target database according to the plurality of first digital strings, wherein the plurality of flow data corresponds to the plurality of first digital strings one by one;
[0116] The testing module 640 is used to test the multiple flow data to obtain a test result, where the test result is used to indicate the difference information of the multiple flow data.
[0117] Optionally, the determination module 620 includes:
[0118] A first determination submodule is used to determine, for each flow indication information, a second digital string and a first character according to the flow indication information, wherein the second digital string is used to indicate a data number of flow data corresponding to the flow indication information, and the first character is used to indicate group information of the flow data corresponding to the flow indication information;
[0119] A generating submodule is used to generate the first digital string according to the second digital string and the first character.
[0120] Optionally, generate submodules including:
[0121] A testing unit, configured to multiply the second digital string by a first coefficient to obtain a third digital string;
[0122] a conversion unit, configured to convert the first character according to a preset encoding rule to obtain a fourth digital string, wherein the first character is an English character;
[0123] A concatenation unit is used to add the third digital string and the fourth digital string numerically according to the preset concatenation rule to generate the first digital string.
[0124] Optionally, the second acquisition module 630 includes:
[0125] A decomposition submodule, used for decomposing the plurality of first digital strings to obtain a plurality of third digital strings and a plurality of fourth digital strings, wherein the plurality of third digital strings and the plurality of fourth digital strings correspond to each other one by one;
[0126] A second determining submodule, configured to determine a plurality of data numbers according to a plurality of the third digital strings, and to determine a plurality of grouping information according to a plurality of the fourth digital strings;
[0127] The query submodule is used to query the target database based on the multiple data numbers and the multiple grouping information corresponding to the multiple data numbers to obtain the multiple flow data.
[0128] Optionally, the testing module 640 includes:
[0129] A third determination submodule, configured to determine a test type according to the test information;
[0130] A fourth determination submodule, used to determine a target test model matching the test type;
[0131] An input module is used to input the multiple flow data into the target test model and output the test result.
[0132] Optionally, the fourth determining submodule includes:
[0133] A determination unit, configured to determine a traffic division rule according to the test type;
[0134] A configuration unit, configured to configure the traffic division rule and determine a traffic division mode;
[0135] An adjustment unit is used to adjust the target parameters of a preset test model according to the traffic division rule and the traffic division mode to obtain the target test model, where the target test model is an AB test model.
[0136] Optionally, also include:
[0137] A data acquisition module, used to acquire multiple target flow data to be stored;
[0138] An information determination module, used to determine a plurality of data numbers and a plurality of grouping information corresponding to the plurality of target flow data, wherein the plurality of data numbers and the plurality of grouping information correspond to the target flow data one by one;
[0139] a data determination module, configured to determine a plurality of fifth digital strings according to the plurality of data numbers, and to determine a plurality of sixth digital strings according to the plurality of grouping information;
[0140] A data synthesis module, used for adding the values of the plurality of fifth digital strings and the corresponding plurality of sixth digital strings to obtain a plurality of seventh digital strings, wherein the plurality of seventh digital strings correspond one-to-one to the plurality of target flow data;
[0141] A data storage module is used to store the multiple seventh digital strings and the multiple target flow data in the target database.
[0142] The present application determines multiple flow indication information in the test information, and determines multiple digital strings through the flow indication information, and obtains multiple stored flow data from the target database through the multiple digital strings. Compared with the retrieval difficulty brought by the use of character strings with complex structures, the use of digital strings avoids the problem of low data acquisition efficiency caused by the use of character strings, thereby improving the analysis efficiency of flow data.
[0143] Figure 7 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application is shown in FIG. Figure 7 As shown, the electronic device 700 includes a memory 710 and a processor 720. The number of the processor 720 in the electronic device 700 may be one or more. Figure 7 A processor 720 is taken as an example; the memory 710 and the processor 720 in the server can be connected via a bus or other means. Figure 7 The example of connecting through bus is taken in the following.
[0144] The memory 710, as a test machine-readable storage medium, can be used to store software programs, test machine executable programs and modules, such as program instructions / modules corresponding to the traffic data testing method in the embodiment of the present application. The processor 720 executes various functional applications and data processing of the server / terminal / server by running the software programs, instructions and modules stored in the memory 710, thereby realizing the above-mentioned traffic data testing method.
[0145] The processor 720 is used to run the test machine program stored in the memory 710 to implement the following steps:
[0146] Acquiring test information, wherein the test information includes a plurality of flow indication information;
[0147] Determine a plurality of first digital strings according to the plurality of flow indication information, the plurality of first digital strings corresponding to the plurality of flow indication information one by one, the first digital strings being used to indicate storage information of flow data corresponding to each of the flow indication information;
[0148] Acquire a plurality of flow data in a target database according to the plurality of first digital strings, the plurality of flow data corresponding one-to-one to the plurality of first digital strings;
[0149] The multiple flow data are tested to obtain a test result, where the test result is used to indicate distinguishing information of the multiple flow data.
[0150] Optionally, determining a plurality of first digital strings according to the plurality of flow indication information includes:
[0151] For each flow indication information, determining a second digital string and a first character according to the flow indication information, wherein the second digital string is used to indicate a data number of flow data corresponding to the flow indication information, and the first character is used to indicate group information of the flow data corresponding to the flow indication information;
[0152] The first numeric string is generated according to the second numeric string and the first character.
[0153] Optionally, generating the first digital string according to the second digital string and the first character includes:
[0154] multiplying the second digital string by the first coefficient to obtain a third digital string;
[0155] Convert the first character according to a preset encoding rule to obtain a fourth digital string, wherein the first character is an English character;
[0156] The third digital string and the fourth digital string are numerically added according to the preset concatenation rule to generate the first digital string.
[0157] Optionally, acquiring a plurality of flow data in a target database according to the plurality of first digital strings comprises:
[0158] Decomposing the plurality of first digital strings to obtain a plurality of third digital strings and a plurality of fourth digital strings, wherein the plurality of third digital strings and the plurality of fourth digital strings correspond to each other one by one;
[0159] Determine a plurality of data numbers according to a plurality of the third digital strings, and determine a plurality of grouping information according to a plurality of the fourth digital strings;
[0160] The target database is queried based on the multiple data numbers and the multiple grouping information corresponding to the multiple data numbers to obtain the multiple flow data.
[0161] Optionally, the testing the multiple flow data to obtain a test result includes:
[0162] Determine a test type according to the test information;
[0163] Determining a target test model that matches the test type;
[0164] The plurality of flow data are input into the target test model, and the test result is output.
[0165] Optionally, determining a target test model according to the test type includes:
[0166] Determining a traffic division rule according to the test type;
[0167] Configuring the traffic division rule to determine a traffic division mode;
[0168] The target parameters of the preset test model are adjusted according to the traffic division rule and the traffic division mode to obtain the target test model, which is an AB test model.
[0169] Optionally, before acquiring a plurality of flow data in a target database according to the plurality of first digital strings, the method further comprises:
[0170] Acquire multiple target flow data to be stored;
[0171] Determine a plurality of data numbers and a plurality of grouping information corresponding to the plurality of target flow data, wherein the plurality of data numbers and the plurality of grouping information correspond to the target flow data one by one respectively;
[0172] Determine a plurality of fifth digital strings according to the plurality of data numbers, and determine a plurality of sixth digital strings according to the plurality of grouping information;
[0173] Adding the multiple fifth digital strings to the corresponding multiple sixth digital strings to obtain multiple seventh digital strings, wherein the multiple seventh digital strings correspond one-to-one to the multiple target flow data;
[0174] The plurality of seventh digital strings and the plurality of target flow data are stored in the target database.
[0175] In one of the embodiments, an electronic device provided in the embodiment of the present application, its test machine program is not limited to the above method operations, and can also execute related operations in the flow data testing method provided in any embodiment of the present application.
[0176] The memory 710 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system and at least one application required for a function; the data storage area may store data created according to the use of the terminal, etc. In addition, the memory 710 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some instances, the memory 710 may further include a memory remotely arranged relative to the processor 720, and these remote memories may be connected to the server / terminal / server via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0177] The present application determines multiple flow indication information in the test information, and determines multiple digital strings through the flow indication information, and obtains multiple stored flow data from the target database through the multiple digital strings. Compared with the retrieval difficulty brought by the use of character strings with complex structures, the use of digital strings avoids the problem of low data acquisition efficiency caused by the use of character strings, thereby improving the analysis efficiency of flow data.
[0178] The test machine readable storage medium of the embodiment of the present application can adopt any combination of one or more test machine readable media. The test machine readable medium can be a test machine readable signal medium or a test machine readable storage medium. The test machine readable storage medium can be, for example, - but not limited to - an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of test machine readable storage media include: an electrical connection with one or more wires, a portable test machine disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this document, the test machine readable storage medium can be any tangible medium containing or storing a program, which can be used by an instruction execution system, a device or a device or used in combination with it.
[0179] The tester-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, which carries a program code readable by the tester. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The tester-readable signal medium may also be any tester-readable medium other than a tester-readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0180] The program code contained on the storage medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
[0181] The test machine program code for performing the operations of the present application can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages such as "C" language or similar programming languages. The program code can be executed entirely on the user test machine, partially on the user test machine, as a separate software package, partially on the user test machine and partially on a remote test machine, or entirely on a remote test machine or terminal. In the case of a remote test machine, the remote test machine can be connected to the user test machine through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external test machine (for example, using an Internet service provider to connect through the Internet).
[0182] The embodiment of the present application further provides a test machine program product, which is stored in a storage medium. The test machine program product is executed by at least one processor to implement the various processes of the above-mentioned virtual machine migration method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0183] Note that the above are only preferred embodiments of the present application and the technical principles used. Those skilled in the art will understand that the present application is not limited to the specific embodiments described herein, and that various obvious changes, readjustments and substitutions can be made by those skilled in the art without departing from the scope of protection of the present application. Therefore, although the present application is described in more detail through the above embodiments, the present application is not limited to the above embodiments, and may include more other equivalent embodiments without departing from the concept of the present application, and the scope of the present application is determined by the scope of the appended claims.
Claims
1. A method for testing flow data, characterized in that: The method comprises: Acquiring test information, wherein the test information includes a plurality of flow indication information; Determine a plurality of first digital strings according to the plurality of flow indication information, the plurality of first digital strings corresponding one-to-one to the plurality of flow indication information, the first digital strings being used to indicate storage information of flow data corresponding to each of the flow indication information; Acquire a plurality of flow data in a target database according to the plurality of first digital strings, wherein the plurality of flow data corresponds one-to-one to the plurality of first digital strings; The plurality of flow data are tested to obtain a test result, where the test result is used to indicate distinguishing information of the plurality of flow data.
2. The method according to claim 1, characterized in that The determining of a plurality of first digital strings according to the plurality of flow indication information comprises: For each flow indication information, determining a second numeric string and a first character according to the flow indication information, wherein the second numeric string is used to indicate a data number of flow data corresponding to the flow indication information, and the first character is used to indicate group information of the flow data corresponding to the flow indication information; The first numeric string is generated according to the second numeric string and the first character.
3. The method according to claim 2, characterized in that Generating the first digital string according to the second digital string and the first character includes: multiplying the second digital string by the first coefficient to obtain a third digital string; Convert the first character according to a preset encoding rule to obtain a fourth digital string, wherein the first character is an English character; The third digital string and the fourth digital string are numerically added according to the preset splicing rule to generate the first digital string.
4. The method according to claim 3, characterized in that The step of obtaining a plurality of flow data from a target database according to the plurality of first digital strings comprises: Decomposing the plurality of first digital strings to obtain a plurality of third digital strings and a plurality of fourth digital strings, wherein the plurality of third digital strings and the plurality of fourth digital strings correspond to each other one by one; determining a plurality of data numbers according to the plurality of third digital strings, and determining a plurality of grouping information according to the plurality of fourth digital strings; The plurality of flow data are obtained by querying the target database based on the plurality of data numbers and the plurality of grouping information corresponding to the plurality of data numbers.
5. The method according to claim 1, characterized in that The testing of the plurality of flow data to obtain a test result includes: determining a test type according to the test information; determining a target test model that matches the test type; The plurality of flow data are input into the target test model, and the test result is output.
6. The method according to claim 5, characterized in that The determining of the target test model according to the test type includes: Determining traffic division rules based on the test type; Configuring the traffic division rule to determine a traffic division mode; The target parameters of the preset test model are adjusted according to the traffic division rule and the traffic division mode to obtain the target test model, which is an AB test model.
7. The method according to claim 1, characterized in that Before acquiring a plurality of flow data in a target database according to the plurality of first digital strings, the method further comprises: Acquire multiple target flow data to be stored; Determine a plurality of data numbers and a plurality of grouping information corresponding to the plurality of target flow data, wherein the plurality of data numbers and the plurality of grouping information respectively correspond to the target flow data one-to-one; determining a plurality of fifth digital strings according to the plurality of data numbers, and determining a plurality of sixth digital strings according to the plurality of grouping information; Adding the plurality of fifth digital strings to the corresponding plurality of sixth digital strings to obtain a plurality of seventh digital strings, wherein the plurality of seventh digital strings correspond one-to-one to the plurality of target flow data; The plurality of seventh digital strings and the plurality of target flow data are stored in the target database.
8. A flow data testing device, characterized in that: The device comprises: A first acquisition module is used to acquire test information, wherein the test information includes a plurality of flow indication information; a determining module, configured to determine a plurality of first digital strings according to the plurality of flow indication information, the plurality of first digital strings corresponding one-to-one to the plurality of flow indication information, the first digital strings being used to indicate storage information of flow data corresponding to each of the flow indication information; A second acquisition module is configured to acquire a plurality of flow data in a target database according to the plurality of first digital strings, wherein the plurality of flow data corresponds one-to-one to the plurality of first digital strings; The test module is used to test the multiple flow data to obtain a test result, where the test result is used to indicate the distinguishing information of the multiple flow data.
9. An electronic device, characterized in that: The method comprises a processor, a memory and a program or instruction stored in the memory and executable on the processor, wherein the program or instruction, when executed by the processor, implements the steps of the flow data testing method according to any one of claims 1 to 7.
10. A test machine readable storage medium, characterized in that: The readable storage medium stores a program or instruction, and when the program or instruction is executed by a processor, the steps of the flow data testing method according to any one of claims 1 to 7 are implemented.
11. A test machine program product, characterized in that: The test machine program product is stored in a storage medium, and the test machine program product is executed by at least one processor to implement the steps in the flow data testing method according to any one of claims 1 to 7.
