Data aggregation method and device, storage medium and computer device

By receiving and splicing initial scripts to generate data aggregation scripts, automated data aggregation is performed on big data platforms, solving the problem of low data aggregation efficiency in e-commerce sales platforms and improving data analysis efficiency and user experience.

CN116204548BActive Publication Date: 2026-04-10GUANGZHOU PINWEI SOFTWARE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
GUANGZHOU PINWEI SOFTWARE CO LTD
Filing Date
2022-12-29
Publication Date
2026-04-10

AI Technical Summary

Technical Problem

In existing technologies, e-commerce sales platforms lack data aggregation solutions for their big data platforms, making it difficult for business personnel to automate data aggregation and reducing data analysis efficiency.

Method used

By receiving data aggregation requests from front-end devices, obtaining user configuration information for configuration items, concatenating initial scripts to generate data aggregation scripts, aggregating data on the big data platform, and returning aggregation result data to display aggregation charts.

Benefits of technology

It enables automatic data aggregation in big data scenarios without manual intervention, improving data analysis efficiency and allowing users to quickly understand the aggregation results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116204548B_ABST
    Figure CN116204548B_ABST
Patent Text Reader

Abstract

The application provides a data aggregation method and device, a storage medium and a computer device. The method comprises the following steps: receiving a data aggregation request sent by a front-end device, wherein the data aggregation request is generated by the front-end device according to user configuration information of each configuration item; obtaining the user configuration information of each configuration item according to the data aggregation request; for each configuration item, determining an initial script corresponding to the configuration item from each preset initial script according to the configuration attribute of the configuration item, and splicing the user configuration information of the configuration item and the initial script corresponding to the configuration item to obtain a data aggregation script; performing data aggregation on a big data platform for storing business data based on each data aggregation script to obtain aggregation result data; and returning the aggregation result data to the front-end device to enable the front-end device to display an aggregation chart according to the aggregation result data when a result acquisition request sent by the front-end device is received. The application can improve data analysis efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of big data processing, and particularly relates to a data aggregation method and device, a storage medium and a computer device. BACKGROUND

[0002] In an e-commerce sales platform, a large amount of data is generated in each sales link due to a large number of types of sales goods, a large number of suppliers and a large sales quantity. In order to enable a business department to master the data of each sales link, a business wide table is usually created to maintain the data generated in each sales link. In the past, the business wide table is generally realized by relying on an excel tool. When the business department needs to obtain corresponding business data, an excel formula can be used to perform data filtering, data pivoting and data aggregation on the data stored in the excel table to obtain the corresponding result. However, as the data quantity increases, the excel is prone to freezing or even unable to open when facing big data, which greatly affects the data processing efficiency.

[0003] To solve this problem, a corresponding big data platform can be constructed to store the business data. However, the prior art lacks a data aggregation scheme for the big data platform, which makes it difficult for business personnel to automatically aggregate the business data stored in the big data platform, and reduces the data analysis efficiency. SUMMARY

[0004] The present application aims to at least solve one of the above technical defects, in particular, the technical defect of low data analysis efficiency in the prior art.

[0005] In a first aspect, an embodiment of the present application provides a data aggregation method applied to a server, and the method comprises the following steps.

[0006] receiving a data aggregation request sent by a front-end device, wherein the data aggregation request is generated by the front-end device according to user configuration information of each configuration item;

[0007] obtaining the user configuration information of each configuration item according to the data aggregation request;

[0008] for each configuration item, determining an initial script corresponding to the configuration item in each preset initial script according to a configuration attribute of the configuration item, and splicing the user configuration information of the configuration item and the initial script corresponding to the configuration item to obtain a data aggregation script;

[0009] performing data aggregation on a big data platform based on each data aggregation script to obtain aggregated result data, wherein the big data platform is used to store business data;

[0010] When receiving the result acquisition request sent by the front-end device, the aggregation result data is returned to the front-end device, so that the front-end device displays an aggregation chart according to the aggregation result data.

[0011] In one of the embodiments, each of the configuration items includes a query field configuration item and an aggregation field configuration item, and the aggregation result data includes business aggregation data.

[0012] The step of performing data aggregation on the big data platform based on each of the data aggregation scripts to obtain aggregation chart data includes:

[0013] Based on the data aggregation script corresponding to the query field configuration item, data query is performed on the big data platform to obtain a query result.

[0014] Based on the data aggregation script corresponding to the aggregation field configuration item, data aggregation is performed on the query result to obtain the business aggregation data.

