Data processing method and device, electronic device and computer readable storage medium
By collecting and analyzing the data usage in the big data cluster and the data usage trend of the application system, a targeted big data cluster expansion solution is provided, which solves the resource waste problem caused by untargeted expansion in the existing technology and realizes data Reasonable allocation and early warning of resources.
Patent Information
- Application Number
- CN202011124091.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-10-20
- Publication Date
- 2024-10-29
- Estimated Expiration
- 2040-10-20
AI Technical Summary
Existing big data cluster expansion solutions rely on data usage, resulting in untargeted expansion, a waste of data resources, and inability to perform targeted expansion based on the data usage of each application system.
Collect the usage of each mode and data table in the big data cluster, determine the application system corresponding to each mode and data table, predict future data usage through the prediction model, and provide the basis for targeted expansion.
It achieves targeted big data cluster data expansion based on the data usage of the application system, avoids waste of resources, and provides a reasonable allocation of data resources and an early warning mechanism.
Smart Images

Figure CN112231356B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of electronic information, and in particular to a data processing method and device, an electronic device, and a computer-readable storage medium. Background Art
[0002] With the development of big data, many big data clusters have been produced, mainly based on Greenplum and HADOOP products. Big data clusters can be used to provide a large amount of data resources for application systems.
[0003] At present, the existing query tools for analyzing the data usage of big data clusters only query the data usage rate of big data clusters. R&D personnel generally determine the expansion plan for big data clusters based on the data usage rate of big data clusters. However, using the data usage rate of big data clusters as the data basis for expanding the capacity of big data clusters often leads to the problem of data resource waste of big data clusters. Therefore, how to obtain a more suitable data basis for expanding the capacity of big data clusters has become an urgent problem to be solved. Summary of the invention
[0004] The inventor has found through research that using the data usage rate of the big data cluster as the basis for expanding the capacity of the big data cluster will lead to a waste of data resources of the big data cluster. The reason is that many application systems actually share the same big data cluster, and different application systems use different amounts of data for the big data cluster, and the growth trends of data usage are also different. Therefore, when there is only the data usage rate of the big data cluster, the expansion of the big data cluster by the R&D personnel is non-targeted (for example, all data tables in the big data cluster are expanded), and it is impossible to expand the big data cluster data in a targeted manner according to the data usage of the big data cluster by each application system, which often leads to a waste of data resources. Therefore, how to obtain the usage of the big data cluster data by the application system has become a problem that needs to be solved urgently.
[0005] In order to achieve the above objectives, this application provides the following technical solutions:
[0006] A data processing method, comprising:
[0007] Collecting preset data collection items of the big data cluster, wherein the data collection items at least include the data usage of each mode in the big data cluster and the data usage of each data table;
[0008] Determine respectively the application systems corresponding to the modes and the data tables; the modes correspond to the application systems in that the application systems are preset to use the modes, and the data tables correspond to the application systems in that the application systems are preset to use the data tables;
[0009] For each application system, the data usage of the application system in the big data cluster is obtained based on the data usage of the mode corresponding to the application system and the data usage of the data table corresponding to the application system.
[0010] In the above method, optionally, the big data cluster is a plurality of big data clusters;
[0011] The preset data collection items for collecting the big data cluster are the preset data collection items for collecting the multiple big data clusters;
[0012] Before collecting the data collection items of the multiple big data clusters, the method further includes:
[0013] Acquire big data cluster information of each of the big data clusters, the big data cluster information at least including a peak usage period of the big data cluster and connection configuration information for connecting the big data cluster;
[0014] For each of the big data clusters, connecting to the big data cluster according to the connection configuration information of the big data cluster;
[0015] According to the peak usage period of each of the big data clusters, the collection period and collection frequency of each of the data collection items are configured.
[0016] The above method may optionally include, for each of the big data clusters, collecting preset data collection items of the big data cluster, including:
[0017] Obtaining a preset collection script corresponding to the data collection item; the collection script includes a script execution statement for collecting and obtaining the data collection item;
[0018] According to the collection period and the collection frequency, the collection script is executed to collect the data collection items.
[0019] In the above method, optionally, the respectively determining the application systems corresponding to the respective modes and the respective data tables preset includes:
[0020] Obtaining a preset correspondence table, wherein the correspondence table includes the application system corresponding to the mode and the application system corresponding to the data table;
[0021] According to the corresponding relationship table, the application system corresponding to each mode and each data table is obtained.
[0022] In the above method, optionally, the data collection item also includes cluster data usage of the big data cluster.
[0023] The above method may optionally further include:
[0024] The cluster data usage of the big data cluster and the historical cluster data usage of the big data cluster obtained historically are input into a pre-established prediction model to obtain the cluster data usage of the big data cluster in a future period; wherein the prediction model is modeled based on a linear regression algorithm.
[0025] For each of the application systems, inputting the data usage of the application system and the historical data usage of the application system obtained in history into the prediction model to obtain the data usage of the application system in a future period;
[0026] The cluster data usage of the big data cluster in the future period and the data usage of the application system in the future period are the basis data for the expansion of the big data cluster.
[0027] The above method may optionally further include:
[0028] In response to a query request for the data collection items input by a user, display each of the data collection items;
[0029] In response to a modification request for the data collection item input by a user, each of the data collection items is displayed, and the new data collection item input by the user is used as the data collection item of the big data cluster.
[0030] A data processing device, comprising:
[0031] A collection unit, used to collect preset data collection items of the big data cluster, wherein the data collection items at least include the data usage of each mode in the big data cluster and the data usage of each data table;
[0032] A determination unit, used to respectively determine the application systems corresponding to the modes and the data tables; the modes correspond to the application systems in that the application systems are preset to use the modes, and the data tables correspond to the application systems in that the application systems are preset to use the data tables;
[0033] The calculation unit is used to obtain, for each application system, the data usage of the application system in the big data cluster based on the data usage of the mode corresponding to the application system and the data usage of the data table corresponding to the application system.
[0034] An electronic device comprises: a processor and a memory, wherein the memory is used to store a program; and the processor is used to run the program to implement the above-mentioned data processing method.
[0035] A computer-readable storage medium stores instructions, which, when executed on a computer, enable the computer to execute the above-mentioned data processing method.
[0036] The method and device described in this application collects data usage information and data usage capacity information of a big data cluster, including at least the data usage of each mode (i.e., the schema of the big data cluster) in the big data cluster and the data usage of each data table, and respectively determines the application system corresponding to each mode and each data table. The mode corresponds to the application system as the preset usage mode of the application system, and the data table corresponds to the application system as the preset usage data table of the application system. According to the usage of the mode corresponding to the application system and the usage of the data table corresponding to the application system, the data usage of the application system in the big data cluster is obtained. According to the fact that the application system uses the data resources of the big data cluster mainly by using the mode and data table of the big data cluster, in this application, the data usage of the application system in the big data cluster can be obtained by determining the data usage of the mode corresponding to the application system and the corresponding data table. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] 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 will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0038] Figure 1 A flowchart of a data processing method provided in an embodiment of the present application;
[0039] Figure 2 A flowchart of a method for predicting data usage provided in an embodiment of the present application;
[0040] Figure 3 An architectural diagram of a data processing platform provided in an embodiment of the present application;
[0041] Figure 4 A schematic diagram of the structure of a data processing device provided in an embodiment of the present application;
[0042] Figure 5 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0043] At present, the existing query tools can only query the data usage rate of the big data cluster. R&D personnel generally determine the expansion plan for the big data cluster based on the data usage rate of the big data cluster. However, using the data usage rate of the big data cluster as the basis for expanding the big data cluster often leads to a waste of data resources of the big data cluster, because many application systems actually share the same big data cluster, and different application systems use different amounts of data in the big data cluster, and the growth trend of data usage is also different. Therefore, when there is only the data usage rate of the big data cluster, the expansion of the big data cluster by R&D personnel is non-targeted, and it is impossible to expand the big data cluster data in a targeted manner according to the data usage of each application system, which often leads to a waste of data resources.
[0044] To this end, the present application provides a data processing method, the purpose of which is to obtain the data usage of each application system in the big data cluster by combining the various modes in the big data cluster and the usage of the data table, so that later R&D personnel can expand the data of the big data cluster in a targeted manner according to the data usage of the big data cluster by each application system.
[0045] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and easy to understand, the present application is further described in detail below in conjunction with the accompanying drawings and specific implementation methods. 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 ordinary technicians in the field without making creative work are within the scope of protection of the present application.
[0046] It should be noted that in this application, the "mode" of a big data cluster refers to the "schema" of the big data cluster. The schema includes schema objects, which can be tables, columns, data types, views, stored procedures, relations, primary keys, and foreign keys.
[0047] Figure 1 A data processing method provided in an embodiment of the present application may include the following steps:
[0048] S101. Collect preset data collection items of a big data cluster.
[0049] The big data cluster includes a large number of pre-created patterns and data tables. The data collection items at least include the data usage of each pattern in the big data cluster and the data usage of each data table.
[0050] The specific implementation method of this step is: obtain the preset collection script corresponding to the data collection item, and execute the collection script to collect the collection item. Among them, the collection script includes the script execution statement for collecting the collection item, and the specific script execution statement of the collection item can be set according to the needs. The collection period and collection frequency can be obtained in combination with the peak period of use of the big data cluster. For example, the collection period is set to the period after the peak period of use of the big data cluster, and the collection frequency can be to collect a preset number of times during the collection period.
[0051] It should be noted that the data collection items of the big data cluster can be queried and modified, so that the data collection items can be expanded and added later according to different data collection needs. The specific implementation method is: in response to the query request of the data collection item input by the user, each data collection item is displayed, in response to the modification request of the data collection item input by the user, each data collection item is displayed, and the new data collection item input by the user is used as the data collection item of the big data cluster.
[0052] S102, respectively determine the application system corresponding to each mode and each data table preset.
[0053] In this embodiment, the mode corresponds to the application system, and the application system presets the mode, and the data table corresponds to the application system, and the application system presets the data table. It should be noted that an application system can preset multiple modes and multiple data tables of a big data cluster.
[0054] The specific implementation method of this step is: obtain a preset correspondence table, which contains the application system corresponding to the packet mode and the application system corresponding to the data table. Based on the correspondence table, the preset corresponding application system of each mode and each data table can be obtained.
[0055] S103 . For each application system, the data usage of the application system in the big data cluster is obtained based on the usage of the mode corresponding to the application system and the usage of the data table corresponding to the application system.
[0056] The specific implementation method of this step is: for each application system, the sum of the usage of the mode corresponding to the application system and the usage of the data table corresponding to the application system is used as the data usage of the application system in the big data cluster.
[0057] The method provided in this embodiment collects data usage information and data usage capacity information of a big data cluster, including at least the data usage of each mode in the big data cluster and the data usage of each data table, and determines the application system preset corresponding to each mode and each data table respectively. The mode and the application system correspond to the preset usage mode of the application system, and the data table and the application system correspond to the preset usage data table of the application system. According to the usage of the mode corresponding to the application system and the usage of the data table corresponding to the application system, the data usage of the application system in the big data cluster is obtained. According to the rule that the application system uses the data resources of the big data cluster mainly by using the mode and data table of the big data cluster, in this application, the data usage of the application system in the big data cluster can be obtained by determining the data usage of the mode corresponding to the application system and the data table corresponding to the application system.
[0058] In this application, the data processing method described in the above embodiment can be executed in parallel or serially on multiple big data clusters to obtain the data usage of the application system in each big data cluster. It should be noted that the multiple big data clusters can be different types of big data clusters, for example, GreenPlum big data clusters and HADOOP big data clusters. As long as you connect to the big data cluster and set the collection period and collection frequency, you can execute Figure 1 The data processing method shown can collect and obtain various collection items of the big data cluster.
[0059] Therefore, for any big data cluster, before collecting data collection items of the big data cluster, it is necessary to connect to the big data cluster and configure the collection period and collection frequency. The specific implementation method may include the following steps A1 to A3:
[0060] Step A1: Obtain big data cluster information of each big data cluster.
[0061] The big data cluster information includes at least the peak usage period of the big data cluster and the connection configuration information of the big data cluster, for example, the identifier of the big data cluster (the identifier of the big data cluster can be the name of the big data set) and the IP address of the big data cluster.
[0062] Step A2: For each big data cluster, connect to the big data cluster according to the connection configuration information of the big data cluster.
[0063] Step A3: According to the peak usage period of each big data cluster, configure the collection period and frequency of each data collection item.
[0064] For example, according to the peak usage period of each big data cluster, the non-peak usage period of each big data cluster is counted. If the non-peak usage period of each big data cluster is the same, parallel collection can be performed. In parallel collection, the collection period and collection frequency corresponding to each big data cluster are the same. If the non-peak usage period of each big data cluster is different, serial collection can be performed. In serial collection, the collection period and collection frequency corresponding to each big data cluster can be set by itself. It should be noted that the collection period is any period in the non-peak usage period.
[0065] The solution provided in the present application can be connected to the big data cluster only according to the connection configuration information of the big data cluster, and is independent of the product type of the big data cluster. Once connected to the big data cluster, data collection items of each big data cluster can be collected in parallel or serially according to the set collection period and collection frequency. In other words, data collection items of big data clusters of different product types can be collected. For example, HADOOP big data clusters and GreenPlum big data clusters can be collected at the same time. On the other hand, with the continuous increase of big data products and clusters, the solution provided in the present application can be connected to the newly added big data cluster according to the connection configuration information of the newly added big data cluster, and data collection items of the newly added big data cluster can be collected. It has good scalability.
[0066] In the above embodiment of the present application, the data collection item may also include the cluster data usage of the big data cluster. Similarly, the cluster data usage of the big data cluster may be obtained by querying a preset cluster data usage query execution statement.
[0067] In order to understand the growth trend of cluster data usage of the big data cluster and the growth trend of data usage of the big data cluster by each application system, so as to serve as a basis for expanding the capacity of the big data cluster, this application provides a method for predicting data usage, such as Figure 2 As shown, the following steps may be included:
[0068] S201. Obtain first data to be predicted of a big data cluster and second data to be predicted of each application system.
[0069] The first data to be predicted of the big data cluster is: the cluster data usage of the big data cluster collected during the collection period, and the historical cluster data usage of the big data cluster obtained historically.
[0070] The second data to be predicted of the application system is: the data usage of the application system collected during the collection period, and the data usage of the application system obtained historically.
[0071] S202: Process the first data to be predicted to obtain first model data.
[0072] For example, the data to be predicted in the big data cluster is cleaned and transformed according to the format requirements of the model data input into the prediction model.
[0073] S203 , respectively process the second data to be predicted of each application system to obtain second model data of each application system.
[0074] S204: Input the data to be predicted into the prediction model to obtain the cluster data usage of the big data cluster in the future period.
[0075] The prediction model is pre-modeled based on a linear regression algorithm. The specific modeling process can refer to the prior art.
[0076] S205 , input the second data to be predicted of each application system into the prediction model respectively, to obtain the cluster data usage of each application system in the future period.
[0077] The method provided in this embodiment predicts the future data usage trend of the big data cluster obtained by the model, which can be used as early warning information for expanding the capacity of the big data cluster. For example, based on the future data usage trend of the big data cluster, at some time in the future, the cluster data usage of the big data cluster will reach the total data capacity of the big data cluster. Before that, the big data cluster needs to be expanded. Therefore, the data on the future data usage of the big data cluster can serve as an early warning for expansion.
[0078] In addition, combined with the cluster data usage of each application system in the future period predicted by the prediction model, the big data cluster can be expanded in a targeted and reasonable manner. For example, if the future data usage of application system A grows faster and the future data usage of application system A grows slower, the data table or schema used by application system A in the big data cluster can be expanded in a targeted manner, thereby realizing the reasonable configuration of data resources of the big data cluster. Therefore, in this embodiment, the cluster data usage of the big data cluster in the future period and the data usage of the application system in the future period can be used as the basis for the expansion of the big data cluster.
[0079] Corresponding to the above examples of this application, Figure 3 The architecture diagram of a data processing platform 300 provided in this application example is as follows: Figure 3 As shown, it includes: a scheduling module 301, a collection module 302, and an analysis and prediction module 303.
[0080] The scheduling module 301 has functions such as configuration management, scheduling management and authority management.
[0081] Permission management is used to control management query permissions and modification permissions. Specifically, in response to query requests for data collection items input by users, each data collection item is displayed; in response to modification requests for data collection items input based on a management account with management permissions, the data collection items are displayed, and the new data collection items input are used as data collection items for the big data cluster.
[0082] Configuration management: manage the big data cluster information entered by users, including the name of the big data cluster, the peak usage period of the big data cluster, and the connection configuration information of the big data cluster.
[0083] The scheduling management function can configure parallel or serial collection tasks, as well as the collection time and frequency of each big data cluster according to the peak usage period of each big data cluster. The collection tasks can be distributed to the collection module 302 on a regular basis according to the set collection period and collection frequency, wherein the collection tasks at least include the connection configuration information of the big data cluster to be collected. Of course, if the scheduling module 301 is abnormal and cannot be triggered on time, manual triggering can be used to distribute collection tasks to the collection module 302.
[0084] The collection module 302 is composed of multiple collection nodes, each of which is pre-installed with a client of the big data cluster to be collected, such as a client of the HADOOP big data cluster and a client of the Greenplum big data cluster. After adopting the connection configuration information of the big data cluster, it is connected to the big data cluster and starts to execute the collection task, collects the data usage of each mode in the big data cluster, the data usage of each data table, and the cluster data usage of the big data cluster, and stores the collected data information in the MySQL database of the analysis and prediction module 303.
[0085] The analysis and prediction module 303 includes analysis management and prediction management.
[0086] Analysis and management is to analyze and process the data in the MySQL database to obtain the data usage of the application system in the big data cluster.
[0087] Prediction management is to input the cluster data usage of the big data cluster, as well as the historical cluster data usage of the big data cluster obtained historically, into a pre-established prediction model to obtain the cluster data usage of the big data cluster in the future period; and, for each of the above-mentioned application systems, input the data usage of the application system, as well as the historical data usage of the application system obtained historically, into the prediction model to obtain the data usage of the application system in the future period, and finally output the cluster data usage of the big data cluster in the future period, as well as the data usage of the application system in the future period.
[0088] The data processing platform provided by the present application can obtain the data usage of the application system in the big data cluster; as well as the historical data usage of the application system.
[0089] Furthermore, with the continuous increase of big data products and clusters, this data processing platform can connect to the newly added big data cluster according to the connection configuration information of the newly added big data cluster, and collect data collection items of the newly added big data cluster, which has good scalability and practicality.
[0090] Furthermore, it can save maintenance manpower. With the continuous increase of big data products and clusters, maintenance personnel no longer need to log in to the tool pages of different big data clusters to view data usage information. Through this data platform, data usage of all big data clusters can be viewed uniformly.
[0091] Furthermore, it provides dynamic early warning and data for cluster expansion. According to the future data usage trend of the data cluster, it can play an early warning role in expansion. Combined with the cluster data usage of each application system in the future period predicted by the prediction model, the big data cluster can be expanded in a targeted and reasonable manner.
[0092] Figure 4 A result schematic diagram of a data processing device 400 is provided for an embodiment of the present application, including:
[0093] A collection unit 401 is used to collect preset data collection items of a big data cluster, wherein the data collection items at least include the data usage of each mode in the big data cluster and the data usage of each data table;
[0094] The determination unit 402 determines the application systems corresponding to the modes and the data tables respectively; the modes correspond to the application systems in that the application systems are preset to use the modes, and the data tables correspond to the application systems in that the application systems are preset to use the data tables;
[0095] The calculation unit 403 is used to obtain, for each application system, the data usage of the application system in the big data cluster based on the data usage of the mode corresponding to the application system and the data usage of the data table corresponding to the application system.
[0096] Optionally, the big data cluster is a plurality of big data clusters;
[0097] The collection unit 401 collects preset data collection items of the big data cluster, which means that the collection unit 401 collects the preset data collection items of the plurality of big data clusters;
[0098] Optionally, the above-mentioned device 400 also includes a configuration unit 404, which is used to obtain big data cluster information of each of the big data clusters, and the big data cluster information at least includes the peak usage period of the big data cluster and the connection configuration information of connecting to the big data cluster; for each of the big data clusters, connect to the big data cluster according to the connection configuration information of the big data cluster; according to the peak usage period of each of the big data clusters, configure the collection period and collection frequency of collecting each of the data collection items.
[0099] Optionally, the data collection item also includes cluster data usage of the big data cluster.
[0100] Optional, such as Figure 4 As shown, the above-mentioned device 400 also includes a prediction unit 405, which is used to input the cluster data usage of the big data cluster and the historical cluster data usage of the big data cluster obtained in history into a pre-established prediction model to obtain the cluster data usage of the big data cluster in the future period; wherein the prediction model is obtained by modeling according to a linear regression algorithm;
[0101] For each of the application systems, inputting the data usage of the application system and the historical data usage of the application system obtained in history into the prediction model to obtain the data usage of the application system in a future period;
[0102] The cluster data usage of the big data cluster in the future period and the data usage of the application system in the future period are the basis data for the expansion of the big data cluster.
[0103] Optional, such as Figure 4 As shown, the above-mentioned device 400 further includes a user interaction unit 406, which displays each of the data collection items in response to a query request of the data collection items input by a user;
[0104] In response to a modification request for the data collection item input by a user, each of the data collection items is displayed, and the new data collection item input by the user is used as the data collection item of the big data cluster.
[0105] Optionally, the specific implementation method of the collection unit 401 collecting preset data collection items of the big data cluster for each big data cluster is: obtaining a preset collection script corresponding to the data collection item; the collection script includes a script execution statement for collecting the data collection item; and executing the collection script according to the collection period and the collection frequency to collect the data collection item.
[0106] Optionally, the specific implementation manner in which the determining unit 402 determines the application systems corresponding to the modes and the data tables is as follows:
[0107] Obtaining a preset correspondence table, wherein the correspondence table includes the application system corresponding to the mode and the application system corresponding to the data table;
[0108] According to the corresponding relationship table, the application system corresponding to each mode and each data table is obtained.
[0109] The device provided in this embodiment collects data usage information and data usage capacity information of a big data cluster, including at least the data usage of each mode in the big data cluster and the data usage of each data table, and determines the application system preset corresponding to each mode and each data table respectively. The mode and the application system correspond to the preset usage mode of the application system, and the data table and the application system correspond to the preset usage data table of the application system. According to the usage of the mode corresponding to the application system and the usage of the data table corresponding to the application system, the data usage of the application system in the big data cluster is obtained. According to the rule that the application system uses the data resources of the big data cluster mainly by using the mode and data table of the big data cluster, in this application, the data usage of the application system in the big data cluster can be obtained by determining the data usage of the mode corresponding to the application system and the data table corresponding to the application system.
[0110] The present application also provides an electronic device 500, whose structural diagram is as follows: Figure 5 As shown, it includes: a processor 501 and a memory 502, the memory 502 is used to store the application program, and the processor 501 is used to execute the application program to implement the data processing method of the present application, that is, to perform the following steps:
[0111] Collecting preset data collection items of the big data cluster, wherein the data collection items at least include the data usage of each mode in the big data cluster and the data usage of each data table;
[0112] Determine respectively the application systems corresponding to the modes and the data tables; the modes correspond to the application systems in that the application systems are preset to use the modes, and the data tables correspond to the application systems in that the application systems are preset to use the data tables;
[0113] For each application system, the data usage of the application system in the big data cluster is obtained based on the data usage of the mode corresponding to the application system and the data usage of the data table corresponding to the application system.
[0114] The present application also provides a computer-readable storage medium, in which instructions are stored. When the computer-readable storage medium is run on a computer, the computer executes the data processing method of the present application, that is, executes the following steps:
[0115] Collecting preset data collection items of the big data cluster, wherein the data collection items at least include the data usage of each mode in the big data cluster and the data usage of each data table;
[0116] Determine respectively the application systems corresponding to the modes and the data tables; the modes correspond to the application systems in that the application systems are preset to use the modes, and the data tables correspond to the application systems in that the application systems are preset to use the data tables;
[0117] For each application system, the data usage of the application system in the big data cluster is obtained based on the data usage of the mode corresponding to the application system and the data usage of the data table corresponding to the application system.
[0118] If the functions described in the method of the embodiment of the present application are implemented in the form of software functional units and sold or used as independent products, they can be stored in a storage medium readable by a computing device. Based on this understanding, the part of the embodiment of the present application that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions to enable a computing device (which can be a personal computer, server, mobile computing device or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program code.
[0119] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0120] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for data processing, characterized in that: include: Collecting preset data collection items of the big data cluster, wherein the data collection items at least include the data usage of each mode in the big data cluster and the data usage of each data table; Determine respectively the application systems corresponding to the modes and the data tables; the modes correspond to the application systems in that the application systems are preset to use the modes, and the data tables correspond to the application systems in that the application systems are preset to use the data tables; For each application system, the data usage of the application system in the big data cluster is obtained according to the data usage of the mode corresponding to the application system and the data usage of the data table corresponding to the application system; For each application system, obtaining the data usage of the application system in the big data cluster according to the data usage of the mode corresponding to the application system and the data usage of the data table corresponding to the application system includes: For each application system, the sum of the data usage of the mode corresponding to the application system and the data usage of the data table corresponding to the application system is taken as the data usage of the application system in the big data cluster.
2. The method according to claim 1, characterized in that The big data cluster is a plurality of big data clusters; The preset data collection items for collecting the big data cluster are the preset data collection items for collecting the multiple big data clusters; Before collecting the data collection items of the multiple big data clusters, the method further includes: Acquire big data cluster information of each of the big data clusters, the big data cluster information at least including a peak usage period of the big data cluster and connection configuration information for connecting the big data cluster; For each of the big data clusters, connecting to the big data cluster according to the connection configuration information of the big data cluster; According to the peak usage period of each of the big data clusters, the collection period and collection frequency of each of the data collection items are configured.
3. The method according to claim 2, characterized in that For each of the big data clusters, collecting the preset data collection items of the big data cluster includes: Obtaining a preset collection script corresponding to the data collection item; the collection script includes a script execution statement for collecting and obtaining the data collection item; According to the collection period and the collection frequency, the collection script is executed to collect the data collection items.
4. The method according to claim 1, characterized in that The respectively determining the application systems corresponding to the modes and the preset corresponding application systems of the data tables includes: Obtaining a preset correspondence table, wherein the correspondence table includes the application system corresponding to the mode and the application system corresponding to the data table; According to the corresponding relationship table, the application system corresponding to each mode and each data table is obtained.
5. The method according to claim 1, characterized in that The data collection items also include the cluster data usage of the big data cluster.
6. The method according to claim 5, characterized in that Also includes: Inputting the cluster data usage of the big data cluster and the historical cluster data usage of the big data cluster obtained in history into a pre-established prediction model to obtain the cluster data usage of the big data cluster in a future period; wherein the prediction model is obtained by modeling based on a linear regression algorithm; For each of the application systems, inputting the data usage of the application system and the historical data usage of the application system obtained in history into the prediction model to obtain the data usage of the application system in a future period; The cluster data usage of the big data cluster in the future period and the data usage of the application system in the future period are the basis data for the expansion of the big data cluster.
7. The method according to claim 1, characterized in that Also includes: In response to a query request for the data collection items input by a user, display each of the data collection items; In response to a modification request for the data collection item input by a user, each of the data collection items is displayed, and the new data collection item input by the user is used as the data collection item of the big data cluster.
8. A data processing device, characterized in that: include: A collection unit, used to collect preset data collection items of the big data cluster, wherein the data collection items at least include the data usage of each mode in the big data cluster and the data usage of each data table; A determination unit, used to respectively determine the application systems corresponding to the modes and the data tables; the modes correspond to the application systems in that the application systems are preset to use the modes, and the data tables correspond to the application systems in that the application systems are preset to use the data tables; a calculation unit, configured to obtain, for each application system, a data usage of the application system in the big data cluster according to a data usage of the mode corresponding to the application system and a data usage of the data table corresponding to the application system; The computing unit is specifically used for: For each application system, the sum of the data usage of the mode corresponding to the application system and the data usage of the data table corresponding to the application system is taken as the data usage of the application system in the big data cluster.
9. An electronic device, characterized in that: include: A processor and a memory, wherein the memory is used to store a program; and the processor is used to run the program to implement the data processing method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores instructions, which, when executed on a computer, enable the computer to execute the data processing method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Monitoring device for data access
CN104965861A
Data processing method and device, storage medium and electronic equipment
CN107220283A
