WO2023082764A1 - Content recording method, content playing method, cdn system, and storage medium - Google Patents

Content recording method, content playing method, cdn system, and storage medium Download PDF

Info

Publication number
WO2023082764A1
WO2023082764A1 PCT/CN2022/114279 CN2022114279W WO2023082764A1 WO 2023082764 A1 WO2023082764 A1 WO 2023082764A1 CN 2022114279 W CN2022114279 W CN 2022114279W WO 2023082764 A1 WO2023082764 A1 WO 2023082764A1
Authority
WO
WIPO (PCT)
Prior art keywords
code stream
content
hot
live
hotspot
Prior art date
Application number
PCT/CN2022/114279
Other languages
French (fr)
Chinese (zh)
Inventor
杨志
马正园
Original Assignee
中兴通讯股份有限公司
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
Application filed by 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2023082764A1 publication Critical patent/WO2023082764A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/12Replacement control
    • 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/21Server components or server architectures
    • H04N21/218Source of audio or video content, e.g. local disk arrays
    • H04N21/2187Live feed
    • 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
    • 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/23106Content storage operation, e.g. caching movies for short term storage, replicating data over plural servers, prioritizing data for deletion involving caching operations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/83Generation or processing of protective or descriptive data associated with content; Content structuring
    • H04N21/845Structuring of content, e.g. decomposing content into time segments

