Data processing method and device, computing equipment and storage medium

By intercepting the query result set and using annotation to configure processing strategies and configuration objects, and calling the target functional components for data format processing, the problems of data format processing complexity and repeated development are solved, and efficient and flexible data processing and format conversion are achieved.

CN119248980APending Publication Date: 2025-01-03BEIJING JINGDONG QIANSHITECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310808141.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-07-03
Publication Date
2025-01-03

AI Technical Summary

Technical Problem

In the prior art, data format processing is complex and difficult to maintain, and the data display format requirements of different business systems are different, resulting in duplicate development and waste of resources.

Method used

By intercepting the query result set, using annotations to configure processing policies and configuration objects, calling target functional components for data format processing, realizing data return in the target format, avoiding the coupling between business logic code and processing policy, and introducing a unified format processing strategy to Adapt to different business needs.

Benefits of technology

Reduces data processing complexity and maintenance difficulty, improves processing efficiency, avoids duplicate development, improves development efficiency, and improves flexibility to meet the format requirements of different business systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119248980A_ABST
    Figure CN119248980A_ABST
Patent Text Reader

Abstract

The invention provides a data processing method and device, computing equipment and a storage medium, and relates to the technical field of computers. The method comprises the following steps: intercepting a query result set; according to a processing strategy and a configuration object, processing data in the intercepted query result set to obtain first return data in a target format; the processing strategy is obtained by calling a target function component and is configured in the business logic code aiming at the target format in an annotation manner, the target function component comprises format processing strategies aiming at various data format requirements, the configuration object is used for indicating a processing object of the processing strategy, and the configuration object corresponds to the processing strategy. According to the method and the device, the problems of high complexity and high maintenance difficulty of data format processing and low development efficiency and resource waste caused by repeated development of different services in related technologies can be solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, and in particular to a data processing method and apparatus, a computing device, and a storage medium. Background Art

[0002] Different business systems have different format requirements for the data format returned by queries, such as displaying some indicators in percentages, accuracy requirements for some indicators, sorting requirements, and other business-specific requirements.

[0003] The current processing method is to process the data format in the business code before returning the query data to the client. However, the amount of data in a single table can reach more than 100 million, and it also contains hundreds of indicators, and the processing rules for different indicators are inconsistent. This makes the data format processing complex and difficult to maintain; and there is repeated development of the same rules for different businesses, resulting in low development efficiency and waste of resources.

[0004] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present disclosure, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention

[0005] The purpose of the embodiments of the present disclosure is to provide a data processing method and apparatus, a computing device, and a storage medium, thereby solving to a certain extent the problems of high complexity of data format processing, high maintenance difficulty, low development efficiency, and waste of resources due to repeated development of different businesses in related technologies.

[0006] According to a first aspect of the present disclosure, a data processing method is provided, the method comprising: intercepting and processing a query result set, the query result set being a query result obtained in response to a data query request; processing the intercepted data in the query result set according to a processing strategy and a configuration object to obtain first return data in a target format; the processing strategy is obtained by calling a target functional component and configured in a business logic code for the target format with annotations, the target functional component including a format processing strategy for each data format requirement; the configuration object is used to indicate a processing object of the processing strategy, and the configuration object corresponds to the processing strategy.

[0007] Optionally, before processing the data in the query result set, the method also includes: performing field parsing on the intercepted query result set to obtain corresponding second return data, the second return data being data in the original data format of the query; generating corresponding processing identification information for the second return data; and caching the first return data corresponding to the second return data according to the processing identification information.

[0008] Optionally, before processing the data in the query result set, the method further includes: matching the processing identification information in cache data; in response to matching the processing identification information in the cache data, using the cache data corresponding to the processing identification information as the first return data.

