Product business data processing method and device, computer equipment and medium
The preset data field template preprocesses and format matching of product business data to generate target storage formats, solving the problem of complexity of data format conversion in traditional data processing, and realizing flexible data storage and efficient data processing.
Patent Information
- Application Number
- CN202411138417.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-19
- Publication Date
- 2024-11-29
AI Technical Summary
In traditional data processing, due to the diversity of data acquisition formats, a large amount of logical code is required to be written, resulting in increased data storage complexity and it is difficult to achieve flexible data format conversion and storage.
The product business data is preprocessed through the preset data field template, segmented and formatted, and data in the target storage format is generated and stored in the corresponding database, including the full, analytical and indexed data database.
It simplifies the data storage process, reduces the difficulty of data storage, improves the flexibility and efficiency of data processing, and reduces the need for later code modification.
Smart Images

Figure CN119046399A_ABST
Abstract
Description
Technical Field
[0001] Embodiments of the present disclosure relate to the field of data processing technology, and in particular, to a method, apparatus, computer equipment, and medium for processing product business data. Background Art
[0002] With the development of the Internet, the amount of data has grown exponentially, and the types and formats of business data are diverse. Connecting business data occupies an important position in project work.
[0003] In the traditional data processing process, the diversity of data collection formats requires the writing of a large amount of logic code. At the same time, with the changes and adjustments of the business, the complexity of data docking has been brought about. When storing data, the logic code needs to be modified according to different formats, which increases the difficulty of data storage. Summary of the invention
[0004] The embodiments described herein provide a method, apparatus, computer device, and medium for processing product business data, which overcome the above-mentioned problems.
[0005] In a first aspect, according to the content of the present disclosure, a method for processing product business data is provided, comprising:
[0006] Acquire product business data, where the product business data is used to describe the collected upstream business data;
[0007] Preprocessing the product business data based on a preset data field template to obtain text business data, wherein the preset data field template is used to constrain the data format of the product business data and a data separator in the product business data, and the data separator is used to segment the product business data;
[0008] Performing storage format matching on the text service data to obtain a target storage format corresponding to the text service data;
[0009] Based on the target storage format corresponding to the text business data, data integration is performed on the text business data to obtain target business data whose data storage format satisfies the target storage format;
[0010] Acquire a target database corresponding to the target storage format;
[0011] storing the target business data in the target database;
[0012] Among them, the target database is one of the following: a first database, a second database and a third database, the first database is used to describe the storage of full data, the second database is used to describe the storage of analysis data, the third database is used to describe the storage of index data, and there is a data index association between the third database and the first database.
[0013] In a second aspect, according to the content of the present disclosure, a device for processing product business data is provided, including:
[0014] A first acquisition module is used to acquire product business data, where the product business data is used to describe the collected upstream business data;
[0015] A preprocessing module, used for performing data preprocessing on the product business data based on a preset data field template to obtain text business data, wherein the preset data field template is used to constrain the data format of the product business data and the data separator in the product business data, and the data separator is used to segment the product business data;
[0016] A matching module, used for performing storage format matching on the text service data to obtain a target storage format corresponding to the text service data;
[0017] An integration module, configured to integrate the text service data based on the target storage format corresponding to the text service data, and obtain target service data whose data storage format satisfies the target storage format;
[0018] A second acquisition module, used to acquire a target database corresponding to the target storage format;
[0019] A storage module, used for storing the target business data in the target database;
[0020] Among them, the target database is one of the following: a first database, a second database and a third database, the first database is used to describe the storage of full data, the second database is used to describe the storage of analysis data, the third database is used to describe the storage of index data, and there is a data index association between the third database and the first database.
[0021] In a third aspect, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the steps of the method for processing product business data in any of the above embodiments are implemented.
[0022] In a fourth aspect, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the method for processing product business data in any of the above embodiments are implemented.
[0023] The method for processing product business data provided in the embodiment of the present application comprises the following steps: obtaining product business data, where the product business data is used to describe the collected upstream business data; performing data preprocessing on the product business data based on a preset data field template to obtain text business data, where the preset data field template is used to constrain the data format of the product business data and the data separator in the product business data, and the data separator is used to segment the product business data; performing storage format matching on the text business data to obtain a target storage format corresponding to the text business data; performing data integration on the text business data based on the target storage format corresponding to the text business data to obtain target business data whose data storage format satisfies the target storage format; obtaining a target database corresponding to the target storage format; and storing the target business data in the target database; wherein the target database is one of the following: a first database, a second database and a third database, where the first database is used to describe and store the full amount of data, the second database is used to describe and store the analysis data, and the third database is used to describe and store the index data, and there is a data index association between the third database and the first database. In this way, the template format of the collected product business data is unified through the pre-set preset data field template, and the unified text business data is stored in the corresponding target database according to its corresponding target storage format, and a format that conforms to the internal processing data is generated to store the business data, which is convenient for simplifying the data storage process and effectively reducing the difficulty of data storage.
[0024] The above description is only an overview of the technical solution of the embodiment of the present application. In order to more clearly understand the technical means of the embodiment of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the embodiment of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings of the embodiments will be briefly described below. It should be noted that the drawings described below only relate to some embodiments of the present disclosure, but are not intended to limit the present disclosure, wherein:
[0026] Figure 1 It is a flowchart of a method for processing product business data provided by the present disclosure.
[0027] Figure 2 It is a structural diagram of a device for processing product business data provided by the present disclosure.
[0028] Figure 3 It is a structural schematic diagram of a computer device provided by the present disclosure.
[0029] It should be noted that the elements in the drawings are schematic and not drawn to scale. DETAILED DESCRIPTION
[0030] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution of the embodiments of the present disclosure will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present disclosure, rather than all of the embodiments. Based on the described embodiments of the present disclosure, all other embodiments obtained by those skilled in the art without creative work also fall within the scope of protection of the present disclosure.
[0031] Unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by a person skilled in the art to which the subject matter of the present disclosure belongs. It will be further understood that terms such as those defined in commonly used dictionaries should be interpreted as having a meaning consistent with their meaning in the context of the specification and the relevant art, and will not be interpreted in an idealized or overly formal form unless otherwise explicitly defined herein. As used herein, a statement that two or more parts are "connected" or "coupled" together shall mean that the parts are joined together directly or through one or more intermediate components.
[0032] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase "embodiments" in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0033] The term "and / or" in this article is only a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can mean: A exists, A and B exist at the same time, and B exists. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship. Terms such as "first" and "second" are only used to distinguish one component (or a part of a component) from another component (or another part of a component).
[0034] In the description of the present application, unless otherwise specified, "plurality" means more than two (including two), and similarly, "multiple groups" means more than two groups (including two).
[0035] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the accompanying drawings.
[0036] Figure 1 is a flowchart of a method for processing product business data provided by an embodiment of the present disclosure, such as Figure 1 As shown, the specific process of the method for processing product business data includes:
[0037] S110. Obtain product business data.
[0038] Among them, product business data is used to describe the collected upstream business data.
[0039] Product business data may include: work order information, insurance policy information and third-party business information. Work order information may include the loan amount, personal information, loan interest rate, loan term, etc. filled in by the loan personnel when making a loan. Insurance policy information may include the guaranteed person, guarantee type, guarantee time limit, guarantee amount, etc. during the loan process. Third-party business information may include the guarantor and the type of guaranteed enterprise corresponding to the insurance policy information.
[0040] In some embodiments, obtaining product business data includes:
[0041] Determine the storage address of the original business data to be collected; in the process of collecting the original business data from the storage address based on the preset collection method, detect the current collection character; if it is detected that the current collection character is a data end character, determine that the product business data is obtained.
[0042] The original business data is provided with a data end character, which can effectively reflect whether the data collection is completed.
[0043] The preset collection method includes one of the following: interface call, file reading and database reading. The preset collection method corresponds to the storage address of the original business data, that is, when the storage address of the original business data is file storage, the preset collection method can be file reading; when the storage address of the original business data is a database, the preset collection method can be database reading; when the storage address of the original business data is a storage area corresponding to a non-built-in interface, the preset collection method can be interface call.
[0044] Therefore, by configuring a variety of data collection rules, the convenient acquisition of product business data can be effectively realized. At the same time, the data terminator corresponding to each original business data is set to provide collection prompts for data collection.
[0045] It should be noted that the data terminator corresponding to each original business data may be different. Specifically, the data terminator corresponding to each original business data may be represented by a character string obtained after encryption encoding / ordinary encoding of the entire content of the original business data. This makes it convenient to set different collection rule prompts for different original business data.
[0046] S120: Preprocess the product business data based on a preset data field template to obtain text business data.
[0047] Among them, the preset data field template is used to constrain the data format of product business data and the data separator in the product business data. The data separator is used to segment the product business data to facilitate the isolation and distinction between field values, and optimize the subsequent data segmentation process.
[0048] The preset data field module is derived based on the data requirements of the product project. For example, by combing the historical business data used by the product, the historical business data is sorted out to form a data field module with a fixed format and specified data separators.
[0049] In addition, after preprocessing the product business data with the preset data field template to obtain the text business data, data cleaning operations can also be performed on the text business data, such as removing duplicate data, completing incomplete data, etc., to ensure the integrity of the text business data.
[0050] S130 , performing storage format matching on the text service data to obtain a target storage format corresponding to the text service data.
[0051] The target storage format can correspond to different target databases. For example, if the target storage format is csv, the corresponding target database is solr; if the target storage format is hive, the corresponding target database is Hive data warehouse; if the target storage format is hbase, the corresponding target database is HBase database.
[0052] In some embodiments, the text service data has an attribute tag corresponding to it. The attribute tag corresponding to the text service data may be a pre-defined identification tag, or may be an identification tag derived based on the category of the data content of the text service data.
[0053] Match the storage format of the text business data to obtain the target storage format corresponding to the text business data, including:
[0054] The attribute tags corresponding to the text business data are matched with the format tags corresponding to each preset storage format for similarity; the preset storage format associated with a format tag with the highest matching degree with the attribute tags corresponding to the text business data is determined as the target storage format corresponding to the text business data.
[0055] Among them, the attribute label corresponding to the text business data and the format label corresponding to each preset storage format can be expressed in vector form, that is, the attribute label can be an attribute representation vector, and the format label can be a format representation vector.
[0056] When the attribute labels corresponding to the text business data are matched with the format labels corresponding to each preset storage format, the cosine similarity can be calculated based on the attribute representation vector and the format representation vector corresponding to each preset storage format to obtain the cosine similarity between the attribute representation vector and the format representation vector corresponding to each preset storage format.
[0057] Determining a preset storage format associated with a format tag that has the highest matching degree with an attribute tag corresponding to text business data as a target storage format corresponding to the text business data may include: determining, from the cosine similarity between the attribute representation vector and the format representation vector corresponding to each preset storage format, that the preset storage format corresponding to the maximum cosine similarity is the target storage format corresponding to the text business data.
[0058] Therefore, by matching the attribute tag corresponding to the text service data with the format tag corresponding to each preset storage format, it is convenient to quickly measure the target storage format corresponding to the text service data.
[0059] S140 . Based on the target storage format corresponding to the text business data, data integration is performed on the text business data to obtain target business data whose data storage format satisfies the target storage format.
[0060] Among them, the generated text business data needs to be integrated and processed through an efficient data collection process. The entire processing process not only involves data integration, but also includes necessary calculation processes to facilitate the generation of text files in different formats (that is, target business data that meets the target storage format).
[0061] S150: Acquire a target database corresponding to the target storage format.
[0062] Among them, the target database is one of the following: a first database, a second database and a third database. The first database is used to describe the storage of full data, the second database is used to describe the storage of analysis data, and the third database is used to describe the storage of index data. There is a data index association between the third database and the first database.
[0063] The first database may be an HBase database, the second database may be a Hive data warehouse, and the third database may be a Solr database.
[0064] In some embodiments, obtaining a target database corresponding to a target storage format includes:
[0065] Obtain a target storage field corresponding to the target storage format; combine the target storage field corresponding to the target storage format with the library storage field corresponding to each preset database; determine that a preset database associated with a library storage field that meets the preset field conditions after integration with the target storage field corresponding to the target storage format is the target database corresponding to the target storage format.
[0066] The preset database is the first database, the second database, or the third database.
[0067] The preset field condition can be used to describe a specified string rule, such as from large to small, from small to large, etc. For example, if the target storage field corresponding to the target storage format is combined with the database storage field corresponding to a preset database, the combined field (which can be represented by a digital sequence) is formed, and if it satisfies the order from large to small, then the preset database is determined to be the target database corresponding to the target storage format.
[0068] When a target storage field corresponding to a target storage format is combined with a library storage field corresponding to a preset database, the resulting combined field may be: a pre-order field + a post-order field, where the pre-order field is the target storage field corresponding to the target storage format, and the post-order field is the library storage field corresponding to a preset database.
[0069] Therefore, by combining the target storage field corresponding to the target storage format with the library storage field corresponding to each preset database, the target database corresponding to the target storage format can be found quickly and accurately.
[0070] S160: Store the target business data in the target database.
[0071] When storing target business data, different business data can be effectively stored by calling interfaces of different storage types.
[0072] Storage types can be defined based on different storage media, such as disks, memory, etc. Storage formats are differentiated based on storage types, such as text, binary, etc. By optimizing storage types and storage formats, efficient support for different business needs is achieved.
[0073] By using interfaces of different storage types to batch load texts in different storage formats into the data repository for direct use by the business system, business developers can focus more on the development of the business system without having to pay attention to the details of the underlying data storage.
[0074] In this embodiment, product business data is obtained, and the product business data is used to describe the collected upstream business data; data preprocessing is performed on the product business data based on a preset data field template to obtain text business data, and the preset data field template is used to constrain the data format of the product business data and the data separator in the product business data, and the data separator is used to segment the product business data; the storage format of the text business data is matched to obtain the target storage format corresponding to the text business data; based on the target storage format corresponding to the text business data, data integration is performed on the text business data to obtain target business data whose data storage format meets the target storage format; a target database corresponding to the target storage format is obtained; the target business data is stored in the target database; wherein the target database is one of the following: a first database, a second database and a third database, the first database is used to describe the storage of full data, the second database is used to describe the storage of analysis data, and the third database is used to describe the storage of index data, and there is a data index association between the third database and the first database. In this way, the template format of the collected product business data is unified through the pre-set preset data field template, and the unified text business data is stored in the corresponding target database according to its corresponding target storage format, and a format that conforms to the internal processing data is generated to store the business data, which is convenient for simplifying the data storage process and effectively reducing the difficulty of data storage.
[0075] In some embodiments, when the target database is the first database, the target business data corresponds to a data query period. The data query period can be a certain time period in a day, such as 15:00 to 18:00 every day; or, the data query period can be a fixed time period, such as 15:00 to 18:00 on May 20, 2024.
[0076] After storing the target business data in the target database, it also includes:
[0077] Receive a data content query request corresponding to target business data sent by a user device; in response to the data content query request, determine whether the sending time point of the data content query request is within the data query time period corresponding to the target business data; if the sending time point of the data content query request is within the data query time period corresponding to the target business data, obtain the target business data from the first database; and send the target business data to the user device.
[0078] Among them, before sending the target business data to the user device, other business data similar to the target business data can be matched from the first database, and when sending the target business data to the user device, the other business data can be sent to the user device in the form of an attached file, so that the user can have a deeper understanding of the connected target business data.
[0079] In some embodiments, in response to the data content query request, after determining whether the sending time point of the data content query request is within the data query period corresponding to the target service data, the method further includes:
[0080] If the sending time point of the data content query request is not within the data query period corresponding to the target service data, query prompt information is sent to the user equipment; and the data query period corresponding to the target service data is sent to the user equipment.
[0081] The query prompt information is used to inform the user that the device is currently unable to query the data content of the target service data.
[0082] Therefore, when the data content of the target business data cannot be queried at the current time point, the user is informed of the situation in a timely manner, and the data query period of the target business data is sent to the user device, so that the user can effectively query the target business data within the specified period through the user device.
[0083] In some embodiments, when the target database is a third database, after storing the target business data in the target database, the method further includes:
[0084] Receive an index content query request corresponding to target business data sent by a user device; in response to the index content query request, search for a business data index in a first database corresponding to the target business data from a third database; based on the business data index, query from the first database to obtain index content corresponding to the business data index; and send the index content corresponding to the business data index to the user device.
[0085] The third database has a data index association with the first database, which means that the third database stores multiple business data indexes, and each business data index has corresponding index content in the first database, so that the required index content can be queried from the first database based on the business data index in the third database.
[0086] In addition, when the target database is the second database, after storing the target business data in the target database, it also includes: receiving a data content search request corresponding to the target business data sent by a user device; in response to the data content search request, searching for the search request content from the second database, and sending the search request content to the user device.
[0087] In this embodiment, a variety of storage types are used to meet different business needs. Hbase is used to store full data, has the characteristics of high concurrency and low latency, and is suitable for the storage and query of real-time data. Hive is used to store analytical data, supports SQL queries, and is convenient for big data analysis. Solr is used to store index data and serves as a secondary index of Hbase to improve retrieval efficiency. The front-end application can retrieve the rowkey from Solr through conditions, and then query the full data from Hbase through the rowkey, which not only ensures the real-time nature of the data, but also improves retrieval efficiency.
[0088] In order to meet the needs of different business scenarios, flexible configuration options are also provided in this embodiment. Users only need to process the original business data in the preprocessing layer to generate a template business data file that meets the standards. For different projects, the methods and types of business data docking with customers vary greatly. Preprocessing is to solve the problem of docking different data. In the preprocessing place, the data is processed in advance according to the established data processing method, which can effectively reduce the modification of the code level in the later stage.
[0089] For example, in one business, it is necessary to connect to the customer's xml file. In preprocessing, the xml file is parsed and a text file in template format is generated for direct use and storage of data collection. In one business, data needs to be collected from the database. In preprocessing, the database business data is collected and generated into a text file in template format by connecting to the database table and reading the table. This is for direct use and storage of data collection.
[0090] This embodiment uses the advantages of scripting language and presets the stored field information in advance to pre-process the data and generate a format that meets the internal processing data to meet the business needs of the back-end data. Easy to learn: you can connect to business data by simply using the scripting language; High flexibility: the pre-data can be modified according to the advantages of the scripting language; Good maintainability: it can be used with simple modifications and adjustments; High reusability: it can be used in a variety of scenarios.
[0091] Figure 2 This is a structural diagram of a product business data processing device provided in this embodiment. The product business data processing device may include: a first acquisition module 210, a preprocessing module 220, a matching module 230, an integration module 240, a second acquisition module 250 and a storage module 260.
[0092] The first acquisition module 210 is used to acquire product business data, where the product business data is used to describe the collected upstream business data.
[0093] The preprocessing module 220 is used to preprocess the product business data based on the preset data field template to obtain text business data. The preset data field template is used to constrain the data format of the product business data and the data separator in the product business data. The data separator is used to segment the product business data.
[0094] The matching module 230 is used to perform storage format matching on the text service data to obtain a target storage format corresponding to the text service data.
[0095] The integration module 240 is used to perform data integration on the text business data based on the target storage format corresponding to the text business data, and obtain target business data whose data storage format satisfies the target storage format.
[0096] The second acquisition module 250 is used to acquire a target database corresponding to the target storage format.
[0097] The storage module 260 is used to store the target business data in the target database.
[0098] Among them, the target database is one of the following: a first database, a second database and a third database. The first database is used to describe the storage of full data, the second database is used to describe the storage of analysis data, and the third database is used to describe the storage of index data. There is a data index association between the third database and the first database.
[0099] In this embodiment, optionally, the text service data corresponds to an attribute tag.
[0100] The matching module 230 is specifically used for:
[0101] The attribute tags corresponding to the text business data are matched with the format tags corresponding to each preset storage format for similarity; the preset storage format associated with a format tag with the highest matching degree with the attribute tags corresponding to the text business data is determined as the target storage format corresponding to the text business data.
[0102] In this embodiment, optionally, the second acquisition module 250 is specifically configured to:
[0103] Obtain a target storage field corresponding to a target storage format; combine the target storage field corresponding to the target storage format with the library storage field corresponding to each preset database, where the preset database is the first database, the second database, or the third database; determine that a preset database associated with a library storage field that satisfies a preset field condition after integration with the target storage field corresponding to the target storage format is the target database corresponding to the target storage format.
[0104] In this embodiment, optionally, the first acquisition module 210 is specifically configured to:
[0105] Determine the storage address of the original business data to be collected, the original business data is provided with a data end character; in the process of collecting the original business data from the storage address based on the preset collection method, detect the current collection character; if it is detected that the current collection character is the data end character, determine to obtain the product business data; wherein the preset collection method includes one of the following: interface call, file reading and database reading.
[0106] In this embodiment, optionally, it further includes: a first receiving module, a judging module, a third acquiring module and a first sending module.
[0107] The first receiving module is used to receive a data content query request corresponding to target service data sent by a user equipment.
[0108] The judgment module is used to respond to the data content query request and judge whether the sending time point of the data content query request is in the data query period corresponding to the target business data.
[0109] The third acquisition module is used to acquire the target business data from the first database if the sending time point of the data content query request is within the data query period corresponding to the target business data.
[0110] The first sending module is used to send target service data to the user equipment.
[0111] In this embodiment, optionally, it also includes: a second sending module.
[0112] The second sending module is used to send query prompt information to the user device if the sending time point of the data content query request is not in the data query time period corresponding to the target business data, and the query prompt information is used to inform the user device that the data content query of the target business data cannot be performed at present; send the data query time period corresponding to the target business data to the user device.
[0113] In this embodiment, optionally, it further includes: a second receiving module, a searching module, a query module and a third sending module.
[0114] The second receiving module is used to receive an index content query request corresponding to the target service data sent by the user equipment.
[0115] The search module is used to search the business data index in the first database corresponding to the target business data from the third database in response to the index content query request.
[0116] The query module is used to query the first database based on the business data index to obtain the index content corresponding to the business data index.
[0117] The third sending module is used to send the index content corresponding to the service data index to the user equipment.
[0118] The device for processing product business data provided in the present disclosure can execute the above method embodiments. Its specific implementation principles and technical effects can be found in the above method embodiments, and the present disclosure will not repeat them here.
[0119] The present application also provides a computer device. Figure 3 , Figure 3 This is a basic structural block diagram of the computer device in this embodiment.
[0120] The computer device includes a memory 310 and a processor 320 that are connected to each other through a system bus. It should be noted that the figure only shows a computer device with a memory 310 and a processor 320, but it should be understood that it is not required to implement all the components shown, and more or fewer components can be implemented instead. Among them, those skilled in the art can understand that the computer device here is a device that can automatically perform numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes but is not limited to microprocessors, application specific integrated circuits (Application Specific Integrated Circuit, ASIC), programmable gate arrays (Field-Programmable Gate Array, FPGA), digital processors (Digital Signal Processor, DSP), embedded devices, etc.
[0121] Computer devices can be computing devices such as desktop computers, notebooks, PDAs, and cloud servers. Computer devices can interact with users through keyboards, mice, remote controls, touch pads, or voice control devices.
[0122] The memory 310 includes at least one type of readable storage medium, and the readable storage medium includes a non-volatile memory or a volatile memory, for example, a flash memory, a hard disk, a multimedia card, a card-type memory (for example, an SD or DX memory, etc.), a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), a programmable read-only memory (PROM), a magnetic memory, a magnetic disk, an optical disk, etc., and the RAM may include a static RAM or a dynamic RAM. In some embodiments, the memory 310 may be an internal storage unit of a computer device, for example, a hard disk or a memory of the computer device. In other embodiments, the memory 310 may also be an external storage device of the computer device, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, or a flash card (FlashCard) equipped on the computer device. Of course, the memory 310 may also include both the internal storage unit of the computer device and its external storage device. In this embodiment, the memory 310 is generally used to store the operating system and various application software installed on the computer device, such as the program code of the above method. In addition, the memory 310 may also be used to temporarily store various data that have been output or are to be output.
[0123] The processor 320 is generally used to perform the overall operation of the computer device. In this embodiment, the memory 310 is used to store program codes or instructions, the program code includes computer operation instructions, and the processor 320 is used to execute the program codes or instructions stored in the memory 310 or process data, such as running the program code of the above method.
[0124] In this article, the bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. The bus system can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
[0125] Another embodiment of the present application also provides a computer-readable medium, which may be a computer-readable signal medium or a computer-readable medium. A processor in a computer reads a computer-readable program code stored in the computer-readable medium, so that the processor can execute the functional actions specified in each step or a combination of steps in the above method; and generate a device for implementing the functional actions specified in each block or a combination of blocks in the block diagram.
[0126] Computer-readable media include but are not limited to electronic, magnetic, optical, electromagnetic, infrared memory or semiconductor systems, devices or apparatuses, or any appropriate combination of the foregoing, the memory is used to store program codes or instructions, the program codes include computer operating instructions, and the processor is used to execute the program codes or instructions of the above methods stored in the memory.
[0127] For the definitions of memory and processor, please refer to the description of the aforementioned computer device embodiment and will not be repeated here.
[0128] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of modules or units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0129] Each functional unit or module in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0130] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) or a processor (processor) to perform all or part of the steps of each embodiment method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), disk or optical disk and other media that can store program code.
[0131] In the claims, any reference symbols placed between brackets shall not be construed as limiting the claims. The word "comprising" described in the present application does not exclude the presence of elements or steps not listed in the claims. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The present application can be implemented with the aid of hardware comprising several different elements and with the aid of a suitably programmed computer. In a unit claim that lists a number of devices, several units of these devices may be embodied by the same hardware item. The use of first, second, and third, etc. does not indicate any order, and these words may be interpreted as names. The steps in the above embodiments, unless otherwise specified, should not be understood as limitations on the order of execution.
[0132] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for processing product business data, characterized in that: include: Acquire product business data, where the product business data is used to describe the collected upstream business data; Preprocessing the product business data based on a preset data field template to obtain text business data, wherein the preset data field template is used to constrain the data format of the product business data and a data separator in the product business data, and the data separator is used to segment the product business data; Performing storage format matching on the text service data to obtain a target storage format corresponding to the text service data; Based on the target storage format corresponding to the text business data, data integration is performed on the text business data to obtain target business data whose data storage format satisfies the target storage format; Acquire a target database corresponding to the target storage format; storing the target business data in the target database; Among them, the target database is one of the following: a first database, a second database and a third database, the first database is used to describe the storage of full data, the second database is used to describe the storage of analysis data, the third database is used to describe the storage of index data, and there is a data index association between the third database and the first database.
2. The method according to claim 1, characterized in that: The text service data corresponds to an attribute tag; The performing storage format matching on the text service data to obtain a target storage format corresponding to the text service data includes: Performing similarity matching between the attribute tag corresponding to the text service data and the format tag corresponding to each preset storage format; A preset storage format associated with a format tag having the highest matching degree with the attribute tag corresponding to the text service data is determined as the target storage format corresponding to the text service data.
3. The method according to claim 1, characterized in that The obtaining of the target database corresponding to the target storage format includes: Obtaining a target storage field corresponding to the target storage format; Combining the target storage field corresponding to the target storage format with the library storage field corresponding to each preset database, the preset database being the first database, the second database, or the third database; A preset database associated with a library storage field that satisfies a preset field condition after integration with the target storage field corresponding to the target storage format is determined as the target database corresponding to the target storage format.
4. The method according to claim 1, characterized in that: The obtaining of product business data includes: Determine a storage address of the original business data to be collected, wherein the original business data is provided with a data end character; In the process of collecting the original business data from the storage address based on the preset collection method, detecting the current collection character; If it is detected that the current collection character is the data end character, it is determined that the product business data is obtained; The preset collection method includes one of the following: interface call, file reading and database reading.
5. The method according to claim 1, characterized in that When the target database is the first database, the target business data corresponds to a data query period; After storing the target business data in the target database, the method further includes: Receiving a data content query request corresponding to the target service data sent by a user device; In response to the data content query request, determining whether a sending time point of the data content query request is within a data query period corresponding to the target service data; If the sending time point of the data content query request is within the data query period corresponding to the target service data, acquiring the target service data from the first database; Sending the target service data to the user equipment.
6. The method according to claim 5, characterized in that After the step of responding to the data content query request and determining whether the sending time point of the data content query request is within the data query period corresponding to the target service data, the step further includes: If the sending time point of the data content query request is not within the data query period corresponding to the target service data, sending query prompt information to the user equipment, wherein the query prompt information is used to inform the user equipment that the data content query of the target service data cannot be performed currently; Sending a data query period corresponding to the target service data to the user equipment.
7. The method according to claim 1, characterized in that When the target database is the third database, after storing the target business data in the target database, the method further includes: Receiving an index content query request corresponding to the target service data sent by a user device; In response to the index content query request, searching the third database for a business data index corresponding to the target business data in the first database; Based on the business data index, query from the first database to obtain index content corresponding to the business data index; Sending the index content corresponding to the service data index to the user equipment.
8. A device for processing product business data, characterized in that: include: A first acquisition module is used to acquire product business data, where the product business data is used to describe the collected upstream business data; A preprocessing module, used for performing data preprocessing on the product business data based on a preset data field template to obtain text business data, wherein the preset data field template is used to constrain the data format of the product business data and the data separator in the product business data, and the data separator is used to segment the product business data; A matching module, used for performing storage format matching on the text service data to obtain a target storage format corresponding to the text service data; An integration module, configured to integrate the text service data based on the target storage format corresponding to the text service data, and obtain target service data whose data storage format satisfies the target storage format; A second acquisition module, used to acquire a target database corresponding to the target storage format; A storage module, used for storing the target business data in the target database; Among them, the target database is one of the following: a first database, a second database and a third database, the first database is used to describe the storage of full data, the second database is used to describe the storage of analysis data, the third database is used to describe the storage of index data, and there is a data index association between the third database and the first database.
9. A computer device, characterized in that: The method comprises a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the method for processing product business data as claimed in any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for processing product business data as claimed in any one of claims 1 to 7 is implemented.