Definitions

  • the present application relates to but not limited to the field of video media services, and in particular relates to a content recording method, a playback method, a CDN system, and a storage medium.
  • IPTV Internet Protocol Television
  • cache devices such as solid state drives (Solid State Drive, SSD) or non-volatile high-speed transmission bus (Non-Volatile Memory express, NVME) can be used to store file blocks, but the cache device The cost is high and cannot be widely used. Therefore, the operator usually records the channel code stream to the low-speed cache device, and after performing heat statistics on the content of the playback or time-shifted access, the high-hot access file blocks are removed from the low-speed cache.
  • the device copy cache device when the file block of the access content has a copy of the cache device, the content is read from the cache device first.
  • the heat statistics and copying and migration of file blocks have a certain lag and will consume a certain amount of operation time, making it difficult to meet the requirements of high real-time services such as live broadcast time shifting.
  • Embodiments of the present application provide a content recording method, a playback method, a CDN system, and a storage medium.
  • the embodiment of the present application provides a content recording method, which is applied to a CDN system, and the CDN system includes a cache device, and the method includes: obtaining hot spot time information pre-associated with hot channel; according to the hot spot time Information, recording the live code stream of the hot channel to the cache device to obtain the cache code stream.
  • the embodiment of the present application provides a method for playing content, which is applied to a CDN system.
  • the CDN system includes a cache device.
  • the method includes: acquiring a live service request, and determining the live broadcast service request corresponding to the live broadcast content; obtain the target code stream corresponding to the live content from the cached code stream, wherein the cached code stream is recorded in the live code stream of the hotspot channel according to the hotspot time information, and the hotspot time information is related to the The hot channel is associated; the target code stream is played.
  • the embodiment of the present application provides a CDN system, including: a memory, a processor, and a computer program stored in the memory and operable on the processor.
  • the processor executes the computer program, the following The content recording method described in one aspect, or, implement the content playing method described in the second aspect.
  • the embodiment of the present application provides a computer-readable storage medium, which stores computer-executable instructions, and the computer-executable instructions are used to execute the content recording method as described in the first aspect, or to implement the content recording method as described in the first aspect.
  • the content playing method described in the second aspect is a computer-readable storage medium, which stores computer-executable instructions, and the computer-executable instructions are used to execute the content recording method as described in the first aspect, or to implement the content recording method as described in the first aspect.
  • FIG. 1 is a flowchart of a content recording method provided by an embodiment of the present application
  • FIG. 2 is a block diagram of a CDN system provided by another embodiment of the present application.
  • Fig. 3 is a flow chart of determining a hotspot channel provided by another embodiment of the present application.
  • Fig. 4 is a flowchart of determining hot content provided by another embodiment of the present application.
  • Fig. 5 is a flow chart of determining a list of hot channels provided by another embodiment of the present application.
  • FIG. 6 is a flow chart of determining a target directory provided by another embodiment of the present application.
  • FIG. 7 is a flow chart of synchronous recording provided by another embodiment of the present application.
  • Fig. 8 is a flowchart of a content playing method provided by another embodiment of the present application.
  • FIG. 9 is a flowchart of obtaining a target code stream provided by another embodiment of the present application.
  • FIG. 10 is a flow chart of obtaining a target code stream from a target directory provided by another embodiment of the present application.
  • Fig. 11 is a flow chart of reporting service bills provided by another embodiment of the present application.
  • Figure 12 is a flowchart of an example provided by the present application.
  • Fig. 13 is a device diagram of a CDN system provided by another embodiment of the present application.
  • the present application provides a content recording method, a playback method, a CDN system, and a storage medium.
  • the content recording method includes: acquiring hotspot time information pre-associated with hotspot channels; Record to the cache device to obtain the cache code stream.
  • the live code stream to be recorded can be determined in advance, effectively speeding up the response time of high-real-time service review or time-shifted access, improving user experience, and effectively reducing the overall operating load of the server.
  • Figure 1 is a flowchart of a content recording method provided by an embodiment of the present application, the content recording method is applied to a CDN system, and the CDN system includes a cache device, including but not limited to step S110 and step S120.
  • Step S110 acquiring hotspot time information pre-associated with hotspot channels.
  • the hotspot time information is for a specific hotspot channel.
  • the number of hotspot channels can be arbitrary, and a hotspot channel is a channel with hotspot content. Therefore, it can be configured for each hotspot channel. Hotspot time information, so that each hotspot channel can trigger the recording of live stream according to its own hotspot time information.
  • this embodiment pre-configures the hotspot time information, starts recording after the hotspot time starts, and stops recording after the hotspot time ends.
  • the live stream has been obtained during the live broadcast.
  • a time-shift request is made, it can directly read the recorded live code stream for playback, without performing heat statistics and file migration after the live content is broadcast, which effectively improves the response efficiency of live broadcast playback or live time-shifting, and gives full play to the
  • the responsiveness advantage of the cache device improves the user experience.
  • hot channels can be determined through historical data, such as analyzing the popularity of broadcast content in the past period of time to determine historical hot content, and TV programs usually have a certain period of regularity, so historical hot content
  • the prediction of hot channels has certain reference, and the time corresponding to the hot content is determined as hot time information, so as to realize the pre-configuration of hot time information.
  • hot channels can also be pre-determined according to other methods. This is not limited.
  • Step S120 according to the time information of the hotspot, record the live stream of the hot channel to the cache device to obtain the cached stream.
  • the technical solution of this embodiment can be applied in the CDN system shown in Figure 2.
  • an encoder and a streaming media channel recording module are included.
  • the encoder encodes the live content of the hot channel to obtain the live code stream, and the live code stream is recorded through the streaming media channel recording module, and the obtained file is saved to the cache device through the file storage server module.
  • the file type stored in the cache device can be adjusted according to actual needs, for example, it can be a live stream, and of course it can also be a file block obtained according to the live stream, which is not limited in this embodiment.
  • the technical solution of this embodiment is used to pre-determine the hotspot channel, and according to the pre-configured
  • the hotspot time information of the hotspot channel records the live stream of the hotspot channel to the cache device.
  • the probability of receiving a review request or a time-shift request is low, so it can be passed as shown in Figure 2
  • Ordinary storage devices for storage such as low-speed cache devices such as mechanical hard disks, store live streams of hot content through high-speed cache devices, which can greatly reduce the cost of storage devices while ensuring the user experience of hot content as much as possible.
  • step S110 and step S120 are for a hot spot time period of a hot spot channel.
  • the number of hot spot channels can be arbitrary, and each hot spot channel can also have multiple hot spot time information , respectively perform the above operations on each hotspot channel according to the time information of each hotspot, which will not be repeated in this embodiment.
  • step S110 of the embodiment shown in FIG. 1 it also includes but is not limited to the following steps:
  • Step S310 obtain the historical service bill of the channel to be evaluated, the historical service bill includes the service start time, service end time and popularity index of the content to be evaluated, wherein the historical service bill belongs to the live broadcast review service and/or live broadcast transfer business;
  • Step S320 when the heat index satisfies the preset condition, determine the content to be evaluated as a hot content, and determine the channel to be evaluated as a hot channel;
  • Step S330 determine hotspot time information according to the service start time and service end time, and associate the hotspot time information with the hotspot channel.
  • service data can be obtained through the hot content analysis module shown in Figure 2 to generate a service bill, and the service bill can be generated after a period of historical service bill collection.
  • Hot content analysis so as to determine the hot channel and the hot time information of the hot channel. For example, for IPTV, TV programs usually have a certain periodicity on a weekly basis, and the historical service bills of the past week can be collected. Analyze the content of each channel to determine the historical hot content. For example, according to the historical service call list, determine the service flow and clicks of the live content and other heat indicators, make statistics on the heat indicators, and count the service traffic or the number of clicks. To determine hot content, of course, other popularity evaluation methods may also be used, which is not limited in this embodiment.
  • the cycle of obtaining historical service bills can be determined according to actual needs, and can also be updated according to the cycle. For example, if the cycle is determined to be one week, you can obtain a new week of historical service bills. , to perform a new hot content analysis to determine new hot channels and hot time information. Moreover, since hot channels and hot time information have a certain predictive component, it is also possible to set the time limit for collecting historical service bills, for example, to collect historical service bills for several weeks in the past, and discard them when a new week’s data is collected. The data of the earliest week, so as to realize the iteration of data update, to ensure that the hot channel and hot time information can have a good reference.
  • the preset conditions can be set according to actual needs. For example, the popularity index meets a certain threshold, or sorted according to the popularity index. Set default conditions, not limited here.
  • the content to be evaluated can be a live program that uses live playback or time-shifted live broadcast.
  • step S320 of the embodiment shown in FIG. 3 also includes but is not limited to the following steps:
  • Step S410 determining the popularity value of the content to be evaluated according to the popularity index
  • Step S420 when the popularity value satisfies the preset threshold, it is determined that the content to be evaluated is a hot content.
  • the heat index can include service traffic or counting times, and because IPTV is not aimed at specific users, but has a certain degree of universality, therefore, taking service traffic as an example, the service traffic is not limited to come from one Instead, it can come from the sum of the service traffic of all users who use live broadcast playback or live broadcast time-shifting services at the same time. Determining the popularity index based on the user's general behavior can make the predicted hot content more in line with the general user needs to provide users with a better experience.
  • the popularity value can be calculated according to the popularity index.
  • the popularity index includes service traffic and counting times. Different weights can be assigned to the service traffic and counting times, and the calculated values can be determined as the popularity value. The calculation may also be performed in other ways, and the specific calculation method of the heat value is not limited too much in this embodiment.
  • step S330 of the embodiment shown in FIG. 3 it also includes but is not limited to the following steps:
  • Step S510 determining at least two hot channels
  • Step S520 generating a hot channel list based on at least two hot channels, wherein the hot channels in the hot channel list are sorted from large to small according to their popularity values, and the hot channel list records the channel IDs, hot time information and popularity values of the hot channels.
  • hot content analysis module shown in Figure 2
  • several hot content can be determined.
  • the hotspot channel list can be fed back to the streaming media channel recording module through the hotspot content analysis module, and the channel identification, hotspot time information and heat value of the hotspot channel are recorded in the hotspot channel list, and streaming media
  • the channel recording module determines the hot channel according to the channel identifier, and incorporates the hot time information into the channel recording management process of the hot channel, and records after the hot time starts.
  • the ranking of the popularity values can be calculated according to unit time, and the hot channels are ranked according to the popularity values from high to low in the hot channel list.
  • the popularity value carried in the hot channel list can be applied in many ways. For example, in the process of recording multiple hot channels at the same time, when the cache device resources are less, it can be used according to the height of the popularity value. The allocation of resources is given priority to hot channels with high popularity values. The technicians in this embodiment have the motivation to adjust the use of popularity values according to actual needs, and no limitation is made here.
  • step S120 of the embodiment shown in FIG. 1 also includes but is not limited to the following steps:
  • Step S610 determining the target directory of the cache device
  • Step S620 write the live code stream into the target directory.
  • a specific target directory can be configured in the cache device to save the live code stream recorded in this embodiment and to respond to the live broadcast playback request or live broadcast time-shifting request.
  • the code stream After detecting a live broadcast review request or a live broadcast time-shift request for hot content, the code stream is located and searched from the target directory, which can further reduce the response time.
  • the CDN system also includes a low-speed cache device.
  • step S120 of the embodiment shown in FIG. 1 also includes but is not limited to the following steps:
  • Step S710 synchronously record the live code stream of the popular channel to the high-speed cache device and the low-speed cache device, so as to obtain the high-speed cache code stream stored in the high-speed cache device and the low-speed cache code stream stored in the low-speed cache device.
  • the low-speed cache device can be a common mechanical hard disk, etc., and its read rate is lower than that of the high-speed cache device, but it only needs to have an advantage over the high-speed cache device in terms of cost.
  • the low-speed cache device can keep recording the live stream, and does not need to judge whether it is a hot content.
  • the low-speed cache stream and the high-speed cache stream recorded in the same live content can be distinguished by the content identifier, as shown in Fig.
  • the streaming media user service module shown in 2 can send the content identifier to the file storage server, and obtain the code stream from the high-speed cache device or the low-speed cache device according to the content identifier for playback.
  • the technical solution of this embodiment adopts the method of synchronous recording of hot content, and according to the time information of hot spots, the The live code stream of the hot channel is written into the high-speed cache device and the low-speed cache device at the same time, which saves the steps of migration and heat analysis.
  • the code stream it can be read directly from the cache device, effectively improving the efficiency of the response , can respond to services in a shorter response time.
  • the embodiment of the present application also provides a content playing method, which is applied to a CDN system.
  • the CDN system includes a cache device.
  • the content playing method includes but is not limited to steps S810, S820, and S830.
  • Step S810 acquiring the live broadcast service request, and determining the live broadcast content corresponding to the live broadcast service request.
  • the live broadcast service request is for the live broadcast content
  • the content ID of the currently live broadcast content can be obtained directly, and the live broadcast content can be determined through the content ID, or the live content can be determined in other ways , not limited here.
  • the live broadcast service request can be a live broadcast review request or a live broadcast time-shift request. It may be an instruction to operate on live content, which is not limited in this embodiment.
  • Step S820 obtaining the target code stream corresponding to the live content from the cache code stream, wherein the cache code stream is recorded in the live code stream of the hot channel according to the hot time information, and the hot time information is associated with the hot channel.
  • the cached code stream stored in the cache device can come from multiple hotspot channels, for example, live streams are recorded simultaneously from multiple hotspot channels within the same hotspot time period. In this case, you can pass the channel
  • the ID or content ID obtains the target code stream from the cache device, and the specific matching method can be adjusted according to actual needs, and is not limited here.
  • Step S830 playing the target code stream.
  • the cached stream is recorded according to the predetermined hotspot channel and hotspot time information, when the live service request is obtained, the target stream can be directly read and played. From receiving the live service request to playing only execution The operation of reading is eliminated, heat analysis and file migration operations are omitted, which can effectively improve the response efficiency of playing the target stream and improve user experience.
  • the CDN system also includes a low-speed cache device, the low-speed cache device stores the low-speed cache code stream, and the low-speed cache code stream and the high-speed cache code stream are synchronously recorded in the live code stream of the hot channel, referring to FIG. Step S820 of the embodiment shown in 8 also includes but is not limited to the following steps:
  • Step S910 when it is determined that the live content is a hot content, obtain the target code stream from the cache code stream;
  • Step S920 when obtaining the target code stream from the high-speed cache code stream fails, obtain the target code stream from the low-speed cache code stream.
  • the technical solution of this embodiment is to improve the response efficiency for high-real-time services. Therefore, before obtaining the target code stream from the cache code stream, it can be judged whether the live content is a hot content, for example, each Hot channels are pre-configured with hot time information. When the time corresponding to the live content corresponds to the hot time information, it can be determined as a hot content, or other methods can be used to determine the live content as a hot content, which is not limited here.
  • the hot channel and hot time information are obtained according to the historical service bills.
  • the channel may not be determined according to the historical service bills.
  • the content within this time period is hot content. For example, for a TV channel, a hot program is temporarily inserted, but this program has not been broadcast before, so it may generate high popularity at present, and it is judged as hot.
  • the content in this period of time will not be determined as hot content, so it will not be recorded in the cache code stream.
  • the corresponding content can be obtained from the low cache code stream.
  • the target code stream to ensure that the target code stream can be obtained successfully.
  • the method for recording the low-speed cache code stream by the low-speed cache device may refer to the description of the embodiment shown in FIG.
  • step S820 of the embodiment shown in FIG. 8 also includes but is not limited to the following steps:
  • Step S1010 determine the target directory of the cache device, wherein the target directory stores the cache code stream;
  • Step S1020 acquiring the target code stream from the cached code stream stored in the target directory.
  • the target directory since the target directory is used to store the recording content of the live stream, the target directory can be directly located during the process of obtaining the target stream from the cached stream, thereby further improving the efficiency of obtaining the target stream .
  • step S830 of the embodiment shown in FIG. 8 is executed, the following steps are also included but not limited to:
  • Step S1110 generate a service bill according to the live service request, the service bill includes the service start time, service end time and popularity index;
  • Step S1120 update the hot spot time information of the hot spot channel according to the service bill.
  • the heat index can be used for the service traffic obtained by the live broadcast content , the number of clicks, etc., those skilled in the art are also familiar with how to obtain the above parameters, and the generation process of the service bill is not limited here.
  • the service bill can be used as a historical service bill, and the streaming media user service module shown in Figure 2 sends it to the hot channel and hot time information of the hot content analysis module.
  • the specific method can be Referring to the description of the embodiment shown in FIG. 3 , details are not repeated here for the sake of brevity.
  • Step S1210 when the user initiates a service request to the streaming media server, after the streaming media user service module completes the service, it reports the service bill to the hot content analysis module, wherein the service bill includes service type, service content ID, service start and end time, service traffic and clicks;
  • Step S1220 the hotspot content analysis module determines the popularity value of the content of each channel according to the collected service call list, according to the service traffic and the number of clicks, and then sorts according to the popularity value per unit time to form a list of hot channels, wherein, hotspot
  • the channel list includes hotspot channel ID, hotspot start time, hotspot end time, popularity value;
  • Step S1230 the hot content analysis module periodically pushes the hot channel list to the streaming media channel recording module;
  • Step S1240 the streaming media channel recording module includes the hot channel list into the management process of channel recording, when the system time reaches the hot spot start time, record the live code stream of the hot channel, and synchronously write the low-speed cache device and the target of the high-speed cache device Table of contents;
  • Step S1250 when the system time reaches the end time of the hotspot, the streaming media channel recording module stops writing the live code stream to the target directory of the cache device;
  • Step S1260 when receiving a service request for live broadcast time-shifting or live broadcast review, the streaming media user service module determines that the corresponding live content is a hot content;
  • Step S1270 when the streaming media user service module obtains the target code stream from the target directory of the cache device, play the target code stream obtained from the cache device, when the target code stream fails to be obtained from the target directory of the cache device, from The low-speed cache device obtains the target code stream and plays it.
  • the CDN system 1300 includes: a memory 1310 , a processor 1320 , and a computer program stored in the memory 1310 and operable on the processor 1320 .
  • the processor 1320 and the memory 1310 may be connected through a bus or in other ways.
  • the non-transitory software programs and instructions required to realize the content recording method of the above-mentioned embodiment are stored in the memory 1310, and when executed by the processor 1320, the content recording method in the above-mentioned embodiment is executed, for example, executing the above-described Figure 1 Method step S110 to step S120 in, method step S310 to step S330 in Fig. 3, method step S410 to step S420 in Fig. 4, method step S510 to step S520 in Fig. 5, method step S610 to step S520 in Fig. 6 Step S620, method step S710 in FIG. 7, or execute the content playing method in the above embodiment, for example, execute method steps S810 to step S830 in FIG. 8 described above, and method steps S910 to step S920 in FIG. 9 , method step S1010 to step S1020 in FIG. 10 , and method step S1110 to step S1120 in FIG. 11 .
  • the device embodiments described above are only illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place, or they may be distributed to multiple network units. Part or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
  • an embodiment of the present application also provides a computer-readable storage medium, the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are executed by a processor or a controller, for example, by the above-mentioned Execution by a processor in the CDN system embodiment can cause the above-mentioned processor to execute the content recording method in the above-mentioned embodiment, for example, execute the method steps S110 to S120 in FIG. 1 and the method step S310 in FIG. 3 described above. to step S330, method step S410 to step S420 in FIG. 4, method step S510 to step S520 in FIG. 5, method step S610 to step S620 in FIG. 6, method step S710 in FIG.
  • the content playing method in the example executes the method step S810 to step S830 in Fig. 8 described above, the method step S910 to step S920 in Fig. 9, the method step S1010 to step S1020 in Fig. 10, and the Method step S1110 to step S1120.
  • a processor such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit .
  • Such software may reside on computer readable media, respectively, which may include computer storage media (or non-transitory media) and communication media (or transitory media).
  • computer storage media includes both volatile and nonvolatile media implemented in any method or technology for storage of information, such as computer readable instructions, data structures, program modules, or other data. permanent, removable and non-removable media.
  • Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cartridges, tape, magnetic disk storage or other magnetic storage devices, or can Any other medium used to store desired information and which can be accessed by a computer.
  • communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media .
  • the embodiment of the present application includes: obtaining the hot spot time information pre-associated with the hot spot channel; according to the hot spot time information, recording the live stream of the hot spot channel to the cache device to obtain the cache stream.
  • the live code stream to be recorded can be determined in advance, effectively speeding up the response time of high-real-time service review or time-shifted access, improving user experience, and effectively reducing the overall operating load of the server.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
  • Management Or Editing Of Information On Record Carriers (AREA)