[0015] In one of the embodiments, each of the configuration items further includes a metric field configuration item, and the aggregation result data further includes metric result data.

[0016] The step of performing data aggregation on the big data platform based on each of the data aggregation scripts to obtain aggregation chart data further includes:

[0017] Based on the data aggregation script corresponding to the metric field configuration item, statistics are performed on the business aggregation data to obtain the metric result data.

[0018] In one of the embodiments, the step of returning the aggregation result data to the front-end device when receiving the result acquisition request sent by the front-end device includes:

[0019] When receiving the result acquisition request, a communication key is determined according to the result acquisition request.

[0020] The communication key is verified, and the aggregation result data is returned to the front-end device if the verification is passed.

[0021] In a second aspect, the embodiments of the present application provide a data aggregation method applied to a front-end device, and the method includes:

[0022] A configuration interface is displayed, and the configuration interface includes a plurality of configuration items and a plurality of configuration boxes for obtaining user configuration information.

[0023] obtaining user configuration information of each configuration item from the configuration interface when a preset data aggregation rule is met, and generating a data aggregation request according to the user configuration information of each configuration item, sending the data aggregation request to a server, and generating a communication key; wherein the data aggregation request is used to instruct the server to determine, for each configuration item, an initial script corresponding to the configuration item according to a configuration attribute of the configuration item in each preset initial script, and splice the user configuration information of the configuration item and the initial script corresponding to the configuration item to obtain a data aggregation script; the data aggregation request is also used to instruct the server to perform data aggregation on a big data platform based on each data aggregation script to obtain aggregated result data, and the big data platform is used to store business data;

[0024] sending a result obtaining request to the server according to the communication key when a preset data obtaining rule is met, to receive aggregated result data returned by the server;

[0025] generating an aggregated chart according to the aggregated result data, and displaying the aggregated chart.

[0026] In one embodiment, the step of sending a result obtaining request to the server according to the communication key when a preset data obtaining rule is met, comprises:

[0027] sending the result obtaining request to the server according to the communication key at a preset request period.

[0028] In a third aspect, the present application provides a data aggregation device applied to a server, comprising:

[0029] an aggregation request receiving module configured to receive a data aggregation request sent by a front-end device, wherein the data aggregation request is generated by the front-end device according to user configuration information of each configuration item;

[0030] a configuration information obtaining module configured to obtain the user configuration information of each configuration item according to the data aggregation request;

[0031] an aggregation script obtaining module configured to determine, for each configuration item, an initial script corresponding to the configuration item according to a configuration attribute of the configuration item in each preset initial script, and splice the user configuration information of the configuration item and the initial script corresponding to the configuration item to obtain a data aggregation script;

[0032] a data aggregation module configured to perform data aggregation on a big data platform based on each data aggregation script to obtain aggregated result data, wherein the big data platform is used to store business data;

[0033] The data returning module is configured to return the aggregated result data to the front-end device when receiving a result obtaining request sent by the front-end device, so that the front-end device displays an aggregated chart according to the aggregated result data.

[0034] In a fourth aspect, the present application provides a data aggregation apparatus applied to a front-end device, the apparatus comprising:

[0035] The interface display module is configured to display a configuration interface, the configuration interface comprising a plurality of configuration items and a plurality of configuration boxes for obtaining user configuration information.

[0036] The aggregation request generation module is configured to obtain user configuration information of each configuration item from the configuration interface when a preset data aggregation rule is met, and generate a data aggregation request according to the user configuration information of each configuration item, send the data aggregation request to a server, and generate a communication key, wherein the data aggregation request is used to instruct the server to determine an initial script corresponding to each configuration item from a plurality of preset initial scripts according to a configuration attribute of the configuration item, and splice user configuration information of the configuration item with the initial script corresponding to the configuration item to obtain a data aggregation script; the data aggregation request is also used to instruct the server to perform data aggregation on a big data platform based on each data aggregation script to obtain aggregated result data, wherein the big data platform is used to store business data.

[0037] The result obtaining request generation module is configured to send a result obtaining request to the server according to the communication key when a preset data obtaining rule is met, so as to receive aggregated result data returned by the server.

[0038] The chart display module is configured to generate an aggregated chart according to the aggregated result data, and display the aggregated chart.

[0039] In a fifth aspect, the embodiments of the present application provide a storage medium, wherein the storage medium stores computer readable instructions, and the computer readable instructions are executed by one or more processors to make the one or more processors execute the steps of the data aggregation method according to any one of the above embodiments.

