Method, apparatus, file packaged service device and the client of patch downloading
Technical field
The present invention relates to field of computer technology, specifically, the present invention relates to a kind of patch downloading method, apparatus,
File packaged service device and client.
Background technique
There are some problems in large software system, if these problems are sent out by hacker or viral design person in use
It is existing, attack will be carried out to user equipment according to the above problem or user equipment will be attacked by designing virus, and cause to use
Family equipment is impaired or user information is revealed, therefore user needs to download some patches, modifies in above-mentioned large software system
Problem avoids the software systems in computer impaired by attack, therefore how to realize that patch downloading becomes a major issue.
Currently, a kind of method of patch downloading, when the carrying that patch update server receives client transmission is multiple close
The patch request message of key (full name in English: key), patch update server and need to search the corresponding lower information carrying of each key respectively
Breath, and is back to client for the corresponding download information of each key, and then client is according to the corresponding download information of each key,
Successively under in content distributing network (full name in English: Content Delivery Network, english abbreviation: CDN) server
Carry patch.
However, when downloading patch from CDN server by the above method, if client needs to download multiple key pairs
The patch answered, then patch updates server and needs successively to search the corresponding download information of each key and need according to each key pairs
The download address answered repeatedly accesses CDN server, and downloads patch from the CDN server, each due to needing successively to search
The corresponding download information of key, and patch file is repeatedly downloaded, the time so as to cause downloading patch file is longer, and needs
Repeatedly access CDN server, download the corresponding patch file of each key, so cause it is larger to the amount of access of CDN server,
Demand to user bandwidth is larger.
Summary of the invention
To overcome above-mentioned technical problem or at least being partially solved above-mentioned technical problem, spy proposes following technical scheme:
The embodiment provides a kind of methods of patch downloading, comprising:
Patch updates server and receives the download information request message that client is sent, in the download information request message
At least one key Key is carried, the download information request message is for requesting the corresponding lower information carrying of at least one described Key
Breath;
It determines the corresponding compression key tarKey of at least one described Key, and searches described tarkey pairs from database
The download information answered;
If finding the corresponding download information of the tarKey, the corresponding download information of the tarKey is back to institute
Client is stated, so that the client downloads corresponding compressed package according to download information from the CDN server, it is described
It include that the corresponding download command of at least one key compares text diff file in compressed package.
It is optionally, described after the step of searching the corresponding download information of the tarkey in database, further includes:
If not finding the corresponding download information of the tarKey, each Key pairs is successively searched from the database
The download information answered, and the corresponding download information of each Key is back to the client, so that the client is according to institute
The corresponding download information of each Key is stated, diff file is downloaded from the CDN server.
It is optionally, described that the corresponding download information of each key is back to after the client, further includes:
At least one described Key is sent to file packaged service device, so that the file packaged service device obtains institute
The corresponding diff file of each key at least one key is stated, and the corresponding diff file of all key is packaged into compressed package, and
It is uploaded to the CDN server.
Specifically, the step of corresponding compression key tarKey of at least one Key described in the determination, comprising:
At least one described key is spliced, spliced key is obtained;
The spliced key is spliced with preset keyword, it is corresponding to obtain at least one described Key
tarKey。
The embodiment of the invention provides the methods of another patch downloading, comprising:
Client updates server to patch and sends download information request message, carries in the download information request message
At least one key Key, the download information request message is for requesting the corresponding download information of at least one described Key;
Receive the patch and update the corresponding download information of tarKey that server is sent, the tarKey by it is described at least
One Key compression obtains;
According to the corresponding download information of the tarKey received, corresponding compressed package, the pressure are downloaded from CDN server
It include that the corresponding download command of at least one key compares text diff file in contracting packet.
Optionally, if the corresponding download information of each key at least one described key is received, according to successively basis
The corresponding download information of each key, downloads corresponding diff file from the CDN server.
Optionally, if other clients are needed from downloading the diff file downloaded in the client, institute in the CDN
Client is stated by the diff file downloaded by point-to-point, is sent to request sender's client.
The embodiment of the invention provides the methods of another patch downloading, comprising:
File packaged service device receives patch and updates at least one described key that server is sent;
The corresponding diff file of each key is obtained from local, and the corresponding diff file of all key is packaged into compression
Packet;
The compressed package is uploaded to CDN server.
Optionally, after the described the step of compressed package is uploaded to CDN server, further includes:
Receive the corresponding download information of the compressed package that the CDN server returns, and by the download information with
And database is written in the corresponding relationship of tarKey, the tarKey is the compressed package of at least one key.
The embodiment of the invention provides a kind of devices of patch downloading, are located at patch and update server, which includes:
Receiving module, for receiving the download information request message of client transmission, in the download information request message
At least one key Key is carried, the download information request message is for requesting the corresponding lower information carrying of at least one described Key
Breath;
Determining module, for determining the corresponding compression key tarKey of at least one described Key;
Searching module, for searching the corresponding download information of the tarkey from database;
Return module, for when finding the corresponding download information of the tarKey, by the tarKey it is corresponding under
Information carrying breath is back to the client, so that the client according to download information, is downloaded from the CDN server and corresponded to
Compressed package, include that the corresponding download command of at least one key compares text diff file in the compressed package.
Optionally, the searching module is also used to when not finding the corresponding download information of the tarKey, from described
The corresponding download information of each Key is successively searched in database;
The return module is also used to the corresponding download information of each Key being back to the client, so that described
Client downloads diff file according to the corresponding download information of each Key from the CDN server.
Optionally, described device further include: sending module;
The sending module, at least one described Key to be sent to file packaged service device, so that the file
Packaged service device obtains the corresponding diff file of each key at least one described key, and by the corresponding diff text of all key
Part is packaged into compressed package, and is uploaded to the CDN server.
Specifically, the determining module obtains spliced specifically for splicing at least one described key
key;
The determining module is specifically also used to splice the spliced key with preset keyword, obtains described
The corresponding tarKey of at least one Key.
The embodiment of the invention provides a kind of clients of patch downloading, comprising:
Sending module sends download information request message for updating server to patch, and the download information request disappears
At least one key Key is carried in breath, the download information request message is for requesting the corresponding downloading of at least one described Key
Information;
Receiving module updates the corresponding download information of tarKey that server is sent for receiving the patch, described
TarKey is compressed by least one described Key to be obtained;
Download module, for being downloaded from CDN server corresponding according to the corresponding download information of tarKey received
Compressed package includes that the corresponding download command of at least one key compares text diff file in the compressed package.
Optionally, the download module is also used to when receiving the corresponding downloading of each key at least one described key
When information, successively according to the corresponding download information of each key, corresponding diff file is downloaded from the CDN server.
Optionally, the sending module is also used to download in the client when other clients needs from the CDN
When the diff file of downloading, by the diff file downloaded by point-to-point, it is sent to request sender's client.
The embodiment of the invention provides a kind of file packaged service devices of patch downloading, comprising:
Receiving module updates at least one key described in server transmission for receiving patch;
Module is obtained, for obtaining the corresponding diff file of each key from local;
Packetization module, for the corresponding diff file of all key to be packaged into compressed package;
Uploading module, for the compressed package to be uploaded to CDN server.
Optionally, the file packaged service device further include: writing module;
The receiving module is also used to receive the corresponding download information of the compressed package that the CDN server returns;
The write module, it is described for database to be written in the corresponding relationship of the download information and tarKey
TarKey is the compressed package of at least one key.
The present invention provides method, apparatus, packaged service device and the clients of a kind of downloading of patch, with prior art phase
Than client updates server transmission download information request message to patch in the present invention, and then patch updates server and receives
The download information request message that client is sent, and according to determining pair of at least one key carried in download information request message
The tarKey answered, and the corresponding download information of the tarKey is searched, and the download information found is back to client, then
Client downloads the pressure comprising the corresponding diff file of at least one above-mentioned key according to download information from CDN server
Contracting packet, i.e. patch update server and only need to access a database according to tarKey, search download information, and only need root
A CDN server is accessed according to download information, the compressed package of the corresponding diff file of above-mentioned all key is downloaded, to reduce visit
It asks the number of CDN server, reduces the duration of downloading patch file, and since client only needs to access a CDN server,
The amount of access to CDN server can be reduced in turn, reduce the demand to user bandwidth.
File packaged service device of the present invention is by being packaged into pressure for the corresponding diff file of key each at least one key
Contracting packet, and is uploaded to CDN server, enable to client access a CDN server can download it is above-mentioned at least one
The corresponding diff file of each key in key reduces downloading patch file so as to reduce the number of access CDN server
Duration, and then the amount of access to CDN server can be reduced, reduce the demand to user bandwidth.
The additional aspect of the present invention and advantage will be set forth in part in the description, these will become from the following description
Obviously, or practice through the invention is recognized.
Detailed description of the invention
Above-mentioned and/or additional aspect and advantage of the invention will become from the following description of the accompanying drawings of embodiments
Obviously and it is readily appreciated that, in which:
Fig. 1 is the system schematic of the downloading patch of the embodiment of the present invention;
Fig. 2 is the embodiment of the method that a kind of patch of the embodiment of the present invention is downloaded;
Fig. 3 is the apparatus structure schematic diagram that a kind of patch of the embodiment of the present invention is downloaded;
Fig. 4 is the structural schematic diagram for the client that the patch of the embodiment of the present invention is downloaded;
Fig. 5 is the file packaged service device that the patch of the embodiment of the present invention is downloaded.
Specific embodiment
The embodiment of the present invention is described below in detail, examples of the embodiments are shown in the accompanying drawings, wherein from beginning to end
Same or similar label indicates same or similar element or element with the same or similar functions.Below with reference to attached
The embodiment of figure description is exemplary, and for explaining only the invention, and is not construed as limiting the claims.
Those skilled in the art of the present technique are appreciated that unless expressly stated, singular " one " used herein, " one
It is a ", " described " and "the" may also comprise plural form.It is to be further understood that being arranged used in specification of the invention
Diction " comprising " refer to that there are the feature, integer, step, operation, element and/or component, but it is not excluded that in the presence of or addition
Other one or more features, integer, step, operation, element, component and/or their group.It should be understood that when we claim member
Part is " connected " or when " coupled " to another element, it can be directly connected or coupled to other elements, or there may also be
Intermediary element.In addition, " connection " used herein or " coupling " may include being wirelessly connected or wirelessly coupling.It is used herein to arrange
Diction "and/or" includes one or more associated wholes for listing item or any cell and all combinations.
Those skilled in the art of the present technique are appreciated that unless otherwise defined, all terms used herein (including technology art
Language and scientific term), there is meaning identical with the general understanding of those of ordinary skill in fields of the present invention.Should also
Understand, those terms such as defined in the general dictionary, it should be understood that have in the context of the prior art
The consistent meaning of meaning, and unless idealization or meaning too formal otherwise will not be used by specific definitions as here
To explain.
Those skilled in the art of the present technique are appreciated that " terminal " used herein above, " terminal device " both include wireless communication
The equipment of number receiver, only has the equipment of the wireless signal receiver of non-emissive ability, and including receiving and emitting hardware
Equipment, have on bidirectional communication link, can carry out two-way communication reception and emit hardware equipment.This equipment
It may include: honeycomb or other communication equipments, shown with single line display or multi-line display or without multi-line
The honeycomb of device or other communication equipments;PCS (Personal Communications Service, PCS Personal Communications System), can
With combine voice, data processing, fax and/or communication ability;PDA (PersonalDigital Assistant, it is personal
Digital assistants), it may include radio frequency receiver, pager, the Internet/intranet access, web browser, notepad, day
It goes through and/or GPS (Global PositioningSystem, global positioning system) receiver;Conventional laptop and/or hand held
Computer or other equipment, have and/or the conventional laptop including radio frequency receiver and/or palmtop computer or other
Equipment." terminal " used herein above, " terminal device " can be it is portable, can transport, be mounted on the vehicles (aviation, sea
Fortune and/or land) in, or be suitable for and/or be configured in local runtime, and/or with distribution form, operate in the earth
And/or any other position operation in space." terminal " used herein above, " terminal device " can also be communication terminal, on
Network termination, music/video playback terminal, such as can be PDA, MID (Mobile Internet Device, mobile Internet
Equipment) and/or mobile phone with music/video playing function, it is also possible to the equipment such as smart television, set-top box.
The embodiment of the present invention provides a kind of method of patch downloading, applied to the system of downloading patch, as shown in Figure 1, should
System includes client, patch update server, Windows server update service (full name in English: Windows Server
Update Services, english abbreviation: wsus) file server, file packaged service device, CDN server and download information
Database, wherein client and patch update server and carry out information exchange, patch update server and wsus server, text
Part packaged service device and unloading information data library carry out information exchange, file packaged service device, wsus file server difference
Information exchange is carried out with CDN server, file packaged service device and unloading information data library carry out information exchange.
Embodiment one
The embodiment of the invention provides a kind of methods of patch downloading, as shown in Fig. 2, this method comprises the following steps:
Step 201, client update server to patch and send download information request message.
Wherein, at least one key Key is carried in download information request message, download information request message is for requesting extremely
Few corresponding download information of a Key.
For the embodiment of the present invention, download information may include: downloading seed and check value.
Step 202, patch update server and receive the download information request message that client is sent.
Step 203, patch update server and determine the corresponding compression key tarKey of at least one Key.
For the embodiment of the present invention, patch updates server at least one above-mentioned Key, is obtained by TarKey algorithm
TarKey.Wherein, which can be 3 Key.
For example, at least one above-mentioned key is spliced, then splices again with keyword " keyofkeys ", obtains the first key,
Then splice again with KEYOFKEYS, obtain TarKey.
Step 204, patch update server and search the corresponding download information of tarkey from database.
For the embodiment of the present invention, patch updates server and finds the corresponding of above-mentioned 3 key from database
Download information.
For example, the download information found can be with are as follows: the corresponding downloading ground the corresponding download address of the first key, the 2nd key
Location and the corresponding download address of the 3rd key.
For the embodiment of the present invention, database is being used, all key can classified, then be divided every class key
Then every class key is defined as the specific mode repelled each other and is inserted into database by class.For example, the beginning in the first key is spliced
KEYOFKEYS, when bulk lookup download information, it is only necessary to which notification database processing meets the key of corresponding modes.
For example, when needing to delete the corresponding download information of all compressed packages in the database, it is only necessary to search above-mentioned lattice
The corresponding download information of formula key is simultaneously deleted, and the download information for successively finding the corresponding each key of compressed package is not needed, from
And the time for searching download information can be reduced, reduce the number of access data.
If step 205 finds the corresponding download information of tarKey, patch update server by tarKey it is corresponding under
Information carrying breath is back to client, so that client according to download information, downloads corresponding compressed package from CDN server.
It wherein, include that the corresponding download command of at least one key compares text diff file in compressed package.
For the embodiment of the present invention, the corresponding download information of tarKey is the corresponding diff file of above-mentioned each key in CDN
Corresponding download information on server.The corresponding diff of above-mentioned all key in embodiments of the present invention can be equivalent to a benefit
Fourth file.
Step 206, client receive patch and update the corresponding download information of tarKey that server is sent.
Wherein, tarKey is compressed by least one Key and is obtained.
Step 207, client are downloaded from CDN server and are corresponded to according to the corresponding download information of the tarKey received
Compressed package.
It wherein, include that the corresponding download command of at least one key compares text diff file in compressed package.
It include wsus file server in the system of the downloading patch, wherein wsus file clothes for the embodiment of the present invention
Device be engaged in when finding new patch, downloads new patch, and the new patch is generated into multiple diff files, and by generation
Diff file is uploaded to CDN server, and the download information of generation is sent to patch and updates server, therefore client needs
Diff file is downloaded, patch file is obtained.
The embodiment of the invention provides a kind of methods of patch downloading, compared with prior art, objective in the embodiment of the present invention
Family end updates server to patch and sends download information request message, and then patch updates server and receives under client transmission
Information request message is carried, and corresponding tarKey is determined according at least one key carried in download information request message, and look into
The corresponding download information of the tarKey is looked for, and the download information found is back to client, then client is according to downloading
Information downloads the compressed package comprising the corresponding diff file of at least one above-mentioned key from CDN server, i.e. patch updates
Server only needs to access a database according to tarKey, searches download information, and only need to access according to download information
CDN server, downloads the compressed package of the corresponding diff file of above-mentioned all key, to reduce time of access CDN server
Number reduces the duration of downloading patch file, and since client only needs to access a CDN server, and then can reduce pair
The amount of access of CDN server reduces the demand to user bandwidth;
File packaged service device of the embodiment of the present invention is by playing the corresponding diff file of key each at least one key
Be bundled into compressed package, and be uploaded to CDN server, enable to client access a CDN server can download it is above-mentioned extremely
The corresponding diff file of each key reduces downloading patch so as to reduce the number of access CDN server in a few key
The duration of file, and then the amount of access to CDN server can be reduced, reduce the demand to user bandwidth.
Embodiment two
The alternatively possible implementation of the embodiment of the present invention, on the basis of as shown in Figure 2, step 204, patch are more
New demand servicing device searches the corresponding download information of tarkey from database, include thes steps that 305- shown in embodiment two later
307, step 207, client download corresponding pressure according to the corresponding download information of the tarKey received from CDN server
Contracting packet, include thes steps that 311 shown in embodiment two, wherein operation and step performed by step 301-304,308-310 later
Operation performed by rapid 201-208 is similar, and details are not described herein.
If step 305 does not find the corresponding download information of tarKey, patch updates server from database successively
Search the corresponding download information of each Key.
For the embodiment of the present invention, if not finding the corresponding download information of tarkey in the database, characterization will not be upper
It states at least one key to be spliced according to tarKey algorithm, store into database.Therefore, patch update server need according to
It is secondary to search the corresponding download information of each key in above-mentioned at least one key.
For the embodiment of the present invention, patch updates server and does not find the corresponding download information of tarKey in the database
It may be the corresponding diff file of at least one above-mentioned key due to there has been no client request.In embodiments of the present invention
Without limitation.
Step 306, patch update server and the corresponding download information of each Key are back to client, so that client
End diff file is downloaded from CDN server according to the corresponding download information of each Key.
For the embodiment of the present invention, patch updates server and is successively searched at least one above-mentioned key in the database often
The corresponding download information of a key, and the download information found is back to client.
For example, include three key, respectively the first key, the 2nd key and the 3rd key at least one above-mentioned key,
In, patch updates server and finds the corresponding download information of the first key, the corresponding download information of the 2nd key and the respectively
The corresponding download information of three key, and the corresponding download information of the first key, the 2nd key are corresponded into download information and the 3rd key
Corresponding download information is back to client.
If step 307 receives the corresponding download information of each key at least one key, client is according to successively root
According to the corresponding download information of each key, corresponding diff file is downloaded from CDN server.
For the embodiment of the present invention, since client is sequentially received under each key is corresponding at least one above-mentioned key
Information carrying breath, therefore client needs successively to be downloaded from CDN server corresponding according to the corresponding download information of each key
Diff file.
For the embodiment of the present invention, when not finding the corresponding download information of tarKey, patch updates server and passes through
The corresponding download information of each key at least one above-mentioned key is successively searched, the corresponding download information of each key can be obtained,
To find the corresponding diff file of each key according to the corresponding download information of each key, to obtain patch file, so as to
The case where to avoid diff file can not be obtained when not finding the corresponding download information of tarKey in the database.
If step 311, other clients are needed from downloading the diff file downloaded in the client, client in CDN
It holds the diff file that will have been downloaded to pass through point-to-point, is sent to request sender's client.
For the embodiment of the present invention, if the first client downloads the first key, the 2nd key and the from CDN server
The corresponding diff file of tarKey that the corresponding diff file of three key or above three key compress, and second
Client is also required to obtain the first key, the 2nd key and the corresponding diff file of the 3rd key or above three key pressure
Contract the obtained corresponding diff file of tarKey, then the first client can be by point-to-point mode, the diff that will have been downloaded
File is sent to the second client.
For the embodiment of the present invention, client is sent to other clients by the point-to-point diff file that will have been downloaded,
It can be avoided other clients and corresponding diff file downloaded by access CDN server, so as to reduce client to CDN
The amount of access of server, and then the access pressure of CDN server can be reduced, reduce the bandwidth demand to client.
Embodiment three
The alternatively possible implementation of the embodiment of the present invention, on the basis of shown in the embodiment two, step 303 is mended
Fourth updates server and determines the corresponding compression key tarKey of at least one Key, includes the steps that 403 shown in example IV,
In, operation performed by 401-402,404-411 is similar to operation performed by step 301-302,304-311, herein no longer
It repeats.
Step 403, patch update server and splice at least one key, obtain spliced key, and will splicing
Key afterwards is spliced with preset keyword, obtains the corresponding tarKey of at least one Key.
For the embodiment of the present invention, preset keyword can be keyofkeys and KEYOFKEYS.Implement in the present invention
In example, patch, which updates server, can splice at least one above-mentioned key, and by key and keyofkeys after splicing, obtain
To the first key, then the first key and KEYOFKEYS is spliced again, obtains tarKey.
Example IV
The alternatively possible implementation of the embodiment of the present invention, on the basis of embodiment three, step 406, patch are more
The corresponding download information of each Key is back to client by new demand servicing device, so that client is according to the corresponding downloading of each Key
Information include thes steps that three 507-510 of embodiment, wherein step 501- after downloading diff file in CDN server
506, operation performed by 511-515 is similar to operation performed by step 401-411, and details are not described herein.
Step 507, patch update server and at least one Key are sent to file packaged service device, so that file is beaten
Packet server obtains the corresponding diff file of each key at least one key, and the corresponding diff file of all key is packaged
At compressed package, and it is uploaded to CDN server.
For the embodiment of the present invention, above-mentioned at least one key pairs is not found in the database when patch updates server
When the corresponding download information of the tarKey answered, above-mentioned each key is sent to file packaged service device, so that file is packaged clothes
Business device by the corresponding diff file of all key, is compressed into compression from the corresponding diff file of above-mentioned each key is locally-downloaded
Packet, and it is uploaded to CDN server.For the embodiment of the present invention, above-mentioned patch updates server and does not find in the database
When stating the corresponding download information of the corresponding tarKey of at least one key, it is understood that there may be following situations:
1, the corresponding diff file of at least one key is downloaded in client request for the first time;
2, the corresponding download information of the tarKey is deleted in the database, and in CDN service
The corresponding diff compressed package of at least one key is deleted in device.
Step 508, file packaged service device receive patch and update at least one key that server is sent.
Step 509, file packaged service device obtain the corresponding diff file of each key from local, and by all key pairs
The diff file answered is packaged into compressed package.
For example, to obtain the corresponding diff file of the first key, the 2nd key from local corresponding for file packaged service device
Diff file, the corresponding diff file of the 3rd key, and carry out the corresponding diff file of above three key to be packaged into pressure
Contracting packet.
Compressed package is uploaded to CDN server by step 510, file packaged service device.
For the embodiment of the present invention, file packaged service device passes through each key at least one above-mentioned key is corresponding
Diff file is packaged into compressed package together, and is uploaded to CDN server, enable to when subsequent client equally request it is above-mentioned more
When the corresponding diff file of a identical key, an accessible CDN server is obtained comprising every at least one above-mentioned key
The compressed package of the corresponding diff file of a key obtains the corresponding diff file of each key to avoid successively access CDN server,
So as to reduce the number of access CDN server, and then the pressure of CDN server can be reduced.
Embodiment five
The alternatively possible implementation of the embodiment of the present invention, on the basis of shown in the example IV, step 510, text
Compressed package is uploaded to CDN server by part packaged service device, include thes steps that embodiment 5 611 later, wherein step 601-
610, operation performed by 612-616 is similar to operation performed by step 501-515, and details are not described herein.
Step 611, file packaged service device receive the corresponding download information of compressed package of CDN server return, and will
Database is written in the corresponding relationship of download information and tarKey.
Wherein, tarKey is the compressed package of at least one key.
For the embodiment of the present invention, after above-mentioned compressed package is uploaded to CDN server by file packaged service device, file
Packaged service device will receive the corresponding download information of the compressed package and write by the download information in the way of tarKey algorithm
Enter database.
For the embodiment of the present invention, file packaged service device is by by the diff file pair of key all at least one key
Database is written according to the form of tarkey in download information of the compressed package answered in CDN server, and patch is enabled to update
Server finds corresponding download information according to tarkey, and avoiding repeatedly accessing database, successively to search each key corresponding
Download information so as to reduce the number of access database, and then can reduce and search the corresponding download information of multiple key
Time.
The embodiment of the invention provides the methods of another patch downloading, when not finding the corresponding download information of tarKey
When, patch updates server by successively searching the corresponding download information of each key at least one above-mentioned key, can obtain
The corresponding download information of each key, to find the corresponding diff text of each key according to the corresponding download information of each key
Part has obtained patch file, can not so as to avoid when not finding the corresponding download information of tarKey in the database
The case where obtaining diff file;Client is sent to other clients by the point-to-point diff file that will have been downloaded, and can keep away
Exempt from other clients and corresponding diff file is downloaded by access CDN server, so as to reduce client to CDN server
Amount of access, and then the access pressure of CDN server can be reduced, reduce the bandwidth demand to client;File packaged service
Device is uploaded to CDN clothes by the way that the corresponding diff file of key each at least one above-mentioned key is packaged into compressed package together
It is engaged in device, enables to when subsequent client equally requests the corresponding diff file of above-mentioned multiple identical key, accessible one
Secondary CDN server obtains the compressed package comprising the corresponding diff file of key each at least one above-mentioned key, to avoid successively
It accesses CDN server and obtains the corresponding diff file of each key, so as to reduce the number of access CDN server, Jin Erke
To reduce the pressure of CDN server;File packaged service device passes through the diff file of key all at least one key is corresponding
Download information of the compressed package in CDN server database is written according to the form of tarkey, enable to patch to update clothes
Device of being engaged according to tarkey finds corresponding download information, avoid repeatedly accessing database successively search each key it is corresponding under
Information carrying breath, so as to reduce the number of access database, and then can reduce search the corresponding download information of multiple key when
Between.
The embodiment of the invention provides a kind of devices of patch downloading, are located at patch and update server, as shown in figure 3, should
Device includes: receiving module 31, determining module 32, searching module 33, return module 34.
Receiving module 31, for receiving the download information request message of client transmission.
Wherein, at least one key Key is carried in download information request message, download information request message is for requesting extremely
Few corresponding download information of a Key.
Determining module 32, for determining the corresponding compression key tarKey of at least one Key.
Searching module 33, for searching the corresponding download information of tarkey from database.
Return module 34, for when finding the corresponding download information of tarKey, by the corresponding download information of tarKey
It is back to client, so that client according to download information, downloads corresponding compressed package from CDN server.
It wherein, include that the corresponding download command of at least one key compares text diff file in compressed package.
Searching module 33 is also used to successively search from database when not finding the corresponding download information of tarKey
The corresponding download information of each Key.
Return module 34 is also used to the corresponding download information of each Key being back to client so that client according to
The corresponding download information of each Key, downloads diff file from CDN server.
Further, as shown in figure 3, the device further include: sending module 35.
Sending module 35, at least one Key to be sent to file packaged service device, so that file packaged service device
The corresponding diff file of each key at least one key is obtained, and the corresponding diff file of all key is packaged into compressed package,
And it is uploaded to CDN server.
Determining module 32 obtains spliced key specifically for splicing at least one key.
Determining module 32 is specifically also used to splice spliced key with preset keyword, obtains at least one
The corresponding tarKey of Key.
The embodiment of the invention provides a kind of devices of patch downloading, compared with prior art, objective in the embodiment of the present invention
Family end updates server to patch and sends download information request message, and then patch updates server and receives under client transmission
Information request message is carried, and corresponding tarKey is determined according at least one key carried in download information request message, and look into
The corresponding download information of the tarKey is looked for, and the download information found is back to client, then client is according to downloading
Information downloads the compressed package comprising the corresponding diff file of at least one above-mentioned key from CDN server, i.e. patch updates
Server only needs to access a database according to tarKey, searches download information, and only need to access according to download information
CDN server, the compressed package of the corresponding diff file of above-mentioned all key now, to reduce time of access CDN server
Number reduces the duration of downloading patch file, and since client only needs to access a CDN server, and then can reduce
To the amount of access of CDN server, the demand to user bandwidth is reduced.
The embodiment of the invention provides the devices of another patch downloading, when not finding the corresponding download information of tarKey
When, patch updates server by successively searching the corresponding download information of each key at least one above-mentioned key, can obtain
The corresponding download information of each key, to find the corresponding diff text of each key according to the corresponding download information of each key
Part has obtained patch file, can not so as to avoid when not finding the corresponding download information of tarKey in the database
The case where obtaining diff file.
The embodiment of the invention provides a kind of clients of patch downloading, as shown in figure 4, the client includes: transmission mould
Block 41, receiving module 42, download module 43.
Sending module 41 sends download information request message for updating server to patch.
Wherein, at least one key Key is carried in download information request message, download information request message is for requesting extremely
Few corresponding download information of a Key.
Receiving module 42 updates the corresponding download information of tarKey that server is sent for receiving patch.
Wherein, tarKey is compressed by least one Key and is obtained;
Download module 43, for downloading and corresponding to from CDN server according to the corresponding download information of tarKey received
Compressed package.
It wherein, include that the corresponding download command of at least one key compares text diff file in compressed package.
Download module 43 is also used to when receiving the corresponding download information of each key at least one key, successively root
According to the corresponding download information of each key, corresponding diff file is downloaded from CDN server.
Sending module 41, be also used to when other clients need from downloaded in CDN downloaded in the client diff text
When part, by the diff file downloaded by point-to-point, it is sent to request sender's client.
The embodiment of the invention provides a kind of clients, and compared with prior art, client is to benefit in the embodiment of the present invention
Fourth updates server and sends download information request message, and the download information that then patch updates that server reception client is sent is asked
Message is sought, and corresponding tarKey is determined according at least one key carried in download information request message, and searching should
The corresponding download information of tarKey, and the download information found is back to client, then client is according to download information
Downloading includes the compressed package of the corresponding diff file of at least one above-mentioned key, i.e. patch more new demand servicing from CDN server
Device only needs to access a database according to tarKey, searches download information, and only needs to be accessed according to download information primary
CDN server, the compressed package of the corresponding diff file of above-mentioned all key now, so that the number of access CDN server is reduced,
The duration for reducing downloading patch file and since client only needs to access a CDN server, and then can reduce pair
The amount of access of CDN server reduces the demand to user bandwidth.
The embodiment of the invention provides another client, client is sent by the point-to-point diff file that will have been downloaded
To other clients, it can be avoided other clients by access CDN server and download corresponding diff file, so as to subtract
Lack client to the amount of access of CDN server, and then the access pressure of CDN server can be reduced, reduces the band to client
Wide demand.
The embodiment of the invention provides a kind of file packaged service devices of patch downloading, as shown in Figure 5, comprising: receive mould
Block 51 obtains module 52, packetization module 53, uploading module 54.
Receiving module 51 updates at least one key that server is sent for receiving patch.
Module 52 is obtained, for obtaining the corresponding diff file of each key from local.
Packetization module 53, for the corresponding diff file of all key to be packaged into compressed package.
Uploading module 54, for compressed package to be uploaded to CDN server.
Receiving module 51 is also used to receive the corresponding download information of compressed package of CDN server return.
Further, this document packaged service device further include: writing module 55.
Writing module 55, for database to be written in the corresponding relationship of download information and tarKey.
Wherein, tarKey is the compressed package of at least one key.
File packaged service device of the embodiment of the present invention is by playing the corresponding diff file of key each at least one key
Be bundled into compressed package, and be uploaded to CDN server, enable to client access a CDN server can download it is above-mentioned extremely
The corresponding diff file of each key reduces downloading patch so as to reduce the number of access CDN server in a few key
The duration of file, and then the amount of access to CDN server can be reduced, reduce the demand to user bandwidth.
The embodiment of the invention provides another file packaged service device, file packaged service device passes through above-mentioned at least one
The corresponding diff file of each key is packaged into compressed package together in a key, and is uploaded to CDN server, enables to when subsequent
When client equally requests above-mentioned multiple identical key corresponding diff file, an accessible CDN server obtains packet
The compressed package of the corresponding diff file containing key each at least one above-mentioned key obtains to avoid successively access CDN server
The corresponding diff file of each key so as to reduce the number of access CDN server, and then can reduce CDN server
Pressure;File packaged service device by by the corresponding compressed package of diff file of key all at least one key in CDN service
Database is written according to the form of tarkey in download information on device, enables to patch to update server and is searched according to tarkey
To corresponding download information, avoids repeatedly accessing database and successively search the corresponding download information of each key, so as to reduce
The number of database is accessed, and then the time for searching the corresponding download information of multiple key can be reduced.
Device, file packaged service device and the client of patch downloading provided in an embodiment of the present invention may be implemented above-mentioned
The embodiment of the method for offer, concrete function realize the explanation referred in embodiment of the method, and details are not described herein.The present invention is implemented
Method, apparatus, file packaged service device and the client for the patch downloading that example provides can be adapted for downloading from CDN server
The corresponding diff file of multiple key, but it is not limited only to this.
Those skilled in the art of the present technique are appreciated that the present invention includes being related to for executing in operation described herein
One or more equipment.These equipment can specially design and manufacture for required purpose, or also may include general
Known device in computer.These equipment have the computer program being stored in it, these computer programs are selectively
Activation or reconstruct.Such computer program can be stored in equipment (for example, computer) readable medium or be stored in
It e-command and is coupled in any kind of medium of bus respectively suitable for storage, the computer-readable medium includes but not
Be limited to any kind of disk (including floppy disk, hard disk, CD, CD-ROM and magneto-optic disk), ROM (Read-Only Memory, only
Read memory), RAM (Random Access Memory, immediately memory), EPROM (Erasable Programmable
Read-Only Memory, Erarable Programmable Read only Memory), EEPROM (Electrically Erasable
ProgrammableRead-Only Memory, Electrically Erasable Programmable Read-Only Memory), flash memory, magnetic card or light card.
It is, readable medium includes by equipment (for example, computer) with any medium for the form storage or transmission information that can be read.
Those skilled in the art of the present technique be appreciated that can be realized with computer program instructions these structure charts and/or
The combination of each frame and these structure charts and/or the frame in block diagram and/or flow graph in block diagram and/or flow graph.This technology neck
Field technique personnel be appreciated that these computer program instructions can be supplied to general purpose computer, special purpose computer or other
The processor of programmable data processing method is realized, to pass through the processing of computer or other programmable data processing methods
The scheme specified in frame or multiple frames of the device to execute structure chart and/or block diagram and/or flow graph disclosed by the invention.
Those skilled in the art of the present technique have been appreciated that in the present invention the various operations crossed by discussion, method, in process
Steps, measures, and schemes can be replaced, changed, combined or be deleted.Further, each with having been crossed by discussion in the present invention
Kind of operation, method, other steps, measures, and schemes in process may also be alternated, changed, rearranged, decomposed, combined or deleted.
Further, in the prior art to have and the step in various operations, method disclosed in the present invention, process, measure, scheme
It may also be alternated, changed, rearranged, decomposed, combined or deleted.
The above is only some embodiments of the invention, it is noted that for the ordinary skill people of the art
For member, various improvements and modifications may be made without departing from the principle of the present invention, these improvements and modifications are also answered
It is considered as protection scope of the present invention.