Abstract

Provided in the present application are a content recording method, a content playing method, a CDN system, and a storage medium. The content recording method comprises: acquiring trend time information which is pre-associated with a trend channel (S110); and according to the trend time information, recording a live streaming code stream of the trend channel to a cache device, so as to obtain a cached code stream (S120).

Description

内容录制方法、播放方法、CDN系统、存储介质Content recording method, playback method, CDN system, storage medium
相关申请的交叉引用Cross References to Related Applications
本申请基于申请号为202111338139.3,申请日为2021年11月12日的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此引入本申请作为参考。This application is based on a Chinese patent application with application number 202111338139.3 and a filing date of November 12, 2021, and claims the priority of this Chinese patent application. The entire content of this Chinese patent application is hereby incorporated by reference into this application.
技术领域technical field
本申请涉及但不限于视频媒体服务领域,尤其涉及一种内容录制方法、播放方法、CDN系统、存储介质。The present application relates to but not limited to the field of video media services, and in particular relates to a content recording method, a playback method, a CDN system, and a storage medium.
背景技术Background technique
内容分发网络(Content Delivery Network,CDN)能够在网络边缘提供缓存加速内容的缓存,从而在靠近用户的服务节点为用户提供媒体服务,能够有效降低服务源站和承载网络的压力,为用户提供更快的服务响应以及更稳定的流式媒体服务。网络协议电视(Internet Protocol Television,IPTV)可以通过CND系统的流媒体设备存储直播节目的频道码流,通过发送网络包至机顶盒组装还原出视频,为用户提供频道的回看或者时移服务。Content Delivery Network (CDN) can provide caching and accelerated content caching at the edge of the network, so as to provide users with media services at service nodes close to users, which can effectively reduce the pressure on service source sites and bearer networks, and provide users with more Fast service response and more stable streaming media service. Internet Protocol Television (IPTV) can store the channel code stream of live programs through the streaming media equipment of the CND system, send network packets to the set-top box to assemble and restore the video, and provide users with channel playback or time-shifting services.
为了提供更快的响应,可以通过固态硬盘(Solid State Drive,SSD)或者非易失性高速传输总线(Non-Volatile Memory express,NVME)等高速缓存设备进行文件块的存储,但是高速缓存设备的成本较高,无法大范围使用,因此,运营商通常会将频道码流录制到低速缓存设备,再对回看或者时移的访问内容进行热度统计后,将高热度访问的文件块从低速缓存设备复制高速缓存设备中,当访问内容的文件块具有高速缓存设备的副本,优先从高速缓存设备进行内容读取。但是文件块的热度统计和复制迁移具有一定的滞后性,并且会耗费一定的操作时间,很难满足直播时移等高实时性业务的要求。In order to provide faster response, cache devices such as solid state drives (Solid State Drive, SSD) or non-volatile high-speed transmission bus (Non-Volatile Memory express, NVME) can be used to store file blocks, but the cache device The cost is high and cannot be widely used. Therefore, the operator usually records the channel code stream to the low-speed cache device, and after performing heat statistics on the content of the playback or time-shifted access, the high-hot access file blocks are removed from the low-speed cache. In the device copy cache device, when the file block of the access content has a copy of the cache device, the content is read from the cache device first. However, the heat statistics and copying and migration of file blocks have a certain lag and will consume a certain amount of operation time, making it difficult to meet the requirements of high real-time services such as live broadcast time shifting.
发明内容Contents of the invention
以下是对本文详细描述的主题的概述。本概述并非是为了限制权利要求的保护范围。The following is an overview of the topics described in detail in this article. This summary is not intended to limit the scope of the claims.
本申请实施例提供了一种内容录制方法、播放方法、CDN系统、存储介质。Embodiments of the present application provide a content recording method, a playback method, a CDN system, and a storage medium.
第一方面,本申请实施例提供了一种内容录制方法,应用于CDN系统,所述CDN系统包括高速缓存设备,所述方法包括:获取热点频道预先关联的热点时间信息;根据所述热点时间信息,将所述热点频道的直播码流录制至所述高速缓存设备,得到高速缓存码流。In the first aspect, the embodiment of the present application provides a content recording method, which is applied to a CDN system, and the CDN system includes a cache device, and the method includes: obtaining hot spot time information pre-associated with hot channel; according to the hot spot time Information, recording the live code stream of the hot channel to the cache device to obtain the cache code stream.
第二方面,本申请实施例提供了一种内容播放方法,应用于CDN系统,所述CDN系统包括高速缓存设备,所述方法包括:获取直播服务请求,确定所述直播服务请求所对应的直播内容;从高速缓存码流中获取与所述直播内容相对应的目标码流,其中,所述高速缓存码流根据热点时间信息录制于热点频道的直播码流,所述热点时间信息与所述热点频道相关联;播放所述目标码流。In the second aspect, the embodiment of the present application provides a method for playing content, which is applied to a CDN system. The CDN system includes a cache device. The method includes: acquiring a live service request, and determining the live broadcast service request corresponding to the live broadcast content; obtain the target code stream corresponding to the live content from the cached code stream, wherein the cached code stream is recorded in the live code stream of the hotspot channel according to the hotspot time information, and the hotspot time information is related to the The hot channel is associated; the target code stream is played.
第三方面,本申请实施例提供了一种CDN系统,包括:存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现如第一方面所述的内容录制方法,或者,实现如第二方面所述的内容播放方法。In the third aspect, the embodiment of the present application provides a CDN system, including: a memory, a processor, and a computer program stored in the memory and operable on the processor. When the processor executes the computer program, the following The content recording method described in one aspect, or, implement the content playing method described in the second aspect.
第四方面,本申请实施例提供了一种计算机可读存储介质,存储有计算机可执行指令, 所述计算机可执行指令用于执行如第一方面所述的内容录制方法,或者,实现如第二方面所述的内容播放方法。In the fourth aspect, the embodiment of the present application provides a computer-readable storage medium, which stores computer-executable instructions, and the computer-executable instructions are used to execute the content recording method as described in the first aspect, or to implement the content recording method as described in the first aspect. The content playing method described in the second aspect.
本申请的其它特征和优点将在随后的说明书中阐述,并且,部分地从说明书中变得显而易见,或者通过实施本申请而了解。本申请的目的和其他优点可通过在说明书、权利要求书以及附图中所特别指出的结构来实现和获得。Additional features and advantages of the application will be set forth in the description which follows, and, in part, will be obvious from the description, or may be learned by practice of the application. The objectives and other advantages of the application will be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
附图说明Description of drawings
附图用来提供对本申请技术方案的进一步理解,并且构成说明书的一部分,与本申请的实施例一起用于解释本申请的技术方案,并不构成对本申请技术方案的限制。The accompanying drawings are used to provide a further understanding of the technical solution of the present application, and constitute a part of the specification, and are used together with the embodiments of the present application to explain the technical solution of the present application, and do not constitute a limitation to the technical solution of the present application.
图1是本申请一个实施例提供的内容录制方法的流程图;FIG. 1 is a flowchart of a content recording method provided by an embodiment of the present application;
图2是本申请另一个实施例提供的CDN系统的模块示意图;FIG. 2 is a block diagram of a CDN system provided by another embodiment of the present application;
图3是本申请另一个实施例提供的确定热点频道的流程图;Fig. 3 is a flow chart of determining a hotspot channel provided by another embodiment of the present application;
图4是本申请另一个实施例提供的确定热点内容的流程图;Fig. 4 is a flowchart of determining hot content provided by another embodiment of the present application;
图5是本申请另一个实施例提供的确定热点频道列表的流程图;Fig. 5 is a flow chart of determining a list of hot channels provided by another embodiment of the present application;
图6是本申请另一个实施例提供的确定目标目录的流程图;FIG. 6 is a flow chart of determining a target directory provided by another embodiment of the present application;
图7是本申请另一个实施例提供的同步录制的流程图;FIG. 7 is a flow chart of synchronous recording provided by another embodiment of the present application;
图8是本申请另一个实施例提供的内容播放方法的流程图;Fig. 8 is a flowchart of a content playing method provided by another embodiment of the present application;
图9是本申请另一个实施例提供的获取目标码流的流程图;FIG. 9 is a flowchart of obtaining a target code stream provided by another embodiment of the present application;
图10是本申请另一个实施例提供的从目标目录获取目标码流的流程图;FIG. 10 is a flow chart of obtaining a target code stream from a target directory provided by another embodiment of the present application;
图11是本申请另一个实施例提供的上报服务话单的流程图;Fig. 11 is a flow chart of reporting service bills provided by another embodiment of the present application;
图12是本申请提供的示例的流程图;Figure 12 is a flowchart of an example provided by the present application;
图13是本申请另一个实施例提供的CDN系统的装置图。Fig. 13 is a device diagram of a CDN system provided by another embodiment of the present application.
具体实施方式Detailed ways
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solution and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described here are only used to explain the present application, not to limit the present application.
需要说明的是,虽然在装置示意图中进行了功能模块划分,在流程图中示出了逻辑顺序,但是在某些情况下,可以以不同于装置中的模块划分,或流程图中的顺序执行所示出或描述的步骤。说明书、权利要求书或上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。It should be noted that although the functional modules are divided in the schematic diagram of the device, and the logical sequence is shown in the flowchart, in some cases, it can be executed in a different order than the module division in the device or the flowchart in the flowchart. steps shown or described. The terms "first", "second" and the like in the specification, claims or the above-mentioned drawings are used to distinguish similar objects, and not necessarily used to describe a specific order or sequential order.
本申请提供了一种内容录制方法、播放方法、CDN系统、存储介质,内容录制方法包括:获取热点频道预先关联的热点时间信息;根据所述热点时间信息,将所述热点频道的直播码流录制至所述高速缓存设备,得到高速缓存码流。根据本实施例的技术方案,能够提前确定需要录制的直播码流,有效加快高实时业务的回看或时移访问的响应时间,提高用户体验,有效降低服务器的整体运行负荷。The present application provides a content recording method, a playback method, a CDN system, and a storage medium. The content recording method includes: acquiring hotspot time information pre-associated with hotspot channels; Record to the cache device to obtain the cache code stream. According to the technical solution of this embodiment, the live code stream to be recorded can be determined in advance, effectively speeding up the response time of high-real-time service review or time-shifted access, improving user experience, and effectively reducing the overall operating load of the server.
下面结合附图,对本申请实施例作进一步阐述。The embodiments of the present application will be further described below in conjunction with the accompanying drawings.
如图1所示,图1是本申请一个实施例提供的一种内容录制方法的流程图,该内容录制方法应用于CDN系统,CDN系统包括高速缓存设备,包括但不限于有步骤S110和步骤S120。As shown in Figure 1, Figure 1 is a flowchart of a content recording method provided by an embodiment of the present application, the content recording method is applied to a CDN system, and the CDN system includes a cache device, including but not limited to step S110 and step S120.
步骤S110,获取热点频道预先关联的热点时间信息。Step S110, acquiring hotspot time information pre-associated with hotspot channels.
需要说明的是,热点时间信息是针对具体的热点频道的,在实际使用过程中,热点频道 的数量可以是任意的,而热点频道是具备热点内容的频道,因此,可以针对每个热点频道配置热点时间信息,使得每个热点频道能够根据各自的热点时间信息触发直播码流的录制。It should be noted that the hotspot time information is for a specific hotspot channel. In actual use, the number of hotspot channels can be arbitrary, and a hotspot channel is a channel with hotspot content. Therefore, it can be configured for each hotspot channel. Hotspot time information, so that each hotspot channel can trigger the recording of live stream according to its own hotspot time information.
需要说明的是,本实施例通过预先配置热点时间信息,在热点时间开始后开始录制,热点时间结束后停止录制,在直播过程中已经获取到了直播码流,当获取到直播回看请求或者直播时移请求时,能够直接读取录制好的直播码流进行播放,无需在直播内容播出后再进行热度统计和文件迁移,有效提高了直播回看或者直播时移的响应效率,充分发挥了高速缓存设备的响应优势,提高了用户体验。It should be noted that this embodiment pre-configures the hotspot time information, starts recording after the hotspot time starts, and stops recording after the hotspot time ends. The live stream has been obtained during the live broadcast. When a time-shift request is made, it can directly read the recorded live code stream for playback, without performing heat statistics and file migration after the live content is broadcast, which effectively improves the response efficiency of live broadcast playback or live time-shifting, and gives full play to the The responsiveness advantage of the cache device improves the user experience.
需要说明的是,热点频道可以通过历史数据确定,例如对过去一段时间内的播放内容进行热度分析,确定出历史热点内容,而电视节目通常是有一定的周期规律性的,因此以历史热点内容进行热点频道的预测具有一定的参考性,并将热点内容所对应的时间确定为热点时间信息,从而实现热点时间信息的预先配置,当然,也可以根据其他方法预先确定热点频道,本实施例对此不多作限定。It should be noted that hot channels can be determined through historical data, such as analyzing the popularity of broadcast content in the past period of time to determine historical hot content, and TV programs usually have a certain period of regularity, so historical hot content The prediction of hot channels has certain reference, and the time corresponding to the hot content is determined as hot time information, so as to realize the pre-configuration of hot time information. Of course, hot channels can also be pre-determined according to other methods. This is not limited.
步骤S120,根据热点时间信息,将热点频道的直播码流录制至高速缓存设备,得到高速缓存码流。Step S120, according to the time information of the hotspot, record the live stream of the hot channel to the cache device to obtain the cached stream.
需要说明的是,本实施例技术方案可以应用在图2所示的CDN系统中,在该CDN系统中,包括编码器和流媒体频道录制模块,在热点时间开始后,参考图2所示的虚线部分,通过编码器对热点频道的直播内容进行编码得到直播码流,通过流媒体频道录制模块进行直播码流的录制,并将得到的文件通过文件存储服务器模块保存至高速缓存设备。需要说明的是,高速缓存设备保存的文件类型可以根据实际需求调整,例如可以是直播码流,当然也可以是根据直播码流得到的文件块,本实施例对此不多作限定。It should be noted that the technical solution of this embodiment can be applied in the CDN system shown in Figure 2. In this CDN system, an encoder and a streaming media channel recording module are included. In the dotted line part, the encoder encodes the live content of the hot channel to obtain the live code stream, and the live code stream is recorded through the streaming media channel recording module, and the obtained file is saved to the cache device through the file storage server module. It should be noted that the file type stored in the cache device can be adjusted according to actual needs, for example, it can be a live stream, and of course it can also be a file block obtained according to the live stream, which is not limited in this embodiment.
值得注意的是,在常见的方案中,为了提高请求响应速度,通常采用全高速存储设备的模式,但是这样会造成成本高昂,采用本实施例的技术方案,预先确定热点频道,并根据预先配置的热点时间信息,将热点频道的直播码流录制至高速缓存设备,对于非热点频道的直播码流,其接收到回看请求或者时移请求的概率较低,因此可以通过图2所示的普通存储设备进行存储,例如采用机械硬盘等低速缓存设备,通过高速缓存设备存储热点内容的直播码流,能够在尽可能确保热点内容的用户体验的前提下,大幅降低存储设备的成本。It is worth noting that in common solutions, in order to improve the response speed of requests, the mode of full high-speed storage devices is usually used, but this will cause high costs. The technical solution of this embodiment is used to pre-determine the hotspot channel, and according to the pre-configured The hotspot time information of the hotspot channel records the live stream of the hotspot channel to the cache device. For the live stream of the non-hotspot channel, the probability of receiving a review request or a time-shift request is low, so it can be passed as shown in Figure 2 Ordinary storage devices for storage, such as low-speed cache devices such as mechanical hard disks, store live streams of hot content through high-speed cache devices, which can greatly reduce the cost of storage devices while ensuring the user experience of hot content as much as possible.
值得注意的是,步骤S110和步骤S120的操作为针对一个热点频道的一个热点时间段内,在实际使用过程中,热点频道的数量可以是任意,每个热点频道也可以具备多个热点时间信息,分别对每个热点频道根据每个热点时间信息执行上述操作即可,本实施例不再赘述。It is worth noting that the operations of step S110 and step S120 are for a hot spot time period of a hot spot channel. In actual use, the number of hot spot channels can be arbitrary, and each hot spot channel can also have multiple hot spot time information , respectively perform the above operations on each hotspot channel according to the time information of each hotspot, which will not be repeated in this embodiment.
另外,参照图3,在一实施例中,在执行图1所示实施例的步骤S110之前,还包括但不限于有以下步骤:In addition, referring to FIG. 3 , in one embodiment, before executing step S110 of the embodiment shown in FIG. 1 , it also includes but is not limited to the following steps:
步骤S310,获取待评价频道的历史服务话单,历史服务话单包括待评价内容的服务开始时刻、服务结束时刻和热度指标,其中,历史服务话单归属于直播回看业务和/或直播时移业务;Step S310, obtain the historical service bill of the channel to be evaluated, the historical service bill includes the service start time, service end time and popularity index of the content to be evaluated, wherein the historical service bill belongs to the live broadcast review service and/or live broadcast transfer business;
步骤S320,当热度指标满足预设条件,将待评价内容确定为热点内容,并将待评价频道确定为热点频道;Step S320, when the heat index satisfies the preset condition, determine the content to be evaluated as a hot content, and determine the channel to be evaluated as a hot channel;
步骤S330,根据服务开始时刻和服务结束时刻确定热点时间信息,并将热点时间信息关联至热点频道。Step S330, determine hotspot time information according to the service start time and service end time, and associate the hotspot time information with the hotspot channel.
需要说明的是,在完成每次直播回看或者直播时移的服务之后,可以通过图2所示的热 点内容分析模块获取服务数据生成服务话单,通过一段周期的历史服务话单采集后进行热点内容分析,从而确定热点频道和该热点频道的热点时间信息,例如,对于IPTV而言,电视节目通常是以周为单位具备一定的周期性,可以采集过去一周的历史服务话单,对每个频道的内容进行热度分析以确定历史热点内容,例如,根据历史服务话单,确定直播内容的服务流量和点击次数等热度指标,对该热度指标进行统计,将服务流量或者点击次数较多的确定为热点内容,当然,也可以采用其他热度评价方法,本实施例在此不多作限定。It should be noted that after completing each live broadcast playback or time-shifted live broadcast service, service data can be obtained through the hot content analysis module shown in Figure 2 to generate a service bill, and the service bill can be generated after a period of historical service bill collection. Hot content analysis, so as to determine the hot channel and the hot time information of the hot channel. For example, for IPTV, TV programs usually have a certain periodicity on a weekly basis, and the historical service bills of the past week can be collected. Analyze the content of each channel to determine the historical hot content. For example, according to the historical service call list, determine the service flow and clicks of the live content and other heat indicators, make statistics on the heat indicators, and count the service traffic or the number of clicks. To determine hot content, of course, other popularity evaluation methods may also be used, which is not limited in this embodiment.
值得注意的是,需要说明的是,获取历史服务话单的周期可以根据实际需求确定,也可以根据周期进行更新,例如周期确定为一周,则可以在获取到新的一周的历史服务话单后,重新进行一次热点内容分析,以确定新的热点频道和热点时间信息。并且,由于热点频道和热点时间信息具有一定的预测成分,因此也可以设定历史服务话单的采集期限,例如采集过去若干周的历史服务话单,当采集到新的一周的数据之后,丢弃最早的一周的数据,从而实现数据更新迭代,确保热点频道和热点时间信息能够具有较好的参考性。It is worth noting that it needs to be explained that the cycle of obtaining historical service bills can be determined according to actual needs, and can also be updated according to the cycle. For example, if the cycle is determined to be one week, you can obtain a new week of historical service bills. , to perform a new hot content analysis to determine new hot channels and hot time information. Moreover, since hot channels and hot time information have a certain predictive component, it is also possible to set the time limit for collecting historical service bills, for example, to collect historical service bills for several weeks in the past, and discard them when a new week’s data is collected. The data of the earliest week, so as to realize the iteration of data update, to ensure that the hot channel and hot time information can have a good reference.
需要说明的是,预设条件可以根据实际需求设定,例如热度指标满足一定的阈值,或者,根据热度指标进行排序,排在前列的若干位为热点内容等,本领域技术人员可以根据实际需求设定预设条件,在此不多作限定。It should be noted that the preset conditions can be set according to actual needs. For example, the popularity index meets a certain threshold, or sorted according to the popularity index. Set default conditions, not limited here.
需要说明的是,待评价内容可以是使用了直播回看或者直播时移的直播节目,在生成服务话单时,可以添加该直播节目所对应的内容标识,从而在进行热点内容分析时,能够通过内容标识区分开不同的内容,具体的内容标识类型可以根据实际需求选取。It should be noted that the content to be evaluated can be a live program that uses live playback or time-shifted live broadcast. When generating the service bill, you can add the content identifier corresponding to the live broadcast program, so that when analyzing hot content, you can Different content is distinguished through content identification, and the specific type of content identification can be selected according to actual needs.
另外,参照图4,在一实施例中,图3所示实施例的步骤S320,还包括但不限于有以下步骤:In addition, referring to FIG. 4 , in one embodiment, step S320 of the embodiment shown in FIG. 3 also includes but is not limited to the following steps:
步骤S410,根据热度指标确定待评价内容的热度值;Step S410, determining the popularity value of the content to be evaluated according to the popularity index;
步骤S420,当热度值满足预设阈值,确定待评价内容为热点内容。Step S420, when the popularity value satisfies the preset threshold, it is determined that the content to be evaluated is a hot content.
需要说明的是,热度指标可以包括服务流量或者点计次数等,并且,由于IPTV并非针对特定用户,而是具有一定的普遍性,因此,以服务流量为例,服务流量并不限定来自于一个用户,而是可以来自于同一时间内使用直播回看或者直播时移服务的全部用户的服务流量之和,基于用户的普遍性行为确定热度指标,能够使得预测出的热点内容更加符合普遍的用户需求,为用户提供更好的体验。It should be noted that the heat index can include service traffic or counting times, and because IPTV is not aimed at specific users, but has a certain degree of universality, therefore, taking service traffic as an example, the service traffic is not limited to come from one Instead, it can come from the sum of the service traffic of all users who use live broadcast playback or live broadcast time-shifting services at the same time. Determining the popularity index based on the user's general behavior can make the predicted hot content more in line with the general user needs to provide users with a better experience.
需要说明的是,对于电视节目而言,通常会有高峰期和非高峰期之分,当处于业务高峰,在业务高峰期能够获取到的服务话单较多,相应的热点内容也就较多,若采用排序确定热点内容,很可能在业务的非高峰期确定多个热点内容,而实际上这些热点内容的用户并不多,若进行高速缓存对用户体验的提升效果并不大,因此,可以通过设置预设阈值的方式,当待评价内容的热度值满足该预设阈值后,确定其为热点内容,能够有效提高热点内容的参考价值。It should be noted that for TV programs, there are usually peak periods and non-peak periods. When the business is at its peak, more service bills can be obtained during the business peak period, and there will be more corresponding hot content , if sorting is used to determine hot content, it is likely to determine multiple hot content during off-peak hours of business, but in fact there are not many users of these hot content, and caching will not greatly improve user experience. Therefore, By setting a preset threshold, when the popularity value of the content to be evaluated meets the preset threshold, it is determined as a hot content, which can effectively improve the reference value of the hot content.
需要说明的是,热度值可以是根据热度指标计算得到,例如热度指标包括服务流量和点计次数,可以为服务流量和点计次数分别赋予不同的权重,将计算出的数值确定为热度值,也可以根据其他方式进行计算,本实施例对热度值的具体计算方法不作过多限定。It should be noted that the popularity value can be calculated according to the popularity index. For example, the popularity index includes service traffic and counting times. Different weights can be assigned to the service traffic and counting times, and the calculated values can be determined as the popularity value. The calculation may also be performed in other ways, and the specific calculation method of the heat value is not limited too much in this embodiment.
另外,参照图5,在一实施例中,在执行图3所示实施例的步骤S330之前,还包括但不限于有以下步骤:In addition, referring to FIG. 5 , in one embodiment, before performing step S330 of the embodiment shown in FIG. 3 , it also includes but is not limited to the following steps:
步骤S510,确定至少两个热点频道;Step S510, determining at least two hot channels;
步骤S520,根据至少两个热点频道生成热点频道列表,其中,热点频道列表中的热点频道根据热度值由大到小排序,热点频道列表记载有热点频道的频道标识、热点时间信息和热度值。Step S520, generating a hot channel list based on at least two hot channels, wherein the hot channels in the hot channel list are sorted from large to small according to their popularity values, and the hot channel list records the channel IDs, hot time information and popularity values of the hot channels.
需要说明的是,对于IPTV而言,同时在线的频道数量较多,而本实施例并不限定热点频道的数量,通过图2所示的热点内容分析模块,能够确定若干个热点内容,当上述热点内容归属于不同的频道,则可以确定出至少两个热点频道。为了针对热点频道进行热点时间信息的配置,可以通过热点内容分析模块向流媒体频道录制模块反馈热点频道列表,并在热点频道列表中记载热点频道的频道标识、热点时间信息和热度值,流媒体频道录制模块根据频道标识确定热点频道,并将热点时间信息纳入该热点频道的频道录制的管理流程,在热点时间开始之后进行录制。It should be noted that, for IPTV, there are many channels online at the same time, and this embodiment does not limit the number of hot channels. Through the hot content analysis module shown in Figure 2, several hot content can be determined. When the above If the hot content belongs to different channels, at least two hot channels can be determined. In order to configure hotspot time information for hotspot channels, the hotspot channel list can be fed back to the streaming media channel recording module through the hotspot content analysis module, and the channel identification, hotspot time information and heat value of the hotspot channel are recorded in the hotspot channel list, and streaming media The channel recording module determines the hot channel according to the channel identifier, and incorporates the hot time information into the channel recording management process of the hot channel, and records after the hot time starts.
值得注意的是,在确定多个热点频道之后,可以按照单位时间统计热度值的排名,在热点频道列表中根据热度值从高到低对热点频道进行排名。It is worth noting that after a plurality of hot channels are determined, the ranking of the popularity values can be calculated according to unit time, and the hot channels are ranked according to the popularity values from high to low in the hot channel list.
需要说明的是,在热点频道列表中携带的热度值可以有多种应用方式,例如,在多个热点频道同时录制过程中,高速缓存设备资源较少的情况下,可以根据热度值的高低进行资源的分配,优先分配给高热度值的热点频道,本实施例技术人员有动机根据实际需求调整热度值的使用方式,在此不多作限定。It should be noted that the popularity value carried in the hot channel list can be applied in many ways. For example, in the process of recording multiple hot channels at the same time, when the cache device resources are less, it can be used according to the height of the popularity value. The allocation of resources is given priority to hot channels with high popularity values. The technicians in this embodiment have the motivation to adjust the use of popularity values according to actual needs, and no limitation is made here.
另外,参照图6,在一实施例中,图1所示实施例的步骤S120,还包括但不限于有以下步骤:In addition, referring to FIG. 6, in one embodiment, step S120 of the embodiment shown in FIG. 1 also includes but is not limited to the following steps:
步骤S610,确定高速缓存设备的目标目录;Step S610, determining the target directory of the cache device;
步骤S620,将直播码流写入目标目录。Step S620, write the live code stream into the target directory.
需要说明的是,对于历史播放内容,其实时性较低,即使采用常规方案录制至低速缓存设备,在热度分析后迁移至高速缓存设备,也不会对用户体验造成太大的影响,因此,为了与非直播的内容进行区分,可以在高速缓存设备中配置特定的目标目录,用于保存本实施例中录制于直播码流,并且用于响应直播回看请求或直播时移请求的高速缓存码流,在检测到针对热点内容的直播回看请求或者直播时移请求后,从目标目录进行码流的定位和查找,能够进一步减少响应时间。It should be noted that the real-time performance of historical playback content is low. Even if the conventional solution is used to record to a low-speed cache device and migrate to the cache device after heat analysis, it will not have a great impact on user experience. Therefore, In order to distinguish it from non-live content, a specific target directory can be configured in the cache device to save the live code stream recorded in this embodiment and to respond to the live broadcast playback request or live broadcast time-shifting request. For code stream, after detecting a live broadcast review request or a live broadcast time-shift request for hot content, the code stream is located and searched from the target directory, which can further reduce the response time.
另外,在一实施例中,CDN系统还包括低速缓存设备,参照图7,图1所示实施例的步骤S120,还包括但不限于有以下步骤:In addition, in one embodiment, the CDN system also includes a low-speed cache device. Referring to FIG. 7, step S120 of the embodiment shown in FIG. 1 also includes but is not limited to the following steps:
步骤S710,将热点频道的直播码流同步录制至高速缓存设备和低速缓存设备,从而得到存储于高速缓存设备的高速缓存码流,以及存储于低速缓存设备的低速缓存码流。Step S710, synchronously record the live code stream of the popular channel to the high-speed cache device and the low-speed cache device, so as to obtain the high-speed cache code stream stored in the high-speed cache device and the low-speed cache code stream stored in the low-speed cache device.
需要说明的是,低速缓存设备可以是常见的机械硬盘等,在读取速率低于高速缓存设备,但在成本上相比起高速缓存设备具有优势即可。It should be noted that the low-speed cache device can be a common mechanical hard disk, etc., and its read rate is lower than that of the high-speed cache device, but it only needs to have an advantage over the high-speed cache device in terms of cost.
值得注意的是,低速缓存设备可以保持对直播码流的录制,并不需要对是否热点内容进行判断,录制于同一直播内容的低速缓存码流和高速缓存码流可以通过内容标识进行区分,图2所示的流媒体用户服务模块可以向文件存储服务器发送内容标识,根据内容标识从高速缓存设备或者低速缓存设备获取码流进行播放。It is worth noting that the low-speed cache device can keep recording the live stream, and does not need to judge whether it is a hot content. The low-speed cache stream and the high-speed cache stream recorded in the same live content can be distinguished by the content identifier, as shown in Fig. The streaming media user service module shown in 2 can send the content identifier to the file storage server, and obtain the code stream from the high-speed cache device or the low-speed cache device according to the content identifier for playback.
值得注意的是,与常规技术中通过低速缓存设备录制直播码流,在热度分析后前移至高速缓存设备不同,本实施例的技术方案采用热点内容同步录制的方式,根据热点时间信息,将热点频道的直播码流同时写入高速缓存设备和低速缓存设备,省去了迁移和热度分析的步 骤,在进行码流读取时能够直接从高速缓存设备进行读取,有效提高了响应的效率,能在更短的响应时间内响应服务。It is worth noting that, unlike the conventional technology that uses low-speed cache equipment to record live streams and then moves them forward to high-speed cache equipment after heat analysis, the technical solution of this embodiment adopts the method of synchronous recording of hot content, and according to the time information of hot spots, the The live code stream of the hot channel is written into the high-speed cache device and the low-speed cache device at the same time, which saves the steps of migration and heat analysis. When reading the code stream, it can be read directly from the cache device, effectively improving the efficiency of the response , can respond to services in a shorter response time.
另外,参照图8,本申请实施例还提供了一种内容播放方法,应用于CDN系统,CDN系统包括高速缓存设备,该内容播放方法包括但不限于有步骤S810、步骤S820和步骤S830。In addition, referring to FIG. 8 , the embodiment of the present application also provides a content playing method, which is applied to a CDN system. The CDN system includes a cache device. The content playing method includes but is not limited to steps S810, S820, and S830.
步骤S810,获取直播服务请求,确定直播服务请求所对应的直播内容。Step S810, acquiring the live broadcast service request, and determining the live broadcast content corresponding to the live broadcast service request.
需要说明的是,由于直播服务请求是针对正在直播的内容,因此在获取到直播服务请求后,可以直接获取当前正在直播的内容标识,通过内容标识确定直播内容,也可以通过其他方式确定直播内容,在此不多作限定。It should be noted that since the live broadcast service request is for the live broadcast content, after obtaining the live broadcast service request, the content ID of the currently live broadcast content can be obtained directly, and the live broadcast content can be determined through the content ID, or the live content can be determined in other ways , not limited here.
需要说明的是,直播服务请求可以是直播回看请求或者直播时移请求,例如观看电视节目的过程中,通过控制终端向机顶盒发送回看指令或者时移指令,从而形成直播服务请求,当然也可以是针对直播内容进行操作的指令,本实施例对此不多作限定。It should be noted that the live broadcast service request can be a live broadcast review request or a live broadcast time-shift request. It may be an instruction to operate on live content, which is not limited in this embodiment.
步骤S820,从高速缓存码流中获取与直播内容相对应的目标码流,其中,高速缓存码流根据热点时间信息录制于热点频道的直播码流,热点时间信息与热点频道相关联。Step S820, obtaining the target code stream corresponding to the live content from the cache code stream, wherein the cache code stream is recorded in the live code stream of the hot channel according to the hot time information, and the hot time information is associated with the hot channel.
需要说明的是,高速缓存码流的录制方式可以参考图1所示实施例的描述,为了叙述简便在此不再重复赘述。It should be noted that, for the recording method of the cache code stream, reference may be made to the description of the embodiment shown in FIG. 1 , and details are not repeated here for the sake of brevity.
值得注意的是,由于高速缓存设备存储的高速缓存码流可以来自于多个热点频道,例如同一个热点时间段内从多个热点频道同时录制直播码流,在这种情况下,可以通过频道标识或者内容标识从高速缓存设备中获取目标码流,具体匹配方式可以根据实际需求调整,在此不多作限定。It is worth noting that since the cached code stream stored in the cache device can come from multiple hotspot channels, for example, live streams are recorded simultaneously from multiple hotspot channels within the same hotspot time period. In this case, you can pass the channel The ID or content ID obtains the target code stream from the cache device, and the specific matching method can be adjusted according to actual needs, and is not limited here.
步骤S830,播放目标码流。Step S830, playing the target code stream.
需要说明的是,由于高速缓存码流根据预先确定的热点频道和热点时间信息录制,因此在获取到直播服务请求时可以直接读取目标码流进行播放,从接到直播服务请求到播放只执行了读取的操作,省去了热度分析和文件迁移操作,能够有效提高播放目标码流的响应效率,提高用户体验。It should be noted that since the cached stream is recorded according to the predetermined hotspot channel and hotspot time information, when the live service request is obtained, the target stream can be directly read and played. From receiving the live service request to playing only execution The operation of reading is eliminated, heat analysis and file migration operations are omitted, which can effectively improve the response efficiency of playing the target stream and improve user experience.
另外,在一实施例中,CDN系统还包括低速缓存设备,低速缓存设备存储有低速缓存码流,低速缓存码流和高速缓存码流同步录制于热点频道的直播码流,参照图9,图8所示实施例的步骤S820,还包括但不限于有以下步骤:In addition, in one embodiment, the CDN system also includes a low-speed cache device, the low-speed cache device stores the low-speed cache code stream, and the low-speed cache code stream and the high-speed cache code stream are synchronously recorded in the live code stream of the hot channel, referring to FIG. Step S820 of the embodiment shown in 8 also includes but is not limited to the following steps:
步骤S910,当确定直播内容为热点内容,从高速缓存码流中获取目标码流;Step S910, when it is determined that the live content is a hot content, obtain the target code stream from the cache code stream;
步骤S920,当从高速缓存码流中获取目标码流失败,从低速缓存码流中获取目标码流。Step S920, when obtaining the target code stream from the high-speed cache code stream fails, obtain the target code stream from the low-speed cache code stream.
需要说明的是,本实施例技术方案是为了提高针对高实时性业务的响应效率,因此,在从高速缓存码流获取目标码流之前,可以先判断直播内容是否为热点内容,例如,每个热点频道都预先配置有热点时间信息,当直播内容所对应的时间与热点时间信息对应,则可以确定其为热点内容,也可以采用其他方式确定直播内容为热点内容,在此不多作限定。It should be noted that the technical solution of this embodiment is to improve the response efficiency for high-real-time services. Therefore, before obtaining the target code stream from the cache code stream, it can be judged whether the live content is a hot content, for example, each Hot channels are pre-configured with hot time information. When the time corresponding to the live content corresponds to the hot time information, it can be determined as a hot content, or other methods can be used to determine the live content as a hot content, which is not limited here.
需要说明的是,在确定直播内容为热点内容后,可以先尝试高速缓存码流中读取目标码流,当读取成功则直接播放,若不成功,由于低速缓存设备录制有所有的码流,因此可以从低速缓存码流中获取目标码流。可以理解的是,在本实施例的技术方案中,热点频道和热点时间信息是根据历史服务话单得到的,当直播内容出现特殊的热点内容,根据历史服务话单并不一定能够确定该频道在该时间段内的内容为热点内容,例如对于一个电视频道,临时插播一个高热度的节目,而这个节目在之前并没有播出过,因此可能在当前产生较高的热度, 被判定为热点内容,但是根据历史服务话单并不会将该时间段内的内容确定为热点内容,从而不将其录制到高速缓存码流中,在这种情况下,可以从低速缓存码流中获取对应的目标码流,以确保能够成功获取到目标码流。It should be noted that after determining that the live content is a hot content, you can try to read the target stream from the cached stream first, and play it directly when the read is successful. , so the target code stream can be obtained from the low-speed cache code stream. It can be understood that, in the technical solution of this embodiment, the hot channel and hot time information are obtained according to the historical service bills. When special hot content appears in the live broadcast content, the channel may not be determined according to the historical service bills. The content within this time period is hot content. For example, for a TV channel, a hot program is temporarily inserted, but this program has not been broadcast before, so it may generate high popularity at present, and it is judged as hot. However, according to the historical service bills, the content in this period of time will not be determined as hot content, so it will not be recorded in the cache code stream. In this case, the corresponding content can be obtained from the low cache code stream. The target code stream to ensure that the target code stream can be obtained successfully.
需要说明的是,低速缓存设备录制低速缓存码流的方法可以参考图7所示实施例的描述,为了叙述简便在此不重复赘述。It should be noted that the method for recording the low-speed cache code stream by the low-speed cache device may refer to the description of the embodiment shown in FIG.
另外,参照图10,在一实施例中,图8所示实施例的步骤S820,还包括但不限于有以下步骤:In addition, referring to FIG. 10 , in one embodiment, step S820 of the embodiment shown in FIG. 8 also includes but is not limited to the following steps:
步骤S1010,确定高速缓存设备的目标目录,其中,目标目录存储有高速缓存码流;Step S1010, determine the target directory of the cache device, wherein the target directory stores the cache code stream;
步骤S1020,从目标目录存储的高速缓存码流中获取目标码流。Step S1020, acquiring the target code stream from the cached code stream stored in the target directory.
需要说明的是,在高速缓存设备设置目标目录的原理和方法可以参考图6所示实施例的描述,为了叙述简便在此不重复赘述。It should be noted that for the principle and method of setting the target directory on the cache device, reference may be made to the description of the embodiment shown in FIG. 6 , and details are not repeated here for the sake of brevity.
需要说明的是,由于目标目录用于存储直播码流的录制内容,因此在从高速缓存码流获取目标码流的过程中,可以直接对目标目录进行定位,从而进一步提高目标码流的获取效率。It should be noted that since the target directory is used to store the recording content of the live stream, the target directory can be directly located during the process of obtaining the target stream from the cached stream, thereby further improving the efficiency of obtaining the target stream .
另外,参照图11,在一实施例中,在执行图8所示实施例的步骤S830之后,还包括但不限于有以下步骤:In addition, referring to FIG. 11 , in one embodiment, after step S830 of the embodiment shown in FIG. 8 is executed, the following steps are also included but not limited to:
步骤S1110,根据直播服务请求生成服务话单,服务话单包括服务开始时刻、服务结束时刻和热度指标;Step S1110, generate a service bill according to the live service request, the service bill includes the service start time, service end time and popularity index;
步骤S1120,根据服务话单更新热点频道的热点时间信息。Step S1120, update the hot spot time information of the hot spot channel according to the service bill.
需要说明的是,在执行完直播服务请求的情况下,本领域技术人员熟知如何获取服务开始时刻和服务结束时刻,并且,参考上述实施例的描述,热度指标可以针对该直播内容得到的服务流量、点击次数等,本领域技术人员也熟知如何获取上述参数,在此对服务话单的生成过程不多作限定。It should be noted that, after executing the live broadcast service request, those skilled in the art are familiar with how to obtain the service start time and service end time, and, referring to the description of the above embodiment, the heat index can be used for the service traffic obtained by the live broadcast content , the number of clicks, etc., those skilled in the art are also familiar with how to obtain the above parameters, and the generation process of the service bill is not limited here.
需要说明的是,在得到服务话单后,可以将服务话单作为历史服务话单,由图2所示的流媒体用户服务模块发送至热点内容分析模块热点频道和热点时间信息,具体方式可以参考图3所示实施例的描述,为了叙述简便在此不重复赘述。It should be noted that after the service bill is obtained, the service bill can be used as a historical service bill, and the streaming media user service module shown in Figure 2 sends it to the hot channel and hot time information of the hot content analysis module. The specific method can be Referring to the description of the embodiment shown in FIG. 3 , details are not repeated here for the sake of brevity.
另外,为了更好地说明本申请的技术方案,以下提出一个具体示例,结合图2所示的CDN系统架构,参照图12,该示例包括但不限于有以下步骤:In addition, in order to better illustrate the technical solution of this application, a specific example is proposed below, in combination with the CDN system architecture shown in Figure 2, referring to Figure 12, this example includes but is not limited to the following steps:
步骤S1210,当用户向流媒体服务器发起服务请求,流媒体用户服务模块完成服务后,向热点内容分析模块上报服务话单,其中,服务话单包括服务类型、服务内容ID、服务起止时间、服务流量和点击次数;Step S1210, when the user initiates a service request to the streaming media server, after the streaming media user service module completes the service, it reports the service bill to the hot content analysis module, wherein the service bill includes service type, service content ID, service start and end time, service traffic and clicks;
步骤S1220,热点内容分析模块根据收集到的服务话单,根据服务流量和点击次数确定每个频道的内容的热度值,再按照单位时间内的热度值进行排序,形成热点频道列表,其中,热点频道列表中包括热点频道ID、热点开始时间、热点结束时间、热度值;Step S1220, the hotspot content analysis module determines the popularity value of the content of each channel according to the collected service call list, according to the service traffic and the number of clicks, and then sorts according to the popularity value per unit time to form a list of hot channels, wherein, hotspot The channel list includes hotspot channel ID, hotspot start time, hotspot end time, popularity value;
步骤S1230,热点内容分析模块周期性将热点频道列表推送至流媒体频道录制模块;Step S1230, the hot content analysis module periodically pushes the hot channel list to the streaming media channel recording module;
步骤S1240,流媒体频道录制模块将热点频道列表纳入频道录制的管理流程,当系统时间达到热点开始时间,针对热点频道的直播码流进行录制,并同步写入低速缓存设备和高速缓存设备的目标目录;Step S1240, the streaming media channel recording module includes the hot channel list into the management process of channel recording, when the system time reaches the hot spot start time, record the live code stream of the hot channel, and synchronously write the low-speed cache device and the target of the high-speed cache device Table of contents;
步骤S1250,当系统时间达到热点结束时间时,流媒体频道录制模块停止向高速缓存设备的目标目录写入直播码流;Step S1250, when the system time reaches the end time of the hotspot, the streaming media channel recording module stops writing the live code stream to the target directory of the cache device;
步骤S1260,当接受到针对直播时移或者直播回看的服务请求,流媒体用户服务模块确定对应的直播内容为热点内容;Step S1260, when receiving a service request for live broadcast time-shifting or live broadcast review, the streaming media user service module determines that the corresponding live content is a hot content;
步骤S1270,当流媒体用户服务模块从高速缓存设备的目标目录获取到目标码流,播放从高速缓存设备获取到的目标码流,当从高速缓存设备的目标目录获取到目标码流失败,从低速缓存设备获取目标码流并播放。Step S1270, when the streaming media user service module obtains the target code stream from the target directory of the cache device, play the target code stream obtained from the cache device, when the target code stream fails to be obtained from the target directory of the cache device, from The low-speed cache device obtains the target code stream and plays it.
另外,参照图13,本申请的一个实施例还提供了一种CDN系统,该CDN系统1300包括:存储器1310、处理器1320及存储在存储器1310上并可在处理器1320上运行的计算机程序。In addition, referring to FIG. 13 , an embodiment of the present application also provides a CDN system. The CDN system 1300 includes: a memory 1310 , a processor 1320 , and a computer program stored in the memory 1310 and operable on the processor 1320 .
处理器1320和存储器1310可以通过总线或者其他方式连接。The processor 1320 and the memory 1310 may be connected through a bus or in other ways.
实现上述实施例的内容录制方法所需的非暂态软件程序以及指令存储在存储器1310中,当被处理器1320执行时,执行上述实施例中的内容录制方法,例如,执行以上描述的图1中的方法步骤S110至步骤S120、图3中的方法步骤S310至步骤S330、图4中的方法步骤S410至步骤S420、图5中的方法步骤S510至步骤S520、图6中的方法步骤S610至步骤S620、图7中的方法步骤S710,或者,执行上述实施例中的内容播放方法,例如,执行以上描述的图8中的方法步骤S810至步骤S830、图9中的方法步骤S910至步骤S920、图10中的方法步骤S1010至步骤S1020、图11中的方法步骤S1110至步骤S1120。The non-transitory software programs and instructions required to realize the content recording method of the above-mentioned embodiment are stored in the memory 1310, and when executed by the processor 1320, the content recording method in the above-mentioned embodiment is executed, for example, executing the above-described Figure 1 Method step S110 to step S120 in, method step S310 to step S330 in Fig. 3, method step S410 to step S420 in Fig. 4, method step S510 to step S520 in Fig. 5, method step S610 to step S520 in Fig. 6 Step S620, method step S710 in FIG. 7, or execute the content playing method in the above embodiment, for example, execute method steps S810 to step S830 in FIG. 8 described above, and method steps S910 to step S920 in FIG. 9 , method step S1010 to step S1020 in FIG. 10 , and method step S1110 to step S1120 in FIG. 11 .
以上所描述的装置实施例仅仅是示意性的,其中作为分离部件说明的单元可以是或者也可以不是物理上分开的,即可以位于一个地方,或者也可以分别到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。The device embodiments described above are only illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place, or they may be distributed to multiple network units. Part or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
此外,本申请的一个实施例还提供了一种计算机可读存储介质,该计算机可读存储介质存储有计算机可执行指令,该计算机可执行指令被一个处理器或控制器执行,例如,被上述CDN系统实施例中的一个处理器执行,可使得上述处理器执行上述实施例中的内容录制方法,例如,执行以上描述的图1中的方法步骤S110至步骤S120、图3中的方法步骤S310至步骤S330、图4中的方法步骤S410至步骤S420、图5中的方法步骤S510至步骤S520、图6中的方法步骤S610至步骤S620、图7中的方法步骤S710,或者,执行上述实施例中的内容播放方法,例如,执行以上描述的图8中的方法步骤S810至步骤S830、图9中的方法步骤S910至步骤S920、图10中的方法步骤S1010至步骤S1020、图11中的方法步骤S1110至步骤S1120。本领域普通技术人员可以理解,上文中所公开方法中的全部或某些步骤、系统可以被实施为软件、固件、硬件及其适当的组合。某些物理组件或所有物理组件可以被实施为由处理器,如中央处理器、数字信号处理器或微处理器执行的软件,或者被实施为硬件,或者被实施为集成电路,如专用集成电路。这样的软件可以分别在计算机可读介质上,计算机可读介质可以包括计算机存储介质(或非暂时性介质)和通信介质(或暂时性介质)。如本领域普通技术人员公知的,术语计算机存储介质包括在用于存储信息(诸如计算机可读指令、数据结构、程序模块或其他数据)的任何方法或技术中实施的易失性和非易失性、可移除和不可移除介质。计算机存储介质包括但不限于RAM、ROM、EEPROM、闪存或其他存储器技术、CD-ROM、数字多功能盘(DVD)或其他光盘存储、磁盒、磁带、磁盘存储或其他磁存储装置、或者可以用于存储期望的信息并且可以被计算机访问的任何其他的介质。此外,本领域普通技术人员公知的是,通信介质通常包含计算机可读指令、数据结构、程序模块或者诸如载波或其他传输机制之类的调制数据信号中的其他数据,并且可包括任何信息递送介质。In addition, an embodiment of the present application also provides a computer-readable storage medium, the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are executed by a processor or a controller, for example, by the above-mentioned Execution by a processor in the CDN system embodiment can cause the above-mentioned processor to execute the content recording method in the above-mentioned embodiment, for example, execute the method steps S110 to S120 in FIG. 1 and the method step S310 in FIG. 3 described above. to step S330, method step S410 to step S420 in FIG. 4, method step S510 to step S520 in FIG. 5, method step S610 to step S620 in FIG. 6, method step S710 in FIG. The content playing method in the example, for example, executes the method step S810 to step S830 in Fig. 8 described above, the method step S910 to step S920 in Fig. 9, the method step S1010 to step S1020 in Fig. 10, and the Method step S1110 to step S1120. Those skilled in the art can understand that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware and an appropriate combination thereof. Some or all of the physical components may be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit . Such software may reside on computer readable media, respectively, which may include computer storage media (or non-transitory media) and communication media (or transitory media). As known to those of ordinary skill in the art, the term computer storage media includes both volatile and nonvolatile media implemented in any method or technology for storage of information, such as computer readable instructions, data structures, program modules, or other data. permanent, removable and non-removable media. Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disk (DVD) or other optical disk storage, magnetic cartridges, tape, magnetic disk storage or other magnetic storage devices, or can Any other medium used to store desired information and which can be accessed by a computer. In addition, as is well known to those of ordinary skill in the art, communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media .
本申请实施例包括:获取热点频道预先关联的热点时间信息;根据所述热点时间信息, 将所述热点频道的直播码流录制至所述高速缓存设备,得到高速缓存码流。根据本实施例的技术方案,能够提前确定需要录制的直播码流,有效加快高实时业务的回看或时移访问的响应时间,提高用户体验,有效降低服务器的整体运行负荷。The embodiment of the present application includes: obtaining the hot spot time information pre-associated with the hot spot channel; according to the hot spot time information, recording the live stream of the hot spot channel to the cache device to obtain the cache stream. According to the technical solution of this embodiment, the live code stream to be recorded can be determined in advance, effectively speeding up the response time of high-real-time service review or time-shifted access, improving user experience, and effectively reducing the overall operating load of the server.
以上是对本申请的一些实施进行了具体说明,但本申请并不局限于上述实施方式,熟悉本领域的技术人员在不违背本申请精神的前提下还可作出种种的等同变形或替换,这些等同的变形或替换均包含在本申请权利要求所限定的范围内。The above is a specific description of some implementations of the present application, but the present application is not limited to the above-mentioned embodiments. Those skilled in the art can also make various equivalent deformations or replacements without violating the spirit of the present application. Any modification or substitution is included within the scope defined by the claims of the present application.