[0009] Optionally, the method also includes: performing entity parsing on the second returned data to determine the corresponding entity type; storing the entity type and the corresponding query result set into a mapping container according to the processing identification information; processing the data in the query result set includes: searching for the corresponding entity type from the mapping container according to the processing identification information; and calling the corresponding assignment method to perform field assignment on the data in the corresponding query result set according to the entity type.

[0010] Optionally, the processing strategy includes multiple format processing strategies, and the processing of the data in the query result set includes: traversing the multiple format processing strategies according to the sorting of the multiple format processing strategies, and processing the data in the query result set; the sorting is determined according to the business associations corresponding to the multiple format processing strategies.

[0011] Optionally, the method also includes: determining a service entity based on attribute information of a target service, wherein the target service is a data processing service configured for a target format; calling processing logic of the target service based on the configuration object and the service entity to process data in the query result set, wherein the processing logic is used to convert the second return data into the first return data.

[0012] Optionally, the processing strategy includes a one-to-one corresponding policy enumeration and a policy implementation class, and the processing of the data in the query result set includes: determining the target policy enumeration in the annotation according to the configuration object; and converting the data in the query result set to the target format according to the target policy enumeration and the corresponding policy implementation class.

[0013] According to a second aspect of the present disclosure, a data processing device is provided, the device comprising: an interception module and a processing module, wherein the interception module is used to intercept and process the query result set, the query result set being the query result obtained in response to the data query request; the processing module is used to process the data in the intercepted query result set according to a processing strategy and a configuration object to obtain first return data in a target format; the processing strategy is obtained by calling a target functional component and configured in a business logic code for the target format with annotations, the target functional component comprising a format processing strategy for each data format requirement; the configuration object is used to indicate a processing object of the processing strategy, and the configuration object corresponds to the processing strategy.

[0014] According to a third aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the method described in any one of the above embodiments is implemented.

[0015] According to a fourth aspect of the present disclosure, a computing device is provided, comprising: one or more processors; and a storage device for one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors execute the method described in any one of the above embodiments.

[0016] According to a fifth aspect of the present disclosure, a computer program product is provided, including a computer program, wherein when the computer program is run on a computer, the computer executes the method described in any one of the above embodiments.

[0017] The exemplary embodiments of the present disclosure may have some or all of the following beneficial effects:

[0018] In the data processing method provided in the example implementation of the present disclosure, on the one hand, the processing strategy can be configured in the business logic code for the target format through annotations, and the data in the intercepted query result set can be processed according to the processing strategy and the configuration object to obtain the first return data in the target format, so that the business logic code is decoupled from the processing strategy, which reduces the difficulty of maintenance. At the same time, the complexity of data processing in the data query process can be reduced and the processing efficiency can be improved. On the other hand, by calling the pre-developed target function component including the format processing strategy for each data format requirement for format processing, the repeated development of different businesses is avoided, the development efficiency is improved, and the development resources are saved. In addition, the target format processing strategy is introduced by annotation, which is highly flexible and can be applied to the different format requirements of different business systems.

[0019] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.

[0021] Figure 1 One of the flowcharts of a data processing method according to an embodiment of the present disclosure is schematically shown.

[0022] Figure 2 A schematic diagram schematically shows the correspondence between configuration objects and processing strategies according to an embodiment of the present disclosure.

[0023] Figure 3 The diagram schematically shows a data processing process based on processing identification information according to an embodiment of the present disclosure.

[0024] Figure 4 A second flowchart of a data processing process according to another embodiment of the present disclosure is schematically shown.

[0025] Figure 5 The structure block diagram of a data processing device according to an embodiment of the present disclosure is schematically shown.

[0026] Figure 6 A block diagram of a computing device suitable for implementing embodiments of the present disclosure is shown. DETAILED DESCRIPTION