[0040] In a sixth aspect, the embodiments of the present application provide a computer device, comprising one or more processors and a memory.

[0041] The memory stores computer readable instructions, and the computer readable instructions are executed by the one or more processors to execute the steps of the data aggregation method according to any one of the above embodiments.

[0042] In the data aggregation method, device, storage medium and computer device, the server can receive the data aggregation request generated by the front-end device according to the user configuration information of each configuration item, and obtain the user configuration information of each configuration item from the data aggregation request. The server can determine the initial script corresponding to each configuration item in each preset initial script based on the configuration attribute of each configuration item, and splice the user configuration information of the configuration item and the initial script corresponding to the configuration item to obtain a data aggregation script that can be used for data aggregation of the business data stored in the big data platform. The server can perform data aggregation on the big data platform based on each data aggregation script to obtain aggregated result data, and return the aggregated result data to the front-end device, so that the front-end device can display the aggregation chart according to the received aggregated result data. In this way, the server can automatically perform data aggregation on the business data stored in the big data platform according to the data aggregation condition configured by the user on the front-end device, without the user performing too much manual operation (such as writing an excel formula), thereby improving the data analysis efficiency in the big data scenario. In addition, the server can also return the aggregated result data to the front-end device, so that the front-end device displays the corresponding aggregation chart, so that the user can quickly understand the data aggregation result, thereby further improving the data analysis efficiency. BRIEF DESCRIPTION OF DRAWINGS

[0043] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings needed to be used in the embodiments or prior art description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can also be obtained without creative labor.

[0044] Figure 1 An application environment diagram of the data aggregation method in an embodiment;

[0045] Figure 2 One of the flowcharts of the data aggregation method in an embodiment;

[0046] Figure 3 The second flowchart of the data aggregation method in an embodiment;

[0047] Figure 4 One of the structural diagrams of the data aggregation device in an embodiment;

[0048] Figure 5 The second structural diagram of the data aggregation device in an embodiment;

[0049] Figure 6 The structural diagram of the computer device in an embodiment. DETAILED DESCRIPTION

[0050] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work fall within the scope of the present application.

[0051] In one embodiment, the data aggregation method of the present application can be applied to Figure 1 The application environment is shown. As Figure 1 shown, the application environment can include a server 102 and a front-end device 104, and the server 102 can be in communication connection with the front-end device 104. The server 102 can be a single server or a server cluster composed of multiple servers, and can perform data aggregation on business data stored in a big data platform. The front-end device 104 refers to a device operated by a user, which can be a notebook computer or a desktop computer, etc. The user can configure data aggregation conditions on the front-end device 104, and generate a data aggregation request based on the configured data aggregation conditions. When the server 102 receives the data aggregation request, it can automatically perform data aggregation on the business data stored in the big data platform to obtain aggregated result data, and return the aggregated result data to the front-end device 104, so that the front-end device 104 can display an aggregated chart.

[0052] In one embodiment, the present application provides a data aggregation method, which can be applied to Figure 1 The server is shown. As Figure 2 shown, the data aggregation method of the present application can include the following steps:

[0053] S202: receiving a data aggregation request sent by a front-end device, the data aggregation request being generated by the front-end device according to user configuration information of each configuration item.

[0054] In this step, the user can configure information of each configuration item on the front-end device according to actual needs, so that the user configuration information of each configuration item can constitute a data aggregation condition. The front-end device can generate a data aggregation request according to the user configuration information of each configuration item, so that the data aggregation request can reflect the configuration information of each configuration item.

[0055] S204: obtaining user configuration information of each configuration item according to the data aggregation request.

[0056] In this step, after receiving the data aggregation request sent by the front-end device, the server can obtain the user configuration information of each configuration item from the data aggregation request, so that the server can determine the data aggregation condition set by the user according to the user configuration information of each configuration item.

[0057] S206: For each configuration item, according to the configuration attribute of the configuration item, determine the initial script corresponding to the configuration item in each preset initial script, and splice the user configuration information of the configuration item and the initial script corresponding to the configuration item to obtain a data aggregation script.

[0058] Specifically, each configuration item can correspond to a configuration attribute, for example, the configuration attribute can be a query configuration item, an aggregation configuration item, a sorting configuration item or an output configuration item. Different configuration attributes correspond to different initial scripts, for example, the query configuration item can correspond to an initial query script, the sorting configuration item can correspond to an initial sorting script, etc. Among them, the initial script can be a script without configuring specific execution conditions, for example, the initial query script can be a query script without configuring specific query conditions, and the initial sorting script can be a script without configuring specific sorting fields.