Claims (12)

  1. 一种内容录制方法,应用于CDN系统,所述CDN系统包括高速缓存设备,所述方法包括:A method for recording content, applied to a CDN system, where the CDN system includes a cache device, and the method includes:
    获取热点频道预先关联的热点时间信息;Get hotspot time information pre-associated with hotspot channels;
    根据所述热点时间信息,将所述热点频道的直播码流录制至所述高速缓存设备,得到高速缓存码流。According to the hotspot time information, the live stream of the hotspot channel is recorded to the cache device to obtain the cached stream.
  2. 根据权利要求1所述的方法,其中,在所述获取热点频道预先关联的热点时间信息之前,所述方法还包括:The method according to claim 1, wherein, before the acquisition of the pre-associated hotspot time information of the hotspot channel, the method further comprises:
    获取待评价频道的历史服务话单,所述历史服务话单包括待评价内容的服务开始时刻、服务结束时刻和热度指标,其中,所述历史服务话单归属于直播回看业务和/或直播时移业务;Obtain the historical service bill of the channel to be evaluated, the historical service bill includes the service start time, service end time and popularity index of the content to be evaluated, wherein the historical service bill belongs to the live broadcast review service and/or live broadcast time-shifting services;
    当所述热度指标满足预设条件,将所述待评价内容确定为热点内容,并将所述待评价频道确定为所述热点频道;When the popularity index satisfies the preset condition, determining the content to be evaluated as hot content, and determining the channel to be evaluated as the hot channel;
    根据所述服务开始时刻和所述服务结束时刻确定所述热点时间信息,并将所述热点时间信息关联至所述热点频道。The hotspot time information is determined according to the service start time and the service end time, and the hotspot time information is associated with the hotspot channel.
  3. 根据权利要求2所述的方法,其中,所述当所述热度指标满足预设条件,将所述待评价内容确定为热点内容,包括:The method according to claim 2, wherein, when the heat index satisfies a preset condition, determining the content to be evaluated as a hot content includes:
    根据所述热度指标确定所述待评价内容的热度值;determining the popularity value of the content to be evaluated according to the popularity index;
    当所述热度值满足预设阈值,确定所述待评价内容为所述热点内容。When the popularity value satisfies a preset threshold, it is determined that the content to be evaluated is the hot content.
  4. 根据权利要求3所述的方法,其中,在所述并将所述热点时间信息关联至所述热点频道之后,所述方法还包括:The method according to claim 3, wherein, after said and associating the hotspot time information with the hotspot channel, the method further comprises:
    确定至少两个所述热点频道;determining at least two of said hotspot channels;
    根据至少两个所述热点频道生成热点频道列表,其中,所述热点频道列表中的所述热点频道根据所述热度值由大到小排序,所述热点频道列表记载有所述热点频道的频道标识、所述热点时间信息和所述热度值。A hot channel list is generated according to at least two hot channels, wherein the hot channels in the hot channel list are sorted according to the popularity value from large to small, and the hot channel list records channels of the hot channels ID, the hotspot time information and the popularity value.
  5. 根据权利要求1所述的方法,其中,所述将所述热点频道的直播码流录制至所述高速缓存设备,包括:The method according to claim 1, wherein the recording the live code stream of the hot channel to the cache device comprises:
    确定所述高速缓存设备的目标目录;determining a target directory for the cache device;
    将所述直播码流写入所述目标目录。Write the live code stream into the target directory.
  6. 根据权利要求1或5所述的方法,其中,所述CDN系统还包括低速缓存设备,所述将所述热点频道的直播码流录制至所述高速缓存设备,得到高速缓存码流,包括:The method according to claim 1 or 5, wherein the CDN system further comprises a low-speed cache device, and recording the live code stream of the hot channel to the cache device to obtain the cache code stream includes:
    将所述热点频道的所述直播码流同步录制至所述高速缓存设备和所述低速缓存设备,从而得到存储于所述高速缓存设备的高速缓存码流,以及存储于所述低速缓存设备的低速缓存码流。synchronously recording the live code stream of the hot channel to the cache device and the low cache device, thereby obtaining the cache code stream stored in the cache device, and the cache code stream stored in the low cache device Low-speed cache code stream.
  7. 一种内容播放方法,应用于CDN系统,所述CDN系统包括高速缓存设备,所述方法包括:A method for playing content, applied to a CDN system, the CDN system including a cache device, the method comprising:
    获取直播服务请求,确定所述直播服务请求所对应的直播内容;Obtain a live broadcast service request, and determine the live broadcast content corresponding to the live broadcast service request;
    从高速缓存码流中获取与所述直播内容相对应的目标码流,其中,所述高速缓存码流根据热点时间信息录制于热点频道的直播码流,所述热点时间信息与所述热点频道相关联;Obtain the target code stream corresponding to the live content from the cache code stream, wherein the cache code stream is recorded in the live code stream of the hot channel according to the hot spot time information, and the hot spot time information is related to the hot channel Associated;
    播放所述目标码流。Play the target code stream.
  8. 根据权利要求7所述的方法,其中,所述CDN系统还包括低速缓存设备,所述低速缓存设备存储有低速缓存码流,所述低速缓存码流和所述高速缓存码流同步录制于所述热点频道的所述直播码流,所述从高速缓存码流中获取与所述直播内容相对应的目标码流,包括:The method according to claim 7, wherein the CDN system further comprises a low-speed cache device, and the low-speed cache device stores a low-speed cache code stream, and the low-speed cache code stream and the cache code stream are synchronously recorded in the The live code stream of the hot channel, the acquisition of the target code stream corresponding to the live content from the cache code stream includes:
    当确定所述直播内容为热点内容,从所述高速缓存码流中获取所述目标码流;When it is determined that the live content is a hot content, obtain the target code stream from the cache code stream;
    当从所述高速缓存码流中获取所述目标码流失败,从所述低速缓存码流中获取所述目标码流。When acquiring the target code stream from the cache code stream fails, acquire the target code stream from the low cache code stream.
  9. 根据权利要求7所述的方法,其中,所述从高速缓存码流中获取与所述直播内容相对应的目标码流,包括:The method according to claim 7, wherein said obtaining the target code stream corresponding to the live content from the cached code stream comprises:
    确定所述高速缓存设备的目标目录,其中,所述目标目录存储有所述高速缓存码流;determining a target directory of the cache device, wherein the target directory stores the cache code stream;
    从所述目标目录存储的所述高速缓存码流中获取所述目标码流。The target code stream is acquired from the cache code stream stored in the target directory.
  10. 根据权利要求7所述的方法,其中,在所述播放所述目标码流之后,所述方法还包括:The method according to claim 7, wherein, after the playing of the target code stream, the method further comprises:
    根据所述直播服务请求生成服务话单,所述服务话单包括服务开始时刻、服务结束时刻和热度指标;generating a service bill according to the live service request, the service bill including service start time, service end time and popularity index;
    根据所述服务话单更新所述热点频道的热点时间信息。Updating the hotspot time information of the hotspot channel according to the service bill.
  11. 一种CDN系统,包括:存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,其中,所述处理器执行所述计算机程序时实现如权利要求1至6中任意一项所述的内容录制方法,或者实现如权利要求7至10中任意一项所述的内容播放方法。A CDN system, comprising: a memory, a processor, and a computer program stored on the memory and operable on the processor, wherein, when the processor executes the computer program, any one of claims 1 to 6 is realized The content recording method, or realize the content playing method according to any one of claims 7-10.
  12. 一种计算机可读存储介质,存储有计算机可执行指令,其中,所述计算机可执行指令用于执行如权利要求1至6中任意一项所述的内容录制方法,或者执行如权利要求7至10中任意一项所述的内容播放方法。A computer-readable storage medium storing computer-executable instructions, wherein the computer-executable instructions are used to execute the content recording method according to any one of claims 1 to 6, or to execute the content recording method according to any one of claims 7 to 6. The content playing method described in any one of 10.
