Equipment detail page resource updating and pushing method, equipment and medium
Patent Information
- Application Number
- CN202510392581.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-31
- Publication Date
- 2025-07-25
AI Technical Summary
[0003]然而,目前的资源更新流程依赖于用户或运营人员手动修改设备型号与资源之间的映射关系
[0069] The method for updating and pushing device detail page resources provided by the present application, the device and the medium, by receiving the update information transmitted from the operation end, automatically identify the device models related to the updated resources, and compare the differences between the historical version and the new version to generate the resource information to be downloaded and the incremental update resources. These information will be automatically stored and associated with the device, thus greatly reducing manual operations, improving the efficiency of resource update, and ensuring that the device can obtain the latest resource information in a timely manner. Through the above update method, the workload of manually modifying the mapping relationship between the device model and the resource version is reduced, human errors are reduced, and the accuracy of the update is improved; by adopting the incremental update method, the repeated download and update of the full-scale resources are avoided, thus accelerating the update speed of the resource version and meeting the requirements of rapid iteration; in addition, the update method of the cached data improves the loading efficiency of the resources, optimizes the timeliness of the device function display, and further improves the user experience.
Smart Images

Figure CN120378303A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of smart home / smart family. Specifically, it relates to a method for updating and pushing device detail page resources, a device, and a medium. Background Art
[0002] With the continuous enrichment and diversification of the functions of smart devices, the device detail page resources, as a key means to display device functions, carry the comprehensive display and update requirements of device functions. In order to adapt to new function changes, the versions of device detail page resources need to be continuously updated and adjusted.
[0003] However, the current resource update process relies on users or operators to manually modify the mapping relationship between device models and resources. On the one hand, the types of device models are huge and updated frequently, and the manual modification workload is large and error-prone, which greatly increases the burden on operation and maintenance personnel and also consumes a large amount of human resources. On the other hand, due to the slow manual update method of the mapping relationship, the update speed of resource versions cannot meet the requirements of rapid iteration, thus affecting the timely display of device functions and the user experience. Summary of the Invention
[0004] In view of the above problems, this application provides a method for updating and pushing device detail page resources, a device, and a medium.
[0005] In a first aspect, this application provides a method for updating device detail page resources, the method including:
[0006] Receiving the version update information of the detail page resources from the operation end, and determining the corresponding device model according to the detail page resources; the version update information includes the first version number of the updated detail page resources;
[0007] Determining the device list corresponding to the device model, and for each device in the device list, determining the second version number corresponding to the historical detail page resources obtained by the device;
[0008] Determining the resource information to be downloaded corresponding to the device according to the first version number and the second version number; the resource information to be downloaded is determined based on the difference between the detail page resources corresponding to the first version number and the second version number respectively;
[0009] Determining the storage address of the resource information to be downloaded, establishing a first association relationship between the identification information of the device and the storage address of the resource information to be downloaded, and updating the first association relationship to the cache data.
[0010] In a possible implementation manner, the method further includes:
[0011] Update the second association relationship in the database according to the device identifier and the resource information to be downloaded, so that when the storage address of the resource information to be downloaded corresponding to the device does not exist in the cached data, determine the storage address of the resource information to be downloaded based on the database;
[0012] Wherein, the second association relationship is used to indicate the association relationship between the device identifier and the resource information to be downloaded, and the database includes the second association relationship and the resource information to be downloaded.
[0013] In a possible implementation manner, the determining the resource information to be downloaded corresponding to the device according to the first version number and the second version number includes:
[0014] Determine the difference information between the historical detail page resource corresponding to the second version number and the detail page resource corresponding to the first version number; the difference information is used to indicate the update range of the detail page resource, and the update range includes the number of data changes and / or the number of added data in the detail page resource;
[0015] According to the difference information, determine whether the preset condition for generating the incremental update resource is satisfied; the preset condition is used to indicate that the update range of the detail page resource is smaller than the preset range, and the incremental update resource is used to indicate the updated part of the updated detail page resource relative to the historical detail page resource;
[0016] If so, generate the incremental update resource, and determine the resource information to be downloaded corresponding to the device as the incremental update resource;
[0017] If not, do not generate the incremental update resource, and determine the resource information to be downloaded corresponding to the device as the updated detail page resource.
[0018] In a possible implementation manner, the determining the difference information between the historical detail page resource corresponding to the second version number and the detail page resource corresponding to the first version number includes:
[0019] Determine the version sequence based on the second version number and the first version number, the version sequence includes the first version number, and one or more historical version numbers between the second version number and the first version number, and the version sequence is sorted based on time;
[0020] According to the preset mapping relationship, obtain the update content corresponding to each version number in the version sequence, the update content is used to indicate the content updated by the current version number relative to the previous version number, and the mapping relationship is used to indicate the corresponding relationship between the version number and the update content;
[0021] Determine the difference information according to the update information corresponding to each of the version numbers.
[0022] In a possible implementation, after updating the cached data, it further includes:
[0023] Determine the cache duration of the first association relationship according to the resource data corresponding to the device, where the resource data includes at least one data item of the update frequency of the first association relationship corresponding to the device and the request frequency of the device for the resource information to be downloaded;
[0024] When the cache duration is reached, invalidate the first association relationship.
[0025] In a possible implementation, the determining the cache duration of the first association relationship according to the resource data corresponding to the device includes:
[0026] Determine the sub-score corresponding to a single data item in the resource data; wherein, the update frequency is inversely proportional to the sub-score, and the request frequency is directly proportional to the sub-score;
[0027] Determine the total score corresponding to the resource data according to the sub-score corresponding to a single data item;
[0028] Determine the cache duration according to the total score; wherein, the total score is directly proportional to the cache duration.
[0029] In a second aspect, the present application provides a method for pushing resources of a device details page, the method including:
[0030] Receive a request from a device to obtain resources of a details page, and determine whether there is a storage address of the resource information to be downloaded corresponding to the device in the cached data according to the obtain request;
[0031] If so, return the storage address of the resource information to be downloaded to the device, so that the device obtains the corresponding resource information to be downloaded based on the storage address; if not, determine the storage address of the resource information to be downloaded corresponding to the device based on the database;
[0032] Wherein, the obtain request carries identification information of the device, the cached data includes a first association relationship between the identification information of the device and the storage address of the resource to be downloaded; the resource information to be downloaded is determined based on the historical details page resources obtained by the device and the details page resources newly updated by the operation end; the database includes the resource information to be downloaded, and a second association relationship between the device identification and the resource information to be downloaded.
[0033] In a possible implementation, determining the storage address of the to-be-downloaded resource information corresponding to the device based on the database includes:
[0034] Determining the to-be-downloaded resource information corresponding to the device based on the second association relationship in the database;
[0035] Obtaining the storage location of the to-be-downloaded resource information in the database, and the storage location is the storage address of the to-be-downloaded resource information.
[0036] In a third aspect, the present application provides an update device for device detail page resources, including:
[0037] A receiving module, configured to receive the version update information of the detail page resources from the operation end and determine the corresponding device model according to the detail page resources; the version update information includes the first version number of the updated detail page resources;
[0038] A query module, configured to determine the device list corresponding to the device model, and for each device in the device list, determine the second version number corresponding to the historical detail page resources obtained by the device;
[0039] An analysis module, configured to determine the to-be-downloaded resource information corresponding to the device according to the first version number and the second version number; the to-be-downloaded resource information is determined based on the differences between the detail page resources corresponding to the first version number and the second version number respectively;
[0040] In a possible implementation, the analysis module is specifically configured to:
[0041] Determine the difference information between the historical detail page resources corresponding to the second version number and the detail page resources corresponding to the first version number; the difference information is used to indicate the update range of the detail page resources, and the update range includes the number of data changes and / or the number of added data in the detail page resources;
[0042] According to the difference information, determine whether the preset condition for generating the incremental update resource is satisfied; the preset condition is used to indicate that the update range of the detail page resources is less than the preset range, and the incremental update resource is used to indicate the updated part of the updated detail page resources relative to the historical detail page resources;
[0043] If so, generate the incremental update resource, and determine the to-be-downloaded resource information corresponding to the device as the incremental update resource;
[0044] If not, do not generate the incremental update resource, and determine the to-be-downloaded resource information corresponding to the device as the updated detail page resources.
[0045] In a possible implementation, the analysis module is specifically configured to:
[0046] Determine a version sequence based on the second version number and the first version number, where the version sequence includes the first version number, and one or more historical version numbers between the second version number and the first version number, and the version sequence is sorted based on time;
[0047] According to a preset mapping relationship, obtain the update content corresponding to each version number in the version sequence, where the update content is used to indicate the content updated by the current version number relative to the previous version number, and the mapping relationship is used to indicate the corresponding relationship between the version number and the update content;
[0048] Determine the difference information according to the update information corresponding to each version number.
[0049] The processing module is configured to determine the storage address of the resource information to be downloaded, establish a first association relationship between the identification information of the device and the storage address of the resource information to be downloaded, and update the first association relationship to the cached data.
[0050] In a possible implementation, the processing module is further configured to:
[0051] Update the second association relationship in the database according to the device identification and the resource information to be downloaded, so that when the storage address of the resource information to be downloaded corresponding to the device does not exist in the cached data, determine the storage address of the resource information to be downloaded based on the database;
[0052] Wherein, the second association relationship is used to indicate the association relationship between the device identification and the resource information to be downloaded, and the database includes the second association relationship and the resource information to be downloaded.
[0053] In a possible implementation, the processing module is further configured to:
[0054] Determine the cache duration of the first association relationship according to the resource data corresponding to the device, where the resource data includes at least one data item of the update frequency of the first association relationship corresponding to the device and the request frequency of the device for the resource information to be downloaded;
[0055] When the cache duration is reached, invalidate the first association relationship.
[0056] In a possible implementation, the processing module is specifically configured to:
[0057] Determine the sub-score corresponding to a single data item in the resource data; wherein, the update frequency is inversely proportional to the sub-score, and the request frequency is directly proportional to the sub-score;
[0058] Determine the total score corresponding to the resource data according to the sub-scores corresponding to the individual data items;
[0059] Determine the caching duration according to the total score; wherein, the total score is directly proportional to the caching duration.
[0060] In a fourth aspect, the present application provides a device details page resource pushing device, including:
[0061] A judgment module, configured to receive a request from a device to obtain a details page resource, and determine whether there is a storage address of the to-be-downloaded resource information corresponding to the device in the cached data according to the obtaining request;
[0062] A return module, configured to, if there is a storage address of the to-be-downloaded resource information, return the storage address of the to-be-downloaded resource information to the device, so that the device obtains the corresponding to-be-downloaded resource information based on the storage address; if there is no storage address of the to-be-downloaded resource information, determine the storage address of the to-be-downloaded resource information corresponding to the device based on a database;
[0063] Wherein, the obtaining request carries identification information of the device, the cached data includes a first association relationship between the identification information of the device and the storage address of the to-be-downloaded resource; the to-be-downloaded resource information is determined based on the historical details page resources obtained by the device and the details page resources newly updated by the operation end; the database includes the to-be-downloaded resource information, and a second association relationship between the device identification and the to-be-downloaded resource information.
[0064] In a possible implementation manner, the return module is specifically configured to:
[0065] Determine the to-be-downloaded resource information corresponding to the device based on the second association relationship in the database;
[0066] Obtain the storage location of the to-be-downloaded resource information in the database, and the storage location is the storage address of the to-be-downloaded resource information.
[0067] In a fifth aspect, the present application provides a computer-readable storage medium, where the computer-readable storage medium includes a stored program, and wherein, when the program runs, it executes the device details page resource update method according to any one of the first aspects, and / or executes the device details page resource pushing method according to any one of the second aspects.
[0068] In a sixth aspect, the present application provides an electronic device, including a memory and a processor. A computer program is stored in the memory, and the processor is configured to execute the method for updating device detail page resources according to any one of the first aspect, and / or execute the method for pushing device detail page resources according to any one of the second aspect through the computer program.
[0069] The method for updating and pushing device detail page resources provided by the present application, the device and the medium, by receiving the update information transmitted from the operation end, automatically identify the device models related to the updated resources, and compare the differences between the historical version and the new version to generate the resource information to be downloaded and the incremental update resources. These information will be automatically stored and associated with the device, thus greatly reducing manual operations, improving the efficiency of resource update, and ensuring that the device can obtain the latest resource information in a timely manner. Through the above update method, the workload of manually modifying the mapping relationship between the device model and the resource version is reduced, human errors are reduced, and the accuracy of the update is improved; by adopting the incremental update method, the repeated download and update of the full-scale resources are avoided, thus accelerating the update speed of the resource version and meeting the requirements of rapid iteration; in addition, the update method of the cached data improves the loading efficiency of the resources, optimizes the timeliness of the device function display, and further improves the user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0070] The accompanying drawings here are incorporated into the specification and form a part of this specification, showing embodiments consistent with the present application, and are used together with the specification to explain the principles of the present application.
[0071] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the accompanying drawings required for use in the description of the embodiments or the prior art. Obviously, for those of ordinary skill in the art, other drawings can also be obtained based on these drawings without creative efforts.
[0072] Figure 1 is a flowchart showing a method for updating device detail page resources according to an embodiment of the present application Figure 1 ;
[0073] Figure 2 is a flowchart showing a method for updating device detail page resources according to an embodiment of the present application Figure 2 ;
[0074] Figure 3 is a flowchart showing a method for pushing device detail page resources according to an embodiment of the present application;
[0075] Figure 4 is a schematic structural diagram of a device for updating device detail page resources according to an embodiment of the present application;
[0076] Figure 5 It is a schematic structural diagram of a device details page resource push device according to an embodiment of the present application;
[0077] Figure 6 It is a hardware schematic diagram of an electronic device according to an embodiment of the present application. Detailed implementation manners
[0078] In order to enable those skilled in the art to better understand the solutions of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.
[0079] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and do not necessarily need to be used to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments of the present application described here can be implemented in an order other than those illustrated or described here. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device including a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0080] In view of the problems in the prior art, the present application provides a method for updating and pushing device details page resources. On the one hand, a method for updating device details page resources is provided, which solves the problems of excessive manual intervention and low update efficiency in the process of updating the device details page resource version through automation and intelligence. Specifically, by receiving the update information transmitted by the operation end, the device model related to the updated resource is automatically identified, and the difference between the historical version and the new version is compared to generate resource information to be downloaded and incremental update resources. This information will be automatically stored and associated with the device, thereby greatly reducing manual operations, improving the efficiency of resource updates, and ensuring that the device can obtain the latest resource information in a timely manner. Through the above-mentioned update method, the workload of manually modifying the mapping relationship between the device model and the resource version is reduced, human errors are reduced, and the accuracy of the update is improved; the incremental update method is adopted to avoid repeated downloading and updating of the full amount of resources, thereby speeding up the update speed of the resource version and meeting the needs of rapid iteration; in addition, the update method of cached data improves the loading efficiency of resources, optimizes the timeliness of device function display, and further improves the user experience.
[0081] Correspondingly, on the other hand, a method for pushing resources of a device details page is provided. By receiving the acquisition request of the device, and judging whether the address information of the resource to be downloaded has been stored in the cache. If the resource information to be downloaded of the device already exists in the cache, the storage address will be directly returned at this time, and the device can quickly obtain the resource according to the address. If the information is not in the cache, the storage address of the resource information to be downloaded of the device is determined by querying the database, so as to ensure that the device can obtain the correct resource information. The above-mentioned push method reduces the frequency of database queries and improves the response speed of resource acquisition through the caching mechanism, thereby optimizing the request processing efficiency of the device; secondly, the association between the device identifier and the resource storage address is utilized to avoid repeated queries and resource redundancy.
[0082] The updating and pushing methods of the above-mentioned device details page resources can be widely used in smart home (Smart Home), smart home, smart home equipment ecology, smart residential (Intelligence House) ecology and other whole-house intelligent digital control application scenarios. The devices in this method may not be limited to PC, mobile phone, tablet computer, smart air conditioner, smart range hood, smart refrigerator, smart oven, smart stove, smart washing machine, smart water heater, smart washing equipment, smart dishwasher, smart projection equipment, smart TV, smart clothes rack, smart curtain, smart audio and video, smart socket, smart audio, smart speaker, smart fresh air equipment, smart kitchen and bathroom equipment, smart bathroom equipment, smart sweeping robot, smart window cleaning robot, smart mopping robot, smart air purification equipment, smart steamer, smart microwave oven, smart kitchen treasure, smart purifier, smart water dispenser, smart door lock, etc.
[0083] The following will, in conjunction with the accompanying drawings, elaborate on some embodiments of the present application. Without conflict between the embodiments, the following embodiments and the features in the embodiments can be combined with each other. Additionally, the step timings in the following method embodiments are only examples and not strictly limited.
[0084] Figure 1 is a flowchart showing a method for updating resources on a device details page according to an embodiment of the present application Figure 1 As Figure 1 shown, the method includes:
[0085] S101. Receive the version update information of the details page resources from the operation end, and determine the corresponding device model according to the details page resources.
[0086] Among them, the version update information includes the first version number of the updated details page resources.
[0087] In this step, by receiving and parsing the version update information of the details page resources sent by the operation end, it is ensured that the details page resources that need to be updated can be correctly identified, and which device models need to be updated can be automatically determined according to the new version of the details page resources. The operation end version update information means that when operation personnel upload the details page resource update information on the server, it usually includes the new version of the details page resource file and the update version number. These information are the core basis of the entire update process. Each intelligent device is usually classified according to the model, and each model of device uses different details page resources. Therefore, according to the details page resource update information, the device models related to the updated details page resources need to be identified.
[0088] Exemplarily, first receive the version update information of the details page resources submitted by the operation end. This information usually includes but is not limited to the version number of the details page resources, the updates of functions or page content included in the new details page resources, the device models or device types applicable to the update, etc. Further, parse the update information submitted by the operation end, and extract the version number of the details page resources and the corresponding device model from it. By comparing with the mapping table of existing device models, it can be determined which devices need to update the details page resources, and the association relationship between the device model and the updated resources is generated.
[0089] S102. Determine the device list corresponding to the device model, and for each device in the device list, determine the second version number corresponding to the historical details page resources obtained by the device.
[0090] S103. Determine the resource information to be downloaded corresponding to the device according to the first version number and the second version number.
[0091] Among them, the resource information to be downloaded is determined based on the differences between the detailed page resources corresponding to the first version number and the second version number respectively.
[0092] It should be noted that the resource version number currently used by each device is determined, compared with the updated version, and the content that needs to be updated is judged. Through this comparison, it is possible to accurately find out which devices need to download the complete detailed page resources and which devices only need partial updates. The device list refers to a list of all devices using the device model obtained from the database according to the device model. Each device in the device list will be checked to see if it needs to update the detailed page resources. The detailed page resource version of each device can be recorded in the database. When the device obtains the detailed page resources, the detailed page resource version of the device can be stored and used for comparison during subsequent updates.
[0093] By determining the specific type of detailed page resources required for each device, it is judged whether complete resources are needed or only partial updates are required. Through this step, the update efficiency of the detailed page resources can be significantly improved, and the device can be prevented from downloading complete resources under unnecessary circumstances. If there are significant differences between the current resources and the historical resources, the difference part will be calculated at this time and incremental update resources will be generated. The incremental update resources only contain the updated part, which can save bandwidth and download time.
[0094] Exemplarily, the incremental update part can be generated by comparing the differences between two versions. A file difference comparison tool can be used to perform differential analysis on the resources; or an incremental update algorithm can be used, such as generating incremental update resources based on hashing. In addition, the type of resources to be downloaded can be judged by comparing the first version number and the second version number. If the two version numbers are not very different, incremental update content is considered to be generated and only incremental updates are performed; if the two version numbers are quite different, the device is considered to download the entire detailed page resources.
[0095] S104. Determine the storage address of the resource information to be downloaded, establish a first association relationship between the identification information of the device and the storage address of the resource information to be downloaded, and update the first association relationship to the cached data.
[0096] In this step, based on the storage address of the resource to be downloaded, an association is established between the device and the updated detailed page resource or the incremental update resource, and the cached data is updated. Through caching, it is possible to ensure that the device can quickly obtain the download address of the resource, improving the efficiency of subsequent requests. Each resource to be downloaded will have a corresponding storage address on a storage medium such as a server or CDN (Content Delivery Network), and the device can download the detailed page resource through this address. To improve access efficiency, the device identifier and its corresponding detailed page resource storage address are cached, so that subsequent resource requests can be directly obtained from the cache without having to query the database again. The device identifier is an identifier used to uniquely identify each device, which can be the device's ID, MAC address, or other information that can uniquely identify the device.
[0097] Exemplarily, the storage address can be obtained by querying a configuration file or an interface. If it is a new detailed page resource, the new detailed page resource can be uploaded to the storage medium and its address can be obtained. For each device, a first association relationship is established between its device identifier information and the storage address of the resource to be downloaded. This relationship can be stored in the cache, such as Redis or Memcached, thus avoiding repeated database queries.
[0098] Exemplarily, the method further includes:
[0099] According to the device identifier and the resource information to be downloaded, the second association relationship in the database is updated, so that when the storage address of the resource information to be downloaded corresponding to the device does not exist in the cached data, the storage address of the resource information to be downloaded is determined based on the database;
[0100] Wherein, the second association relationship is used to indicate the association relationship between the device identifier and the resource information to be downloaded, and the database includes the second association relationship and the resource information to be downloaded.
[0101] It should be noted that through the above example, it is possible to provide an accurate detailed page resource storage address through the database when the cache fails, ensuring that the device can successfully download the required detailed page resources, thus avoiding the failure to obtain the detailed page resources due to cache failure or cache miss. The second association relationship is a data structure in the database used to record the mapping relationship between the device and the resource to be downloaded. It can include the association information between the device identifier and the detailed page resource, such as the association information between the device identifier and the identifier or storage address of the detailed page resource. Ensure that when the device requests the detailed page resource, the correct storage address of the detailed page resource can be found and matched in the database, thus avoiding the difficulty of resource search when the cache fails.
[0102] Exemplarily, after updating the cached data, it further includes:
[0103] Determine the caching duration of the first association relationship according to the resource data corresponding to the device, where the resource data includes at least one data item of the update frequency of the first association relationship corresponding to the device and the request frequency of the device for the resource information to be downloaded;
[0104] When the caching duration is reached, the first association relationship is invalidated.
[0105] It should be noted that through the above example, the life cycle of cached data can be intelligently managed to ensure that the cache efficiently and accurately provides the storage address of the detail page resources, while avoiding storing outdated or invalid resource information in the cache. By dynamically determining the survival duration of the cache based on data such as the update frequency and request frequency of the device, the use of resources in the server can be effectively balanced, the performance can be optimized, and the user experience can be improved. Resource data refers to the interaction information between the device and the detail page resources, mainly including the resource update frequency of the device and the request frequency of the device for the detail page resources. The update frequency of the device refers to the frequency at which the content of the detail page resources changes, and the request frequency of the device refers to the number of requests of the device for the detail page resources. These data can help determine how long the cache of the detail page resources of the device should be maintained to ensure the timeliness of the resources and the efficient use of the cache. The caching duration determines the survival time of the cached data. The setting of the caching duration needs to comprehensively consider factors such as the request frequency and update frequency of the device. For example, if a device frequently requests detail page resources and the resource update frequency is low, the detail page resources can be saved in the cache for a longer time after each update to avoid frequent database queries. On the contrary, if the device is updated frequently or the requests are few, the caching duration can be set shorter to ensure that the detail page resource data in the cache is the latest.
[0106] Exemplarily, the determining the caching duration of the first association relationship according to the resource data corresponding to the device includes:
[0107] Determine the sub-score corresponding to a single data item in the resource data; wherein, the update frequency is inversely proportional to the sub-score, and the request frequency is directly proportional to the sub-score;
[0108] Determine the total score corresponding to the resource data according to the sub-score corresponding to a single data item;
[0109] Determine the caching duration according to the total score; wherein, the total score is directly proportional to the caching duration.
[0110] It should be noted that for each data item (such as update frequency or request frequency), a sub-score is calculated based on its impact on the cache duration. The update frequency is inversely proportional to the sub-score, meaning that when the resource is updated frequently, the cache duration of the resource information to be downloaded should be shorter; the request frequency is directly proportional to the sub-score, meaning that when the request is frequent, the cache duration should be longer. In this way, weights can be assigned to the cache duration according to the characteristics of the resource. By summing up the sub-scores of each data item, a total score is obtained. This total score reflects the comprehensive characteristics of the interaction between the device and the detail page resource. For example, a detail page resource with frequent updates will have a lower total score, while a detail page resource with frequent requests will get a higher score. The total score provides a basis for the decision of the cache duration, that is, a detail page resource with a higher score will have a longer cache duration.
[0111] Exemplarily, for the calculation of the sub-score, the influence weights of the update frequency and the request frequency on the cache duration can be determined by an algorithm. For example, the update frequency may be converted according to a certain proportional value, and the higher the update frequency, the lower the corresponding sub-score; the request frequency is weighted according to the frequency, and the higher the sub-score corresponding to the resource information to be downloaded with frequent requests. The update frequency and the request frequency can reflect their relative importance by setting weights. The sub-scores of all data items related to the cache duration are summed up into a total score. The total score can be obtained by weighted summation, that is, the sub-scores of each data item (such as update frequency, request frequency) are weighted and summed according to a certain proportion to obtain a final score. According to the total score, a proportional relationship is used to calculate the cache duration. For example, a benchmark value can be set, and when the total score reaches a certain threshold, the cache duration will increase accordingly. If the score is low, the cache duration will be reduced to balance the cache demand and the resource update demand.
[0112] In addition, in order to support the determination of differential information, it is actually necessary to store the historical detail page resources corresponding to the historical version numbers. However, the storage space of the database is still limited and cannot store all versions of the historical detail page resources without limit. Therefore, an intelligent storage-expiration mechanism for the historical detail page resources can be considered.
[0113] Exemplarily, the frequency levels corresponding to the update frequencies of different device types are determined. The higher the frequency level, the higher the update frequency of the detail page resource;
[0114] According to the frequency level, the target number of historical versions that can be stored in the database for each device type is determined. The target number of historical versions represents the number of detail page resources corresponding to the historical version number closest to the latest version number; among them, the higher the frequency level, the more historical versions that can be stored;
[0115] Whenever the number of historical versions of a single device type stored in the database reaches the target number of historical versions, the detailed page resources corresponding to the historical version number farthest from the latest version number are deleted.
[0116] For example, the frequency level can be set to high frequency, medium frequency, and low frequency. The device types corresponding to high frequency may be smartphones, smart speakers, etc. The detailed page resources of these devices are updated frequently. Each iteration may involve adjustments to page elements, addition of functions, etc. Therefore, multiple historical versions (such as the last 5 versions) should be stored to support version rollback or incremental updates. The device types corresponding to medium frequency may be smart home appliances. The detailed page resources of such devices are mainly updated with the firmware version and do not change frequently. Usually, they are updated once every six months or one year. Fewer historical versions (such as 1 - 2 versions) can be stored. The devices corresponding to low frequency may be smart lighting, wearable devices, etc. The detailed page resources of such devices hardly change and are usually only adjusted during major updates. The latest version can always be stored without storing historical versions. If a major update occurs, the old version can be retained only for a short period (such as 30 days) for transitional support.
[0117] The method for updating the detailed page resources of devices provided in the embodiments of the present application receives the update information passed in by the operation end, automatically identifies the device models related to the updated resources, and compares the differences between the historical version and the new version to generate the resource information to be downloaded and the incremental update resources. These information will be automatically stored and associated with the devices, thereby greatly reducing manual operations, improving the efficiency of resource updates, and ensuring that the devices can obtain the latest resource information in a timely manner. Through the above update method, the workload of manually modifying the mapping relationship between the device model and the resource version is reduced, human errors are reduced, and the accuracy of the update is improved; by adopting the incremental update method, the repeated download and update of full - volume resources are avoided, thus accelerating the update speed of the resource version and meeting the requirements of rapid iteration; in addition, the update method of cached data improves the loading efficiency of resources, optimizes the timeliness of device function display, and further improves the user experience.
[0118] Figure 2 is a flowchart showing a method for updating the detailed page resources of a device according to an embodiment of the present application Figure 2 As Figure 2 shown, the method includes:
[0119] S201. Determine the difference information between the historical detailed page resources corresponding to the second version number and the detailed page resources corresponding to the first version number.
[0120] Among them, the difference information is used to indicate the update range of the detailed page resources, and the update range includes the number of data changes and / or the number of added data in the detailed page resources.
[0121] In this step, the difference information will help determine the scope of resource updates and decide whether to adopt the incremental update method. By obtaining the difference information between two versions of resources, incremental update resources can be generated more precisely, reducing unnecessary data transmission and improving system efficiency. The second version number represents the version number corresponding to the historical detail page resources, which is the version of the detail page resources currently used by the device. The first version number represents the version number of the updated detail page resources. The difference information refers to the specific changes between the updated version and the historical version. These changes can be additions, modifications, or deletions of data. Among them, the quantity of data changes can represent, for example, the amount of data where the values of certain fields have changed, or the data that was originally present has been modified. The quantity of added data refers to the new elements or data items in the new version, which may be the amount of new functions, content, or other updated data.
[0122] Exemplarily, determining the difference information between the historical detail page resources corresponding to the second version number and the detail page resources corresponding to the first version number includes:
[0123] Determine a version sequence based on the second version number and the first version number, where the version sequence includes the first version number, and one or more historical version numbers between the second version number and the first version number, and the version sequence is sorted based on time;
[0124] According to a preset mapping relationship, obtain the update content corresponding to each version number in the version sequence, where the update content is used to indicate the content updated by the current version number relative to the previous version number, and the mapping relationship is used to indicate the corresponding relationship between the version number and the update content;
[0125] Determine the difference information according to the update information corresponding to each version number.
[0126] It should be noted that the version sequence refers to all historical versions between two version numbers (the second version number and the first version number), which are arranged in chronological order to ensure that the updates of each version are continuous and orderly. Through this version sequence, the update content of each version is gradually analyzed. The mapping relationship is a pre-maintained data structure that associates the version number with the corresponding update content (such as function changes, data modifications, etc.), helping to locate the specific changes of each version compared to the previous version. Through this mapping relationship, according to each version number in the version sequence, the update content of each version can be obtained in turn, and by analyzing these update contents, the difference information between the versions can be extracted, so as to further determine the overall difference between the second version number and the first version number, which can include which data, functions, or content have changed.
[0127] S202. Determine whether the preset condition for generating the incremental update resource is satisfied according to the difference information.
[0128] Among them, the preset condition is used to indicate that the update range of the detail page resource is smaller than the preset range; the incremental update resource is used to indicate the updated part of the updated detail page resource relative to the historical detail page resource.
[0129] In this step, the preset condition is used as the standard for judging whether to adopt incremental update, and can be set according to factors such as the change range and the number of changed contents. Exemplarily, according to the difference information, the update range of the detail page resource can be quantified. For example, if the number of updated fields and the number of added content items are less than a certain set threshold, it is considered that the update range is small and suitable for incremental update. For example, when the number of changed contents is less than 10 fields, it is considered a small-range update.
[0130] S203. If so, generate the incremental update resource and determine that the resource information to be downloaded corresponding to the device is the incremental update resource.
[0131] Among them, the incremental update resource is used to indicate the updated part of the updated detail page resource relative to the historical detail page resource;
[0132] S204. If not, do not generate the incremental update resource and determine that the resource information to be downloaded corresponding to the device is the updated detail page resource.
[0133] It should be noted that when it is judged that the update range meets the incremental update condition, an incremental update resource is generated and the resource information that the device needs to download is determined. The incremental update resource contains the changed part, thereby reducing the consumption of network bandwidth and improving the update efficiency. The incremental update resource is generated according to the difference information determined in the previous step. The historical version and the updated version can be differentially encoded or packaged, and a specific differential compression tool can be used to generate a differential file. If the update range exceeds the preset incremental update condition, no incremental update resource is generated, but instead the complete updated detail page resource transmitted by the operation end is directly corresponded. In this case, the updated content of the entire detail page resource is relatively large and cannot be transmitted by the incremental update method, so the device needs to download the entire detail page resource.
[0134] Exemplarily, more refined incremental splitting can also be performed. By splitting the incremental part into different types and determining different types of incremental situations, fine-grained incremental resource generation can be performed. For example:
[0135] Split the difference information by data category, where the data category includes at least one of picture resources, text descriptions, and function lists;
[0136] Determine the resource information to be downloaded corresponding to the device based on the difference information of data categories.
[0137] Exemplarily, determining whether to generate incremental update resources based on the difference information of data categories includes:
[0138] If the data change range of a single data category is less than the corresponding preset threshold, only generate incremental update resources for this category;
[0139] If the data change range of a single data category is greater than or equal to the corresponding preset threshold, determine that the content part corresponding to this data category is updated in the updated detail page resource;
[0140] Through the above example, the differential part can be updated in a fine-grained manner, which can significantly reduce data transmission and storage costs, improve update efficiency, reduce user waiting time, and at the same time adapt to the resource requirements of different device types. By splitting the update content according to data categories (such as pictures, texts, function lists, etc.), more flexible version management can be achieved, avoiding unnecessary overall resource replacement, thereby reducing operation and maintenance costs.
[0141] For example, the update of the detail page resource of a smart washing machine involves multiple parts: adding an energy-saving function (function list change), updating the interface screenshot (picture resource change), and optimizing the description text (text description change). After differential analysis, it is found that the change ranges of "function list" and "text description" are small and meet the conditions for incremental update, but the change of "picture resource" is large and exceeds the corresponding preset threshold. Adopt a hybrid update strategy, incrementally update the "function list" and "text description", but perform a full download on the "picture resource".
[0142] The method for updating the device detail page resource provided by the embodiment of the present application can flexibly determine whether to adopt incremental update or full update by accurately identifying and analyzing the differences between each version, thereby reducing unnecessary data transmission and storage pressure and improving the download efficiency of the detail page resource. When the update range is small, adopting incremental update can significantly reduce bandwidth consumption and device storage occupancy, while accelerating the download speed and enhancing the user experience. When the updated content is large, directly providing a full update package ensures the accuracy and integrity of the update. The above intelligent update strategy can automatically select the appropriate update method according to actual needs, optimize resource usage and update processes, thereby improving operation efficiency and user satisfaction.
[0143] Figure 3 It is a flowchart of a method for pushing device detail page resources according to an embodiment of the present application. As Figure 3 shown, the method includes:
[0144] S301. The receiving device receives a request for details page resources, and determines whether there is a storage address of the to-be-downloaded resource information corresponding to the device in the cached data according to the request.
[0145] In this step, first, it is determined whether there is already to-be-downloaded resource information of this device in the cache. If the cache hits, the download address of the to-be-downloaded resource information can be directly provided, avoiding unnecessary database queries, thereby improving efficiency. The acquisition request refers to a request sent by the device, such as outputting a request through the corresponding interface, which includes device identification information and indicates the to-be-downloaded resource information that the device needs to obtain. The cached data is the fast-access data stored in the server, including the mapping between the device identification information and the storage address of the corresponding to-be-downloaded resource information. The purpose of caching is to accelerate the query process and reduce access to the database.
[0146] S302. If so, return the storage address of the to-be-downloaded resource information to the device, so that the device can obtain the corresponding to-be-downloaded resource information based on the storage address.
[0147] S303. If not, determine the storage address of the to-be-downloaded resource information corresponding to the device based on the database.
[0148] Among them, the acquisition request carries the identification information of the device, and the cached data includes the first association relationship between the identification information of the device and the storage address of the to-be-downloaded resource; the to-be-downloaded resource information is determined based on the historical details page resources obtained by the device and the details page resources newly updated by the operation side; the database includes the to-be-downloaded resource information, and the second association relationship between the device identification and the to-be-downloaded resource information.
[0149] It should be noted that when the cache hits, directly return the storage address of the to-be-downloaded resource information requested by the device to ensure fast response and minimize latency. When the cache misses, obtain the storage address of the to-be-downloaded resource information required by the device through the database to meet the device's request. The database is used to store persistent data, including the mapping relationship between the device identification and the to-be-downloaded resource information. The database is also responsible for storing information about all devices and their corresponding to-be-downloaded resource information, ensuring that even if the cache misses, the address of the to-be-downloaded resource information can be accurately returned through internal matching search.
[0150] Exemplarily, the determining the storage address of the to-be-downloaded resource information corresponding to the device based on the database includes:
[0151] Determine the to-be-downloaded resource information corresponding to the device based on the second association relationship in the database;
[0152] Obtain the storage location of the to-be-downloaded resource information in the database, and the storage location is the storage address of the to-be-downloaded resource information.
[0153] Specifically, when the device sends a request, if the cache does not have the corresponding resource information, the server will query through the database, obtain the to-be-downloaded resource information required by the device from the second association relationship in the database based on the device identification information, and return the storage address of the resource, ensuring the accuracy and timeliness of the download of the to-be-downloaded resource information. For example, when the cache miss occurs, the server will query the second association relationship in the database through the identification information of the device. This relationship can be a table that stores the mapping between the device identification and the corresponding to-be-downloaded resource information. When obtaining the information of the to-be-downloaded resource, the database will also include the storage location of the to-be-downloaded resource information. This storage location can be a field in the database or a record in another table, storing the physical storage address of the to-be-downloaded resource information (such as a file system path, a cloud storage path, etc.). The server returns this storage location to the device as the storage address of the to-be-downloaded resource information.
[0154] The method for pushing device detail page resources provided by the embodiments of the present application receives the acquisition request of the device and determines whether the address information of the to-be-downloaded resource has been stored in the cache. If the to-be-downloaded resource information of the device already exists in the cache, the storage address will be directly returned at this time, and the device can quickly obtain the resource according to this address. If the information does not exist in the cache, the storage address of the to-be-downloaded resource information of the device is determined by querying the database, so as to ensure that the device can obtain the correct resource information. The above-mentioned pushing method reduces the frequency of database queries through the cache mechanism, improves the response speed of resource acquisition, and thus optimizes the request processing efficiency of the device; secondly, by using the association relationship between the device identification and the resource storage address, duplicate queries and resource redundancy are avoided.
[0155] Corresponding to the above method, the embodiments of the present application further provide a device detail page resource update device Figure 4 is a schematic structural diagram of a device detail page resource update device according to an embodiment of the present application; as Figure 4 shown, the device includes:
[0156] A receiving module 401, configured to receive the version update information of the detail page resource from the operation end and determine the corresponding device model according to the detail page resource; the version update information includes the first version number of the updated detail page resource;
[0157] A query module 402, configured to determine the device list corresponding to the device model, and for each device in the device list, determine the second version number corresponding to the historical detail page resource obtained by the device;
[0158] An analysis module 403 is configured to determine the resource information to be downloaded corresponding to the device according to the first version number and the second version number; the resource information to be downloaded is determined based on the differences between the detailed page resources corresponding to the first version number and the second version number respectively;
[0159] In a possible implementation, the analysis module 403 is specifically configured to:
[0160] Determine the difference information between the historical detailed page resources corresponding to the second version number and the detailed page resources corresponding to the first version number; the difference information is used to indicate the update range of the detailed page resources, and the update range includes the number of data changes and / or the number of added data in the detailed page resources;
[0161] According to the difference information, determine whether the preset conditions for generating the incremental update resources are met; the preset conditions are used to indicate that the update range of the detailed page resources is less than the preset range, and the incremental update resources are used to indicate the updated part of the updated detailed page resources relative to the historical detailed page resources;
[0162] If so, generate the incremental update resources, and determine that the resource information to be downloaded corresponding to the device is the incremental update resources;
[0163] If not, do not generate the incremental update resources, and determine that the resource information to be downloaded corresponding to the device is the updated detailed page resources.
[0164] In a possible implementation, the analysis module 403 is specifically configured to:
[0165] Determine the version sequence based on the second version number and the first version number, where the version sequence includes the first version number and one or more historical version numbers between the second version number and the first version number, and the version sequence is sorted based on time;
[0166] According to the preset mapping relationship, obtain the update content corresponding to each version number in the version sequence, where the update content is used to indicate the content updated by the current version number relative to the previous version number, and the mapping relationship is used to indicate the corresponding relationship between the version number and the update content;
[0167] According to the update information corresponding to each version number, determine the difference information.
[0168] A processing module 404 is configured to determine the storage address of the resource information to be downloaded, establish a first association relationship between the identification information of the device and the storage address of the resource information to be downloaded, and update the first association relationship to the cached data
[0169] In a possible implementation, the processing module 404 is further configured to:
[0170] Update the second association relationship in the database according to the device identifier and the resource information to be downloaded, so that when the storage address of the resource information to be downloaded corresponding to the device does not exist in the cached data, determine the storage address of the resource information to be downloaded based on the database;
[0171] Wherein, the second association relationship is used to indicate the association relationship between the device identifier and the resource information to be downloaded, and the database includes the second association relationship and the resource information to be downloaded.
[0172] In a possible implementation, the processing module 404 is further configured to:
[0173] Determine the cache duration of the first association relationship according to the resource data corresponding to the device, where the resource data includes at least one data item of the update frequency of the first association relationship corresponding to the device and the request frequency of the device for the resource information to be downloaded;
[0174] When the cache duration is reached, invalidate the first association relationship.
[0175] In a possible implementation, the processing module 404 is specifically configured to:
[0176] Determine the sub-score corresponding to a single data item in the resource data; wherein, the update frequency is inversely proportional to the sub-score, and the request frequency is directly proportional to the sub-score;
[0177] Determine the total score corresponding to the resource data according to the sub-score corresponding to a single data item;
[0178] Determine the cache duration according to the total score; wherein, the total score is directly proportional to the cache duration.
[0179] Corresponding to the above method, an embodiment of the present application further provides a device details page resource push device, Figure 5 is a schematic structural diagram of a device details page resource push device according to an embodiment of the present application; as Figure 5 shown, the device includes:
[0180] A judgment module 501, configured to receive a request from a device to obtain a details page resource, and judge whether the storage address of the resource information to be downloaded corresponding to the device exists in the cached data;
[0181] A return module 502, configured to return the storage address of the to-be-downloaded resource information to the device if there is a storage address of the to-be-downloaded resource information, so that the device can obtain the corresponding to-be-downloaded resource information based on the storage address; if there is no storage address of the to-be-downloaded resource information, determine the storage address of the to-be-downloaded resource information corresponding to the device based on a database.
[0182] Wherein, the acquisition request carries identification information of the device, and the cache data includes a first association relationship between the identification information of the device and the storage address of the to-be-downloaded resource; the to-be-downloaded resource information is determined based on the historical detail page resources obtained by the device and the detail page resources newly updated by an operation end; the database includes the to-be-downloaded resource information, and a second association relationship between the device identification and the to-be-downloaded resource information.
[0183] In a possible implementation manner, the return module 502 is specifically configured to:
[0184] Determine the to-be-downloaded resource information corresponding to the device based on the second association relationship in the database;
[0185] Obtain the storage location of the to-be-downloaded resource information in the database, and the storage location is the storage address of the to-be-downloaded resource information.
[0186] Figure 6 It is a hardware schematic diagram of an electronic device according to an embodiment of the present application. As Figure 6 shown, the electronic device 60 provided in this embodiment includes: at least one processor 601 and a memory 602. The device 60 further includes a communication component 603. Wherein, the processor 601, the memory 602, and the communication component 603 are connected through a bus 604.
[0187] In a specific implementation process, at least one processor 601 executes computer execution instructions stored in the memory 602, so that at least one processor 601 executes the above method.
[0188] For the specific implementation process of the processor 601, reference may be made to the above method embodiment, and its implementation principle and technical effects are similar, which will not be elaborated here in this embodiment.
[0189] In the above Figure 6In the illustrated embodiments, it should be understood that the processor may be a central processing unit (CPU), or it may also be other general-purpose processors, digital signal processors (DSPs), application specific integrated circuits (ASICs), etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The steps of the method disclosed in combination with the invention can be directly embodied as being executed and completed by a hardware processor, or executed and completed by a combination of hardware and software modules in the processor.
[0190] The memory may include a random access memory (RAM), and may also include non-volatile memory (NVM), such as at least one disk memory.
[0191] The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For the sake of representation, the buses in the drawings of this application are not limited to only one bus or one type of bus.
[0192] This application also provides a computer-readable storage medium, in which computer-executable instructions / computer programs are stored. When the processor executes the computer-executable instructions / computer programs, the method described above is implemented.
[0193] The above-mentioned readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, a magnetic disk or an optical disk. The readable storage medium can be any available medium that can be accessed by a general-purpose or special-purpose computer.
[0194] An exemplary readable storage medium is coupled to a processor, enabling the processor to read information from and write information to the readable storage medium. Of course, the readable storage medium can also be a component of the processor. The processor and the readable storage medium can be located in an Application Specific Integrated Circuits (ASIC). Of course, the processor and the readable storage medium can also exist as discrete components in a device.
[0195] The division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Additionally, the couplings or direct couplings or communication connections shown or discussed among each other can be indirect couplings or communication connections through some interfaces, devices or units, and can be in electrical, mechanical or other forms.
[0196] The units described as separate components may or may not be physically separated. The components shown as units may or may not be physical units, that is, they can be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0197] In addition, in each embodiment of the present invention, the functional units can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit.
[0198] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or a part of this technical solution can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in each embodiment of the present invention. The aforementioned storage medium includes various media that can store program codes, such as USB flash drives, mobile hard disks, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical discs.
[0199] Those of ordinary skill in the art will understand that all or part of the steps of implementing the above method embodiments can be completed by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it performs the steps of the above method embodiments; and the aforementioned storage medium includes: various media such as ROM, RAM, magnetic disks, or optical discs that can store program codes.
[0200] So far, the technical solutions of the present application have been described in conjunction with the preferred embodiments shown in the drawings. However, those skilled in the art can easily understand that the protection scope of the present application is obviously not limited to these specific embodiments. The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements on some or all of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.
Claims
1. A method for updating resources on a device details page, characterized in that, The method includes: Receiving version update information of the detail page resources from the operation end, and determining the corresponding device model according to the detail page resources; the version update information includes the first version number of the updated detail page resources. Determining the device list corresponding to the device model, and for each device in the device list, determining the second version number corresponding to the historical detail page resources obtained by the device. Determining the resource information to be downloaded corresponding to the device according to the first version number and the second version number; the resource information to be downloaded is determined based on the differences between the detail page resources corresponding to the first version number and the second version number respectively. Determining the storage address of the resource information to be downloaded, establishing a first association relationship between the identification information of the device and the storage address of the resource information to be downloaded, and updating the first association relationship to the cache data.
2. The method according to claim 1, wherein The method further includes: Updating the second association relationship in the database according to the device identification and the resource information to be downloaded, so that when the storage address of the resource information to be downloaded corresponding to the device does not exist in the cache data, the storage address of the resource information to be downloaded is determined based on the database. Wherein, the second association relationship is used to indicate the association relationship between the device identification and the resource information to be downloaded, and the database includes the second association relationship and the resource information to be downloaded.
3. The method according to claim 1, characterized in that The determining the resource information to be downloaded corresponding to the device according to the first version number and the second version number includes: Determining the difference information between the historical detail page resources corresponding to the second version number and the detail page resources corresponding to the first version number; the difference information is used to indicate the update range of the detail page resources, and the update range includes the number of data changes and / or the number of added data in the detail page resources. Determining whether a preset condition for generating incremental update resources is satisfied according to the difference information; the preset condition is used to indicate that the update range of the detail page resources is less than a preset range, and the incremental update resources are used to indicate the updated part of the updated detail page resources relative to the historical detail page resources. If so, generating the incremental update resources, and determining the resource information to be downloaded corresponding to the device as the incremental update resources. If not, not generating the incremental update resources, and determining the resource information to be downloaded corresponding to the device as the updated detail page resources.
4. The method according to claim 3, wherein The determining the difference information between the historical detail page resources corresponding to the second version number and the detail page resources corresponding to the first version number includes: Determining a version sequence based on the second version number and the first version number, the version sequence includes the first version number, and one or more historical version numbers between the second version number and the first version number, and the version sequence is sorted based on time. Obtaining the update content corresponding to each version number in the version sequence according to a preset mapping relationship, the update content is used to indicate the content updated by the current version number relative to the previous version number, and the mapping relationship is used to indicate the corresponding relationship between the version number and the update content. Determine the difference information according to the update information corresponding to each of the version numbers.
5. The method according to claim 1, wherein After updating the cache data, it further includes: Determine the cache duration of the first association relationship according to the resource data corresponding to the device, where the resource data includes at least one data item of the update frequency of the first association relationship corresponding to the device and the request frequency of the device for the to-be-downloaded resource information; When the cache duration is reached, invalidate the first association relationship.
6. The method according to claim 5, characterized in that The determining the cache duration of the first association relationship according to the resource data corresponding to the device includes: Determine the sub-score corresponding to a single data item in the resource data; wherein, the update frequency is inversely proportional to the sub-score, and the request frequency is directly proportional to the sub-score; Determine the total score corresponding to the resource data according to the sub-score corresponding to a single data item; Determine the cache duration according to the total score; wherein, the total score is directly proportional to the cache duration.
7. A method for pushing device detail page resources, characterized in that, The method includes: Receive a request from a device to obtain resource information of a detail page, and determine whether there is a storage address of the to-be-downloaded resource information corresponding to the device in the cache data according to the request; If so, return the storage address of the to-be-downloaded resource information to the device, so that the device can obtain the corresponding to-be-downloaded resource information based on the storage address; if not, determine the storage address of the to-be-downloaded resource information corresponding to the device based on the database; Wherein, the request carries identification information of the device, the cache data includes a first association relationship between the identification information of the device and the storage address of the to-be-downloaded resource; the to-be-downloaded resource information is determined based on the historical detail page resources obtained by the device and the detail page resources newly updated by the operation end; the database includes the to-be-downloaded resource information and a second association relationship between the device identification and the to-be-downloaded resource information.
8. The method according to claim 7, characterized in that, The determining the storage address of the to-be-downloaded resource information corresponding to the device based on the database includes: Determine the to-be-downloaded resource information corresponding to the device based on the second association relationship in the database; Obtain the storage location of the to-be-downloaded resource information in the database, and the storage location is the storage address of the to-be-downloaded resource information.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored program, wherein the program, when running, executes the method for updating resource information of a device detail page according to any one of claims 1 to 6, and / or executes the method for pushing resource information of a device detail page according to any one of claims 7 or 8.
10. An electronic device, comprising a memory and a processor, characterized in that, A computer program is stored in the memory, and the processor is configured to execute the method for updating resource information of a device detail page according to any one of claims 1 to 6, and / or execute the method for pushing resource information of a device detail page according to any one of claims 7 or 8 through the computer program.