[0059] For each configuration item, the server can determine the initial script corresponding to the configuration item in at least one preset initial script according to the configuration attribute of the configuration item, and splice the user configuration information of the configuration item into the corresponding initial script to obtain a data aggregation script configured with specific execution conditions. In this way, the server can use the data aggregation script to perform data query, data filtering, data sorting and / or data perspective on the business data stored in the big data platform.

[0060] S208: Perform data aggregation on the big data platform based on each data aggregation script to obtain aggregated result data; wherein the big data platform is used to store business data.

[0061] In this step, after obtaining each data aggregation script configured with specific execution conditions, the server can use each data aggregation script to perform data aggregation on the business data stored in the big data platform and obtain aggregated result data. It can be understood that the specific data of the aggregated result data is determined according to the execution condition configured by the data aggregation script, which is not limited in the present application.

[0062] S210: When receiving the result acquisition request sent by the front-end device, return the aggregated result data to the front-end device to make the front-end device display an aggregation chart according to the aggregated result data.

[0063] In this step, when the front-end device needs to obtain the aggregation result, the front-end device can send a result obtaining request to the server. When the server receives the result obtaining request, the server returns the aggregation result data to the front-end device, so that the front-end device can display the aggregation chart according to the aggregation result data. Further, the aggregation result data in this embodiment can be the business data satisfying the condition, or the total data obtained by further processing the business data satisfying the condition. For example, if the user aggregation condition set by the user is to calculate the total number of returns of each brand of supplier A in October, the aggregation result data generated by the server can be the return details of each brand of supplier A in October, or the total amount of returns of each brand of supplier A in October.

[0064] In one of the embodiments, S210 can include the following steps:

[0065] Upon receiving the result obtaining request, determining the communication key according to the result obtaining request;

[0066] verifying the communication key, and returning the aggregation result data to the front-end device if the verification is passed.

[0067] Specifically, in the data interaction process between the server and the front-end device, the server and the front-end device need to be based on the pre-determined communication key. When the server receives the result obtaining request sent by the front-end device, the server needs to obtain the communication key used by the front-end device from the received result obtaining request, and verify the communication key used by the front-end device. Only if the verification is passed, the aggregation result data can be returned to the front-end device, so as to ensure the security of the data interaction process.

[0068] In the present application, the server can receive a data aggregation request generated by the front-end device according to the user configuration information of each configuration item, and obtain the user configuration information of each configuration item from the data aggregation request. The server can determine an initial script corresponding to each configuration item in each preset initial script based on the configuration attribute of each configuration item, and splice the user configuration information of the configuration item and the initial script corresponding to the configuration item to obtain a data aggregation script that can be used for data aggregation of business data stored in the big data platform. The server can perform data aggregation on the big data platform based on each data aggregation script to obtain aggregated result data, and return the aggregated result data to the front-end device, so that the front-end device can display an aggregated chart according to the received aggregated result data. In this way, the server can automatically perform data aggregation on the business data stored in the big data platform according to the data aggregation conditions configured by the user on the front-end device, without the user performing excessive manual operations (such as writing an excel formula), thereby improving the data analysis efficiency in the big data scenario. In addition, the server can also return the aggregated result data to the front-end device, so that the front-end device displays the corresponding aggregated chart, so that the user can quickly understand the data aggregation result, thereby further improving the data analysis efficiency.

[0069] In one embodiment, each configuration item can include a query field configuration item and an aggregation field configuration item, that is, the server can obtain the user configuration information corresponding to the query field configuration item and the user configuration information corresponding to the aggregation field configuration item from the data aggregation request.

[0070] The query field configuration item refers to a configuration item for configuring a field used when querying data, and further, the user can configure the query field configuration item by enumeration, multiple values, and a list. The aggregation field configuration item refers to a configuration item for configuring a field used when aggregating data, and further, the aggregation field configuration item can be used to configure a field used for data segmentation and data escape. The aggregated result data includes business aggregation data, wherein the business aggregation data refers to business data that meets the user configuration information of the query field configuration item and the user configuration information of the aggregation field configuration item.

[0071] The step of performing data aggregation on the big data platform based on each data aggregation script to obtain aggregated chart data includes:

[0072] Performing data query on the big data platform based on the data aggregation script corresponding to the query field configuration item to obtain a query result;

[0073] Performing data aggregation on the query result based on the data aggregation script corresponding to the aggregation field configuration item to obtain the business aggregation data.