PCT/CN2022/114279 2021-11-12 2022-08-23 Content recording method, content playing method, cdn system, and storage medium WO2023082764A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202111338139.3A CN116132698A (en) 2021-11-12 2021-11-12 Content recording method, playing method, CDN system and storage medium
CN202111338139.3 2021-11-12

Publications (1)

Publication Number Publication Date
WO2023082764A1 true WO2023082764A1 (en) 2023-05-19

Family

ID=86301393

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/114279 WO2023082764A1 (en) 2021-11-12 2022-08-23 Content recording method, content playing method, cdn system, and storage medium

Country Status (2)

Country Link
CN (1) CN116132698A (en)
WO (1) WO2023082764A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117119052A (en) * 2023-10-25 2023-11-24 腾讯科技(深圳)有限公司 Data processing method, device, electronic equipment and computer readable storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040148469A1 (en) * 2003-01-29 2004-07-29 Sudarshan Kadambi Method and apparatus for predicting hot spots in cache memories
US20080059721A1 (en) * 2006-09-01 2008-03-06 Microsoft Corporation Predictive Popular Content Replication
JP2010231798A (en) * 2010-05-26 2010-10-14 Thomson Licensing Cache server at hotspot for downloading service
US20200275153A1 (en) * 2019-02-26 2020-08-27 At&T Intellectual Property I, L.P. System and method for pushing scheduled content to optimize network bandwidth

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040148469A1 (en) * 2003-01-29 2004-07-29 Sudarshan Kadambi Method and apparatus for predicting hot spots in cache memories
US20080059721A1 (en) * 2006-09-01 2008-03-06 Microsoft Corporation Predictive Popular Content Replication
JP2010231798A (en) * 2010-05-26 2010-10-14 Thomson Licensing Cache server at hotspot for downloading service
US20200275153A1 (en) * 2019-02-26 2020-08-27 At&T Intellectual Property I, L.P. System and method for pushing scheduled content to optimize network bandwidth

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117119052A (en) * 2023-10-25 2023-11-24 腾讯科技(深圳)有限公司 Data processing method, device, electronic equipment and computer readable storage medium
CN117119052B (en) * 2023-10-25 2024-01-19 腾讯科技(深圳)有限公司 Data processing method, device, electronic equipment and computer readable storage medium

