Data processing method and device, electronic equipment and storage medium
By detecting user operation behavior and preloading related data, the problem of data loading time in traditional rendering methods is solved, the rendering efficiency and user experience are improved, and more efficient data processing is achieved.
Patent Information
- Application Number
- CN202410965826.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-18
- Publication Date
- 2024-11-12
AI Technical Summary
Traditional rendering methods require frequent acquisition of data from data sources when acquiring data, resulting in too long data loading time, affecting rendering efficiency and user experience, especially in scenarios where data volume is large or network signal is poor.
By detecting user operation behavior, preloading data related to historical operation behavior, and deciding whether to preload data based on preload attributes, reducing unnecessary data processing and rendering, and improving rendering efficiency.
It reduces data loading time, improves rendering efficiency and user experience, reduces the demand for network bandwidth and storage space, and improves the overall performance of the system.
Smart Images

Figure CN118939360A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a data processing method, device, electronic equipment and storage medium. Background Art
[0002] In many application scenarios, it is necessary to frequently display complex charts or dynamic data and other information to users, which requires the system to have high rendering capabilities.
[0003] The traditional rendering method is to obtain data from the corresponding data source and perform rendering processing when receiving a user request. However, each rendering process needs to obtain data from the data source, which not only requires repeated operations, but also causes a long data loading time when the amount of data to be obtained is too large or the network signal is poor, resulting in low rendering efficiency and affecting the user experience. Summary of the invention
[0004] The present invention provides a data processing method, device, electronic equipment and storage medium, which realize data preloading processing and improve rendering efficiency.
[0005] According to one aspect of the present invention, there is provided a data processing method, the method comprising:
[0006] When detecting that the target interface is displayed, obtaining at least one historical operation behavior of the target user in the target interface and data to be processed corresponding to the at least one historical operation behavior;
[0007] For the historical operation behavior, the preload attribute of the historical operation behavior is determined according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data;
[0008] Based on the preloaded attributes corresponding to at least one historical operation behavior, the target historical operation behavior is determined, and the target data corresponding to the target historical operation behavior is preloaded, so that when it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed based on the target data corresponding to the target historical operation behavior and the target rendering description information.
[0009] According to another aspect of the present invention, there is provided a data processing device, the device comprising:
[0010] A data acquisition module, used to acquire at least one historical operation behavior of the target user in the target interface and the to-be-processed data corresponding to the at least one historical operation behavior when detecting that the target interface is displayed;
[0011] A preload attribute determination module, for determining the preload attribute of the historical operation behavior according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data;
[0012] An interface display module is used to determine the target historical operation behavior based on the preloaded attributes corresponding to at least one historical operation behavior, and preload the target data corresponding to the target historical operation behavior, so that when it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed based on the target data corresponding to the target historical operation behavior and the target rendering description information.
[0013] According to another aspect of the present invention, there is provided an electronic device, the electronic device comprising:
[0014] at least one processor; and
[0015] a memory communicatively connected to at least one processor; wherein,
[0016] The memory stores a computer program that can be executed by at least one processor. The computer program is executed by at least one processor so that the at least one processor can execute the data processing method of any embodiment of the present invention.
[0017] According to another aspect of the present invention, a computer-readable storage medium is provided. The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement the data processing method of any embodiment of the present invention when executed.
[0018] The technical solution of the embodiment of the present invention provides data support for the subsequent determination of the preload attributes of each historical operation behavior by acquiring at least one historical operation behavior of the target user in the target interface and the to-be-processed data corresponding to the at least one historical operation behavior when the target interface is detected. For the historical operation behavior, the preload attribute of the historical operation behavior is determined according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data. Based on this, it is convenient to provide accurate preload data for the user. According to the preload attribute corresponding to at least one historical operation behavior, the target historical operation behavior is determined, and the target data corresponding to the target historical operation behavior is preloaded, thereby improving the data loading efficiency. When it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed according to the target historical data corresponding to the target historical operation behavior and the target rendering description information. The present invention solves the problem of low rendering efficiency caused by long data loading time in the prior art. By analyzing the operation behavior of the target user, the corresponding target data is accurately obtained and preloaded. Not only the data loading time is reduced, but also the data rendering efficiency is improved, and the user experience is improved.
[0019] It should be understood that the contents described in this section are not intended to identify the key or important features of the embodiments of the present invention, nor are they intended to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0021] Figure 1 is a flow chart of a data processing method provided by an embodiment of the present invention;
[0022] Figure 2 is a flow chart of a method for determining target cache information provided by an embodiment of the present invention;
[0023] Figure 3 is a structural schematic diagram of a data processing device provided by an embodiment of the present invention;
[0024] Figure 4 It is a structural schematic diagram of an electronic device for implementing the data processing method of an embodiment of the present invention. DETAILED DESCRIPTION
[0025] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0026] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0027] Embodiment 1
[0028] Figure 1 It is a flowchart of a data processing method provided in the first embodiment of the present invention. This embodiment can be applied to any situation where data preloading processing is performed on the target interface so as to directly perform rendering processing when the corresponding trigger operation is detected. The embodiment of the present invention can be implemented through the Avalonia framework, and can also be implemented through other front-end frameworks. The method can be executed by a data processing device, which can be implemented in the form of hardware and / or software, and the data processing device can be configured in an electronic device such as a mobile phone, a computer or a server. Figure 1 As shown, the method includes:
[0029] S110. When it is detected that the target interface is displayed, obtaining at least one historical operation behavior of the target user in the target interface and data to be processed corresponding to the at least one historical operation behavior.
[0030] The target interface can be understood as the page that the current user is accessing. The current user is the target user. The historical operation behavior can be the operation that the target user has performed in the target interface before. Optionally, the target user can perform various operations in the target interface, and these operations are historical operation behaviors. For example, the historical operation behavior can be clicking on the controls in the target interface, browsing the target interface, and submitting the form data in the target interface. The data to be processed can be data associated with the historical operation behavior. Optionally, the data to be processed can be data required to trigger or execute the target demand corresponding to the historical operation behavior.
[0031] Specifically, when the target interface is detected and displayed, at least one historical operation behavior of the target user in the target interface and the to-be-processed data corresponding to the historical operation behavior are obtained from the corresponding database or log file, thereby providing data basis for subsequent determination of the target historical operation behavior.
[0032] Exemplarily, a corresponding mechanism is set up to capture various historical operation behaviors of the target user in the target interface, such as clicking controls, browsing pages, and submitting forms, and these historical operation behaviors and pending data are recorded as UserActions. In this process, the integrity and accuracy of data collection are ensured to avoid missing important operation behaviors. Select a suitable data storage method, save the collected UserActions, and establish a corresponding data structure to manage the pending data. Based on this, when the target interface is detected to be displayed, the historical operation behaviors and pending data corresponding to the target interface can be quickly obtained.
[0033] S120: For the historical operation behavior, determine the preload attribute of the historical operation behavior according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data.
[0034] Among them, the storage type of the data to be processed can be cache storage and local storage. Cache storage can be understood as temporary storage for accelerating data access. In this embodiment, cache storage is to store the data to be processed in the target cache information. Local storage can be data storage of the running data on its corresponding storage device. Based on the above, the data to be processed can be divided into cache data and running execution data. The preload attribute can be understood as the preload evaluation value of the data to be processed. That is, the preload attribute is used to characterize the potential demand probability of the data to be processed corresponding to the historical operation behavior. The higher the preload attribute, the greater the potential demand probability of the data to be processed.
[0035] Specifically, for each historical operation behavior, a preset evaluation algorithm or model is used to evaluate and analyze the to-be-processed data and storage type corresponding to the historical operation behavior to determine the preload attribute corresponding to each historical operation behavior. It should be noted that when evaluating and analyzing the preload attribute, factors such as the browsing trend of the target user and the context information of the target interface may also be considered.
[0036] Optionally, determining the preloaded attributes of the historical operation behaviors according to the to-be-processed data corresponding to the historical operation behaviors and the storage type of the to-be-processed data includes: determining the transition probability between the historical operation behaviors based on the historical operation behaviors and the to-be-processed data corresponding to the historical operation behaviors; determining the behavior pattern indicator corresponding to the historical operation behaviors based on the transition probability and the to-be-processed data;
[0037] Based on the behavior pattern indicator and the storage type of the data to be processed, each historical operation behavior is evaluated to determine the preload attribute corresponding to each historical operation behavior.
[0038] The transition probability can be understood as the probability corresponding to the transition from the current historical operation behavior to another historical operation behavior. For example, the transition probability can be the probability of transitioning from historical operation behavior A to historical operation behavior B, or it can be the probability of transitioning from historical operation behavior B to historical operation behavior C. The behavior pattern indicator can be the indicator data summarized based on the historical operation behavior. For example, the behavior pattern indicator can include the frequency of target users visiting the target interface, the number of times the historical operation behavior occurs, the distribution of the target users' stay time on the target interface, etc.
[0039] Specifically, the preset behavior analysis algorithm is determined according to actual needs. Optionally, the preset behavior analysis algorithm can be a Markov chain algorithm. The preset behavior analysis algorithm is used to analyze the historical operation behavior of the target user and the data to be processed corresponding to the historical operation behavior, and determine the transition probability between each historical operation behavior. Based on the transition probability and the data to be processed, the behavior pattern indicator corresponding to the historical operation behavior is determined. Determine the storage type corresponding to the data to be processed in the target interface. According to the behavior model indicator and the storage type of the data to be processed, each historical operation behavior is evaluated to determine the probability value of the potential demand data corresponding to the historical operation behavior, that is, the preload attribute. Based on this, the target data to be preloaded can be determined according to the preload attribute.
[0040] Exemplarily, in combination with the above example, the preset behavior analysis algorithm is described as a Markov chain algorithm. If it is detected that the historical operation behaviors performed by the target user in the target interface are historical operation behavior A, historical operation behavior B, historical operation behavior C, historical operation behavior B, and historical operation behavior A, the transition probability between different historical operation behaviors is calculated by the Markov chain algorithm, such as the transition probability from historical operation behavior A to historical operation behavior B, the transition probability from historical operation behavior B to historical operation behavior C, etc. The transition probability and the data to be processed are input into the clustering algorithm to determine the behavior pattern indicators PatternIndicators corresponding to the historical operation behaviors according to the output results of the algorithm. For example, the behavior pattern indicators may include the target user's active time period, access frequency, number of occurrences of historical operation behaviors, and distribution of residence time. The behavior pattern indicators can be used to optimize the page layout of the target interface and provide a basis for preloading data. According to the behavior model indicators PatternIndicators and the storage type of the data to be processed, each historical operation behavior is evaluated to determine the probability value of the potential demand data corresponding to the historical operation behavior, that is, the preload attribute PotentialDemandProbability.
[0041] S130. Determine the target historical operation behavior based on the preloaded attributes corresponding to at least one historical operation behavior, and preload the target data corresponding to the target historical operation behavior, so that when it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed based on the target data corresponding to the target historical operation behavior and the target rendering description information.
[0042] The target data may be data corresponding to the target historical operation behavior. The target data may be data obtained from the corresponding cache. It can be understood that the to-be-processed data corresponding to the target historical operation behavior may be updated or changed, so the target data may be obtained from the target cache information. The target rendering description information may be description information after the target data is rendered. For example, the target rendering description information may be the display format of the target data.
[0043] Specifically, according to the preload attributes corresponding to each historical operation behavior and the preload evaluation threshold, the target historical operation behavior is determined from each historical operation behavior. The target data corresponding to the target historical operation behavior is preloaded, so that when it is detected that the trigger operation of the target user in the target interface is consistent with the target historical operation behavior, the target data corresponding to the target historical operation behavior and the target rendering description information are displayed in the target interface corresponding to the trigger operation.
[0044] Optionally, a target historical operation behavior is determined based on a preloading attribute corresponding to at least one historical operation behavior, including: for at least one historical operation behavior, based on the preloading attribute of the historical operation behavior and a preloading evaluation threshold, determining a comparison result corresponding to each historical operation behavior; based on each comparison result, determining a target historical operation behavior from the historical operation behaviors.
[0045] The preload evaluation threshold may be a pre-set standard value for evaluating the preload attribute. The comparison result may be the result of comparing the preload attribute with the preload evaluation threshold. For example, the comparison result may be that the preload attribute exceeds the preload evaluation threshold, or that the preload attribute does not exceed the preload evaluation threshold.
[0046] Specifically, a preloading evaluation threshold is set according to actual needs to determine whether to preload data based on the preloading evaluation threshold. The preloading attributes corresponding to each historical operation behavior are compared with the preloading evaluation threshold to determine the comparison results corresponding to each historical operation behavior. If the comparison result is that the preloading attribute exceeds the preloading evaluation threshold, the preloading operation is performed, and the target historical operation behavior is selected from the historical operation behaviors to preload data based on the target data of the target historical operation behavior. If the comparison result is that the preloading attribute does not exceed the preloading evaluation threshold, the preloading operation may not be performed temporarily, or one or more of the preloading attributes with the highest preloading attributes may be selected, and the corresponding historical operation behavior may be used as the target historical operation behavior to perform the preloading operation.
[0047] Exemplarily, in combination with the above example, an appropriate preloading evaluation threshold ThresholdValue is set according to actual needs. If the preloading attribute PotentialDemandProbability exceeds the preloading evaluation threshold ThresholdValue, the target historical operation behavior is determined from the historical operation behavior in order to perform the preloading operation. If the preloading attribute PotentialDemandProbability does not exceed the preloading evaluation threshold ThresholdValue, the preloading operation may not be performed temporarily. For example, based on the behavior pattern indicator that the target user frequently visits the target page and the data to be processed is cached data, the preloading attribute is determined to be 0.7. If the preloading evaluation threshold is 0.6, 0.7>0.6, the target historical operation behavior is determined from the historical operation behavior, so as to obtain the target data from the target cache information and perform data preloading.
[0048] Optionally, before preloading the target data corresponding to the target historical operation behavior, it also includes: taking the preloaded target data as a preloading task, evaluating system resources based on the preloading task, and obtaining an evaluation result, wherein the system resources include at least one of allocatable storage space and network bandwidth; and allocating system resources to the preloading task according to the evaluation result.
[0049] The allocatable storage space may be understood as the physical or logical space that can be used to store data or programs. The network bandwidth may be understood as the maximum rate of data transmission in a network connection. The evaluation result may be the result of how much system resources can be allocated to the preloading task.
[0050] Specifically, the preload target data is used as a preload task. System resources are evaluated according to the preload task to determine how much system resources can be allocated for the preload task. That is, the evaluation result is determined. Based on the evaluation result, system resources are allocated to the preload task. It should be noted that during the execution of the preload task, the execution progress of the preload task and the use of system resources can be continuously monitored to dynamically adjust the system resources according to demand, ensure the efficient execution of the preload task, and improve the overall performance of the system.
[0051] Exemplarily, the preloading target data is used as a preloading task, and currently available system resources are evaluated to determine how many system resources AllocatedResources can be allocated for the preloading task. The evaluation of system resources can be an evaluation of the computing power, storage space, and network bandwidth of the system. When the preloading task is created and started, appropriate system resources are allocated to the preloading task according to the evaluation results, such as allocating a certain CPU time slice, storage space, and part of the network bandwidth.
[0052] The technical solution of this embodiment, by obtaining at least one historical operation behavior of the target user in the target interface and the to-be-processed data corresponding to at least one historical operation behavior when detecting the display target interface, provides data support for the subsequent determination of the preload attribute of each historical operation behavior. For the historical operation behavior, the preload attribute of the historical operation behavior is determined according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data. Based on this, it is convenient to provide accurate preload data for the user. According to the preload attribute corresponding to at least one historical operation behavior, the target historical operation behavior is determined, and the target data corresponding to the target historical operation behavior is preloaded, thereby improving the data loading efficiency. When it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed according to the target historical data corresponding to the target historical operation behavior and the target rendering description information. The present invention solves the problem of low rendering efficiency caused by long data loading time in the prior art. By analyzing the operation behavior of the target user, the corresponding target data is accurately obtained and preloaded. Not only the data loading time is reduced, but also unnecessary data processing and rendering are avoided, the data rendering efficiency is improved, and the user experience is improved.
[0053] Embodiment 2
[0054] Figure 2 This is a flow chart of a method for determining target cache information provided by the second embodiment of the present invention. This embodiment is based on the above embodiment. Before obtaining the data to be processed, the target cache information can also be constructed to quickly locate and obtain the data to be processed through the target cache information. The specific implementation method can refer to the technical solution of this embodiment. Among them, the technical terms that are the same or corresponding to the above embodiment are not repeated here. Figure 2 As shown, the method includes:
[0055] S210: Acquire business data corresponding to each target interface in the target program and associated parameters associated with the business data.
[0056] The target program may be an application or business system that requires data preloading. For example, the target program may be an application for item recommendation and selection. The target interface may be a web interface or a mobile interface corresponding to the target program. Business data may be data associated with the target program. For example, if the target program is an application for item recommendation and selection, the business data may include item data, user selection data, and user information data. The associated parameters may be parameters associated with business data permissions, for example, the associated parameters may be access permissions for business data, validity periods for business data, etc.
[0057] Specifically, the business data corresponding to each target interface in the target program and the associated parameters associated with the business data are obtained so as to cache the business data and the associated parameters.
[0058] Exemplarily, the data range of the business data that needs to be classified and processed in the target program is obtained, and the business data can come from different data sources. For example, the business data can be obtained from database records, from the content of file records, or from data collected by sensors. And the associated parameters related to each business data are determined.
[0059] S220: Determine a data category corresponding to the business data, and set a data identifier for the business data based on the data category.
[0060] The data category may be a category determined according to factors such as different types of business data, different uses, and corresponding associations. For example, business data may be divided into item information data, user information data, and user selection information data. The data identifier may be a unique identifier for distinguishing different data categories. Optionally, the data identifier may be a number, a string, or other forms, and this embodiment does not limit the data identifier.
[0061] Specifically, according to the different types, different uses and corresponding associations of business data, the business data is analyzed to determine the data category corresponding to the business data. Data identifiers are assigned to the business data according to the data category. A mapping relationship between the data category and the data identifier of the business data is established to achieve rapid query and retrieval of business data based on the mapping relationship.
[0062] Exemplarily, the business data is analyzed according to factors such as the data characteristics and purpose of the business data to determine the analysis results. According to the analysis results, the data categories of the business data are clarified, and a data classification set DataCategories is established. For example, the business data can be divided into large categories such as user data, application data, and system data, and each large category is further subdivided into small data categories. A unique data identifier categoryID is assigned to each small data category category. A mapping table or data structure is established to associate the data category with the data identifier, and the association relationship is stored in the mapping table or data structure for fast query and retrieval. For example, taking the target program as an item selection program as an example, the data category of the business data can be item data, user personal information data, and user order data. The data identifier of the item data can be "PD001", and the data identifier of the user order data can be "OD001". By determining the data category and data identifier of the business data, the business data can be better managed and convenient for subsequent data processing. It should be noted that the set data category and data identifier can be recorded in the corresponding document so that relevant personnel can understand the meaning and purpose of the data category and category identifier of the business data. In addition, in the process of applying data categories and data identification, if there are areas that need improvement, the corresponding data categories or data identifications should be adjusted or updated in a timely manner.
[0063] S230: Determine target cache information based on the business data, data identifier, associated parameters, and rendering description information, so as to obtain to-be-processed data corresponding to at least one historical operation behavior based on the target cache information.
[0064] Among them, the rendering description information can be understood as pre-defined or set information or rules for describing how to convert business data into a visual format. Optionally, the rendering description information can be an HTML template, a CSS style, a JavaScript logic, or a rule defined in the server-side processing logic. The rendering description information can be used to determine how the business data is displayed in the target interface. The target cache information can be a data cache module for storing business data, data identifiers, associated parameters, and rendering description information.
[0065] Specifically, the business data, associated parameters, and rendering description information are stored correspondingly, and the above-mentioned stored information is associated with the data identifier to obtain the target cache information. Based on this, the business data, associated parameters, and rendering description information corresponding to the historical operation behavior can be obtained through the data identifier in the target cache information, that is, the to-be-processed data corresponding to the historical operation behavior can be obtained. Based on this, the business data in the target cache information can be quickly located and accessed, reducing the loading time of the business data and improving the system response speed.
[0066] Exemplarily, the target cache information is a cache dictionary CacheDictionary filled with data as an example for explanation. According to the business data data, the associated parameters parameters and the rendering description information renderedResult, a data cache structure DataCacheEntry is created, and the above data is stored in the data cache structure DataCacheEntry according to the preset storage method. Select a suitable data structure to build the cache dictionary CacheDictionary. The following is an example of the cache dictionary being a hash table, and the cache dictionary is initialized to ensure that it is empty. Determine the data identifier categoryID corresponding to each business data. The data identifier categoryID is used as the key and the corresponding data cache structure DataCacheEntry is used as the value to add it to the cache dictionary CacheDictionary, and the business data, data identifier, associated parameters and rendering description information are added to the cache dictionary one by one in the above manner, and the target cache information is obtained. For example, taking the business data as user information data as an example, the process of storing business data in the target cache information is explained. First, a data cache structure DataCacheEntry is created, the user information data is used as the content of the data field, the associated parameters are placed in the parameters field, and the possible pre-processed display format, that is, the rendering description information is placed in the renderedResult field. Then obtain the data identifier categoryID corresponding to the user information data, such as "UID001", and add DataCacheEntry as a value to the cache dictionary CacheDictionary in association with the "UID001" key, thereby obtaining the target cache information.
[0067] It should be noted that a cache expiration policy is established for the target cache information, for example, whether the business data in the target cache information is invalid is determined based on time or other conditions. A cache cleanup mechanism is set for the target cache information to prevent the cache from growing infinitely. A cache update policy is set to update and replace the business data in the target cache information.
[0068] Optionally, based on the target cache information, data to be processed corresponding to at least one historical operation behavior is obtained, including: for each historical operation behavior, determining the data category corresponding to the current historical operation behavior; based on the data identifier corresponding to the data category, determining the business data corresponding to the current historical operation behavior from the target cache information; and performing data preprocessing on the business data to obtain the data to be processed corresponding to the current historical operation behavior.
[0069] Among them, data preprocessing can be data cleaning, format conversion and other operations on business data. By preprocessing business data, the availability of business data can be guaranteed.
[0070] Specifically, for each historical operation behavior, determine the data category corresponding to the current historical operation behavior, and determine the corresponding data identifier based on the data category. Based on the data identifier, determine the business data corresponding to the data identifier from the target cache information, that is, the business data corresponding to the current historical operation behavior. Perform data preprocessing on the business data to obtain the data to be processed corresponding to the current historical operation behavior. Correspondingly, the rendering description information corresponding to the current historical operation behavior can also be determined through the data identifier. Based on this, it is convenient to determine the target data and the target rendering description information through the above method according to the data identifier of the target historical operation behavior after determining the target historical operation behavior, so as to quickly restore and render the target interface.
[0071] Exemplarily, in combination with the above example, the data category corresponding to the current historical operation behavior is determined to determine the corresponding data identifier categoryID according to the data category. In the target cache information CacheDicti-onary, the determined categoryID is used as the key to search to obtain the business data corresponding to the categoryID and the rendering description information corresponding to the business data, so as to facilitate the subsequent determination of the target data and the target rendering description information according to the data to be processed and the rendering description information. Thus, the target data and the target rendering description information are transmitted to the corresponding rendering module or rendering mechanism to render and display the target interface. Correspondingly, if the business data with the categoryID cannot be found, it can be obtained from the original data source. For example, taking the historical operation behavior as an example of displaying user personal information data, the data category is determined to be the user data category from the historical operation behavior, and the data identifier is determined to be "UID001". Search the business data and rendering description information with the key "UID001" in the cache dictionary CacheDictionary to obtain the data to be processed.
[0072] Optionally, after determining the target cache information, it also includes: monitoring the business data to determine monitoring information corresponding to the business data, wherein the monitoring information includes at least one of field change information and storage type change information of the business data; based on the monitoring information, determining an update strategy corresponding to the business data; and updating the business data based on the update strategy to obtain updated business data.
[0073] The monitoring information may be information about changes in business data monitored by a data monitoring mechanism. Optionally, the monitoring information may be at least one of field change information and storage type change information of business data. For example, the monitoring information may be that a field value of business data changes from "10" to "20". The update strategy may be a business data update method determined based on the current monitoring information. For example, if part of the business data changes, the business data of the changed part is updated; if the entire business data is replaced, a comprehensive update of the business data is performed.
[0074] Specifically, the business data is continuously monitored, and when any modification, addition, or deletion occurs in the monitored business data, the monitoring information corresponding to the business data is determined. The cache update operation is triggered by the monitoring information and the corresponding event mechanism. The update strategy for the corresponding business data is determined based on the monitoring information, so that the business data in the target cache information, the associated parameters corresponding to the business data, and the rendering description information are modified or updated based on the update strategy to obtain the updated business data, the updated associated parameters, and the updated rendering description information. It should be noted that in order to ensure the consistency of data updates, the updated business data can be marked to facilitate subsequent updates of the corresponding business data by other modules.
[0075] Exemplarily, the data monitoring frequency is set, for example, the business data is detected every 1 second or 5 seconds. When any modification, addition or deletion of the business data is detected. A notification signal is sent immediately. The event mechanism of cache update is triggered by the notification signal of data change. According to the event mechanism of cache update, the monitoring information is determined to clarify the specific data changes in the business data. For example, it is determined whether the field value in the business data has changed or the storage category has changed. According to the monitoring information, the corresponding update strategy is determined to update the business data, associated parameters and rendering description information based on the update strategy to obtain the updated business data, associated parameters and rendering description information. For example, when it is detected that the field value of a certain business data changes from "10" to "20", the cache update event mechanism is triggered, the corresponding position of the business data is determined from the target cache information, and the corresponding field value is updated to "20". Correspondingly, the associated parameters and rendering description information corresponding to the business data are synchronously updated.
[0076] Optionally, monitoring the business data and determining the monitoring information corresponding to the business data may also include: setting the monitoring object, that is, determining the business data to be monitored in each original data source and the corresponding system status parameters. For example, determining the business data in a specific database table or storage file and the corresponding network connection status and other information. Setting the frequency of monitoring the monitoring object, that is, monitoring the monitoring object once every preset time. For example, monitoring the business data once every 5 seconds. In the monitoring process summary, the current business data is obtained by reading the data interface, querying the database, or monitoring system events. Compare the current business data with the business data monitored last time, and analyze whether there is a data change to obtain the monitoring information. At the same time, the system status parameters are evaluated to determine whether the system status parameters are abnormal. If it is detected that the business data has changed or the system status parameters are abnormal, a monitoring signal is generated. Among them, the monitoring signal includes the monitoring information of the business data and the data identifier of the business data. Through the monitoring signal, the corresponding stored business data is determined from the target cache information, and the business data is updated to ensure the accuracy of the target cache information.
[0077] Optionally, the business data is updated based on the update strategy to obtain updated business data, including: updating the business data based on the update strategy to obtain the business data to be verified; performing data verification on the business data to be verified to obtain a data verification result; when the data verification result meets the preset conditions, obtaining the updated business data.
[0078] The business data to be verified may be the business data after preliminary update. To ensure the accuracy and completeness of the updated business data, the business data after preliminary update may be used as the business data to be verified for verification. The data verification result may be that the business data to be verified is successful, or that the business data to be verified is failed. The data verification result is set as a preset condition that the business data to be verified is successful, so that when the preset condition is met, the business data to be verified is used as the updated business data.
[0079] Specifically, the business data is updated through the update strategy to obtain the business data to be verified. The business data to be verified is subjected to data verification processing to determine the data verification result corresponding to the business data to be verified. When the data verification result is that the verification of the business data to be verified is successful, the business data to be verified is used as the updated business data. Optionally, the data verification processing can be performed by comparing with the original business data or by executing preset verification logic. It should be noted that during the business data update process, if it is detected that the business data is inconsistent or the business data fails to be written into the target cache information, corresponding error handling and recording are performed for subsequent investigation and modification.
[0080] The technical solution of this embodiment provides data support for the subsequent construction of target cache information by obtaining the business data corresponding to each target interface in the target program and the associated parameters associated with the business data. Determine the data category of the business data and set a data identifier for the business data based on the data category. The uniqueness and identifiability of the business data can be ensured by the data identifier. Based on the business data, data identifier, associated data and rendering description information, determine the target cache information to obtain the pending data corresponding to at least one historical operation behavior based on the target cache information. The target cache information can be used to quickly locate and obtain the pending data, reduce data acquisition time, and improve system response speed. In addition, it is convenient to directly determine the target data from the target cache information when preloading subsequent data, reduce frequent requests to the data source, reduce network load, further improve data loading efficiency, and enhance user experience.
[0081] Embodiment 3
[0082] Figure 3 Schematic diagram of the structure of a data processing device provided by Embodiment 3 of the present invention. Figure 3 As shown, the device includes: a data acquisition module 310 , a preload attribute determination module 320 and an interface display module 330 .
[0083] The data acquisition module 310 is used to acquire at least one historical operation behavior of the target user in the target interface and the to-be-processed data corresponding to the at least one historical operation behavior when the display target interface is detected; the preloading attribute determination module 320 is used to determine the preloading attributes of the historical operation behavior for the historical operation behavior according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data; the interface display module 330 is used to determine the target historical operation behavior according to the preloading attributes corresponding to at least one historical operation behavior, and preload the target data corresponding to the target historical operation behavior, so that when it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed according to the target data corresponding to the target historical operation behavior and the target rendering description information.
[0084] The technical solution of this embodiment, by obtaining at least one historical operation behavior of the target user in the target interface and the to-be-processed data corresponding to at least one historical operation behavior when detecting the display target interface, provides data support for the subsequent determination of the preload attributes of each historical operation behavior. For the historical operation behavior, the preload attributes of the historical operation behavior are determined according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data. Based on this, it is convenient to provide accurate preload data for the user. According to the preload attributes corresponding to at least one historical operation behavior, the target historical operation behavior is determined, and the target data corresponding to the target historical operation behavior is preloaded, thereby improving the data loading efficiency. When it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed according to the target historical data corresponding to the target historical operation behavior and the target rendering description information. The present invention solves the problem of low rendering efficiency caused by long data loading time in the prior art. By analyzing the operation behavior of the target user, the corresponding target data is accurately obtained and preloaded. Not only the data loading time is reduced, but also the data rendering efficiency is improved, and the user experience is improved.
[0085] On the basis of the above embodiment, optionally, the preloading attribute determination module includes: a transition probability determination unit, which is used to determine the transition probability between each historical operation behavior based on the historical operation behavior and the data to be processed corresponding to the historical operation behavior; a pattern indicator determination unit, which is used to determine the behavior pattern indicator corresponding to the historical operation behavior based on the transition probability and the data to be processed; and a behavior evaluation unit, which is used to evaluate each historical operation behavior based on the behavior pattern indicator and the storage type of the data to be processed, and determine the preloading attribute corresponding to each historical operation behavior.
[0086] Optionally, before the data acquisition module, the device also includes: a cache information determination module, which includes: an associated parameter acquisition unit, used to acquire the business data corresponding to each target interface in the target program and associated parameters associated with the business data; a data identification setting unit, used to determine the data category corresponding to the business data, and to set the data identification for the business data based on the data category; a cache information determination unit, used to determine the target cache information based on the business data, data identification, associated parameters and rendering description information, and to acquire the data to be processed corresponding to at least one historical operation behavior based on the target cache information.
[0087] Optionally, the cache information determination unit includes: a data category determination subunit, used to determine the data category corresponding to the current historical operation behavior for each historical operation behavior; a business data determination subunit, used to determine the business data corresponding to the current historical operation behavior from the target cache information based on the data identifier corresponding to the data category; a data preprocessing subunit, used to perform data preprocessing on the business data to obtain the data to be processed corresponding to the current historical operation behavior.
[0088] Optionally, the device also includes a cache update module, which includes: a monitoring information determination unit, used to monitor the business data and determine the monitoring information corresponding to the business data, wherein the monitoring information includes at least one of field change information of the business data and storage type change information; an update strategy determination unit, used to determine the update strategy corresponding to the business data based on the monitoring information; and a business data update unit, used to update the business data based on the update strategy to obtain updated business data.
[0089] Optionally, a business data update unit is used to update the business data based on the update strategy to obtain the business data to be verified; perform data verification on the business data to be verified to obtain a data verification result; when the data verification result meets the preset conditions, obtain the updated business data.
[0090] Optionally, the interface display module includes: a comparison result determination unit, used to determine, for at least one historical operation behavior, the comparison result corresponding to each historical operation behavior based on the preloading attributes of the historical operation behavior and a preloading evaluation threshold; and a target historical operation behavior determination unit, used to determine the target historical operation behavior from the historical operation behaviors based on each comparison result.
[0091] Optionally, the interface display module also includes: a resource evaluation unit, which is used to preload target data as a preloading task, evaluate system resources based on the preloading task, and obtain an evaluation result, wherein the system resources include at least one of allocatable storage space and network bandwidth; a resource allocation unit, which is used to allocate system resources to the preloading task according to the evaluation result.
[0092] The data processing device provided in the embodiment of the present invention can execute the data processing method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method.
[0093] Embodiment 4
[0094] Figure 41 is a schematic diagram of the structure of an electronic device provided in Embodiment 4 of the present invention. The electronic device 10 is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices (such as helmets, glasses, watches, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or required herein.
[0095] like Figure 4 As shown, the electronic device 10 includes at least one processor 11, and a memory connected to the at least one processor 11, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc., wherein the memory stores a computer program that can be executed by at least one processor, and the processor 11 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or the computer program loaded from the storage unit 18 to the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 can also be stored. The processor 11, the ROM 12, and the RAM 13 are connected to each other through a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.
[0096] A number of components in the electronic device 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a disk, an optical disk, etc.; and a communication unit 19, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0097] The processor 11 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 11 performs the various methods and processes described above, such as a data processing method.
[0098] In some embodiments, the data processing method may be implemented as a computer program, which is tangibly contained in a computer-readable storage medium, such as a storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on the electronic device 10 via the ROM 12 and / or the communication unit 19. When the computer program is loaded into the RAM 13 and executed by the processor 11, one or more steps of the data processing method described above may be performed. Alternatively, in other embodiments, the processor 11 may be configured to perform the data processing method in any other appropriate manner (e.g., by means of firmware).
[0099] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0100] The computer program for implementing the data processing method of the present invention can be written in any combination of one or more programming languages. These computer programs can be provided to a processor of a general-purpose computer, a special-purpose computer or other programmable data processing device, so that when the computer program is executed by the processor, the functions / operations specified in the flow chart and / or block diagram are implemented. The computer program can be executed entirely on the machine, partially on the machine, partially on the machine as a stand-alone software package and partially on a remote machine, or entirely on a remote machine or server.
[0101] Embodiment 5
[0102] Embodiment 5 of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer instructions, and the computer instructions are used to cause a processor to execute a data processing method, the method comprising:
[0103] When a target interface is detected for display, at least one historical operation behavior of the target user in the target interface and data to be processed corresponding to the at least one historical operation behavior are obtained; for the historical operation behavior, the preloading attribute of the historical operation behavior is determined according to the data to be processed corresponding to the historical operation behavior and the storage type of the data to be processed; according to the preloading attribute corresponding to at least one historical operation behavior, the target historical operation behavior is determined, and the target data corresponding to the target historical operation behavior is preloaded, so that when it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed according to the target data corresponding to the target historical operation behavior and the target rendering description information.
[0104] In the context of the present invention, a computer-readable storage medium may be a tangible medium that may contain or store a computer program for use by or in combination with an instruction execution system, device or equipment. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or equipment, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, 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 foregoing.
[0105] To provide interaction with a user, the systems and techniques described herein may be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or trackball) through which the user can provide input to the electronic device. Other types of devices may also be used to provide interaction with the user; for example, the feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form (including acoustic input, voice input, or tactile input).
[0106] The systems and techniques described herein may be implemented in a computing system that includes backend components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes frontend components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.
[0107] A computing system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The client and server relationship is generated by computer programs running on the corresponding computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system to solve the defects of difficult management and weak business scalability in traditional physical hosts and VPS services.
[0108] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.
[0109] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. A data processing method, characterized in that: include: When detecting that the target interface is displayed, obtaining at least one historical operation behavior of the target user in the target interface and the to-be-processed data corresponding to the at least one historical operation behavior; For the historical operation behavior, determining a preload attribute of the historical operation behavior according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data; According to the preloading attributes corresponding to the at least one historical operation behavior, the target historical operation behavior is determined, and the target data corresponding to the target historical operation behavior is preloaded, so that when it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed according to the target data corresponding to the target historical operation behavior and the target rendering description information.
2. The method according to claim 1, characterized in that: The determining of the preloading attribute of the historical operation behavior according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data includes: Determining the transition probability between each of the historical operation behaviors based on the historical operation behaviors and the to-be-processed data corresponding to the historical operation behaviors; Determining a behavior pattern indicator corresponding to the historical operation behavior based on the transition probability and the data to be processed; Based on the behavior pattern indicator and the storage type of the data to be processed, each of the historical operation behaviors is evaluated to determine the preload attribute corresponding to each of the historical operation behaviors.
3. The method according to claim 1, characterized in that Before obtaining the to-be-processed data corresponding to the at least one historical operation behavior, the method further includes: Acquire business data corresponding to each target interface in the target program and associated parameters associated with the business data; Determining a data category corresponding to the business data, and setting a data identifier for the business data based on the data category; Based on the business data, the data identifier, the associated parameters and the rendering description information, target cache information is determined to obtain to-be-processed data corresponding to the at least one historical operation behavior based on the target cache information.
4. The method according to claim 3, characterized in that The acquiring, based on the target cache information, data to be processed corresponding to the at least one historical operation behavior includes: For each of the historical operation behaviors, determine the data category corresponding to the current historical operation behavior; Based on the data identifier corresponding to the data category, determining the business data corresponding to the current historical operation behavior from the target cache information; The business data is preprocessed to obtain the data to be processed corresponding to the current historical operation behavior.
5. The method according to claim 3, characterized in that: After determining the target cache information, the method further includes: Monitoring the business data to determine monitoring information corresponding to the business data, wherein the monitoring information includes at least one of field change information and storage type change information of the business data; Based on the monitoring information, determining an update strategy corresponding to the business data; The service data is updated based on the update strategy to obtain updated service data.
6. The method according to claim 5, characterized in that The updating of the service data based on the update strategy to obtain updated service data includes: Based on the update strategy, the business data is updated to obtain the business data to be verified; Performing data verification processing on the business data to be verified to obtain a data verification result; When the data verification result meets the preset conditions, the updated business data is obtained.
7. The method according to claim 1, characterized in that The determining the target historical operation behavior according to the preloaded attribute corresponding to the at least one historical operation behavior includes: For the at least one historical operation behavior, determining a comparison result corresponding to each of the historical operation behaviors based on a preload attribute of the historical operation behavior and a preload evaluation threshold; Based on each of the comparison results, the target historical operation behavior is determined from the historical operation behaviors.
8. The method according to claim 1, characterized in that Before preloading the target data corresponding to the target historical operation behavior, the method further includes: preloading the target data as a preloading task, and evaluating system resources based on the preloading task to obtain an evaluation result, wherein the system resources include at least one of an allocatable storage space and a network bandwidth; The system resources are allocated to the preloading task according to the evaluation result.
9. A data processing device, characterized in that: include: A data acquisition module, configured to acquire, when detecting that a target interface is displayed, at least one historical operation behavior of a target user in the target interface and data to be processed corresponding to the at least one historical operation behavior; A preload attribute determination module, used to determine the preload attribute of the historical operation behavior according to the to-be-processed data corresponding to the historical operation behavior and the storage type of the to-be-processed data; An interface display module is used to determine the target historical operation behavior based on the preloaded attributes corresponding to the at least one historical operation behavior, and preload the target data corresponding to the target historical operation behavior, so that when it is detected that the trigger operation is the same as the target historical operation behavior, the display interface corresponding to the trigger operation is displayed based on the target data corresponding to the target historical operation behavior and the target rendering description information.
10. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can perform the data processing method according to any one of claims 1 to 8.
Citation Information
Cited By
Task processing method and device, computer equipment and storage medium
CN119603364A