[0074] Specifically, since the server uses different operation logics when performing data query and data aggregation, different initial scripts can be set for data query and data aggregation respectively. When the data aggregation request includes the user configuration information of the query field configuration item and the user configuration information of the aggregation field configuration item, the server can splice the user configuration information of the query field configuration item into the initial script corresponding to the query field configuration item to obtain a data aggregation script that can be used to perform data query. The server can also splice the user configuration information of the aggregation field configuration item into the initial script corresponding to the aggregation field configuration item to obtain a data aggregation script that can be used to perform data aggregation.

[0075] When obtaining each data aggregation script, the server can execute the data aggregation script corresponding to the query field configuration item to perform data query on the business data stored in the big data platform according to the user configuration information of the query field configuration item, so that the corresponding query result can be filtered out from the big data platform. The server can also execute the data aggregation script corresponding to the aggregation field configuration item to perform data aggregation on the filtered query result according to the user configuration information of the aggregation field configuration item to obtain the business aggregation data. In this way, the server can perform data aggregation according to a certain execution order to ensure the accuracy of the data aggregation result.

[0076] Further, each configuration item can also include a metric field configuration item, which can be a calculation project for performing data measurement. The aggregation result data can also include metric result data, which refers to the result obtained by performing data measurement on the business data according to the user configuration information of the metric field configuration item.

[0077] The step of performing data aggregation on the big data platform based on each data aggregation script to obtain aggregation chart data can also include: performing statistics on the business aggregation data based on the data aggregation script corresponding to the metric field configuration item to obtain the metric result data. Specifically, the server can measure the business data in the big data platform according to the user configuration to obtain the corresponding metric result data, and return the metric result data to the front-end device to facilitate the user to quickly understand the result that meets his / her demand.

[0078] In one embodiment, the present application provides a data aggregation method, which can be applied to Figure 1 As shown in the front-end device shown in the front-end device shown in Figure 3 The data aggregation method of the present application can include the following steps:

[0079] S302: display a configuration interface, the configuration interface including a plurality of configuration items and a plurality of configuration boxes for obtaining user configuration information.

[0080] In this step, the front-end device can display a configuration interface for the user to configure information of each configuration item according to actual data aggregation conditions, so that the server can implement dynamic query data according to the user configuration conditions of each configuration item.

[0081] S304: When the preset data aggregation rule is met, the user configuration information of each configuration item is obtained from the configuration interface, and a data aggregation request is generated according to the user configuration information of each configuration item, the data aggregation request is sent to the server, and a communication key is generated.

[0082] The data aggregation request is used to instruct the server to determine, for each configuration item, an initial script corresponding to the configuration item in each preset initial script according to the configuration attribute of the configuration item, and splice the user configuration information of the configuration item with the initial script corresponding to the configuration item to obtain a data aggregation script; the data aggregation request is also used to instruct the server to perform data aggregation on a big data platform based on each data aggregation script to obtain aggregated result data, and the big data platform is used to store business data.

[0083] It can be understood that the preset data aggregation rule can be determined according to actual conditions, for example, it can be that the user clicks a query button or an export button in the configuration interface. In the case where the data aggregation rule is met, the front-end device can obtain the user configuration information input by the user in the configuration interface, and generate a data aggregation request based on the user configuration information. The front-end device can send the data aggregation request to the server, so that the server executes the steps of any one of the data aggregation methods applied to the server. In addition, the front-end device can also generate a communication key after sending the data aggregation request, so as to obtain the aggregated result data from the server based on the communication key subsequently.

[0084] S306: When the preset data acquisition rule is met, a result acquisition request is sent to the server according to the communication key to receive the aggregated result data returned by the server.

[0085] The result acquisition request is used to instruct the server to return the aggregated result data to the front-end device. It can be understood that the preset data acquisition rule can be determined according to actual conditions, which is not limited in the present application. In one embodiment, the data acquisition rule can be to acquire according to a preset request period, that is, the front-end device can send the result acquisition request to the server according to the communication key according to the preset request period. In this way, the aggregated result data can be acquired in an asynchronous manner, avoiding the timeout problem of the front-end device, so that the user can perceive the aggregated result data in time.

[0086] S308: An aggregated chart is generated according to the aggregated result data, and the aggregated chart is displayed.

[0087] In this step, the front-end device can generate and display aggregated charts based on the aggregated data returned by the server, achieving a structured display. This facilitates a quick understanding of the data aggregation results, further improving data analysis efficiency.