Also Published As

Publication number Publication date
CN116132698A (en) 2023-05-16

Similar Documents

Publication Publication Date Title
US11316946B2 (en) Processing and caching in an information-centric network
KR101138897B1 (en) Method for splitting and distributing a file
CN110764706B (en) Storage system, data management method, and storage medium
US8880650B2 (en) System and method for storing streaming media file
CN100556114C (en) A kind of method of media slicing storage
US20110055881A1 (en) Media file on-demand method, system and appartus
WO2013159703A1 (en) Offline download method, multimedia file download method and system thereof
CN104394380A (en) Video monitoring management system and playback method of video monitoring record
WO2017080428A1 (en) Streaming media channel recording, reviewing method, device, server and storage medium
WO2009026819A1 (en) A method and device for merging bill and saving the state of the buffer queue
WO2023082764A1 (en) Content recording method, content playing method, cdn system, and storage medium
WO2009065309A1 (en) Method and system for storing the program and system for the program demanding
WO2012106923A1 (en) Object adjusting method, migration control device, node device and storage system
CN102291256A (en) Monitoring data query method and equipment
CN101068341B (en) Stream media dispatching system and medium file scheduling method thereof
KR20200101047A (en) Video streaming method using real time caching technique and system thereof
WO2022206529A1 (en) Resource request processing method and apparatus, computer device, and medium
WO2009006768A1 (en) Peer to peer system for supporting time shift service
CN103297431A (en) Streaming media video-on-demand duplicate hybrid buffer strategy based on cloud server cluster
CN103220587A (en) Method and device for obtaining time shifting contents
WO2024146330A1 (en) Video storage method and video playback method
CN114090577A (en) Time sequence data storage and reading method and device
WO2011137681A1 (en) Method and apparatus for filing time shift slicing files and playing programs in an interactive personality television system
CN116193170A (en) Video cartoon scheduling method, device, medium and equipment
Pang et al. Resource scheduling in a high-performance multimedia server

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 22891571

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE