Application updating method and system
Patent Information
- Application Number
- CN202311699016.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-12
- Publication Date
- 2025-03-07
- Estimated Expiration
- Not applicable · inactive patent
Smart Images

Figure CN119576358A_ABST
Abstract
Description
Technical Field
[0001] One or more embodiments of the present specification relate to the technical field of software update, and in particular, to an application update method and system. Background Art
[0002] In today's digital age, mobile applications (APPs) have become an important part of people's daily lives. With the continuous upgrading of software versions, the update process of APPs often requires users to manually update, which undoubtedly brings certain inconveniences to users. Therefore, how to achieve automatic updates of APPs to reduce the user's operation steps and improve the user experience has become a problem that needs to be solved urgently.
[0003] When there are operational problems during or after the automatic update process, human intervention is often required to solve them, and the APP operation problems cannot be solved automatically. Summary of the invention
[0004] One or more embodiments of this specification describe an application update method and system that can implement automatic updates and roll back to a previous version when the installation of a new version affects the application runtime.
[0005] In a first aspect, an embodiment of the present specification provides an application update method, including: When an application update is detected on the server, the update package of the application is downloaded; When an operation problem occurs during the installation of an update package, the installation of the update package is terminated and the application is restored to run under the version before the update; or, when an operation problem occurs after the installation of the update package, the installation of the update package is canceled and the application is run under the version before the update; Feedback the installation status and operation problems of update packages with operation problems to the server; When the server determines that there is a problem with the update package, it receives a patch or a replacement update package sent by the server, and adds and stores the patch at the update package of the corresponding version in the download list, or overwrites and stores the replacement update package at the update package of the corresponding version in the download list; Retry installing the update package with the patch or replace the update package.
[0006] In some implementations, when an application update is detected on the server, downloading the update package of the application includes: Regularly detect the server and obtain the update package list in the server; Compare the update package list in the server with the download list at the application, and download the latest update package that does not exist in the download list from the update package list in the server; After the update package is downloaded, the information of the corresponding update package in the update package list is synchronized to the download list; wherein the update package list stores the version number, update package, and upload time; and the download list stores the version number, update package, and download time.
[0007] In some embodiments, the method further comprises: After the update package is successfully installed, the installation is terminated, or the installation is canceled, the installation status and installation time of the update package are fed back to the installation list; wherein the installation list stores the version number, installation status, and installation time, and the installation status includes successful installation, terminated installation, not installed, and historical installation; an update package whose installation is terminated due to an operation problem is in an installation terminated state, an update package whose installation is canceled due to an operation problem is in an not installed state, an update package after successful installation is in an installation successful state, and an update package of a version before the update is in a historical installation state after being canceled due to successful installation of the update package of the updated version.
[0008] In some implementations, when an operation problem occurs during the installation of the update package, the installation of the update package is terminated, and the application is restored to run in the version before the update, including: When installing the update package, the application runs under the version before the update, and the update package is installed silently; When an operating problem occurs during the installation of an update package, the installation of the update package is terminated and the application resumes running under the version before the update.
[0009] In some implementations, when an operation problem occurs after installing an update package, uninstalling the update package and running the application under the version before the update includes: After installing the update package and not restarting the application, if there is a running problem, uninstall the update package and restore the application to the version before the update; After installing the update package and restarting the application, if a running problem occurs, uninstall the update package and switch the application from the updated version back to the version before the update.
[0010] In some implementations, after the update package is installed and the application is restarted, when a running problem occurs, the update package is uninstalled, and the application is switched from the updated version to the version before the update, including: After installing the update package and restarting the application, if there is a running problem, the foreground will uninstall the update package and the background will reinstall the version before the update; After restarting the application again, the application runs under the version before the update; The background reinstallation of the version before the update includes: Obtain all historical update package information before the installation time of the update package from the installation list; Selecting an update package with the earliest installation time and the installation status of historical installation from the historical update package information, and determining it as the update package of the version before the update; According to the version number of the update package of the version before the update, the update package in the download list is obtained, and the update package of the version before the update is reinstalled in the background; Among them, the installation list stores the version number, installation status, and installation time, and the installation status includes successful installation, aborted installation, not installed, and historical installation; the update package whose installation was aborted due to operation problems is in the aborted installation state, the update package whose installation was canceled due to operation problems is in the not installed state, the update package after successful installation is in the successful installation state, and the update package of the version before the update is canceled due to the successful installation of the update package of the updated version is in the historical installation state; the download list stores the version number, update package, and download time.
[0011] In some embodiments, the method further comprises: When a version switching instruction is received, the update package under the corresponding version number in the download list is obtained according to the version number in the version switching instruction; When running under the version before switching, the update package of the version after switching is silently installed.
[0012] In some embodiments, after the step of terminating the installation of the update package and resuming the application to run in the version before the update when an operation problem occurs during the installation of the update package; or after the step of canceling the installation of the update package and running the application in the version before the update when an operation problem occurs after the installation of the update package, the method further includes: In some implementations, after feeding back the installation status of the update package with the operation problem and the operation problem to the server, the method further includes: When the server determines that there is a conflict between the update package and the application operation, a retry installation instruction sent by the server is received, and the update package is retried to be installed after the application is shut down.
[0013] In some implementations, before feeding back the installation status and the operation problem of the update package with the operation problem to the server, the method includes: Obtain the capacity of the update package with the running problem from the download list, and obtain the capacity of the corresponding update package in the update package list in the server; When determining whether the capacity sizes of the two are consistent, if not, re-download the update package with the operation problem from the server, and overwrite and store its related information in the installation list to execute the reinstallation process; if so, the installation status and operation problem of the update package with the operation problem are fed back to the server.
[0014] In a second aspect, an embodiment of the present specification provides an application update system, including: The detection module is used to trigger the download module to work when an application update is detected on the server; Download module, used to download the update package of the application; Installation module, used to install and decompress update packages; The running module is used to terminate the installation of the update package by the installation module when an operation problem occurs during the installation of the update package, and the application resumes running under the version before the update; or, when an operation problem occurs after the update package is installed, trigger the installation module to deinstall the update package, and the application runs under the version before the update.
[0015] The beneficial effects brought by the technical solutions provided by some embodiments of this specification include at least: In one or more embodiments of the present specification, automatic downloading and installation of update packages are achieved by detecting application updates on a server; when an application has an operational problem while installing the update package or thereafter, the application can be automatically restored or switched to a version before the update; further, when operational problems occur multiple times, the installation process can be automatically retried based on the server's feedback on the problem, thereby reducing the user's operating steps, improving the user experience, and providing timely and targeted solutions to user misoperations or problems with the new version, thereby improving the success rate of version updates. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the technical solutions in the embodiments of this specification, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0017] Figure 1 A schematic diagram of the use of an application update method provided in an embodiment of this specification in an actual application scenario; Figure 2 A flowchart of an application update method provided in an embodiment of this specification; Figure 3 A structural block diagram of an application update system provided in an embodiment of this specification. DETAILED DESCRIPTION
[0018] The technical solutions in the embodiments of this specification will be described clearly and completely below in conjunction with the drawings in the embodiments of this specification.
[0019] The terms "first", "second", "third", etc. in the description and claims of this specification and the above-mentioned drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but optionally includes steps or units that are not listed, or optionally includes other steps or units inherent to these processes, methods, products or devices.
[0020] In the past, application upgrades required manual operation by users. In response to this, most of the existing automatic update mechanisms are based on the app store. Upon the developer's application, the app store will publish the upgraded version of the App to the store and remind the user to update. This mechanism has high requirements for user operation and is highly dependent on the app store. Other update mechanisms, such as the push notification mechanism, require users to choose this update; and the in-app update mechanism requires clicking the update option in the app to check and update the app.
[0021] Regardless of which of the above methods is used, the user is required to intervene in the update process multiple times (including update package download and update package installation), and the in-app update mechanism also requires the user to check whether there is an update.
[0022] In order to solve the running problem of the new version, the prior art proposes a solution of rolling back the version, but the rollback is only performed for the convenience of operation, ignoring the running problem itself, and the new version update problem is not solved.
[0023] To address this problem, the embodiments of this specification propose an application update solution that can automatically download and install update packages by detecting the update status of the server; when operation problems occur during or after the update, it can automatically restore or switch back to the previous version; and retry the new version update for different operation problems to improve the success rate of the new version update See also Figure 2 , Figure 2 A flowchart of an application updating method provided by an embodiment of this specification is shown.
[0024] like Figure 2 As shown, the application update method may specifically include the following steps: Step 102, when an application update is detected on the server, download the update package of the application; Step 104, when an operation problem occurs during the installation of the update package, the installation of the update package is terminated, and the application is restored to run under the version before the update; or, when an operation problem occurs after the installation of the update package, the installation of the update package is canceled, and the application is run under the version before the update; Step 106, feeding back the installation status of the update package with the running problem and the running problem to the server; Step 108, when the server determines that there is a problem with the update package, the server receives a patch or a replacement update package sent by the server, and adds and stores the patch at the update package of the corresponding version in the download list, or overwrites and stores the replacement update package at the update package of the corresponding version in the download list; Step 110: Retry installing the update package with the patch or replacing the update package.
[0025] The method of the embodiment of this specification is executed on the application APP side. Figure 1 The communication architecture between APP and server is shown. The developer uploads the new version of the application update package to the server. The APP system is connected to the server and regularly checks whether there are new updates on the server through the API interface on the APP. When there are new update packages, the download and installation process is executed. When an application operation problem is found during or after the installation, the application is run under the version before the update. Furthermore, the operation problem is fed back to the server, and the server solves the problem with the update package itself, enters the retry process, and remediates the update package installation.
[0026] The following is a detailed description of the embodiments of the present invention with reference to specific examples and embodiments. Figure 2 Each step is described separately.
[0027] The step 102 can realize automatic downloading of update packages by regularly detecting the update status of the server.
[0028] When an application update is detected on the server, downloading the update package of the application includes: Step 1021, regularly checking the server and obtaining an update package list in the server; The developer uploads the update package of the new version to the server, and the server stores all the update packages sent by the developer at different times. The update package list stores the version number, update package, and upload time. The update package is uploaded to the server in a compressed format and stored in the update package list.
[0029] The time for regular server detection can be set as needed, for example, once every 24 hours.
[0030] Step 1023, comparing the update package list in the server with the download list at the application, and downloading the latest update package that does not exist in the download list from the update package list in the server; Obtain a download list stored on the application side, wherein the download list stores the update package and its related information after the update package is downloaded from the server. Specifically, the download list stores the version number, update package, and download time. The update package of the download list is stored in a compressed format.
[0031] Get the update package list from the server, compare the update package list with the download list, determine the version number from the update package list that does not exist in the download list, and then obtain the corresponding update package based on the version number and download it. If there are multiple update packages that do not exist in the download list, select the update package with the latest upload time for download based on the upload time.
[0032] Step 1025, after the update package is downloaded, the information of the corresponding update package in the update package list is synchronized to the download list; After the download to the APP is successful, for example, the version number is synchronized to the download list.
[0033] The step 104 executes the installation process after the update package is downloaded in step 102. If no operation problems occur during or after the installation of the update package, the installation is successful. If an operation problem occurs during or after the installation of the update package, the installation suspension and installation cancellation process is entered. To this end, after the update package is successfully installed, the installation is suspended, or the installation is cancelled, the installation status and installation time of the update package are fed back to the installation list; wherein the installation list stores the version number, installation status, and installation time, and the installation status includes successful installation, suspended installation, not installed, and historical installation; the update package whose installation is suspended due to operation problems is in the installation suspension state, the update package whose installation is cancelled due to operation problems is in the not installed state, the update package after successful installation is in the installation success state, and the update package of the version before the update is cancelled due to the successful installation of the update package of the updated version is in the historical installation state.
[0034] For the case of suspending installation, when an operation problem occurs during the installation of the update package, the installation of the update package is suspended, and the application is restored to run under the version before the update, including: Step A1, when installing the update package, the application runs under the version before the update, and the update package is installed silently; Step A3: When an operation problem occurs during the installation of the update package, the installation of the update package is terminated, and the application is restored to run under the version before the update.
[0035] The app runs in the current version (i.e. the version before the update) in the foreground, and the background silently installs the update at the same time. In this way, the foreground can still facilitate users to use the APP without being disturbed. If the foreground operation has operational problems such as no response, slow response, black screen, etc. during the silent installation process, there may be problems with the background installation. At this time, when the background detects that there is an operational problem in the foreground, it triggers the abort process and aborts the installation of the update package in the background. After the abort, the "installation aborted" status is stored in the installation list. When the application is restarted, the application keeps running with the original version.
[0036] For the uninstallation, when a running problem occurs after installing the update package, the installation of the update package is uninstalled and the application runs under the version before the update, including: B1, after installing the update package and not restarting the application, when an operation problem occurs, uninstall the update package and restore the application to the version before the update; B2, after installing the update package and restarting the application, if an operation problem occurs, the update package is uninstalled and the application is switched from the updated version back to the version before the update.
[0037] In case B1, specifically, after the update package is installed, the application is not restarted, so the foreground still runs the version before the update. When the foreground operation has operation problems such as no response, slow response, black screen, etc., the update package is uninstalled in the background, and the original "installed successfully" status of the update package in the installation list is changed to "not installed". When the application is restarted, the application keeps running the original version.
[0038] In case B2, specifically, after the update package is installed and the application is restarted, the application runs under the updated version, the original version has been uninstalled, and the installation status of the installation package of the original version in the installation list is changed from the "successful installation" status to the "historical installation" status. When there are operational problems such as no response, slow response, black screen, etc., the installation of the update package is canceled in the foreground, and the original "successful installation" status of the update package in the installation list is changed to the "not installed" status. The version before the update is reinstalled in the background. After the installation is successful, the original "historical installation" status of the update package in the installation list is changed to the "successful installation" status; after restarting the application again, the application runs under the version before the update.
[0039] For situations B1 and B2, the background monitors in real time whether there are any operational problems in the foreground. Once they occur, the above B1 and B2 processes are triggered.
[0040] In case B2, in one implementation mode, the background reinstalling the version before the update includes: Step C1, obtaining all historical update package information before the installation time of the update package from the installation list; When the version before the update needs to be reinstalled, all the earlier historical update package information with the installation time as the boundary in the installation list is obtained according to the installation time of the currently installed updated version.
[0041] The installation list stores the version number, installation status, and installation time, and the installation status includes successful installation, aborted installation, not installed, and historical installation; an update package whose installation was aborted due to an operation problem is in an installation aborted state, an update package whose installation was canceled due to an operation problem is in an not installed state, an update package after successful installation is in an installation successful state, and an update package of a version before the update is in a historical installation state after being canceled due to the successful installation of the update package of the updated version.
[0042] It is worth noting that the installation list does not store the update package itself, that is, the update package stored in the form of a compressed package. The installation list stores the version number of the update package, which can be associated with the update package in the download list through the version number.
[0043] Step C3, selecting an update package with the earliest installation time and an installation status of historical installation from the historical update package information, and determining it as an update package of the version before the update; All historical update package information obtained through time filtering contains update packages with various installation states, including update packages with "installation aborted", "not installed", "historically installed", and "successfully installed". We further filter by installation state to obtain update packages that have been installed and used for a period of time, to ensure that the reinstalled update packages are update packages that can run normally and meet the user's operating habits.
[0044] If there are two or more update packages in the "historical installation" state, you can filter out the latest update package before the current update by time.
[0045] Step C4, obtaining the update package in the download list according to the version number of the update package of the version before the update, and reinstalling the update package of the version before the update in the background; The download list stores version numbers, update packages, and download times.
[0046] By using the version number in the installation list, you can obtain the update package (compressed package) under the corresponding version number in the download list. This way, you don’t need to download the update package from the server repeatedly. You can directly obtain the historically downloaded update package through the download list and enter the update package reinstallation process. Switching to the original version is highly efficient.
[0047] In case B2, in another implementation manner, the background reinstalling the version before the update includes: Step D1, obtaining all historical update package information before the installation time of the update package from the installation list; Step D2, feeding back the historical update package information before the installation time of the update package to the user in the form of a notification, and after receiving the user's selection instruction, determining the version number in the selection instruction as the version before the update; Step D3, according to the version before the update, obtain the update package in the download list, and reinstall the update package of the version before the update in the background.
[0048] Compared with the above two implementations, the former is an automatic reinstallation process, but the reinstalled version is the latest historically installed version, while the latter needs to obtain user instructions (ie, the user can select the version independently) before executing the reinstallation process.
[0049] In addition, the version can be switched according to user needs. To this end, the method of the embodiment of this specification also includes: Step 31, when a version switching instruction is received, obtaining an update package with a corresponding version number in the download list according to the version number in the version switching instruction; Step 33: When running under the version before switching, silently install the update package of the version after switching.
[0050] The application sets a relevant version switching button or option. When the user triggers the version switching button or option, the information of the installation list can be obtained, and the user can select update packages with different version numbers according to the selection (including update packages in the status of installation aborted, not installed, and historical installation. Generally, it is preferred to select installation packages in the "historical installation" state). When the user determines the version to be updated, a version switching instruction is formed. The version switching instruction includes update instructions and version number information. After the background parses the version switching instruction, the update package with the corresponding version number in the download list is obtained according to the version number. When the current version is running in the foreground, the background silently installs the update package of the switched version.
[0051] During or after the installation of the switched version, if no operational problems occur, the version is switched normally, and the installation status of the updated package of the switched version is modified to successfully installed, while the installation status of the updated package of the switched version is modified to historical installation. If an operational problem occurs, step 104 is executed.
[0052] In step 106, when the operation problem occurs in step 104, the installation status of the update package and the operation problem are fed back to the server. The operation problem is fed back in the form of error data collected from the application operation code. The operation code can feedback which link of the operation has a problem and contains the original data of the error code. The installation status of the update package when the operation problem occurs is generally installation aborted or not installed.
[0053] The server is pre-configured with a trained big data model, which can locate the problem based on the installation status and operation problem analysis. When the problem is the update package itself, the relevant patch is obtained from the experience library and fed back to the APP. Different patches are configured for different problems in the experience library. When the problem cannot be located, the server triggers the manual channel, and the developer develops a patch or replaces the update package based on the installation status and operation problems, and then uploads it to the server. The server feeds back the patch or replacement update package to the APP.
[0054] In step 108, once the application receives the patch or replacement package sent by the server, it receives and stores it in the download list.
[0055] In step 110, after the application receives the patch or replacement package, the retry installation process is triggered. During or after the installation process, if there is no operational problem, the retry installation is successful, and the installation status of the update package is changed to successful installation, and the installation status of the update package of the previously running version is changed to historical installation. After the retry installation is successful, this information is also fed back to the server. The big data model of the server can be learned and optimized based on this information. The server corrects the update package that had previous operational problems. When other user-side APPs are updated, the corrected update package is directly obtained to enter the update process, thereby improving the installation success rate. During or after the installation process, if there is an operational problem, proceed to step 204.
[0056] In addition, the step 108 also includes: when the server determines that there is a conflict between the update package and the application operation, receiving a retry installation instruction sent by the server, and retrying to install the update package after the application is shut down.
[0057] To avoid operation problems caused by incomplete download of the update package during the download process, before step 106, the method of the embodiment of this specification further includes: Obtain the capacity of the update package with the running problem from the download list, and obtain the capacity of the corresponding update package in the update package list in the server; When determining whether the capacity sizes of the two are consistent, if not, re-download the update package with the operation problem from the server, and overwrite and store its related information in the installation list, and execute the reinstallation process; if so, the installation status and operation problem of the update package with the operation problem are fed back to the server.
[0058] By determining the size of the update package on the APP side, the operation problem caused by the download process can be eliminated before the problem is fed back to the server. At this time, there is no need to wait for the server to analyze the problem and start the re-download and installation process. If the operation problem occurs during or after the installation process, step 104 is executed.
[0059] Furthermore, during the above capacity determination process, when the same version of the update package has the problem of multiple (for example, 3) download capacity inconsistency with the update package capacity on the server, the re-download and installation process will no longer be started, and a download error problem feedback will be sent to the server.
[0060] When the server determines that there is a flow limiting problem in the download of the update package, the update package is split into two or more update sub-packages, and the associated parameter files are configured between the update sub-packages belonging to the same version. The server sends the update sub-packages of the same version to the APP in batches, and the associated parameter files are transmitted to the APP together with the update sub-package each time. The APP side parses the received update sub-packages and associated parameter files, and stores the update sub-packages of the same version in the download list. After downloading the update package, the APP side enters the installation process. When an operation problem occurs during or after the installation process, step 104 is executed.
[0061] Furthermore, when an operational problem occurs, when executing step 106, the installation status of the update package with the operational problem and the operational problem will be fed back to the server in the form of each update sub-package. The server can locate the problem for a single update sub-package. When all update sub-packages are individually judged to be ok, the overall problem is located for all update sub-packages. If the problem exists in a separate update sub-package, the corresponding patch and replacement package are sent to the APP only for the problematic update sub-package. The APP does not need to download the entire update sub-package, and does not need to re-split the update package by the server due to current limiting issues. It can quickly locate the problem and quickly enter the version update retry process, greatly improving the update efficiency.
[0062] The server big data model can locate problems based on the installation status and operation problem analysis. When the problem is the update timing of the update package, that is, the update package cannot be installed silently, a retry installation instruction is sent to the application. The retry installation instruction contains the version number and installation timing of the update package to be retried. After that, after receiving the retry installation instruction, the application side parses the instruction, obtains the update package with the relevant version number from the download list, and retries to install the update package after shutting down. After the installation is successful, after restarting the application, the application runs under the updated version.
[0063] Figure 2 In the update process under the example, when the user activates the APP for the first time, the APP requests authorization from the user to allow the above automatic download and installation process to be executed, and the process can only be executed after authorization.
[0064] See also Figure 3 A schematic diagram of the structure of an application update system according to an embodiment of the present specification is shown.
[0065] like Figure 3As shown, the system 1000 may at least include a detection module 1001, a download module 1002, an installation module 1003, and an operation module 1004, wherein: The detection module 1001 is used to trigger the download module to work when it detects that there is an application update on the server; Specifically, the detection module includes: A detection unit, used for periodically detecting a server and obtaining an update package list in the server; A comparison unit, used to compare the update package list in the server with the download list at the application, determine the latest update package that does not exist in the download list from the update package list in the server, and send it to the download module to execute the download process; The download module 1002 is used to download the update package of the application; After the update package is downloaded, the information of the corresponding update package in the update package list is synchronized to the download list; wherein the update package list stores the version number, update package, and upload time; and the download list stores the version number, update package, and download time.
[0066] The installation module 1003 is used to install and decompress the update package; The operation module 1004 is used to terminate the installation of the update package by the installation module when an operation problem occurs during the installation of the update package, and the application resumes running under the version before the update; or, when an operation problem occurs after the update package is installed, trigger the installation module to deinstall the update package, and the application runs under the version before the update.
[0067] After the update package is successfully installed, the installation is terminated, or the installation is canceled, the operation module feeds back the installation status and installation time of the update package to the installation list; wherein the installation list stores the version number, installation status, and installation time, and the installation status includes successful installation, terminated installation, not installed, and historical installation; the update package whose installation is terminated due to operation problems is in the installation terminated state, the update package whose installation is canceled due to operation problems is in the not installed state, the update package after successful installation is in the successful installation state, and the update package of the version before the update is in the historical installation state after being canceled due to the successful installation of the update package of the updated version.
[0068] Specifically, the operation module 1004 includes: The monitoring unit is used to monitor whether there are any operational problems during and after the installation of the update package; when an operational problem occurs during the installation of the update package, the installation package is triggered to terminate the installation process, and the application resumes running under the version before the update; when an operational problem occurs after the update package is installed, the installation module is triggered to deinstall the update package, and the application runs under the version before the update.
[0069] A status recording unit, used to feed back the installation status and installation time of the update package to the installation list after the update package is successfully installed, the installation is terminated, or the installation is canceled; The operation module also includes: A problem feedback unit, used to feed back the installation status of the update package with the running problem and the running problem to the server; When the server determines that there is a problem with the update package, it receives the patch or replacement update package sent by the server, and adds the patch to the update package of the corresponding version in the download list, or overwrites the replacement update package with the update package of the corresponding version in the download list; triggers the installation module to execute the process of retrying the installation of the update package with the patch or the replacement update package.
[0070] When the server determines that there is a conflict between the update package and the application operation, a retry installation instruction sent by the server is received, and the installation module is triggered to retry the installation of the update package after the application is shut down.
[0071] The operation module also includes: The version switching unit is used to obtain the update package of the corresponding version number in the download list according to the version number in the version switching instruction when receiving the version switching instruction; when running under the version before switching, silently install the update package of the version after switching.
[0072] The embodiments described above are merely preferred embodiments of this specification and are not intended to limit the scope of this specification. Without departing from the design spirit of this specification, various modifications and improvements made to the technical solutions of this specification by ordinary technicians in this field should fall within the scope of protection determined by the claims of this specification.
Claims
1. An application update method, characterized in that: include: When an application update is detected on the server, the update package of the application is downloaded; When an operation problem occurs during the installation of an update package, the installation of the update package is terminated and the application is restored to run under the version before the update; or, when an operation problem occurs after the installation of the update package, the installation of the update package is canceled and the application is run under the version before the update; Feedback the installation status and operation problems of update packages with operation problems to the server; When the server determines that there is a problem with the update package, it receives a patch or a replacement update package sent by the server, and adds and stores the patch at the update package of the corresponding version in the download list, or overwrites and stores the replacement update package at the update package of the corresponding version in the download list; Retry installing the update package with the patch or replace the update package.
2. The method according to claim 1, characterized in that When an application update is detected on the server, downloading the update package of the application includes: Regularly detect the server and obtain the update package list in the server; Compare the update package list in the server with the download list at the application, and download the latest update package that does not exist in the download list from the update package list in the server; After the update package is downloaded, the information of the corresponding update package in the update package list is synchronized to the download list; wherein the update package list stores the version number, update package, and upload time; and the download list stores the version number, update package, and download time.
3. The method according to claim 1, characterized in that Also includes: After the update package is successfully installed, the installation is terminated, or the installation is canceled, the installation status and installation time of the update package are fed back to the installation list; wherein the installation list stores the version number, installation status, and installation time, and the installation status includes successful installation, terminated installation, not installed, and historical installation; an update package whose installation is terminated due to an operation problem is in an installation terminated state, an update package whose installation is canceled due to an operation problem is in an not installed state, an update package after successful installation is in an installation successful state, and an update package of a version before the update is in a historical installation state after being canceled due to successful installation of the update package of the updated version.
4. The method according to claim 1, characterized in that: When an operation problem occurs during the installation of the update package, the installation of the update package is terminated, and the application is restored to run under the version before the update, including: When installing the update package, the application runs under the version before the update, and the update package is installed silently; When an operating problem occurs during the installation of an update package, the installation of the update package is terminated and the application resumes running under the version before the update.
5. The method according to claim 1, characterized in that When a running problem occurs after installing the update package, the installation of the update package is canceled, and the application runs under the version before the update, including: After installing the update package and not restarting the application, if there is a running problem, uninstall the update package and restore the application to the version before the update; After installing the update package and restarting the application, if a running problem occurs, uninstall the update package and switch the application from the updated version back to the version before the update.
6. The method according to claim 5, characterized in that After the update package is installed and the application is restarted, when a running problem occurs, the update package is uninstalled, and the application is switched from the updated version to the version before the update, including: After installing the update package and restarting the application, if there is a running problem, the foreground will uninstall the update package and the background will reinstall the version before the update; After restarting the application again, the application runs under the version before the update; The background reinstallation of the version before the update includes: Obtain all historical update package information before the installation time of the update package from the installation list; Selecting an update package with the earliest installation time and the installation status of historical installation from the historical update package information, and determining it as the update package of the version before the update; According to the version number of the update package of the version before the update, the update package in the download list is obtained, and the update package of the version before the update is reinstalled in the background; Among them, the installation list stores the version number, installation status, and installation time, and the installation status includes successful installation, aborted installation, not installed, and historical installation; the update package whose installation was aborted due to operation problems is in the aborted installation state, the update package whose installation was canceled due to operation problems is in the not installed state, the update package after successful installation is in the successful installation state, and the update package of the version before the update is canceled due to the successful installation of the update package of the updated version is in the historical installation state; the download list stores the version number, update package, and download time.
7. The method according to claim 1, characterized in that Also includes: When a version switching instruction is received, the update package under the corresponding version number in the download list is obtained according to the version number in the version switching instruction; When running under the version before switching, the update package of the version after switching is silently installed.
8. The method according to claim 1, characterized in that: After the installation status of the update package with the running problem and the running problem are fed back to the server, the method further includes: When the server determines that there is a conflict between the update package and the application operation, a retry installation instruction sent by the server is received, and the update package is retried to be installed after the application is shut down.
9. The method according to claim 1, characterized in that: Before feeding back the installation status and operation problem of the update package having the operation problem to the server, the method includes: Obtain the capacity of the update package with the running problem from the download list, and obtain the capacity of the corresponding update package in the update package list in the server; When determining whether the capacity sizes of the two are consistent, if not, re-download the update package with the operation problem from the server, and overwrite and store its related information in the installation list to execute the reinstallation process; if so, the installation status and operation problem of the update package with the operation problem are fed back to the server.
10. An application update system, characterized in that: include: The detection module is used to trigger the download module to work when an application update is detected on the server; Download module, used to download the update package of the application; Installation module, used to install and decompress update packages; The running module is used to terminate the installation of the update package by the installation module when an operation problem occurs during the installation of the update package, and the application resumes running under the version before the update; or, when an operation problem occurs after the update package is installed, trigger the installation module to deinstall the update package, and the application runs under the version before the update.
Citation Information
Patent Citations
Method and system for processing application program exception and mobile terminal
CN103365732A
Restoration method and device for aborted installation of software
CN105095006A
Software upgrade method and system
CN105335183A
Software upgrading method and device for household appliance and household appliance
CN113590145A
Application upgrading method and device, terminal and computer readable storage medium
CN114064096A