CN105635747A - Video cache method and device - Google Patents

Video cache method and device Download PDF

Info

Publication number
CN105635747A
CN105635747A CN201510332469.XA CN201510332469A CN105635747A CN 105635747 A CN105635747 A CN 105635747A CN 201510332469 A CN201510332469 A CN 201510332469A CN 105635747 A CN105635747 A CN 105635747A
Authority
CN
China
Prior art keywords
video file
unit
uncached
request
local cache
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201510332469.XA
Other languages
Chinese (zh)
Other versions
CN105635747B (en
Inventor
梁捷
王尧佳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba China Co Ltd
Original Assignee
Guangzhou Dongjing Computer Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Family has litigation
First worldwide family litigation filed litigation Critical https://patents.darts-ip.com/?family=56050176&utm_source=google_patent&utm_medium=platform_link&utm_campaign=public_patent_search&patent=CN105635747(A) "Global patent litigation dataset” by Darts-ip is licensed under a Creative Commons Attribution 4.0 International License.
Application filed by Guangzhou Dongjing Computer Technology Co Ltd filed Critical Guangzhou Dongjing Computer Technology Co Ltd
Priority to CN201510332469.XA priority Critical patent/CN105635747B/en
Publication of CN105635747A publication Critical patent/CN105635747A/en
Application granted granted Critical
Publication of CN105635747B publication Critical patent/CN105635747B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/238Interfacing the downstream path of the transmission network, e.g. adapting the transmission rate of a video stream to network bandwidth; Processing of multiplex streams
    • H04N21/2385Channel allocation; Bandwidth allocation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/231Content storage operation, e.g. caching movies for short term storage, replicating data over plural servers, prioritizing data for deletion
    • H04N21/23113Content storage operation, e.g. caching movies for short term storage, replicating data over plural servers, prioritizing data for deletion involving housekeeping operations for stored content, e.g. prioritizing content for deletion because of storage space restrictions

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The embodiment of the invention discloses a video cache method and device. The method comprises the following steps: determining a video file that is not completely cached in a local cache; and when judging that the network is idle, caching the rest data blocks of the video file that is not completely cached in the local cache through the idle bandwidth. In the embodiment of the invention, when determining that the video file that is not completely cached exists in the local cache, the rest data blocks of the video file that is not completely cached are stored in the local cache through the idle bandwidth to be subsequently requested by a client. The use of the idle bandwidth is increased, the video cache is optimized, and the play speed of the online video play is accelerated.

Description

A kind of video cache method and device
Technical field
The present invention relates to caching technology field, particularly to a kind of video cache method and device.
Background technology
Along with developing rapidly of mobile terminal technology, watching Online Video on smart mobile phone, the portable equipment of flat board becomes a kind of trend. And in order to provide high-quality Video service, at present, content distributing network (CDN, ContentDeliveryNetwork) generally adopts the mode of block buffer memory, described piece of buffer memory, be exactly each video file being all with data-block cache, such as, client asks certain video file, or during a data block in certain video file, whether CDN can first inquire about in local cache exists this video file, if it does, directly address corresponding for this video file is sent to client; If it does not exist, then ask this video file in the way of data block successively to source server, and the data block of request is sent to successively client, simultaneously at this video file of local cache.
But, in video file playing process, user understands F.F. or retrogressing, now, the data block of client request, right and wrong are successional, for CDN, the data block at this video file of local cache is also incomplete, and at this moment, if other clients, identical video file is play in request, and when being different data block, CDN needs again to initiate request to source server, and after obtaining corresponding data block, it is sent to other clients this data block of local cache. Above, obtain if the behavior of the requested data block of first client is bandwidth idle, and the behavior that second client asks another data block to be bandwidth busy obtain, this be exactly a kind of waste for the bandwidth between CDN and source server.
Based on the process of above two requested data block, it is required for client request and triggers. This makes the bandwidth between CDN and source server, can change along with the change of user's request data behavior, thus the bandwidth causing idle cannot utilize, busy then employs too much bandwidth. It is to say, the bandwidth wasted between CDN and source server.
Summary of the invention
The embodiment of the present invention provides a kind of video cache method and device, to solve in existing video cache mode, owing to the bandwidth between CDN and source server can change along with the change of the playing request behavior of client, thus causing the technical problem that the bandwidth resources between CDN and source server are wasted.
In order to solve above-mentioned technical problem, the embodiment of the invention discloses following technical scheme:
First aspect provides a kind of video cache method, and described method includes:
Determine uncached complete video file in local cache;
When judging network idle, idle bandwidth is utilized to be cached in described local cache by the remaining data block of described uncached complete video file.
Optionally, described method also includes:
Determine the Heat range of described uncached complete video file;
Described idle bandwidth is utilized to be cached in described local cache by the remaining data block of described uncached complete video file, including: utilize idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file according to the height of described Heat range.
Optionally, the described Heat range determining described uncached complete video file, including:
Obtain client and send the video playback request of the request described uncached complete video file of broadcasting;
The Heat range of described uncached complete video file is determined according to the request of described video playback.
Optionally, the described Heat range determining described uncached complete video file according to the request of described video playback, including:
Judging the 0th byte whether including request playing video file in the request of described video playback, if including the 0th byte, then record request accesses the number of times of described video file;
Determine the Heat range of described video file according to the number of times of the request described video file of access of record in setting cycle.
Optionally, described method also includes:
Judge that whether described local cache is full, if it is, delete the described uncached complete video file that Heat range in described local cache is minimum.
Optionally, described judgement network idle, specifically include:
The current time of acquisition system, it is judged that whether described current time is Preset Time, if it is, judge described network idle; Or
Add up the present flow rate of described network, it is judged that whether described present flow rate is less than flow threshold, if it is, judge described network idle.
Second aspect provides a kind of video cache device, and described device includes:
First determines unit, for determining uncached complete video file in local cache;
First judging unit, is used for judging that whether network is idle;
Buffer unit, for when described first judging unit judges described network idle, utilizing idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file.
Optionally, described device also includes:
Second determines unit, for determining the Heat range of described uncached complete video file;
Described buffer unit, specifically for utilizing idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file according to the height of described Heat range.
Optionally, described second determines that unit includes:
Acquiring unit, sends the video playback request of the request described uncached complete video file of broadcasting for obtaining client;
Heat range determines unit, for determining the Heat range of described uncached complete video file according to the request of described video playback.
Optionally, described Heat range determines that unit includes:
Byte judging unit, for judging the 0th byte whether including request playing video file in the request of described video playback;
Record unit, for when described second judging unit judges to include the 0th byte, record request accesses the number of times of described video file;
Heat range determines subelement, for determining the Heat range of described video file in setting cycle according to the number of times of the request described video file of access of described recording unit records.
Optionally, described device also includes:
Second judging unit, is used for judging that whether described local cache is full;
Delete unit, for when described second judging unit judges that described local cache is completely, deleting the described uncached complete video file that Heat range in described local cache is minimum.
Optionally, described first judging unit includes: acquiring unit, the first judgment sub-unit and first determine subelement; And/or, statistic unit, the second judgment sub-unit and second determine subelement, wherein,
Described acquiring unit, for obtaining the current time of system;
Described first judgment sub-unit, for judging whether the described current time that described acquiring unit obtains is Preset Time;
Described first determines subelement, for when described first judgment sub-unit judges that described current time is Preset Time, it is determined that described network idle;
Described statistic unit, for adding up the present flow rate of described network;
Described second judgment sub-unit, for judging that whether described present flow rate that described statistic unit adds up is less than flow threshold;
Described second determines subelement, for when described second judgment sub-unit judges present flow rate less than flow threshold, it is determined that described network idle.
As shown from the above technical solution, in the embodiment of the present invention, when having uncached complete video file in determining local cache, idle bandwidth is utilized to store in local cache by data block remaining in described video file, in order to subsequent client is asked. The bandwidth adding idle uses, and optimizes video cache, improves the online broadcasting speed playing video.
Accompanying drawing explanation
In order to be illustrated more clearly that the embodiment of the present invention or technical scheme of the prior art, the accompanying drawing used required in embodiment will be briefly described below, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skill in the art, under the premise not paying creative work, it is also possible to obtain other accompanying drawing according to these accompanying drawings.
The flow chart of a kind of video cache method that Fig. 1 provides for the embodiment of the present invention;
Another flow chart of a kind of video cache method that Fig. 2 provides for the embodiment of the present invention;
The structural representation of a kind of video cache device that Fig. 3 provides for the embodiment of the present invention;
Another structural representation of a kind of video cache device that Fig. 4 provides for the embodiment of the present invention;
Another structural representation of a kind of video cache device that Fig. 5 provides for the embodiment of the present invention;
Another structural representation of a kind of video cache device that Fig. 6 provides for the embodiment of the present invention;
Fig. 7 shows schematic diagram for the structure of a kind of server that the embodiment of the present invention provides.
Detailed description of the invention
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 carried out clear, complete description, it is clear that described embodiment is only a part of embodiment of the present invention, rather than whole embodiments. Based on the embodiment in the present invention, the every other embodiment that those of ordinary skill in the art obtain under not making creative work premise, broadly fall into the scope of protection of the invention.
The term used in embodiments of the present invention is only merely for the purpose describing specific embodiment, and is not intended to be limiting the present invention. " one ", " described " and " being somebody's turn to do " of the singulative used in the embodiment of the present invention and appended claims is also intended to include most form, unless context clearly shows that other implications. It is also understood that term "and/or" used herein refers to and comprises any or all of one or more project of listing being associated and be likely to combination.
Although should be appreciated that and be likely in embodiments of the present invention adopt term first, second, third, etc. to describe various information, but these information should not necessarily be limited by these terms. These terms are only used for being distinguished from each other out same type of information. Such as, when without departing from range of embodiment of the invention, the first information can also be referred to as the second information, it is not required that or imply the relation or order that there is any this reality between these entities or operation. Similarly, the second information can also be referred to as the first information. Depend on linguistic context, word as used in this " if " can be construed to " ... time " or " when ... " or " in response to determining ". And, term " includes ", " comprising " or its any other variant are intended to comprising of nonexcludability, so that include the process of a series of key element, method, article or equipment not only include those key elements, but also include other key elements being not expressly set out, or also include the key element intrinsic for this process, method, article or equipment.
Refer to the flow chart of a kind of video cache method that Fig. 1, Fig. 1 provide for the embodiment of the present invention; Described method includes:
Step 101: determine uncached complete video file in local cache;
In this step, content distributing network (CDN, ContentDeliveryNetwork) whether system can video file regularly or in real-time judge local cache be complete video file, the mode of its judgement has multiple, such as, it is possible to by judging that the length of video file judges that whether video file is complete etc. And add up uncached complete video file. Wherein, uncached complete video file is the part data block only storing this video file. Wherein it is determined that uncached complete video file to those skilled in the art, has been know technology, has not repeated them here in local cache.
Wherein, in the present embodiment, CDN system can be one or more CDN server, it is also possible to be, main CDN server and edge cache server etc.
Step 102: when judging network idle, utilize idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file.
In this step, CDN system can from source server the remaining data block of the uncached complete video file of buffer memory.
Wherein, CDN system judges that whether network is idle, and the present embodiment is example in two ways:
One is: obtain the current time in system, it is judged that whether current time is Preset Time; If it is, judge described network idle; Otherwise, it is determined that described network busy.
Wherein, Preset Time can be one is the time period, it is of course also possible to be a time point, the present embodiment is not limited as. Such as, it is assumed that Preset Time is 22:00 to 3:00 etc., but is not limited to this, if the current time of the system of acquisition is 12:00, then it is assumed that current network is idle; If the current time of the system of acquisition is 21:00, then it is assumed that current network is busy. Certainly, this is an example, in actual applications, however it is not limited to this.
Whether another kind is: add up the present flow rate of described network, according to described present flow rate less than flow threshold, if it is, judge described network idle; Otherwise, it is determined that described network busy.
Wherein, flow threshold can as desired to set, it is of course also possible to set based on experience value, the present embodiment is not limited as.
And add up the mode of the present flow rate of described network, to those skilled in the art, it is know technology, has not repeated them here.
In the embodiment of the present invention, when the video file in determining local cache is uncached complete video file, idle bandwidth is utilized to store in local cache by data block remaining in described video file, in order to subsequent client is asked. The bandwidth adding idle uses, and optimizes video cache, improves the online broadcasting speed playing video.
Also referring to another flow chart of a kind of video cache method that Fig. 2, Fig. 2 provide for the embodiment of the present invention, described method includes:
Step 201: determine uncached complete video file in local cache;
This step is same with step 101, specifically refers to above-mentioned, does not repeat them here.
Step 202: determine the Heat range of described uncached complete video file;
In this step, a kind of determine video file Heat range mode be: obtain client send request play described uncached complete video file video playback request; The Heat range of described uncached complete video file is determined according to the request of described video playback.
That is, this determines in the process of Heat range, first obtain the video playback request of described uncached complete video file, then, judge the 0th byte whether including request playing video file in the request of described video playback, if including the 0th byte, then record request accesses the number of times of described video file; Finally, in setting cycle, the Heat range of described video file is determined according to the number of times of the request described video file of access of record.
Wherein, the 0th byte is used to indicate that the temperature of video file identifies. It is to say, in the present embodiment, use the 0th byte of whole video file, as the foundation judging the whether requested broadcasting of this video file. Namely one video file of complete download, will necessarily download the 0th byte.
Such as, DNS system receives the video playback request that 60 clients send, wherein, having the video playback request that 30 clients send is that same video file 1 is play in request, and, scope in these 30 video playback requests all includes the 0th byte, the Heat range then determining this video file 1 is high temperature, and having the video playback request that 20 clients send is that same video file 2 is play in request, and, scope in these 20 video playback requests also all includes the 0th byte, then confirm that video file 2 Heat range is time temperature; In like manner, the video playback request that remaining 10 clients send is that same video file 3 is play in request, and, the scope in these 10 video playback requests also all includes the 0th byte, then confirm that video file 3 Heat range is low temperature.
Certainly, in this embodiment, if the scope in video playback request does not all include the 0th byte, mean that, this video file is not play first by client (namely sending the client of this video playback request), and for this client, second time or n-th are play substantially, namely processing according to existing online playing flow, the present embodiment no longer illustrates one by one.
Step 203: judge that whether network is idle; If it is, perform step 204; Otherwise, return step 203, continue to judge that whether network is idle;
In this step, it judges that whether network is idle for following two ways, specifically includes:
One is: obtain the current time in system, it is judged that whether current time is Preset Time; If it is, judge described network idle; Otherwise, it is determined that described network busy.
Whether another kind is: add up the present flow rate of described network, according to described present flow rate less than flow threshold, if it is, judge described network idle; Otherwise, it is determined that described network busy.
The process that implements of both modes refers to above-mentioned, does not repeat them here.
Step 204: utilize idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file according to the height of described Heat range.
In this step, when network idle, DNS system can utilize idle bandwidth according to remaining data block in the height buffer memory correspondence video file of this Heat range.
In the embodiment of the present invention, when having uncached complete video file in determining local cache, further determine that the Heat range of this video file, and utilize remaining data block in the described video file that idle bandwidth elder generation buffer memory Heat range is higher, the bandwidth not only adding idle uses, optimize video cache, improve the satisfaction of the online broadcasting speed playing video and user.
Optionally, in another embodiment, this embodiment is on the basis of above-described embodiment, and described method can also include: judge that whether described local cache is full, if it is, delete the described uncached complete video file that Heat range in described local cache is minimum.
In this embodiment, whether DNS system meeting periodic detection local cache is full, and when detecting that local cache is full, can delete the uncached complete video file that some Heat ranges are relatively low. It is, of course, also possible to delete the video file that some broadcasting rates are relatively low further, the present embodiment is not limited as.
It is to say, in the present embodiment, when local cache is expired, delete the uncached complete video file that some Heat ranges are relatively low, to vacate some buffer memorys to download the uncached complete video file that Heat range is higher, improve the satisfaction of user.
Based on the process that realizes of said method, the embodiment of the present invention also provides for a kind of video cache device, and its structural representation is as it is shown on figure 3, described device includes: first determines unit 31, the first judging unit 32 and buffer unit 33, wherein,
Described first determines unit 31, for determining uncached complete video file in local cache;
Described first judging unit 32, is used for judging that whether network is idle;
Described buffer unit 33, for when described first judging unit 32 judges described network idle, utilizing idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file.
Optionally, in another embodiment, this embodiment is on the basis of above-described embodiment, and described device also includes: second determines unit 41, its structural representation as shown in Figure 4, wherein,
Described second determines unit 41, for determining that unit 31 is determined in local cache after uncached complete video file described first, it is determined that the Heat range of described uncached complete video file;
Described buffer unit 33, specifically for utilizing idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file according to the height of described Heat range.
Optionally, in another embodiment, this embodiment is on the basis of above-described embodiment, and described second determines that unit 41 includes: acquiring unit 51 and Heat range determine unit 52, its structural representation as it is shown in figure 5, wherein,
Described acquiring unit 51, sends the video playback request of the request described uncached complete video file of broadcasting for obtaining client;
Described Heat range determines unit 52, for determining the Heat range of described uncached complete video file according to the request of described video playback.
Optionally, in another embodiment, this embodiment is on the basis of above-described embodiment, and described Heat range determines that unit 52 includes: byte judging unit, and record unit and Heat range determine subelement (not shown), wherein,
Described byte judging unit, for judging the 0th byte whether including request playing video file in the request of described video playback;
Described record unit, for when described second judging unit judges to include the 0th byte, record request accesses the number of times of described video file;
Described Heat range determines subelement, for determining the Heat range of described video file in setting cycle according to the number of times of the request described video file of access of described recording unit records.
Optionally, in another embodiment, this embodiment is on the basis of above-described embodiment, described device can also include: the second judging unit 61 and deletion unit 62, and as shown in Figure 6, this embodiment is on the basis of Fig. 5 for its structural representation, but it is not limited to this, wherein
Described second judging unit 61, is used for judging that whether described local cache is full;
It is to say, after buffered video file (including complete video file and/or incomplete video file), just can go to judge that whether described local cache is full in local cache at described buffer unit 33.
Described deletion unit 62, for when described second judging unit 61 judges that described local cache is completely, deleting the described uncached complete video file that Heat range in described local cache is minimum.
Optionally, in another embodiment, this embodiment is on the basis of above-described embodiment, and described first judging unit includes: acquiring unit, the first judgment sub-unit and first determine subelement; And/or, statistic unit, the second judgment sub-unit and second determine subelement (not shown), wherein,
Described acquiring unit, for obtaining the current time of system;
Described first judgment sub-unit, for judging whether the described current time that described acquiring unit obtains is Preset Time;
Described first determines subelement, for when described first judgment sub-unit judges that described current time is Preset Time, it is determined that described network idle;
Described statistic unit, for adding up the present flow rate of described network;
Described second judgment sub-unit, for judging that whether described present flow rate that described statistic unit adds up is less than flow threshold;
Described second determines subelement, for when described second judgment sub-unit judges present flow rate less than flow threshold, it is determined that described network idle.
What in described device, the function of unit and the process that realizes of effect referred in said method corresponding step realizes process, does not repeat them here.
In the embodiment of the present invention, uncached complete video file is had in determining local cache, further determine that the Heat range of this uncached complete video file, then, when judging network idle, utilize idle bandwidth to store in local cache by remaining data block in described uncached complete video file according to the height of Heat range, the bandwidth adding idle uses, the bandwidth reducing busy uses, and optimizes video cache, improves the online broadcasting speed playing video.
Referring to Fig. 7, for the structural representation of a kind of server that the embodiment of the present invention provides, this server 700 includes: processor 710, memorizer 720, transceiver 730 and bus 740;
Processor 710, memorizer 720, transceiver 730 are connected with each other by bus 740; Bus 740 can be isa bus, pci bus or eisa bus etc. Described bus can be divided into address bus, data/address bus, control bus etc. For ease of representing, Fig. 7 only represents with a thick line, it is not intended that only have a bus or a type of bus.
Memorizer 720, is used for depositing program. Specifically, program can include program code, and described program code includes computer-managed instruction. Memorizer 720 is likely to comprise high-speed RAM memorizer, it is also possible to also include nonvolatile memory (non-volatilememory), for instance at least one disk memory.
Described processor 710 performs the described program code of storage in memorizer 720, for determining uncached complete video file in local cache according to the request of described video playback, when judging network idle, idle bandwidth is utilized to be cached in described local cache by the remaining data block of described uncached complete video file.
Alternatively, described processor 710, it is additionally operable to determine the Heat range of described uncached complete video file, and utilizes idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file according to the height of described Heat range.
Alternatively, the Heat range of described uncached complete video file determined by described processor 710, including: obtain client and send the video playback request of the request described uncached complete video file of broadcasting; The Heat range of described uncached complete video file is determined according to the request of described video playback.
Alternatively, the Heat range determining described uncached complete video file according to the request of described video playback determined by described processor 710, including: judge the 0th byte whether including request playing video file in the request of described video playback, if including the 0th byte, then record request accesses the number of times of described video file; Determine the Heat range of described video file according to the number of times of the request described video file of access of record in setting cycle.
Alternatively, described processor 710, it is additionally operable to judge that whether described local cache is full, if it is, delete the described uncached complete video file that Heat range in described local cache is minimum.
Alternatively, described transceiver 730, for obtaining the current time of system;
Described processor 710 is additionally operable to judge whether the current time that described transceiver obtains is Preset Time, if it is, judge described network idle;
Alternatively, described transceiver 730, it is additionally operable to add up the present flow rate of described network;
Described processor 710 is additionally operable to judge that whether described present flow rate is less than flow threshold, if it is, judge described network idle.
In the embodiment of the present invention, after having uncached complete video file in determining local cache, determine that the heat of this uncached complete video file determines grade, then, the height that idle bandwidth determines grade according to heat is utilized to store in local cache by remaining data block in described uncached complete video file, in order to subsequent client is asked. The bandwidth adding idle uses, and optimizes video cache, improves the online broadcasting speed playing video.
Those skilled in the art is it can be understood that can add the mode of required general hardware platform by software to the technology in the embodiment of the present invention and realize. Based on such understanding, the part that prior art is contributed by technical scheme in the embodiment of the present invention substantially in other words can embody with the form of software product, this computer software product can be stored in storage medium, such as ROM/RAM, magnetic disc, CD etc., including some instructions with so that a computer equipment (can be personal computer, server, or the network equipment etc.) perform the method described in some part of each embodiment of the present invention or embodiment.
Each embodiment in this specification all adopts the mode gone forward one by one to describe, between each embodiment identical similar part mutually referring to, what each embodiment stressed is the difference with other embodiments. Especially for system embodiment, owing to it is substantially similar to embodiment of the method, so what describe is fairly simple, relevant part illustrates referring to the part of embodiment of the method.
Invention described above embodiment, is not intended that limiting the scope of the present invention. Any amendment, equivalent replacement and improvement etc. made within the spirit and principles in the present invention, should be included within protection scope of the present invention.

Claims (12)

1. a video cache method, it is characterised in that including:
Determine uncached complete video file in local cache;
When judging network idle, idle bandwidth is utilized to be cached in described local cache by the remaining data block of described uncached complete video file.
2. method according to claim 1, it is characterised in that also include:
Determine the Heat range of described uncached complete video file;
Described idle bandwidth is utilized to be cached in described local cache by the remaining data block of described uncached complete video file, including: utilize idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file according to the height of described Heat range.
3. method according to claim 2, it is characterised in that the described Heat range determining described uncached complete video file, including:
Obtain client and send the video playback request of the request described uncached complete video file of broadcasting;
The Heat range of described uncached complete video file is determined according to the request of described video playback.
4. method according to claim 3, it is characterised in that the described Heat range determining described uncached complete video file according to the request of described video playback, including:
Judging the 0th byte whether including request playing video file in the request of described video playback, if including the 0th byte, then record request accesses the number of times of described video file;
Determine the Heat range of described video file according to the number of times of the request described video file of access of record in setting cycle.
5. method according to claim 4, it is characterised in that also include:
Judge that whether described local cache is full, if it is, delete the described uncached complete video file that Heat range in described local cache is minimum.
6. the method according to any one of claim 1 to 5, it is characterised in that described judgement network idle, specifically includes:
The current time of acquisition system, it is judged that whether described current time is Preset Time, if it is, judge described network idle; Or
Add up the present flow rate of described network, it is judged that whether described present flow rate is less than flow threshold, if it is, judge described network idle.
7. a video cache device, it is characterised in that including:
First determines unit, for determining uncached complete video file in local cache;
First judging unit, is used for judging that whether network is idle;
Buffer unit, for when described first judging unit judges described network idle, utilizing idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file.
8. device according to claim 7, it is characterised in that also include:
Second determines unit, for determining the Heat range of described uncached complete video file;
Described buffer unit, specifically for utilizing idle bandwidth to be cached in described local cache by the remaining data block of described uncached complete video file according to the height of described Heat range.
9. device according to claim 8, it is characterised in that described second determines that unit includes:
Acquiring unit, sends the video playback request of the request described uncached complete video file of broadcasting for obtaining client;
Heat range determines unit, for determining the Heat range of described uncached complete video file according to the request of described video playback.
10. device according to claim 9, it is characterised in that described Heat range determines that unit includes:
Byte judging unit, for judging the 0th byte whether including request playing video file in the request of described video playback;
Record unit, for when described second judging unit judges to include the 0th byte, record request accesses the number of times of described video file;
Heat range determines subelement, for determining the Heat range of described video file in setting cycle according to the number of times of the request described video file of access of described recording unit records.
11. device according to claim 10, it is characterised in that also include:
Second judging unit, is used for judging that whether described local cache is full;
Delete unit, for when described second judging unit judges that described local cache is completely, deleting the described uncached complete video file that Heat range in described local cache is minimum.
12. according to the device described in any one of claim 7 to 11, it is characterised in that described first judging unit includes: acquiring unit, the first judgment sub-unit and first determine subelement; And/or, statistic unit, the second judgment sub-unit and second determine subelement, wherein,
Described acquiring unit, for obtaining the current time of system;
Described first judgment sub-unit, for judging whether the described current time that described acquiring unit obtains is Preset Time;
Described first determines subelement, for when described first judgment sub-unit judges that described current time is Preset Time, it is determined that described network idle;
Described statistic unit, for adding up the present flow rate of described network;
Described second judgment sub-unit, for judging that whether described present flow rate that described statistic unit adds up is less than flow threshold;
Described second determines subelement, for when described second judgment sub-unit judges present flow rate less than flow threshold, it is determined that described network idle.
CN201510332469.XA 2015-06-16 2015-06-16 A kind of video cache method and device Active CN105635747B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510332469.XA CN105635747B (en) 2015-06-16 2015-06-16 A kind of video cache method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510332469.XA CN105635747B (en) 2015-06-16 2015-06-16 A kind of video cache method and device

Publications (2)

Publication Number Publication Date
CN105635747A true CN105635747A (en) 2016-06-01
CN105635747B CN105635747B (en) 2017-03-15

Family

ID=56050176

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510332469.XA Active CN105635747B (en) 2015-06-16 2015-06-16 A kind of video cache method and device

Country Status (1)

Country Link
CN (1) CN105635747B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101494768A (en) * 2009-01-23 2009-07-29 华为技术有限公司 Method and apparatus for sending and downloading multimedia data, and multimedia order programme system
CN103312776A (en) * 2013-05-08 2013-09-18 青岛海信传媒网络技术有限公司 Method and device for caching contents of videos by edge node server
CN104093044A (en) * 2014-01-20 2014-10-08 腾讯科技(深圳)有限公司 Online media playing method, server and system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101494768A (en) * 2009-01-23 2009-07-29 华为技术有限公司 Method and apparatus for sending and downloading multimedia data, and multimedia order programme system
CN103312776A (en) * 2013-05-08 2013-09-18 青岛海信传媒网络技术有限公司 Method and device for caching contents of videos by edge node server
CN104093044A (en) * 2014-01-20 2014-10-08 腾讯科技(深圳)有限公司 Online media playing method, server and system

Also Published As

Publication number Publication date
CN105635747B (en) 2017-03-15

Similar Documents

Publication Publication Date Title
CN101510219B (en) File data accessing method, apparatus and system
CN109600437B (en) Downloading method of streaming media resource and cache server
CN101645928B (en) Content resource caching method, device and system
CN104468395A (en) Direct-broadcasting-room channel access method and system
US8527610B2 (en) Cache server control device, content distribution system, method of distributing content, and program
CN102413151B (en) Network resource sharing method and system
US11256663B2 (en) Caching with dynamic and selective compression of content
CN102164160B (en) Method, device and system for supporting large quantity of concurrent downloading
CN106161569A (en) The recommendation of Web content, buffer replacing method and equipment
CN105573667A (en) Data reading method and storage server
CN111597213B (en) Caching method, software server and storage medium
CN111083217B (en) Method and device for pushing Feed stream and electronic equipment
CN107026879B (en) Data caching method and background application system
CN101277211A (en) Method and apparatus for buffering data
CN110809167B (en) Video playing method and device, electronic equipment and storage medium
KR20140011591A (en) Method and apparatus for caching proxy
WO2018233539A1 (en) Video processing method, computer storage medium, and device
CN109067916B (en) Online multimedia file downloading method and device and electronic equipment
CN113630329A (en) Load balancing method and system based on user access amount and readable storage medium
US8209711B2 (en) Managing cache reader and writer threads in a proxy server
CN102164309B (en) Program processing method, system and device
CN111597259B (en) Data storage system, method, device, electronic equipment and storage medium
CN109582233A (en) A kind of caching method and device of data
CN111131864A (en) Data transmission method, device and system
CN104063269B (en) It is a kind of to realize the method and device applied offline

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20200420

Address after: 310052 room 508, floor 5, building 4, No. 699, Wangshang Road, Changhe street, Binjiang District, Hangzhou City, Zhejiang Province

Patentee after: Alibaba (China) Co.,Ltd.

Address before: 510627 Guangdong city of Guangzhou province Whampoa Tianhe District Road No. 163 Xiping Yun Lu Yun Ping B radio 14 floor tower square

Patentee before: GUANGZHOU UCWEB COMPUTER TECHNOLOGY Co.,Ltd.