[0027] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as being limited to the examples set forth herein; on the contrary, these embodiments are provided so that the present disclosure will be more comprehensive and complete, and the concepts of the example embodiments are fully conveyed to those skilled in the art. The described features, structures, or characteristics may be combined in one or more embodiments in any suitable manner. In the following description, many specific details are provided to provide a full understanding of the embodiments of the present disclosure. However, those skilled in the art will appreciate that the technical solutions of the present disclosure may be practiced while omitting one or more of the specific details, or other methods, components, devices, steps, etc. may be adopted. In other cases, known technical solutions are not shown or described in detail to avoid obscuring various aspects of the present disclosure.

[0028] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.

[0029] The data processing method provided in the embodiment of the present application can be implemented on various business systems, and its execution subject may include an interactive system composed of a terminal and a back-end server. The terminal may be, but is not limited to, a mobile phone, a tablet computer, a personal computer (PC), a smart TV, and a client (Client) installed on any terminal device. The client may be a life service application, an instant messaging application, a social application, a shopping application, and the like. The server may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms, or a node in a blockchain.

[0030] The above-mentioned execution entity does not constitute a limitation of the present application. For the convenience of description, the embodiment of the present application is explained by taking the execution entity as a business system server involving data query as an example.

[0031] The data processing method disclosed in the embodiments of this specification is introduced below in conjunction with specific embodiments.

[0032] refer to Figure 1 As shown, a data processing method according to an exemplary embodiment of the present disclosure may include the following steps.

[0033] Step S110 , intercepting and processing the query result set, where the query result set is the query result obtained in response to the data query request.

[0034] Step S120, according to the processing strategy and the configuration object, the data in the intercepted query result set is processed to obtain the first return data in the target format; the processing strategy is obtained by calling the target functional component and configured in the business logic code for the target format with annotations, and the target functional component includes a format processing strategy for each data format requirement; the configuration object is used to indicate the processing object of the processing strategy, and the configuration object corresponds to the processing strategy.

[0035] In the data processing method provided in this example implementation, on the one hand, the processing strategy can be configured in the business logic code for the target format through annotations, and the data in the intercepted query result set can be processed according to the processing strategy and the configuration object to obtain the first return data in the target format, so that the business logic code is decoupled from the processing strategy, which reduces the difficulty of maintenance. At the same time, the complexity of data processing in the data query process can be reduced, and the processing efficiency can be improved. On the other hand, by calling the pre-developed target function component including the format processing strategy for each data format requirement for format processing, the repeated development of different businesses is avoided, the development efficiency is improved, and the development resources are saved. In addition, the target format processing strategy is introduced by annotation, which is highly flexible and can be applied to the different format requirements of different business systems.

[0036] The following describes each step of the present disclosure in more detail.

[0037] In step S110, the query result set is intercepted.

[0038] In this example implementation, the query result set is the query result obtained in response to the data query request. Exemplarily, in response to the user's operation on the business system of the client (such as product search, recommendation, etc.), a data query request is sent to the server, and the corresponding data is queried and obtained from the database according to the data query request to form a query result set. The data in the query result set can be the original data format obtained from the database. Before the query result set is returned to the client, the query result set is intercepted.

[0039] In step S120, the data in the intercepted query result set is processed according to the processing strategy and the configuration object to obtain first returned data in a target format.

[0040] In this example implementation, the target functional component is a pre-developed unified functional component that includes format processing strategies for various data format requirements. Different business systems can configure processing strategies through this functional component. For example, the processing strategy can be obtained by calling the target functional component, and then configured in the business logic code for the target format with annotations. The processing strategy of the target format can also be encapsulated in the annotation, and the annotation is configured in the data processing interface (business logic code) that needs to be converted to the target format. One or more strategy enumerations in the annotation can be selected according to business needs to form the processing strategy corresponding to the current target format, such as Figure 2 As shown, a configuration object may correspond to a processing strategy. A configuration object may include multiple configurations, such as configurations 1, 2, and 3. Each configuration may be for an indicator or a field, and each configuration may correspond to a policy enumeration.

