Summary of the invention
The invention provides a kind of method and apparatus of software upgrading, can provide APK increment AKU for terminal device, the flow and the time that to reduce this terminal device, consume when the upgrade software.
For achieving the above object, embodiments of the invention adopt following technical scheme:
First aspect, provides a kind of method of software upgrading, comprising:
Identification information and the version information of the software that is installed on described terminal device that software update service device receiving terminal apparatus sends, and determine the first Android installation kit APK according to the identification information of described software;
At the version of determining described software according to the version information of described software, during lower than the version of a described APK, obtain the 2nd APK, wherein, the version of described the 2nd APK is identical with the version that described version information represents;
According to the difference of described the 2nd APK and a described APK, obtain APK increment AKU, and send software upgrading message to described terminal device, so that described terminal device is being downloaded after described APK increment AKU according to described software upgrading message, call installation procedure and utilize described APK increment AKU to upgrade to described software.
In the possible implementation of the first of first aspect, the described difference according to described the 2nd APK and a described APK obtains APK increment AKU and comprises:
According to described the 2nd APK, determine the updating file in a described APK, wherein, described updating file comprises newly-increased file and the change file in a described APK, and described newly-increased file and described change file are formed to described APK increment AKU.
In conjunction with the possible implementation of the first, in the possible implementation of the second, described method also comprises:
Obtain the updating file inventory information in described APK increment AKU;
Describedly to described terminal device, send software upgrading message and comprise:
To described terminal device, send described updating file inventory information, so that described terminal device is downloaded described updating file according to described updating file inventory information.
In conjunction with the possible implementation of the first or the possible implementation of the second, in the third possible implementation, described method also comprises, obtains the operational order collection of corresponding described APK increment AKU, and described operational order collection is sent to described terminal device;
Described to described terminal device transmission software upgrading message, so that described terminal device is being downloaded after described APK increment AKU according to described software upgrading message, call installation procedure and utilize described APK increment AKU that described software is upgraded and comprised:
To described terminal device, send software upgrading message, so that described terminal device is being downloaded after described APK increment AKU according to described software upgrading message, call installation procedure and utilize software described in described APK increment AKU and described operational order set pair to upgrade.
In conjunction with the third possible implementation, in the 4th kind of possible implementation, described updating file inventory information comprises the download path that updating file is corresponding, so that described terminal device is downloaded corresponding updating file according to described download path.
Second aspect present invention provides a kind of software update service device, comprising:
Receiving element, identification information and the version information of the software that is installed on described terminal device sending for receiving terminal apparatus, and determine the first Android installation kit APK according to the identification information of described software;
Processing unit, the version of determining described software for the version information of the software receiving according to described receiving element during lower than the version of a described APK, obtains the 2nd APK, and wherein, the version of described the 2nd APK is identical with the version that described version information represents;
Described processing unit also for, according to the difference of described the 2nd APK and a described APK, obtain APK increment AKU;
Transmitting element, for obtaining after described APK increment AKU at described processing unit, to described terminal device, send software upgrading message, so that described terminal device is being downloaded after described APK increment AKU according to described software upgrading message, call installation procedure and utilize described APK increment AKU to upgrade to described software.
In the possible implementation of the first of second aspect, described processing unit also for, according to described the 2nd APK, determine the updating file in a described APK, wherein, described updating file comprises newly-increased file and the change file in a described APK, and described newly-increased file and described change file are formed to described APK increment AKU.
In conjunction with the possible implementation of the first, in the possible implementation of the second, described processing unit specifically for, obtain the updating file inventory information in described APK increment AKU; Described transmitting element specifically for, to described terminal device, send described updating file inventory information, so that described terminal device is downloaded described updating file according to described updating file inventory information.
In conjunction with the possible implementation of the first or the possible implementation of the second, in the third possible implementation, described processing unit specifically for, obtain the operational order collection of corresponding described APK increment AKU, described transmitting element specifically for, described operational order collection is sent to described terminal device, so that described terminal device is being downloaded after described APK increment AKU according to described software upgrading message, call installation procedure and utilize software described in described APK increment AKU and described operational order set pair to upgrade.
In conjunction with the third possible implementation, in the 4th kind of possible implementation, described updating file inventory information comprises the download path that updating file is corresponding, so that described terminal device is downloaded corresponding updating file according to described download path.
Adopt such scheme, software update service device is when receiving the identification information of the software that is installed on this terminal device that terminal device sends and version information, according to the identification information of this software, determine an APK, and at the version of determining this software according to the version information of this software during lower than the version of an APK, obtain the 2nd identical APK of version representing with this version information, this software update service device obtains APK increment AKU according to the difference of the 2nd APK and an APK, and send software upgrading message to this terminal device, so that this terminal device is being downloaded according to this software upgrading message after this APK increment AKU, calling installation procedure utilizes described APK increment AKU to upgrade to this software.Because this APK increment AKU is the part that an APK is different from the 2nd APK, therefore the data volume of this APK increment AKU is less than an APK, like this, terminal device is when carrying out software upgrading, only need to download this APK increment AKU, without downloading a complete APK, thereby reduced, download flow and the time consuming.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is clearly and completely described, obviously, described embodiment is only the present invention's part embodiment, rather than whole embodiment.Embodiment based in the present invention, those of ordinary skills, not making the every other embodiment obtaining under creative work prerequisite, belong to the scope of protection of the invention.
The embodiment of the present invention provides a kind of method of software upgrading, and as shown in Figure 1, the method comprises:
Identification information and the version information of the software that is installed on this terminal device that S101, software update service device receiving terminal apparatus send, and determine the first Android installation kit APK according to the identification information of this software.
Particularly, when the software that user installs in to terminal device is upgraded, this terminal device sends identification information and the version information of this software to software update service device, wherein, the operating system of this terminal device is Android operating system, the APK to different editions that should software that this software update service device stores that software developer or developer upload, this software update service device is determined an APK in the APK of different editions according to the identification information of this software, and an APK can be to the highest APK of version that should software in this software update service device.
Example, the title of this software that the identification information of this software is: xx, in this software update service device, store the installation kit to a plurality of different editions that should software, for example xx_1.APK, xx_2.APK and xx_3.APK, this software update service device is when receiving the identification information xx of this software that this terminal device sends, according to the identification information xx of this software, determine installation kit xx_1.APK, xx_2.APK and xx_3.APK that should software, and the highest xx_3.APK of definite version is an APK.
S102, this software update service device during lower than the version of an APK, obtain the 2nd APK at the version of determining this software according to the version information of this software.
Wherein, the version of the 2nd APK is identical with the version that this version information represents.
Particularly, this software update service device is according to the version information of this software relatively version of this software and the version of an APK, if the version of this software is more than the version of an APK, this software update service device determines that the version of this software has been highest version, without carrying out edition upgrading; If the version of this software is lower than the version of an APK, this software update service device determines that this software need to upgrade and obtain and two APK of this software with version.
Illustratively, the one APK is xx_3.APK, the version of an APK is the third edition, if the version of this software is the third edition, when the version that this software update service device represents at definite this version information is identical with the version of an APK, this software update service device determines that this software is without carrying out edition upgrading; If the version of this software is second edition, this software update service device is when determining version that this version information represents lower than the version of an APK, this software update service device determines that this software can carry out edition upgrading, and obtain the identical xx_2.APK of version representing with this version information, i.e. the 2nd APK.
S103, this software update service device obtain APK increment AKU according to the difference of the 2nd APK and an APK, and send software upgrading message to this terminal device, so that this terminal device is being downloaded after this APK increment AKU according to this software upgrading message, call installation procedure and utilize this APK increment AKU to upgrade to this software.
Alternatively, this software update service device is determined the updating file in an APK according to the 2nd APK, wherein, this updating file comprises newly-increased file and the change file in an APK, and this newly-increased file and this change file are formed to this APK increment AKU.
Further, this software update service device obtains the updating file inventory information in this APK increment AKU, and this updating file inventory information is sent to this terminal device, so that this terminal device is downloaded this updating file according to this updating file inventory information.
Particularly, this software update service device compares the 2nd APK and an APK, may have following four kinds of situations:
1, there is the installation file A in an APK, be not present in the 2nd APK, in an APK, increased this installation file A;
2, there is the installation file B in the 2nd APK, be not present in an APK, in an APK, deleted this installation file B;
3, in an APK and the 2nd APK, all have installation file C, but an APK is different to storage information that should installation file C from the 2nd APK, an APK has revised this installation file C;
4, in an APK and the 2nd APK, all have installation file D, and an APK is identical to storage information that should installation file D with the 2nd APK, this installation file D remains unchanged in an APK and the 2nd APK.
Like this, the definite installation file A that meets this situation 1 of this software update service device is this newly-increased file, the installation file A that meets situation 3 is this change file, and this software update service device is compressed into this APK increment AKU by this newly-increased file and this change Piece file mergence.In addition, this software update service device, when definite this newly-increased file and this change file, records the identification information of this newly-increased file and the identification information of this change file, obtains this updating file inventory information.
Alternatively, this updating file inventory information also comprises the download path that updating file is corresponding, so that this terminal device is downloaded corresponding updating file according to this download path.
Further, this software update service device obtains to operational order collection that should APK increment AKU, so that this terminal device, after downloading this APK increment AKU, is upgraded to this software according to this operational order collection and this APK increment AKU.
Wherein, this software update service device can be sent to this terminal device by this updating file inventory information and this operational order collection by sending software upgrading message to this terminal device, that is to say, this software upgrading message comprises this updating file inventory information and this operational order collection.
It should be noted that, this terminal device is after downloading this APK increment AKU, need to will in this terminal device, for the 3rd APK of this software and this APK increment AKU are installed, merge and generate a 4th new APK, wherein, the version of the 3rd APK is identical with the version of the 2nd APK, and the version of the 4th APK is identical with the version of an APK.
Particularly, this terminal device is after receiving the software upgrading message of this software update service device transmission, according to the updating file inventory information in this software upgrading message, from this software update service device, download this APK increment AKU, and operate according to this APK increment AKU of the operational order set pair in this software upgrading message, for example, four kinds of situations that compare according to above-mentioned the 2nd APK and an APK, for the installation file A in situation 1, this terminal device need to be carried out update that should installation file A, this installation file A is inserted in the 3rd APK, for the installation file B in situation 2, this terminal device need to be carried out deletion action that should installation file B, and this installation file B is deleted from the 3rd APK, for the installation file C in situation 3, this terminal device need to be carried out replacement operation that should installation file C, and the installation file C in the 3rd APK is replaced with to the installation file C in this APK incremental update bag.Like this, this terminal device is merged into a 4th new APK by this operational order collection by the 3rd APK and this APK incremental update bag, this terminal device carries out fitting operation by calling installation procedure to the 4th APK, complete the more installation of highest version of this software, make this software upgrade to highest version by lowest version.
Adopt such scheme, software update service device is when receiving the identification information of the software that is installed on this terminal device that terminal device sends and version information, according to the identification information of this software, determine an APK, and at the version of determining this software according to the version information of this software during lower than the version of an APK, obtain the 2nd identical APK of version representing with this version information, this software update service device obtains APK increment AKU according to the difference of the 2nd APK and an APK, and send software upgrading message to this terminal device, so that this terminal device is being downloaded according to this software upgrading message after this APK increment AKU, calling installation procedure utilizes described APK increment AKU to upgrade to this software.Because this APK increment AKU is the part that an APK is different from the 2nd APK, therefore the data volume of this APK increment AKU is less than an APK, like this, terminal device is when carrying out software upgrading, only need to download this APK increment AKU, without downloading a complete APK, thereby reduced, download flow and the time consuming.
The invention provides a kind of method of software upgrading, as shown in Figure 2, the method comprises:
S201, software update service device obtain identification information and the version information of the software that is installed on terminal device.
Particularly, when the software that user installs in to terminal device is upgraded, this terminal device sends identification information and the version information of this software to software update service device, wherein, the operating system of this terminal device is Android operating system, the APK to different editions that should software that this software update service device stores that software developer or developer upload.
S202, this software update service device are determined an APK according to the identification information of this software.
Particularly, this software update service device is determined an APK in the APK of different editions according to the identification information of this software, and wherein, an APK can be to the highest APK of version that should software in this software update service device.
Example, the title of this software that the identification information of this software is: xx, in this software update service device, store the installation kit to a plurality of different editions that should software, for example xx_1.APK, xx_2.APK and xx_3.APK, this software update service device is when receiving the identification information xx of this software that this terminal device sends, according to the identification information xx of this software, determine installation kit xx_1.APK, xx_2.APK and xx_3.APK that should software, and the highest xx_3.APK of definite version is an APK.
S203, this software update service device during lower than the version of an APK, obtain the 2nd identical APK of version representing with this version information at the version of determining this software according to the version information of this software.
Particularly, this software update service device is according to the version information of this software relatively version of this software and the version of an APK, if the version of this software is more than the version of an APK, this software update service device determines that the version of this software has been highest version, without carrying out edition upgrading; If the version of this software is lower than the version of an APK, this software update service device determines that this software need to upgrade and obtain and two APK of this software with version.
Illustratively, the one APK is xx_3.APK, the version of an APK is the third edition, if the version of this software is the third edition, when the version that this software update service device represents at definite this version information is identical with the version of an APK, this software update service device determines that this software is without carrying out edition upgrading; If the version of this software is second edition, this software update service device is when determining version that this version information represents lower than the version of an APK, this software update service device determines that this software can carry out edition upgrading, and obtain the xx_2.APK identical with the version of this version information sign, i.e. the 2nd APK.
S204, this software update service device compare the 2nd APK and an APK, obtain newly-increased file and change file.
Particularly, this software update service device compares the 2nd APK and an APK, may have following four kinds of situations:
1, there is the installation file A in an APK, be not present in the 2nd APK, in an APK, increased this installation file A;
2, there is the installation file B in the 2nd APK, be not present in an APK, in an APK, deleted this installation file B;
3, in an APK and the 2nd APK, all have installation file C, but an APK is different to storage information that should installation file C from the 2nd APK, an APK has revised this installation file C;
4, in an APK and the 2nd APK, all have installation file D, and an APK is identical to storage information that should installation file D with the 2nd APK, this installation file D remains unchanged in an APK and the 2nd APK.
Like this, the definite installation file A that meets this situation 1 of this software update service device is this newly-increased file, and the installation file A that meets situation 3 is this change file.
S205, this software update service device are APK increment AKU by this newly-increased file and this change Piece file mergence, and obtain updating file inventory information.
Wherein, this updating file comprises this newly-increased file and this change file.
This software update service device, when definite this newly-increased file and this change file, records the identification information of this newly-increased file and the identification information of this change file, obtains this updating file inventory information.
Alternatively, this updating file inventory information also comprises the download path that updating file is corresponding, so that this terminal device is downloaded corresponding updating file according to this download path.
S206, this software update service device obtain operational order collection that should APK increment AKU, and send software upgrading message to this terminal device.
Wherein, this software upgrading message comprises this updating file inventory information and this operational order collection.
S207, this terminal device are downloaded this APK increment AKU according to this updating file inventory information from this software update service device, and according to this operational order, this APK increment AKU and the 3rd APK are merged into the 4th APK.
It should be noted that, this terminal device is after downloading this APK increment AKU, need to will in this terminal device, for the 3rd APK of this software and this APK increment AKU are installed, merge and generate a 4th new APK, wherein, the version of the 3rd APK is identical with the version of the 2nd APK, and the version of the 4th APK is identical with the version of an APK.
S208, this terminal device call installation procedure and utilize the 4th APK that the more highest version of this software is installed, and complete the upgrading of this software.
Particularly, this terminal device is after receiving the software upgrading message of this software update service device transmission, according to the updating file inventory information in this software upgrading message, from this software update service device, download this APK increment AKU, and according to the operational order in this software upgrading message, this APK increment AKU is operated, for example, four kinds of situations that compare according to above-mentioned the 2nd APK and an APK, for the installation file A in situation 1, this terminal device need to be carried out update that should installation file A, this installation file A is inserted in the 3rd APK, for the installation file B in situation 2, this terminal device need to be carried out deletion action that should installation file B, and this installation file B is deleted from the 3rd APK, for the installation file C in situation 3, this terminal device need to be carried out replacement operation that should installation file C, and the installation file C in the 3rd APK is replaced with to the installation file C in this APK incremental update bag.Like this, this terminal device is merged into a 4th new APK by this operational order by the 3rd APK and this APK incremental update bag, this terminal device carries out fitting operation by calling installation procedure to the 4th APK, complete the more installation of highest version of this software, make this software upgrade to highest version by lowest version.
Pass through above-mentioned steps, because this APK increment AKU is the part that an APK is different from the 2nd APK, therefore this APK increment AKU is less than an APK, like this, terminal device is when carrying out software upgrading, only need to download this APK increment AKU, without downloading a complete APK, thereby reduced, download flow and the time consuming.
In addition, for said method embodiment, for simple description, therefore it is all expressed as to a series of combination of actions, but those skilled in the art should know, the present invention is not subject to the restriction of described sequence of movement, secondly, those skilled in the art also should know, the embodiment described in instructions all belongs to preferred embodiment, and related action and module might not be that the present invention is necessary.
The embodiment of the present invention provides a kind of softwareupdate service device 30, and as shown in Figure 3, this softwareupdate service device 30 comprises:
Receivingelement 31, identification information and the version information of the software that is installed on this terminal device sending for receiving terminal apparatus, and determine the first Android installation kit APK according to the identification information of this software.
Processingunit 32, the version of determining this software for the version information of the software receiving according to this receivingelement 31 during lower than the version of an APK, obtains the 2nd APK.
Wherein, the version of the 2nd APK is identical with the version that this version information represents.
Thisprocessing unit 32 also for, according to the difference of the 2nd APK and an APK, obtain APK increment AKU.
Transmittingelement 33, for obtaining after this APK increment AKU at thisprocessing unit 32, to this terminal device, send software upgrading message, so that this terminal device is being downloaded after this APK increment AKU according to this software upgrading message, call installation procedure and utilize this APK increment AKU to upgrade to this software.
Particularly, when the software that user installs in to terminal device is upgraded, this terminal device sends identification information and the version information of this software to software update service device, wherein, the operating system of this terminal device is Android operating system, the APK to different editions that should software that this software update service device stores that software developer or developer upload, this software update service device is determined an APK in the APK of different editions according to the identification information of this software, and an APK can be to the highest APK of version that should software in this software update service device.
Example, the title of this software that the identification information of this software is: xx, in this software update service device, store the installation kit to a plurality of different editions that should software, for example xx_1.APK, xx_2.APK and xx_3.APK, this software update service device is when receiving the identification information xx of this software that this terminal device sends, according to the identification information xx of this software, determine installation kit xx_1.APK, xx_2.APK and xx_3.APK that should software, and the highest xx_3.APK of definite version is an APK.
Further, this software update service device is according to the version information of this software relatively version of this software and the version of an APK, if the version of this software is more than the version of an APK, this software update service device determines that the version of this software has been highest version, without carrying out edition upgrading; If the version of this software is lower than the version of an APK, this software update service device determines that this software need to upgrade and obtain and two APK of this software with version.
Illustratively, the one APK is xx_3.APK, the version of an APK is the third edition, if the version of this software is the third edition, when the version that this software update service device represents at definite this version information is identical with the version of an APK, this software update service device determines that this software is without carrying out edition upgrading; If the version of this software is second edition, this software update service device is when determining version that this version information represents lower than the version of an APK, this software update service device determines that this software can carry out edition upgrading, and obtain the identical xx_2.APK of version representing with this version information, i.e. the 2nd APK.
Alternatively, thisprocessing unit 32 specifically for, according to the 2nd APK, determine the updating file in an APK, wherein, this updating file comprises newly-increased file and the change file in an APK, and this newly-increased file and this change file are formed to this APK increment AKU.
Further, thisprocessing unit 32 also for, obtain the updating file inventory information in this APK increment AKU, this transmittingelement 33 specifically for, this updating file inventory information is sent to this terminal device, so that this terminal device is downloaded this updating file according to this updating file inventory information.
Particularly, this software update service device compares the 2nd APK and an APK, may have following four kinds of situations:
1, there is the installation file A in an APK, be not present in the 2nd APK, in an APK, increased this installation file A;
2, there is the installation file B in the 2nd APK, be not present in an APK, in an APK, deleted this installation file B;
3, in an APK and the 2nd APK, all have installation file C, but an APK is different to storage information that should installation file C from the 2nd APK, an APK has revised this installation file C;
4, in an APK and the 2nd APK, all have installation file D, and an APK is identical to storage information that should installation file D with the 2nd APK, this installation file D remains unchanged in an APK and the 2nd APK.
Like this, the definite installation file A that meets this situation 1 of this software update service device is this newly-increased file, the installation file A that meets situation 3 is this change file, and this software update service device is compressed into this APK increment AKU by this newly-increased file and this change Piece file mergence.In addition, this software update service device, when definite this newly-increased file and this change file, records the identification information of this newly-increased file and the identification information of this change file, obtains this updating file inventory information.
Alternatively, this updating file inventory information also comprises the download path that updating file is corresponding, so that this terminal device is downloaded corresponding updating file according to this download path.
Further, thisprocessing unit 32 specifically for, obtain operational order collection that should APK increment AKU, this transmittingelement 33 specifically for, this operational order collection is sent to this terminal device, so that this terminal device, after downloading this APK increment AKU, is upgraded to this software according to this operational order collection and this APK increment AKU.
It should be noted that, this terminal device is after downloading this APK increment AKU, need to will in this terminal device, for the 3rd APK of this software and this APK increment AKU are installed, merge and generate a 4th new APK, wherein, the version of the 3rd APK is identical with the version of the 2nd APK, and the version of the 4th APK is identical with the version of an APK.
Particularly, this terminal device is after receiving the software upgrading message of this software update service device transmission, according to the updating file inventory information in this software upgrading message, from this software update service device, download this APK increment AKU, and operate according to this APK increment AKU of the operational order set pair in this software upgrading message, for example, four kinds of situations that compare according to above-mentioned the 2nd APK and an APK, for the installation file A in situation 1, this terminal device need to be carried out update that should installation file A, this installation file A is inserted in the 3rd APK, for the installation file B in situation 2, this terminal device need to be carried out deletion action that should installation file B, and this installation file B is deleted from the 3rd APK, for the installation file C in situation 3, this terminal device need to be carried out replacement operation that should installation file C, and the installation file C in the 3rd APK is replaced with to the installation file C in this APK incremental update bag.Like this, this terminal device is merged into a 4th new APK by this operational order collection by the 3rd APK and this APK incremental update bag, this terminal device carries out fitting operation by calling installation procedure to the 4th APK, complete the more installation of highest version of this software, make this software upgrade to highest version by lowest version.
Adopt above-mentioned software update service device, this software update service device is when receiving the identification information of the software that is installed on this terminal device that terminal device sends and version information, according to the identification information of this software, determine an APK, and at the version of determining this software according to the version information of this software during lower than the version of an APK, obtain the 2nd identical APK of version representing with this version information, this software update service device obtains APK increment AKU according to the difference of the 2nd APK and an APK, and send software upgrading message to this terminal device, so that this terminal device is being downloaded according to this software upgrading message after this APK increment AKU, calling installation procedure utilizes described APK increment AKU to upgrade to this software.Because this APK increment AKU is the part that an APK is different from the 2nd APK, therefore the data volume of this APK increment AKU is less than an APK, like this, terminal device is when carrying out software upgrading, only need to download this APK increment AKU, without downloading a complete APK, thereby reduced, download flow and the time consuming.
The above; be only the specific embodiment of the present invention, but protection scope of the present invention is not limited to this, is anyly familiar with those skilled in the art in the technical scope that the present invention discloses; the variation that can expect easily or replacement, within all should being encompassed in protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion with the protection domain of claim.