[0088] In this application, the front-end device can display a configuration interface to obtain user configuration information for each configuration item. Based on this interface, it generates and sends a data aggregation request, enabling the server to dynamically query data according to the user configuration conditions for each item. When preset data acquisition rules are met, the front-end device can send a result acquisition request to the server using a communication key to receive the aggregation result data returned by the server and display the aggregation chart accordingly. This allows users to quickly understand the data aggregation results, further improving data analysis efficiency.

[0089] The data aggregation apparatus provided in the embodiments of this application is described below. The data aggregation apparatus described below and the data aggregation method described above can be referred to in correspondence.

[0090] In one embodiment, this application provides a data aggregation apparatus 400 for use with a server. For example... Figure 4 As shown, the data aggregation device 400 includes:

[0091] The aggregation request receiving module 410 is used to receive a data aggregation request sent by the front-end device, wherein the data aggregation request is generated by the front-end device based on the user configuration information of each configuration item;

[0092] Configuration information acquisition module 420 is used to acquire user configuration information for each configuration item according to the data aggregation request;

[0093] The aggregation script acquisition module 430 is used to determine the initial script corresponding to each configuration item from among the preset initial scripts based on the configuration attributes of the configuration item, and to concatenate the user configuration information of the configuration item with the initial script corresponding to the configuration item to obtain the data aggregation script.

[0094] The data aggregation module 440 is used to aggregate data from the big data platform based on the various data aggregation scripts to obtain aggregated result data; wherein, the big data platform is used to store business data;

[0095] The data return module 450 is used to return the aggregated result data to the front-end device when it receives a result retrieval request sent by the front-end device, so that the front-end device can display an aggregated chart based on the aggregated result data.

[0096] In one embodiment, each configuration item includes a query field configuration item and an aggregation field configuration item, and the aggregation result data includes business aggregation data. The data aggregation module 440 includes a query unit and an aggregation unit. The query unit is used to query the big data platform based on the data aggregation script corresponding to the query field configuration item to obtain query results. The aggregation unit is used to aggregate the query results based on the data aggregation script corresponding to the aggregation field configuration item to obtain the business aggregation data.

[0097] In one embodiment, each of the configuration items further includes a metric field configuration item, and the aggregated result data further includes metric result data. The data aggregation module 440 further includes a metric unit. This metric unit is used to perform statistics on the business aggregated data based on the data aggregation script corresponding to the metric field configuration item to obtain the metric result data.

[0098] In one embodiment, the data return module 450 includes a key acquisition unit and a data return unit. The key acquisition unit determines a communication key based on the result acquisition request upon receiving the request. The data return unit verifies the communication key and, if the verification is successful, returns the aggregated result data to the front-end device.

[0099] In one embodiment, this application provides a data aggregation apparatus 500 applied to a front-end device. For example... Figure 5 As shown, the data aggregation device 500 includes:

[0100] The interface display module 510 is used to display a configuration interface, which includes multiple configuration items and multiple configuration boxes for obtaining user configuration information.

[0101] The aggregation request generation module 520 is used to obtain user configuration information of each configuration item from the configuration interface when a preset data aggregation rule is met, generate a data aggregation request based on the user configuration information of each configuration item, send the data aggregation request to the server, and generate a communication key. The data aggregation request instructs the server, for each configuration item, to determine the corresponding initial script from a set of preset initial scripts based on the configuration attributes of that configuration item, and to concatenate the user configuration information of that configuration item with the corresponding initial script to obtain a data aggregation script. The data aggregation request also instructs the server to perform data aggregation on the big data platform based on each of the data aggregation scripts to obtain aggregated result data. The big data platform is used to store business data.

[0102] The result obtaining request generation module 530 is configured to send a result obtaining request to the server according to the communication key to receive the aggregated result data returned by the server when the preset data obtaining rule is met.

[0103] The chart display module 540 is configured to generate an aggregated chart according to the aggregated result data and display the aggregated chart.

[0104] In one embodiment, the result obtaining request generation module 530 comprises a periodic sending unit. The periodic sending unit is configured to send the result obtaining request to the server according to the communication key in a preset request period.

[0105] In one embodiment, the present application further provides a storage medium, wherein the storage medium stores computer readable instructions. When the computer readable instructions are executed by one or more processors, the one or more processors perform the steps of the data aggregation method in any of the above embodiments.

[0106] In one embodiment, the present application further provides a computer device. The computer device stores computer readable instructions. When the computer readable instructions are executed by one or more processors, the one or more processors perform the steps of the data aggregation method in any of the above embodiments.

[0107] Schematically, Figure 6 An internal structure schematic diagram of a computer device provided by the embodiments of the present application is shown in the figure. In one example, the computer device can be a server. In this case, the computer device can perform the steps of the data aggregation method for the server in any of the above embodiments. In another example, the computer device can be a front-end device. In this case, the computer device can perform the steps of the data aggregation method for the front-end device in any of the above embodiments.

[0108] Referring to Figure 6 The computer device 900 comprises a processing component 902, which further comprises one or more processors, and a memory resource represented by a memory 901, for storing instructions executable by the processing component 902, such as an application program. The application program stored in the memory 901 can comprise one or more than one module each corresponding to a set of instructions. In addition, the processing component 902 is configured to execute the instructions to perform the steps of the data aggregation method in any of the above embodiments.

[0109] The computer device 900 can further include a power supply component 903 configured to perform power management of the computer device 900, a wired or wireless network interface 904 configured to connect the computer device 900 to a network, and an input / output (I / O) interface 905. The computer device 900 can operate based on an operating system stored in the memory 901, such as Windows Server TM, Mac OS X TM, Unix TM, Linux TM, Free BSD TM, or the like.

[0110] Those skilled in the art can understand that the internal structure of the computer device shown in the present application is only a block diagram of part of the structure related to the scheme of the present application, and does not constitute a limitation on the computer device to which the scheme of the present application is applied. A specific computer device can include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0111] Finally, it should be noted that in this document, the terms such as first and second are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "contain" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such a process, method, article or device. Without more limitations, the element defined by the statement "including a" does not exclude the presence of another identical element in the process, method, article or device including the element. In this document, "a", "an", "said", "the" and "it" can also include plural forms, unless the context clearly indicates otherwise. A plurality means at least two, such as 2, 3, 5 or 8, etc. "And / or" includes any and all combinations of the related listed items.

[0112] The various embodiments in the specification are described in a progressive manner, each embodiment focusing on the differences from other embodiments, and the various embodiments can be combined as needed, and the same and similar parts refer to each other.

[0113] The foregoing description of the disclosed embodiments enables a person skilled in the art to make or use the application. Modifications of these embodiments will occur to persons of skill in the art, and that the generic principles defined herein can be applied to other embodiments without departing from the spirit or scope of the application. Therefore, the present application is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A data aggregation method, characterized in that, Applied to a server, the method includes: Receive a data aggregation request sent by a front-end device. The data aggregation request is generated by the front-end device based on the user configuration information of various configuration items, including query field configuration items and aggregation field configuration items. The user configuration information for each configuration item is obtained according to the data aggregation request. For each configuration item, based on the configuration attributes of that configuration item, the initial script corresponding to that configuration item is determined from each preset initial script, and the user configuration information of that configuration item is concatenated with the initial script corresponding to that configuration item to obtain the data aggregation script; Data is aggregated on the big data platform based on the various data aggregation scripts to obtain aggregated result data; wherein, the big data platform is used to store business data, and the aggregated result data includes business aggregated data; Upon receiving a result retrieval request sent by the front-end device, the aggregated result data is returned to the front-end device so that the front-end device can display an aggregated chart based on the aggregated result data; The step of aggregating data from the big data platform based on each of the data aggregation scripts to obtain the aggregated result data includes: Based on the data aggregation script corresponding to the query field configuration item, data is queried on the big data platform to obtain query results; Based on the data aggregation script corresponding to the aggregation field configuration item, the query results are aggregated to obtain the business aggregated data.

2. The data aggregation method according to claim 1, characterized in that, Each of the configuration items also includes a metric field configuration item, and the aggregated result data also includes metric result data; The step of aggregating data from the big data platform based on each of the data aggregation scripts to obtain aggregated chart data further includes: Based on the data aggregation script corresponding to the metric field configuration item, the business aggregated data is statistically analyzed to obtain the metric result data.

3. The data aggregation method according to claim 1 or 2, characterized in that, The step of returning the aggregated result data to the front-end device upon receiving a result retrieval request sent by the front-end device includes: Upon receiving the result retrieval request, a communication key is determined based on the result retrieval request; The communication key is verified, and if the verification is successful, the aggregation result data is returned to the front-end device.

4. A data aggregation method, characterized in that, Applied to a front-end device, the method includes: The display configuration interface includes multiple configuration items and multiple configuration boxes for obtaining user configuration information. When the preset data aggregation rules are met, the user configuration information of each configuration item is obtained from the configuration interface, and a data aggregation request is generated based on the user configuration information of each configuration item. The data aggregation request is sent to the server, and a communication key is generated. Each configuration item includes a query field configuration item and an aggregation field configuration item. The data aggregation request instructs the server, for each configuration item, to determine the corresponding initial script from each preset initial script based on the configuration attributes of that configuration item, and to concatenate the user configuration information of that configuration item with the corresponding initial script to obtain a data aggregation script. The data aggregation request also instructs the server to perform data aggregation on the big data platform based on each of the data aggregation scripts to obtain aggregated result data. The big data platform is used to store business data, and the aggregated result data includes business aggregated data. The step of performing data aggregation on the big data platform based on each of the data aggregation scripts to obtain aggregated result data includes: performing a data query on the big data platform based on the data aggregation script corresponding to the query field configuration item to obtain a query result; and performing data aggregation on the query result based on the data aggregation script corresponding to the aggregation field configuration item to obtain the business aggregated data. When the preset data acquisition rules are met, a result acquisition request is sent to the server according to the communication key to receive the aggregated result data returned by the server; An aggregated chart is generated based on the aggregated result data, and the aggregated chart is displayed.

5. The data aggregation method according to claim 4, characterized in that, The step of sending a result retrieval request to the server according to the communication key when the preset data retrieval rules are met includes: According to a preset request period, a result retrieval request is sent to the server based on the communication key.

6. A data aggregation device, characterized in that, Applied to a server, the device includes: An aggregation request receiving module is used to receive data aggregation requests sent by a front-end device. The data aggregation request is generated by the front-end device based on user configuration information of various configuration items, including query field configuration items and aggregation field configuration items. The configuration information acquisition module is used to acquire user configuration information for each configuration item according to the data aggregation request; The aggregation script acquisition module is used to determine the corresponding initial script from the preset initial scripts for each configuration item based on the configuration attributes of the configuration item, and to concatenate the user configuration information of the configuration item with the corresponding initial script to obtain the data aggregation script. The data aggregation module is used to aggregate data from the big data platform based on the various data aggregation scripts to obtain aggregated result data; wherein, the big data platform is used to store business data, and the aggregated result data includes business aggregated data; The data return module is used to return the aggregated result data to the front-end device when it receives a result retrieval request sent by the front-end device, so that the front-end device can display an aggregated chart based on the aggregated result data; The data aggregation module includes: The query unit is used to perform data queries on the big data platform based on the data aggregation script corresponding to the query field configuration item, so as to obtain query results; The aggregation unit is used to aggregate the query results based on the data aggregation script corresponding to the aggregation field configuration item to obtain the business aggregated data.

7. A data aggregation device, characterized in that, Applied to a front-end device, the device includes: The interface display module is used to display the configuration interface, which includes multiple configuration items and multiple configuration boxes for obtaining user configuration information. An aggregation request generation module is used to obtain user configuration information for each configuration item from the configuration interface when preset data aggregation rules are met, generate a data aggregation request based on the user configuration information of each configuration item, send the data aggregation request to the server, and generate a communication key. Each configuration item includes query field configuration items and aggregation field configuration items. The data aggregation request instructs the server, for each configuration item, to determine the corresponding initial script from preset initial scripts based on the configuration attributes of that configuration item, and to concatenate the user configuration information of that configuration item with the corresponding initial script to obtain data. The data aggregation request further instructs the server to aggregate data on the big data platform based on each of the data aggregation scripts to obtain aggregated result data. The big data platform is used to store business data, and the aggregated result data includes business aggregated data. The step of aggregating data on the big data platform based on each of the data aggregation scripts to obtain aggregated result data includes: querying the big data platform based on the data aggregation script corresponding to the query field configuration item to obtain query results; and aggregating the query results based on the data aggregation script corresponding to the aggregation field configuration item to obtain the business aggregated data. The result acquisition request generation module is used to send a result acquisition request to the server according to the communication key when the preset data acquisition rules are met, so as to receive the aggregated result data returned by the server. The chart display module is used to generate an aggregate chart based on the aggregated result data and to display the aggregate chart.

8. A computer-readable storage medium, characterized in that, The storage medium stores computer-readable instructions that, when executed by one or more processors, cause the one or more processors to perform the steps of the data aggregation method as described in any one of claims 1 to 5.

9. A computer device, characterized in that, include: One or more processors, and memory; The memory stores computer-readable instructions that, when executed by the one or more processors, perform the steps of the data aggregation method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Data aggregation method and device, computer device and computer readable storage medium

    CN109558403A

  • Code generation method and code generation device

    CN113268229A