[0041] In this example implementation, the target format refers to the data display format of the business system. The target format may include one or more of the formats regarding data accuracy requirements, whether it needs to be displayed after being expanded by a certain multiple (such as 100), ranking formats, formats that do not need to display null values ​​for certain fields, and formats with different sorting rules for different indicators, etc. This example does not limit this. Each display format will correspond to a corresponding processing strategy, for example, accuracy processing strategy, whether it needs to be returned after multiplying by 100, ranking strategy, null data replacement strategy, sorting rule strategy, etc. Commonly used processing strategies can be encapsulated in the target function component for invocation by different business systems.

[0042] In this example implementation, the configuration object is used to indicate the processing object of the processing strategy. The configuration object can be set according to business needs. For example, the configuration object can be at the indicator level or field level. The indicator can be customized according to different business needs. For example, in each application store, the daily order volume, the order volume growth rate in a specified time period, the number of returns, and the number of complaint orders can all be set as indicators. The field level can be to use the object containing the specified field as the processing object. For example, if the gender field is configured to 1 (representing female), all data in the query result set with the gender field being 1 need to be processed by the corresponding processing strategy.

[0043] Exemplarily, the processing strategy may include a one-to-one corresponding policy enumeration and a policy implementation class, and the data in the query result set is processed, including: determining the target policy enumeration in the annotation according to the configuration object.

[0044] In this example implementation, if Figure 2 As shown, a configuration item may correspond to a policy enumeration, and a policy enumeration may correspond to a policy implementation class. That is, the corresponding policy enumeration (target policy enumeration) may be determined according to the configuration object.

[0045] According to the target policy enumeration and the corresponding policy implementation class, the data in the query result set is converted to the target format.

[0046] In this example implementation, target policy enumerations may be nested with each other to form a processing policy, and the corresponding policies may be used to implement layer-by-layer processing of classes to achieve conversion processing of the target format.

[0047] In some embodiments, the processing strategy includes multiple format processing strategies, and the data in the query result set is processed, including: according to the sorting of the multiple format processing strategies, traversing the multiple format processing strategies, and processing the data in the query result set; the sorting is determined according to the business associations corresponding to the multiple format processing strategies.

[0048] In this example implementation, the format processing strategy may be a processing strategy for a certain format requirement, such as a format processing strategy for precision requirements, a format processing strategy that requires a certain multiple (such as 100) expansion, a format processing strategy for ranking display, etc. A processing strategy may include multiple format processing strategies, and there may be business associations between different format processing strategies, for example, there is a business association between expansion by a certain multiple and precision requirements, there is a business association between precision requirements and rankings, etc. The strategy corresponding to expansion by a certain multiple will affect the precision requirement result, and the precision requirement result will affect the ranking result. Accordingly, the ranking result of the three is: the strategy corresponding to expansion by a certain multiple>the strategy corresponding to the precision requirement>the strategy corresponding to the ranking.

[0049] For example, the format requirement of a processing strategy is to enlarge the display by 100 times and the display precision requirement is to retain three decimal places. Since the format display of the enlarged multiple will affect the precision format requirement result, the precision format processing strategy needs to be placed after the enlarged multiple format processing strategy to avoid the latter's influence on the former.

[0050] In some embodiments, the format conversion may also be performed by means of a customized service, that is, the method further includes: determining a service entity according to attribute information of the target service.

[0051] In this example implementation, the target service is a data processing service configured for the target format, and the service may be a user-defined service to increase the flexibility of policy configuration. The attribute information of the target service may include one or more of a service name, a service identifier, and a service category. For example, the service entity corresponding to the target service may be determined based on the service name of the target service. The service entity refers to the entity object defined by different business entities involved in the service, such as orders, commodities, etc.

[0052] According to the configuration object and the service entity, the processing logic of the target service is called to process the data in the query result set, and the processing logic is used to convert the second return data into the first return data.

[0053] In this example implementation, the data to be processed corresponding to the service entity and the configuration object can be determined in the query result set, and then the processing logic of the target service (i.e., the dataProcess method in the service) is called to perform format conversion on the data to be processed, so as to convert the second return data in the original data format into the first return data in the target format.

[0054] In some embodiments, before processing the data in the query result set, refer to Figure 3 , the method also includes the following steps S310-S370.

[0055] Step S310, performing field parsing on the intercepted query result set to obtain corresponding second returned data.

[0056] In this example implementation, the second return data is data in the original data format queried from the database. The query data, i.e., the query result set, can be encapsulated into a specified format, for example, encapsulated into a Response abstract object, and the Response is field parsed to obtain the content of the data field, which is the second return data.

[0057] Step S320: Generate corresponding processing identification information for the second returned data.

[0058] In this example implementation, a unique processing identification information (such as dataProcessID) can be generated for the second return data of the query result set of each data query request to distinguish different query result sets. The processing identification information can be generated based on the query index, query date, etc., which is not limited in this example.

[0059] Step S330: caching the first returned data corresponding to the second returned data according to the processing identification information.

[0060] In this example implementation, the processing identification information may be used as a key to cache the second returned data, so as to facilitate subsequent direct matching from the cache.

[0061] Step S340, matching the processing identification information in the cache data.

[0062] In this example implementation, the cache data uses the processing identification information as a key for data storage, so the current processing identification information can be directly searched in the cache data to speed up the data matching process.

[0063] Step S350, determine whether the processing identification information is matched in the cache data, if so, go to step S360, otherwise go to step S370.

[0064] Step S360: Use the cache data corresponding to the processing identification information as the first returned data.

[0065] In this example implementation, when the match is successful, it means that the first return data in the target format exists in the cache, and the matching result is directly used as the final return data and returned to the client.

[0066] Step S370, obtaining a processing strategy and a configuration object, and processing the data in the intercepted query result set to obtain first returned data in a target format.

[0067] In this example implementation, when the match fails, it means that the same format processing of the same data has not been performed before, and the data processing can be performed by calling the target functional component, configuring the processing object and the processing strategy.

[0068] The above embodiments can avoid repeated calculations of the same processing process for the same data, thereby reducing calculation complexity and improving processing efficiency.

[0069] In some embodiments, the method further includes: performing entity parsing on the second returned data to determine a corresponding entity type.

[0070] In this example implementation, different parsing strategies can be configured for different entity types, and the configured parsing strategy is used to perform entity parsing on the second return data to determine the data type, and then the entity type is determined by reflection, that is, the entity bean. The entity bean is a persistent object that can be stored on a persistent storage medium. Entity beans are often used to represent permanent data and provide methods for operating these data. Generally, an entity bean corresponds to a table in the database, and an instance of an entity class corresponds to a record in this table. The entity type can be a Map, List, or a custom user class, which is not limited in this example.

[0071] According to the processing identification information, the entity type and the corresponding query result set are stored in the mapping container.

[0072] In this example implementation, the processing identification information may be used as an index to store the mapping relationship between the corresponding entity type and the query result set into the mapping container.

[0073] The data in the query result set is processed, including: searching for a corresponding entity type from a mapping container according to the processing identification information; and assigning a field value to the data in the corresponding query result set by calling a corresponding assignment method according to the entity type.

[0074] In this example implementation, different entity types may correspond to different field assignment methods (such as set methods). In the process of data processing of the query result set, the entity type can be directly found from the mapping container, and the corresponding assignment method can be called based on the entity type to assign values ​​to each field in the processing process to complete the data processing process. Through this example method, the data processing process can be decoupled from the entity type parsing process of the query result set to avoid mutual interference between processes and improve processing efficiency.

[0075] For example, Figure 4 As shown, the data processing method of the present disclosure can be specifically implemented through the following steps S401-S408.

[0076] Step S401: The client sends a data query request to the server.

[0077] Step S402: the server executes a data query process based on the received data query request to obtain query results from the database to form a query result set.

