Mobile terminal application access method and device, electronic equipment and storage medium
By saving the static resource cache package of mobile applications on the server side and combining preheating, caching, pushing and pre-submission processes, the problem of high cost of hardware access is solved, and efficient and low-cost data access is achieved in harsh network environments.
Patent Information
- Application Number
- CN202410026842.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-08
- Publication Date
- 2025-07-08
AI Technical Summary
When the prior art improves the access efficiency of mobile applications, it is often solved from a hardware perspective. It is costly and can easily lead to dirty or wrong data in the system, and it is not effective in harsh network environments.
By saving the tenant's static resource cache package on the server side, and determining whether the user needs to upgrade when entering the application, dynamic content requests are made by combining the warm-up process, cache process, push process and pre-submission process to reduce the number of network requests and ensure data consistency and correctness.
While reducing costs, it improves the access efficiency and response speed of mobile applications in harsh network environments, reduces the time-consuming time of multiple submissions caused by cache expiration, and ensures the correctness and consistency of data.
Smart Images

Figure CN120281810A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of network communication technologies, and in particular, to a method, device, electronic device, and storage medium for accessing mobile applications. Background Art
[0002] With the in-depth development of modern social science and technology and the rapid popularization of the Internet industry, the need for enterprise office mobility and channel mobility has emerged. Currently, widely known mobile office systems such as OA systems, ERP systems, email systems, and CRM systems have become indispensable tools for enterprise office. The rapid development of the mobile Internet, the large-area coverage of wireless networks such as 5G / Wi-Fi, and the widespread use of smartphones and tablets. In addition to personal applications, users' requirements for mobile phone applications also include the ability to perform mobile office, which has promoted the popularization of industry mobility. However, in the process of using mobile devices, there has always been a problem, that is, "poor signal", which generally refers to all problems of unsmooth system operation. As the mobile network evolves from 2G to 5G and the Wi-Fi standard evolves from IEEE 802.11 to Wi-Fi CERTIFIED6, users' complaints about "poor signal" have never stopped. To solve this pain point, currently, more efforts are made from the hardware perspective. However, improving the access efficiency through hardware is costly and easily leads to the generation of dirty data or incorrect data in the system. Summary of the Invention
[0003] In view of this, an object of the present invention is to provide a method, device, electronic device, and storage medium for accessing mobile applications, which can improve the access efficiency of mobile applications in a harsh network environment and ensure the correctness and consistency of data while reducing costs.
[0004] To achieve the above object, the technical solutions adopted in the embodiments of the present invention are as follows:
[0005] In a first aspect, an embodiment of the present invention provides a method for accessing a mobile application, including: when a user enters the home page of the mobile application, if the static resource cache package of the tenant in the mobile application needs to be upgraded, downloading the corresponding static resource cache package from the server side according to the tenant's serial number; where the server side is the storage server closest to the usage scenario of the mobile application; when the user enters the function module of the mobile application, making dynamic content requests through a warm-up process, a caching process, a push process, and a pre-pull communication process.
[0006] In one embodiment, the preheating process includes: when the user enters the function module of the mobile application, according to the current time and the user's current location, the preheating data is pre-returned from the server side to the mobile application; wherein, the preheating data includes: preset data and / or personal historical data pre-set by the user.
[0007] In one embodiment, the preheating process further includes: regularly obtaining usage data related to the user's personal habits of using the mobile application, and learning and optimizing based on the characteristic data of the usage data related to personal habits to obtain personal historical data.
[0008] In one embodiment, the caching process includes: when receiving data pushed by the server side and / or uploaded by the user, judging the type of the data according to the flag bit of the data; wherein, the flag bit at least includes: lazy data and non-lazy data; if the data is lazy data, then when the lazy data is received for the first time, the lazy data is cached to the mobile application; wherein, the lazy data is data that does not change within a preset time period.
[0009] In one embodiment, the pushing process includes: when the cached data of the mobile application changes, the changed data is automatically pushed to the mobile application for caching through the server side.
[0010] In one embodiment, the pre-submission process includes: when the user submits a form, the version information of the cached data in the mobile application used in the form is pre-uploaded to the server side for verification; if the version information passes the verification, the form is uploaded to the server side; if the version information has expired, new data is returned from the server side to the mobile application, and the form is modified based on the new data, and the modified form is uploaded to the server side.
[0011] In a second aspect, an access device for a mobile application provided by an embodiment of the present invention includes: a static request module, configured to, when the user enters the home page of the mobile application, if the static resource cache package of the tenant in the mobile application needs to be upgraded, download the corresponding static resource cache package from the server side according to the tenant's serial number; wherein, the server side is the storage server closest to the usage scenario of the mobile application; a dynamic request module, configured to, when the user enters the function module of the mobile application, perform dynamic content requests through the preheating process, the caching process, the pushing process, and the pre-submission process.
[0012] In one embodiment, the dynamic request module includes: a preheating unit, configured to: when the user enters the function module of the mobile application, according to the current time and the user's current location, pre-return the preheating data from the server side to the mobile application; wherein, the preheating data includes: preset data and / or personal historical data pre-set by the user.
[0013] In a third aspect, an embodiment of the present invention provides an electronic device, including a processor and a memory. The memory stores computer-executable instructions that can be executed by the processor, and the processor executes the computer-executable instructions to implement the steps of the method according to any one of the above first aspects.
[0014] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored. When the computer program is run by a processor, it executes the steps of the method according to any one of the above first aspects.
[0015] The embodiments of the present invention bring the following beneficial effects:
[0016] For the access method, device, electronic device, and storage medium of the mobile application provided in the embodiments of the present invention, when a user enters the home page of the mobile application, if the static resource cache package of the tenant in the mobile application needs to be upgraded, the corresponding static resource cache package is downloaded from the server end according to the serial number of the tenant; wherein, the server end is the storage server closest to the usage scenario of the mobile application. When the user enters the function module of the mobile application, dynamic content requests are made through the warm-up process, caching process, push process, and prefetching process. The above method saves the process cost caused by upgrading the mobile application and reduces the hardware cost by storing the static resource cache package (with a serial number) of the tenant in the storage server closest to the usage scenario of the mobile application, and determining whether the static resource cache package of the current tenant needs to be upgraded when the user enters the home page of the mobile application. If it needs to be upgraded, the corresponding static resource cache package is downloaded according to the serial number, so that it is not necessary to upgrade the mobile application every time the static content is updated. In addition, in the above method, when making a network request for dynamic content, dynamic content requests can be made through the warm-up process, caching process, push process, and prefetching process, which can reduce the number of network requests, improve the response speed of the application, and avoid the time-consuming caused by multiple submissions due to cache expiration through the prefetching process, ensuring the correctness and consistency of the data.
[0017] Other features and advantages of the present invention will be described in the following specification, and, in part, will be obvious from the specification, or will be understood by implementing the present invention. The objectives and other advantages of the present invention are achieved and obtained by the structures specifically pointed out in the specification, claims, and drawings.
[0018] To make the above objectives, features, and advantages of the present invention more obvious and understandable, the following specific preferred embodiments are given, and in conjunction with the accompanying drawings, the detailed description is as follows. Description of the Drawings
[0019] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the following will briefly introduce the drawings required for the description of the specific embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.
[0020] Figure 1 It is a flowchart of an access method for a mobile application provided by an embodiment of the present invention;
[0021] Figure 2 It is a timing diagram of an access method for a mobile application provided by an embodiment of the present invention;
[0022] Figure 3 It is a schematic structural diagram of an access device for a mobile application provided by an embodiment of the present invention;
[0023] Figure 4 It is a schematic structural diagram of an electronic device provided by an embodiment of the present invention. Specific Embodiments
[0024] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the following will clearly and completely describe the technical solutions of the present invention with reference to the accompanying drawings. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts fall within the scope of protection of the present invention.
[0025] Currently, in the prior art, most solutions to the problem of "poor signal" are from the perspective of hardware to improve access efficiency, mainly including the following:
[0026] (1) Pure hardware solution: By purchasing and deploying more wireless routers or wireless APs (Access Points), or applying to the operator to build additional wireless base stations to improve the network environment and thus accelerate the access speed.
[0027] (2) Purchase a CDN (Content Delivery Network) to accelerate the access speed of the public cloud.
[0028] (3) Simply cache the access resources (such as static HTML, CSS, JavaScript, etc.) built-in to the mobile terminal to reduce the requirements for access resources and thus accelerate the access speed.
[0029] (4) Simply cache the request data and set the cache expiration period for the relevant request returns to skip the access resource requirements and thus accelerate the access speed.
[0030] However, existing methods all have certain drawbacks:
[0031] (1) The main drawback of a pure hardware solution is the high cost. The cost of purchasing equipment and deployment is extremely high. At the same time, it is not applicable when there are severe interference sources nearby (near strong electromagnetic field equipment), where the signal will be greatly affected.
[0032] (2) Purchasing a CDN can speed up the access speed of Internet resources, but it will not improve the access quality of the local area network / Wi-Fi, and it is not applicable when the mobile terminal is in a Wi-Fi blind area.
[0033] (3) Simply caching the accessed resources internally in the mobile device will improve the running efficiency of mobile applications in a poor network environment, but it will lead to an increase in development costs. Since simply caching the accessed resources internally in the mobile device will require upgrading the APP every time the content is updated, thus triggering the entire process of overall APP changes, such as: from overall testing to submission and review in the APP store.
[0034] (4) The scheme of simply caching the requested data and setting the cache expiration period for the relevant request returns has the risk of data inconsistency. Assuming that the relevant cached data is still within the expiration period, but an actual change has occurred, and the user submits based on the outdated (incorrect) data, it will lead to the generation of dirty data / incorrect data in the system.
[0035] Based on this, an access method, device, electronic device, and storage medium for a mobile application provided by an embodiment of the present invention can improve the access efficiency of mobile applications in a poor network environment, and ensure the correctness and consistency of data while reducing costs.
[0036] To facilitate the understanding of this embodiment, first, a detailed introduction is given to an access method for a mobile application disclosed in an embodiment of the present invention. This method can be executed by an electronic device, such as a smart phone, a computer, a tablet computer, etc. Refer to Figure 1 The flowchart of an access method for a mobile application shown, which indicates that the method mainly includes the following steps S101 to step S102:
[0037] Step S101: When the user enters the home page of the mobile application, if the static resource cache package of the tenant in the mobile application needs to be upgraded, download the corresponding static resource cache package from the server according to the tenant's serial number.
[0038] In one embodiment, the static resource cache package is stored in the storage server (i.e., the server side) closest to the usage scenario of the APP (i.e., the mobile application). The static resource cache package has a serial number (including: tenant ID and version number). For example, for an APP based on Internet SAAS operation, the static resource cache package is placed on the cloud storage node / CDN node with the best line; for a private deployment in an offline mode, it is stored on the hard disk / NAS storage node closest to the main router.
[0039] When the user enters the home page of the mobile application, it is judged through the interface whether the static resource cache package of the tenant in the current APP needs to be upgraded. If it needs to be upgraded, the corresponding static resource cache package is downloaded according to the serial number of the tenant. When there is a static resource cache package, all static requests of the APP do not require network connection, thus avoiding the problem of slow APP response caused by request timeout due to a large number of packet losses in a poor network environment. At the same time, in this embodiment, since the static resource cache package is not built into the APP, it will not happen that the APP needs to be upgraded every time the static content is updated, and a whole set of process costs caused by APP upgrade will not occur, thus reducing the cost.
[0040] Step S102: When the user enters the function module of the mobile application, dynamic content requests are made through the preheating process, caching process, pushing process, and pre-withdrawal process.
[0041] In one embodiment, in addition to static content, the network requests of the APP also include dynamic content. The optimization of dynamic content requests mainly includes: preheating process, caching process, pushing process, and pre-withdrawal process.
[0042] The preheating process includes: when the user enters the function module of the mobile application, according to the current time and the user's current location, the preheating data is returned to the mobile application from the server side in advance; among them, the preheating data includes: preset data and / or personal historical data preset by the user.
[0043] In specific implementation, when a user enters a function module of the mobile application, preheating data (with version numbers) that the user may use can be provided to the user according to the user's regular operations. For example, when a doctor receives a patient, the doctor can query the patient's past medical history data in advance and return it to the mobile application. When the doctor goes to see the patient, there is no need to wait for the time-consuming network request, and the relevant data can be quickly provided to the doctor, thus accelerating the operation performance of the APP. At the same time, the data required by the user may vary at different times and locations. Therefore, in this embodiment, according to the current time and the user's current location, the preheating data will provide the user with relevant information according to different situations. For example, the preheating data required by a doctor during ward rounds and during diagnosis in the consulting room may be different, and the preheating data required by the doctor during ward rounds at different times may also be different. Therefore, in this embodiment, the location of the doctor can be obtained through the mobile device, and combined with the current time, the preheating data required by the doctor can be provided to the doctor in advance.
[0044] Furthermore, in the preheating process, the preheating data includes: preset data and / or personal historical data pre-set by the user. The user can pre-set the preset data in the APP according to their own usage habits, or the APP background program can regularly obtain the usage data related to the user's personal habits of using the mobile application, and learn and optimize based on the characteristic data of the usage data related to personal habits to obtain personal historical data. Specifically, the APP background program regularly obtains the usage data related to the user's personal habits of using the mobile application, and automatically learns and optimizes according to the characteristic data to obtain personal historical data, so that it can better understand and master the user's usage habits, and make the subsequent preheating data more cost-effective.
[0045] The caching process includes: when receiving the data pushed by the server side and / or uploaded by the user, judging the type of the data according to the flag bit of the data; wherein, the flag bit at least includes: lazy data and non-lazy data; if the data is lazy data, then when the lazy data is received for the first time, the lazy data is cached to the mobile application; wherein, the lazy data is data that does not change within a preset time period.
[0046] In specific implementation, due to business characteristics, some dynamic content does not change within a certain period of time, which is inert data. In the embodiments of the present invention, a flag bit can be added to the data to distinguish between inert data and non-inert data. When the APP receives the data pushed by the server side and / or uploaded by the user, if it is inert data, it only needs to be cached once, that is, when the inert data is received for the first time, the inert data is cached to the mobile application, and subsequent requests of the same kind do not need to be initiated, thereby improving the running performance of the APP. For example, for the patient's past medical history, when the patient comes to see a doctor, the past medical history does not change. Therefore, it only needs to be requested once and cached to the APP, and the same request does not need to be initiated later. In addition, in this embodiment, additional attributes are required to assist in controlling the caching of dynamic content. For example, version information can be used to determine whether the cached data has been updated.
[0047] The push process includes: when the cached data of the mobile application changes, the changed data is automatically pushed to the mobile application for caching through the server side.
[0048] In specific implementation, assume that the cached data on the APP side has changed. In the existing processing scenarios, either no processing is performed, resulting in dirty data, or an error is reported on the backend and the page is refreshed, and all data is reloaded. The latter will cause lag regardless of the network situation. Therefore, in the embodiments of the present invention, after the data is preheated, loaded, and cached by the APP side, when it changes, the changed data can be actively pushed by the server side to the mobile application through the flag bit, so as to ensure that the cached data on the APP side is the latest version, without the need for additional network requests, improving the response speed of the APP and making the use of the APP smoother.
[0049] In one implementation manner, there may be a part of data between inert data and non-inert data in the cached data of the APP segment. This part of the data will change, but it will not always change. For example, the patient's examination data will change when the patient undergoes an examination, and the data will not change until the patient's next examination. Therefore, in the embodiments of the present invention, after the patient undergoes an examination and the examination data is generated, the server side can actively push the new examination data to the APP side for caching.
[0050] In addition, for data such as drug inventory that changes frequently, if data is pushed every time the data changes, multiple network requests will be made, resulting in APP lag and low access efficiency. Therefore, in the embodiments of the present invention, for such data, by setting a threshold, after the pharmacy inventory reaches the threshold, the server side will push the changed data to the APP, thereby reducing the number of data pushes and improving the access efficiency.
[0051] In the embodiments of the present invention, the adopted push method includes two technical implementation methods: one is WebSocket and Server Send Event under the html5 standard, and the other is a compatibility solution that actively pulls new information by comparing the version codes carried in the traditional request returns. These two methods can set the priority through configuration and be configured according to the characteristics of the network environment.
[0052] The pre-submission process includes: when the user submits a form, the version information of the cached data in the mobile application used in the form is pre-uploaded to the server side for verification; if the version information passes the verification, the form is uploaded to the server side; if the version information has expired, the server side returns the new data to the mobile application, modifies the form based on the new data, and uploads the modified form to the server side.
[0053] In specific implementation, when the network condition is poor, it is necessary to be vigilant that the server side may not be successful in pushing the latest data to the client side. In this case, operations such as form submission may be detected by the server side that the input parameters are expired, resulting in a page refresh after an error is reported and all data being reloaded. Based on this, in the embodiments of the present invention, the pre-submission process is adopted. When the form is submitted and the user can click the submit button, the version information of the cached data in the mobile application used in this request is first submitted to the backend (i.e., the server side) to verify the timeliness of the data. After the backend program verifies, the entire page is submitted. If the version of some cached data expires during the backend verification, the latest data is returned to the APP side through the interface, thereby avoiding the time-consuming caused by multiple submissions due to expired cached data and ensuring the correctness and consistency of the data. At the same time, since the network requests are minimized, the running fluency of the APP can be optimized to the maximum extent.
[0054] The access method of the mobile application provided in the embodiments of the present invention saves the static resource cache package (with a serial number) of the tenant in the storage server closest to the usage scenario of the mobile application. When the user enters the home page of the mobile application, it is judged whether the static resource cache package of the current tenant needs to be upgraded. If it needs to be upgraded, the corresponding static resource cache package is downloaded according to the serial number, so that the situation where the mobile application needs to be upgraded every time the static content is updated will not occur, saving the process cost caused by upgrading the mobile application and reducing the hardware cost at the same time; in addition, when dynamically requesting network content in the above method, the dynamic content request can be carried out through the warm-up process, cache process, push process and pre-submission process, which can reduce the number of network requests, improve the response speed of the application, and the pre-submission process can avoid the time-consuming caused by multiple submissions due to cache expiration and ensure the correctness and consistency of the data.
[0055] For ease of understanding, an embodiment of the present invention also provides a timing diagram of an access method for a mobile application. Refer to Figure 2 As shown in the figure, when the user logs in to the APP, the static login cache version is submitted to the cache data management backend program. If the static resource package needs to be upgraded, the download address of the latest version of the static resource package is returned to the APP side, and the user is prompted that there is a new resource package to be downloaded. When the user enters the APP home page, the new static resource package is downloaded, and the function list is displayed to the user.
[0056] When the user enters the function module, an asynchronous notification is sent to the cache data preheating backend program to preheat the microservice. The cache data preheating backend program reads the preset data and personal historical data, and pushes the data to the APP side.
[0057] When the cache data on the APP side changes, the cache data management backend program retrieves the active users who need to be notified, and pushes the changed data to the APP side for caching.
[0058] When the user provides a form, the version information of the cache data can be submitted to the cache data management backend program for verification in advance. If the version of some cache data expires during backend verification, the latest data is returned to the APP side through the interface, and the local cache is updated.
[0059] In addition, the backend program of the corresponding function module of the APP can synchronize the usage data related to personal habits to the cache data preheating backend program for learning and optimization every day, and store the optimized personal preference historical data.
[0060] The above method provided by the embodiment of the present invention, without incurring hardware costs, maximizes the reduction of the number of network requests, thereby improving the usability of the APP, accelerating the response speed and usage efficiency of the APP, especially in an environment with poor Internet / Wifi signals.
[0061] For the access method of the mobile application provided in the foregoing embodiment, an embodiment of the present invention also provides an access device for a mobile application. Refer to Figure 3 As shown in the structural schematic diagram of an access device for a mobile application, it is shown that the device mainly includes the following parts:
[0062] A static request module 301, configured to, when the user enters the home page of the mobile application, if the static resource cache package of the tenant in the mobile application needs to be upgraded, download the corresponding static resource cache package from the server side according to the tenant's serial number; wherein, the server side is the storage server closest to the usage scenario of the mobile application.
[0063] The dynamic request module 302 is used to perform dynamic content requests through a warm-up process, a caching process, a push process, and a pre-withdrawal communication process when a user enters a functional module of the mobile application.
[0064] For the access device of the mobile application provided in the embodiments of the present invention, by storing the static resource cache package (with a serial number) of the tenant in the storage server closest to the usage scenario of the mobile application, when the user enters the home page of the mobile application, it is determined whether the static resource cache package of the current tenant needs to be upgraded. If an upgrade is required, the corresponding static resource cache package is downloaded according to the serial number, so that the situation where the mobile application needs to be upgraded every time the static content is updated will not occur, saving the process cost caused by upgrading the mobile application and reducing the hardware cost at the same time. In addition, when the above device requests dynamic content over the network, it can perform dynamic content requests through a warm-up process, a caching process, a push process, and a pre-withdrawal communication process, which can reduce the number of network requests, improve the response speed of the application, and avoid the time-consuming caused by multiple submissions due to cache expiration through the pre-withdrawal communication process, ensuring the correctness and consistency of the data.
[0065] In one implementation manner, the above dynamic request module 302 includes: a warm-up unit, which is used to: when a user enters a functional module of the mobile application, pre-return warm-up data to the mobile application through the server side according to the current time and the user's current location; where the warm-up data includes: preset data and / or personal historical data pre-set by the user.
[0066] In one implementation manner, the above warm-up unit is further used to: regularly obtain usage data related to the personal habits of the user using the mobile application, and perform learning and optimization based on the characteristic data of the usage data related to personal habits to obtain personal historical data.
[0067] In one implementation manner, the above dynamic request module 302 includes: a caching unit, which is used to: when receiving data pushed by the server side and / or uploaded by the user, judge the type of the data according to the flag bit of the data; where the flag bit includes at least: lazy data and non-lazy data; if the data is lazy data, when the lazy data is received for the first time, the lazy data is cached to the mobile application; where the lazy data is data that does not change within a preset time period.
[0068] In one implementation manner, the above dynamic request module 302 includes: a push unit, which is used to: when the cached data of the mobile application changes, automatically push the changed data to the mobile application for caching through the server side.
[0069] In one embodiment, the dynamic request module 302 includes: a pre-submission unit, configured to: when a user submits a form, upload the version information of the cached data in the mobile application used in the form to the server side in advance for verification; if the version information passes the verification, upload the form to the server side; if the version information has expired, return new data to the mobile application through the server side, modify the form based on the new data, and upload the modified form to the server side.
[0070] It should be noted that for the device provided in the embodiments of the present invention, the implementation principle and the technical effects produced are the same as those in the foregoing method embodiments. For the sake of brief description, for the parts not mentioned in the device embodiments, reference may be made to the corresponding content in the foregoing method embodiments.
[0071] The embodiments of the present invention also provide an electronic device. Specifically, the electronic device includes a processor and a storage device; a computer program is stored on the storage device, and when the computer program is run by the processor, it executes the method described in any one of the above embodiments.
[0072] Figure 4 FIG. 10 is a schematic structural diagram of an electronic device provided in an embodiment of the present invention. The electronic device 100 includes: a processor 40, a memory 41, a bus 42, and a communication interface 43. The processor 40, the communication interface 43, and the memory 41 are connected through the bus 42; the processor 40 is configured to execute an executable module stored in the memory 41, such as a computer program.
[0073] Among them, the memory 41 may include a high-speed random access memory (RAM, Random Access Memory), and may also include a non-volatile memory, such as at least one disk memory. Through at least one communication interface 43 (which may be wired or wireless), a communication connection is established between the system network element and at least one other network element, and the Internet, a wide area network, a local area network, a metropolitan area network, etc. can be used.
[0074] The bus 42 may be an ISA bus, a PCI bus, an EISA bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For the sake of convenience of representation, Figure 4 only a bidirectional arrow is used in FIG. 10, but it does not mean that there is only one bus or one type of bus.
[0075] Among them, the memory 41 is used to store a program. After receiving an execution instruction, the processor 40 executes the program. The method executed by the device defined by the flow process disclosed in any one of the foregoing embodiments of the present invention can be applied to the processor 40 or implemented by the processor 40.
[0076] The processor 40 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method may be completed by the integrated logic circuit of the hardware in the processor 40 or the instructions in the form of software. The above-mentioned processor 40 may be a general-purpose processor, including a central processing unit (CPU for short), a network processor (NP for short), etc.; it may also be a digital signal processor (DSP for short), an application specific integrated circuit (ASIC for short), a field-programmable gate array (FPGA for short), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components. It can implement or execute various methods, steps, and logic block diagrams disclosed in the embodiments of the present invention. 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 embodiments of the present invention may be directly embodied as being executed and completed by a hardware decoding processor, or executed and completed by a combination of the hardware and software modules in the decoding processor. The software module may be located in a mature storage medium in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. This storage medium is located in the memory 41, and the processor 40 reads the information in the memory 41 and combines its hardware to complete the steps of the above method.
[0077] The computer program product of the readable storage medium provided by the embodiments of the present invention includes a computer-readable storage medium storing program code, and the instructions included in the program code can be used to execute the method described in the foregoing method embodiments. For specific implementation, reference may be made to the foregoing method embodiments, which will not be elaborated herein.
[0078] If the above-described 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 may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention. The aforementioned storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical discs that can store program codes.
[0079] Finally, it should be noted that the above-described embodiments are only specific implementation manners of the present invention, used to illustrate the technical solutions of the present invention, and are not intended to limit them. The protection scope of the present invention is not limited thereto. Although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: any person skilled in the technical field can still modify the technical solutions described in the foregoing embodiments, or can easily conceive of changes, or perform equivalent replacements for some of the technical features; and these modifications, changes, or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be covered by the protection scope of the present invention. Therefore, the protection scope of the present invention should be subject to the protection scope of the claims.
Claims
1. A method for accessing a mobile application, characterized in that including: When a user enters the home page of the mobile application, if the static resource cache package of the tenant in the mobile application needs to be upgraded, download the corresponding static resource cache package from the server according to the serial number of the tenant; wherein, the server is the storage server closest to the usage scenario of the mobile application; When the user enters the function module of the mobile application, perform dynamic content requests through the preheating process, caching process, pushing process, and pre-submission process.
2. The method according to claim 1, characterized in that, The preheating process includes: When the user enters the function module of the mobile application, according to the current time and the location where the user is currently located, pre-return the preheating data from the server to the mobile application in advance; wherein, the preheating data includes: the preset data and / or personal historical data preset by the user.
3. The method according to claim 2, wherein The preheating process further includes: Regularly obtain the usage data related to the personal habits of the user using the mobile application, and perform learning and optimization based on the characteristic data of the usage data related to the personal habits to obtain personal historical data.
4. The method according to claim 1, wherein The caching process includes: When receiving the data pushed by the server and / or uploaded by the user, determine the type of the data according to the flag bit of the data; wherein, the flag bit includes at least: lazy data and non-lazy data; If the data is lazy data, when the lazy data is received for the first time, cache the lazy data to the mobile application; wherein, the lazy data is the data that does not change within a preset time period.
5. The method according to claim 1, wherein The pushing process includes: When the cached data of the mobile application changes, automatically push the changed data to the mobile application through the server for caching.
6. The method according to claim 1, wherein The pre-submission process includes: When the user submits a form, upload the version information of the cached data in the mobile application used in the form to the server in advance for verification; If the version information passes the verification, upload the form to the server; If the version information has expired, return new data to the mobile application through the server, modify the form based on the new data, and upload the modified form to the server.
7. An access device for a mobile application, characterized in that, including: A static request module, which is used to, when a user enters the home page of the mobile application, if the static resource cache package of the tenant in the mobile application needs to be upgraded, download the corresponding static resource cache package from the server according to the serial number of the tenant; wherein, the server is the storage server closest to the usage scenario of the mobile application; A dynamic request module, which is used to, when the user enters the function module of the mobile application, perform dynamic content requests through the preheating process, caching process, pushing process, and pre-submission process.
8. The device according to claim 7, characterized in that, The dynamic request module includes: a preheating unit, configured to: when the user enters the function module of the mobile application, pre-return preheating data to the mobile application through the server side according to the current time and the location where the user is currently located; wherein, the preheating data includes: preset data and / or personal historical data preset by the user.
9. An electronic device, characterized in that, It includes a processor and a memory, the memory stores computer-executable instructions that can be executed by the processor, and the processor executes the computer-executable instructions to implement the steps of the method according to any one of claims 1 to 6.
10. A computer-readable storage medium, on which a computer program is stored, characterized in that, When the computer program is run by the processor, it executes the steps of the method according to any one of claims 1 to 6 above.