[0078] Step S403: the server intercepts the query result set.

[0079] Step S404: the server performs field analysis on the interception object (query result set) to obtain corresponding second returned data.

[0080] Step S405: the server generates corresponding processing identification information for the second returned data.

[0081] Step S406, the server determines whether the processing identification information is matched in the cache data, if so, go to step S407, otherwise, go to step S408.

[0082] In step S407, the server takes the cached data corresponding to the processing identification information as the first returned data and proceeds to step S413.

[0083] Step S408: The server performs entity resolution on the second returned data to determine the corresponding entity type.

[0084] Step S409, the server stores the entity type and the corresponding query result set into a mapping container according to the processing identification information;

[0085] Step S410: the server searches for the corresponding entity type from the mapping container according to the processing identification information.

[0086] In step S411, the server processes the second return data according to the processing strategy, configuration object and entity type to obtain the first return data in the target format, and then proceeds to step S413.

[0087] In step S412, the server stores the first returned data into a cache according to the processing identification information, for use in step S406 to perform cache data matching on subsequent data processing.

[0088] Step S413: the server sends the first returned data to the client, so as to display the query data in the target format on the client.

[0089] In the above embodiments, before the business logic runs, the business system operation and maintenance or developers need to configure the processing object of the target format, that is, which part of the data needs to be displayed in the target format, and on the other hand, call the target function component for format processing, select the strategy enumeration from the target function component to form a processing strategy, and configure the processing strategy in the business logic code through annotations. The order of the steps in this example is only exemplary and can be adjusted accordingly according to actual needs.

[0090] The present invention aims to solve the problem of large amount of data in a single table queried in existing databases and different business systems having different requirements for the display format of query results, resulting in the problem of repeated business function development for data display formats in different business systems and the problem of high dimensional difficulty caused by the interference of the processing code for the data display format with the original business code.

[0091] On the one hand, the present invention develops a unified target functional component for data format conversion processing for different business systems, which can avoid the problem of repeated development of different business systems and improve development efficiency. On the other hand, by forming a one-to-one correspondence between the configuration object and the processing strategy, the processing strategy accurately processes the configuration object and ensures the accuracy of data processing; and it is configured in the business logic code in the form of annotations, which realizes the decoupling of data format processing and business logic and avoids mutual interference problems. In addition, the decoupling of entity type parsing and format processing logic improves processing efficiency.

[0092] Furthermore, in this exemplary embodiment, a data processing device 500 is also provided. The data processing device 500 can be applied to a server. Figure 5 As shown, the data processing device 500 may include: an interception module 510 and a processing module 520. The interception module 510 can be used to intercept and process a query result set, where the query result set is a query result obtained in response to a data query request; the processing module 520 can be used to process the data in the intercepted query result set according to a processing strategy and a configuration object to obtain first return data in a target format; the processing strategy is obtained by calling a target functional component and is configured in a business logic code for the target format with annotations, and the target functional component includes a format processing strategy for each data format requirement; the configuration object is used to indicate a processing object of the processing strategy, and the configuration object corresponds to the processing strategy.

[0093] In an exemplary embodiment of the present disclosure, the device 500 may also include: a first parsing module, which can be used to perform field parsing on the intercepted query result set before processing the data in the query result set, and obtain corresponding second return data, where the second return data is data in the original data format of the query; a generation module, which can be used to generate corresponding processing identification information for the second return data; and a cache module, which can be used to cache the first return data corresponding to the second return data according to the processing identification information.

[0094] In an exemplary embodiment of the present disclosure, the device 500 also includes: a matching module, which can be used to match processing identification information in cache data; in response to matching the processing identification information in the cache data, the cache data corresponding to the processing identification information is used as the first return data.

[0095] In an exemplary embodiment of the present disclosure, the device 500 also includes: a second parsing module, which can be used to: perform entity parsing on the second return data to determine the corresponding entity type; and store the entity type and the corresponding query result set into a mapping container based on the processing identification information.

[0096] The processing module 520 can also be used to: search for a corresponding entity type from a mapping container according to the processing identification information; and call a corresponding assignment method to perform field assignment on data in a corresponding query result set according to the entity type.

[0097] In an exemplary embodiment of the present disclosure, the processing strategy includes multiple format processing strategies, and the processing module 520 can also be used to: traverse the multiple format processing strategies according to the order of the multiple format processing strategies, and process the data in the query result set; the order is determined according to the business associations corresponding to the multiple format processing strategies.

[0098] In an exemplary embodiment of the present disclosure, the device 500 also includes: a service module, which can be used to: determine the service entity based on the attribute information of the target service, where the target service is a data processing service configured for the target format; call the processing logic of the target service based on the configuration object and the service entity to process the data in the query result set, and the processing logic is used to convert the second return data into the first return data.

[0099] In an exemplary embodiment of the present disclosure, the processing strategy includes a one-to-one corresponding policy enumeration and a policy implementation class, and the processing module 520 can also be used to: determine the target policy enumeration in the annotation according to the configuration object; and convert the data in the query result set to the target format according to the target policy enumeration and the corresponding policy implementation class.

[0100] The specific details of each module or unit in the above-mentioned data processing device have been described in detail in the corresponding data processing method, so they will not be repeated here.

[0101] As another aspect, the present application also provides a computer-readable medium, which may be included in the computing device described in the above embodiments; or may exist independently without being assembled into the computing device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a computing device, the computing device implements the method in the following embodiments. For example, the computing device may implement Figure 1 to Figure 4 The various process steps shown, etc.

[0102] It should be noted that the computer-readable medium shown in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.

[0103] Refer to the following Figure 6 hereinafter describes a computing device 600 according to such an embodiment of the present disclosure. Figure 6 The computing device 600 shown is only an example and should not bring any limitation to the functionality and scope of use of the embodiments of the present disclosure.

[0104] like Figure 6 As shown, the computing device 600 is in the form of a general computing device. The components of the computing device 600 may include, but are not limited to: at least one processing unit 610, at least one storage unit 620, a bus 630 connecting different system components (including the storage unit 620 and the processing unit 610), and a display unit 640.

[0105] The storage unit stores program codes, which can be executed by the processing unit 610, so that the processing unit 610 executes the steps according to various exemplary embodiments of the present disclosure described in the above “Exemplary Method” section of this specification.

[0106] The storage unit 620 may include a readable medium in the form of a volatile storage unit, such as a random access memory unit (RAM) 6201 and / or a cache memory unit 6202 , and may further include a read-only memory unit (ROM) 6203 .

[0107] The storage unit 620 may also include a program / utility 6204 having a set (at least one) of program modules 6205, such program modules 6205 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.

[0108] Bus 630 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.

[0109] The computing device 600 may also communicate with one or more external devices 670 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), may also communicate with one or more devices that enable a user to interact with the computing device 600, and / or communicate with any device that enables the computing device 600 to communicate with one or more other computing devices (e.g., routers, modems, etc.). Such communication may be performed via an input / output (I / O) interface 650. Furthermore, the computing device 600 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 660. As shown, the network adapter 660 communicates with other modules of the computing device 600 via a bus 630. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the computing device 600, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RA identification systems, tape drives, and data backup storage systems.

[0110] In an exemplary embodiment, a computer program product is also provided, which may include, for example, a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code; when the computer program product runs on a computer, the computer executes the method in the above embodiment.

[0111] Through the description of the above embodiments, it is easy for those skilled in the art to understand that the example embodiments described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the embodiment of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the embodiment of the present disclosure.

[0112] In addition, the above-mentioned figures are only schematic illustrations of the processes included in the method according to the exemplary embodiments of the present disclosure, and are not intended to be limiting. It is easy to understand that the processes shown in the above-mentioned figures do not indicate or limit the time sequence of these processes. In addition, it is also easy to understand that these processes can be performed synchronously or asynchronously, for example, in multiple modules.

[0113] It should be noted that, although the steps of the method in the present disclosure are described in a specific order in the drawings, this does not require or imply that the steps must be performed in the specific order, or that all the steps shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps, etc., which shall all be considered as part of the present disclosure.

[0114] It should be understood that the disclosure disclosed and defined in this specification extends to all alternative combinations of two or more individual features mentioned or evident in the text and / or the accompanying drawings. All these different combinations constitute multiple alternative aspects of the disclosure. The embodiments of this specification illustrate the best mode known for implementing the disclosure and will enable those skilled in the art to utilize the disclosure.

Claims

1. A data processing method, characterized in that: include: Intercepting a query result set, where the query result set is a query result obtained in response to a data query request; Processing the intercepted data in the query result set according to the processing strategy and the configuration object to obtain first returned data in a target format; The processing strategy is obtained by calling the target functional component and configured in the business logic code for the target format by annotation, and the target functional component includes the format processing strategy for each data format requirement; The configuration object is used to indicate the processing object of the processing strategy, and the configuration object corresponds to the processing strategy.

2. The data processing method according to claim 1, characterized in that: Before processing the data in the query result set, the method further includes: Performing field parsing on the intercepted query result set to obtain corresponding second returned data, where the second returned data is data in the original data format of the query; generating corresponding processing identification information for the second returned data; The first returned data corresponding to the second returned data is cached according to the processing identification information.

3. The data processing method according to claim 2, characterized in that: Before processing the data in the query result set, the method further includes: matching the processing identification information in the cache data; In response to matching the processing identification information in the cache data, the cache data corresponding to the processing identification information is used as the first returned data.

4. The data processing method according to claim 2, characterized in that: The method further comprises: Performing entity parsing on the second returned data to determine a corresponding entity type; According to the processing identification information, the entity type and the corresponding query result set are stored in a mapping container; The processing of the data in the query result set includes: According to the processing identification information, searching for a corresponding entity type from the mapping container; According to the entity type, the corresponding assignment method is called to perform field assignment on the data in the corresponding query result set.

5. The data processing method according to claim 1, characterized in that: The processing strategy includes a plurality of format processing strategies, and the processing of the data in the query result set includes: According to the order of the multiple format processing strategies, the multiple format processing strategies are traversed to process the data in the query result set; the order is determined according to the business associations corresponding to the multiple format processing strategies.

6. The data processing method according to claim 1, characterized in that: The method further comprises: Determining a service entity according to attribute information of a target service, wherein the target service is a data processing service configured for a target format; According to the configuration object and the service entity, the processing logic of the target service is called to process the data in the query result set, wherein the processing logic is used to convert the second returned data into the first returned data.

7. The data processing method according to claim 1 or 5, characterized in that: The processing strategy includes a one-to-one corresponding strategy enumeration and a strategy implementation class, and the processing of the data in the query result set includes: Determine, according to the configuration object, a target policy enumeration in the annotation; According to the target policy enumeration and the corresponding policy implementation class, the data in the query result set is converted to the target format.

8. A data processing device, characterized in that: The device comprises: An interception module, used to intercept and process the query result set, where the query result set is a query result obtained in response to a data query request; A processing module is used to process the intercepted data in the query result set according to the processing strategy and the configuration object to obtain the first return data in the target format; the processing strategy is obtained by calling the target functional component and is configured in the business logic code for the target format with annotations, and the target functional component includes a format processing strategy for each data format requirement; the configuration object is used to indicate the processing object of the processing strategy, and the configuration object corresponds to the processing strategy.

9. A computing device, characterized in that include: one or more processors; as well as A storage device for storing one or more programs, which, when executed by the one or more processors, enables the one or more processors to implement the method according to any one of claims 1 to 7.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.