Distributed live broadcast service slice alignment method

By selecting benchmark nodes in the distributed live broadcast service to adjust slice alignment, the problem of slice deviation between nodes caused by network delays is solved, seamless switching and high availability are achieved, and the quality of the live broadcast service is ensured.

CN118540523APending Publication Date: 2024-08-23CHINA TELECOM CLOUD TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410536139.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-04-30
Publication Date
2024-08-23

AI Technical Summary

Technical Problem

In distributed Internet protocol TV live broadcast services, due to network delay and jitter, the existing slice alignment method based on Unix system clock cannot ensure that the live stream reaches each node at the same time, resulting in an increase in slice content deviation between nodes. Seamless switching cannot be achieved, which affects the user experience.

Method used

By randomly selecting a benchmark node at the central node, adjusting the starting position and strategy of slicing of unaligned nodes to align it with the benchmark node, and slicing based on the Unix system clock when a new node is added, and periodically triggering slice alignment to ensure that the node Align the slices between them.

Benefits of technology

It achieves seamless switching between live broadcast service nodes, avoids frame skipping and mosaic phenomena, and ensures high availability and high concurrency capabilities of the live broadcast service. The alignment status is maintained by the nodes themselves, with low overhead and easy expansion and maintenance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118540523A
    Figure CN118540523A
Patent Text Reader

Abstract

The invention discloses a method for aligning distributed live broadcast service slices. The method mainly comprises the following steps: step 1, periodically acquiring an alignment state of distributed live broadcast service nodes by a content library; 2, if no reference node is marked currently, randomly selecting one of the central nodes as a reference node; 3, aiming at the non-aligned nodes, the content library issues an alignment task, the slicing initial position of the non-aligned nodes is adjusted, and meanwhile, the slicing strategy of the non-aligned nodes is adjusted into the mode that the non-aligned nodes are segmented according to the slicing duration; 4, performing fragmentation segmentation on nodes newly added into the live broadcast service cluster based on a Unix system clock; 5, when slice alignment is triggered next time in the content library, the step 3 is repeated; and 6, if the state of the reference node becomes unavailable, the content library reselects one of the remaining center nodes as the reference node and marks the reference node. According to the invention, seamless switching among multiple nodes of the distributed live broadcast service can be realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of Internet television technology, and in particular to a method for aligning distributed live broadcast service slices. Background Art

[0002] Internet Protocol Television provides users with live, on-demand, and time-shifted television programs that support interactivity through IP bearer networks.

[0003] The live broadcast server receives the live broadcast stream from the broadcast control party, transcodes and slices the live broadcast stream, divides the live broadcast stream into video segments of equal length, and then provides live broadcast services to the outside world through protocols such as HLS and DASH. In order to improve the high concurrency and high availability capabilities of live broadcast services, live broadcast services usually adopt a distributed deployment mode of central cluster plus edge cluster. For user requests, the scheduling system will prioritize scheduling them to the nearest node. During the request process, if the node status is abnormal, the scheduling system will seamlessly switch the request to other nodes.

[0004] The existing technology implements slice alignment with reference to the Unix system clock. In a distributed deployment scenario, due to factors such as network delay and network jitter, it is impossible to predict and control the time when the live stream arrives at each live service node. Therefore, aligning slices with reference to the Unix system clock cannot guarantee that the content of the same named slices is completely consistent. As the running time of the live service increases, the deviation of the slice content between nodes gradually increases, resulting in obvious frame skipping and mosaics during the node switching process, which is obvious to users and cannot meet the seamless switching requirements. Therefore, a distributed live service slice alignment method is proposed. Summary of the invention

[0005] The purpose of this section is to summarize some aspects of embodiments of the present invention and briefly introduce some preferred embodiments. Some simplifications or omissions may be made in this section and the specification abstract and the invention title of this application to avoid blurring the purpose of this section, the specification abstract and the invention title, and such simplifications or omissions cannot be used to limit the scope of the present invention.

[0006] In order to solve the above technical problems, the present invention provides the following technical solutions: a method for aligning slices of a distributed live broadcast service, comprising the following steps:

[0007] Step 1: The content library periodically obtains the alignment status of the distributed live broadcast service nodes;

[0008] Step 2: If there is no marked reference node, randomly select one from the central nodes as the reference node;

[0009] Step 3: For the unaligned nodes, the content library issues an alignment task, adjusts the slice starting position of the unaligned nodes according to the slice starting position information provided by the reference node, and adjusts the slice strategy of the unaligned nodes to be sliced ​​according to the slice duration, ensuring that the slices of the unaligned nodes are aligned with those of the reference nodes;

[0010] Step 4: The nodes newly added to the live broadcast service cluster are divided into shards based on the Unix system clock;

[0011] Step 5: When the content library triggers slice alignment next time, repeat step 3 to ensure that the newly added node M is aligned with the reference node;

[0012] Step 6: If the status of the reference node becomes unavailable, the content library will reselect one from the remaining central nodes as the reference node and mark it.

[0013] As a preferred solution of the method for aligning slices of distributed live broadcast services described in the present invention, the content library refers to a content management system, which is responsible for the access and management of video content and the status detection, configuration distribution, slice alignment and node management of multiple nodes of distributed live broadcast services.

[0014] As a preferred solution of the method for aligning distributed live broadcast service slices described in the present invention, the role of the reference node is to provide an alignment basis for other nodes.

[0015] As a preferred solution of the method for aligning slices of the distributed live broadcast service described in the present invention, wherein: when slicing is performed based on the Unix system clock in step 4, if the expected slice duration is 5s, the slice division points are distributed at the first I frame after a time point that is an integer multiple of 5s, and the slice name is taken from the value after the start time of the slice is aligned with the expected slice duration.

[0016] As a preferred solution of the distributed live broadcast service slice alignment method of the present invention, the slice alignment process is:

[0017] S1: When slice alignment is triggered, the reference node returns the starting position information of the most recent N slices;

[0018] S2: The content library sends the slice start position information returned by the reference node to the unaligned node;

[0019] S3: After receiving the alignment task, the unaligned node traverses the GOP from the current position forward, compares the slice start position information sent by the matching content library, and searches for the alignment point;

[0020] S4: If the alignment fails, the unaligned nodes remain in the Unix system clock-based segmentation mode and will be compared and adjusted the next time the slice alignment is triggered.

[0021] As a preferred solution of the method for aligning slices of distributed live broadcast service described in the present invention, wherein: N is 3, and the starting position information includes the starting position I frame md5 and the corresponding timestamp [GOP0: {md0, t0}, GOP5: {md5, t5}, GOP10: {md10, t10}].

[0022] As a preferred solution of the distributed live broadcast service slice alignment method described in the present invention, the I frame refers to a key frame, which uses intra-frame compression and can be decoded into a complete picture alone without relying on other pictures.

[0023] As a preferred solution of the distributed live broadcast service slice alignment method described in the present invention, the GOP refers to Group of Pictures, a group of continuous pictures, and the first picture is an I frame.

[0024] As a preferred solution of the method for aligning slices of distributed live broadcast services described in the present invention, wherein: in S3, when GOP10 is matched, its timestamp is set to t10, and at the same time, the next segmentation point is predicted to be GOP15 based on the expected slice duration, and its timestamp information is set to t10+5. After successful alignment, the slice mode of the node is adjusted to the duration mode, that is, when the slice duration is equal to the expected duration, slice segmentation is performed, and the slice naming also takes the value of the slice start time after alignment with the expected slice duration.

[0025] As a preferred solution of the method for aligning distributed live broadcast service slices described in the present invention, wherein: the expected duration is 5s.

[0026] Beneficial effects of the present invention:

[0027] 1. The present invention proposes a slice alignment strategy based on a reference point, in which all live broadcast service node slices are aligned with the reference point, which is not affected by network delays, network fluctuations, etc., and can achieve seamless switching between multiple nodes of distributed live broadcast services.

[0028] 2. In the present invention, after the slices are aligned, the live broadcast service node generates slices according to the slice duration, which can ensure that the subsequently generated slices are continuously aligned, and there is no situation where the slice deviation between nodes gradually increases as the live broadcast service running time increases.

[0029] 3. In the present invention, the alignment status is maintained by each live broadcast service node. The content library only triggers the inspection and task delivery. The functions are decoupled and easy to expand and maintain. For unaligned nodes, the alignment operation is only triggered once, and the overhead is small. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for describing the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative labor. Among them:

[0031] Figure 1 A flowchart of a method for aligning slices of a distributed live broadcast service according to the present invention.

[0032] Figure 2 A diagram of the interaction process between a content library and a live broadcast service node in a distributed live broadcast service slice alignment method of the present invention.

[0033] Figure 3 This is a slice alignment process diagram in a distributed live broadcast service slice alignment method of the present invention. DETAILED DESCRIPTION

[0034] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are described in detail below in conjunction with the accompanying drawings.

[0035] In the following description, many specific details are set forth to facilitate a full understanding of the present invention, but the present invention may also be implemented in other ways different from those described herein, and those skilled in the art may make similar generalizations without violating the connotation of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed below.

[0036] Secondly, the term "one embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The term "in one embodiment" that appears in different places in this specification does not necessarily refer to the same embodiment, nor does it refer to a separate or selective embodiment that is mutually exclusive with other embodiments.

[0037] Secondly, the present invention is described in detail with reference to the schematic diagram. When describing the embodiments of the present invention in detail, for the sake of convenience, the cross-sectional diagrams showing the device structure will not be partially enlarged according to the general scale, and the schematic diagrams are only examples, which should not limit the scope of protection of the present invention. In addition, in actual production, the three-dimensional dimensions of length, width and depth should be included.

[0038] Reference Figure 1-3 The present invention provides a method for aligning slices of a distributed live broadcast service, comprising the following steps (eg Figure 1-2 ):

[0039] Step 1: The content library periodically obtains the alignment status of the distributed live broadcast service nodes.

[0040] The content library refers to the content management system, which is responsible for the access and management of video content, as well as the status detection, configuration distribution, slice alignment and node management of multiple nodes of distributed live broadcast services.

[0041] Step 2: If there is no marked reference node currently, randomly select one from the central nodes as the reference node. The reference node provides the basis for alignment of other nodes.

[0042] Step 3: For the misaligned nodes, the content library issues an alignment task. According to the slice starting position information provided by the reference node, the slice starting position of the misaligned node is adjusted. At the same time, the slice strategy of the misaligned node is adjusted to be split according to the slice duration to ensure that the misaligned node and the reference node slice are aligned. The specific process is described in the slice alignment process section.

[0043] Step 4: The nodes newly added to the live service cluster are segmented based on the Unix system clock. Assuming that the expected segment duration is 5 seconds, the segmentation points are distributed at the first I frame after the time point that is an integer multiple of 5 seconds. The slice name is the value after the start time of the slice is aligned with the expected duration of the slice. Among them, I frame refers to the key frame, which uses intra-frame compression and can be decoded into a complete picture alone without relying on other pictures.

[0044] For example, the first I frame found after 1692597600s is the starting position of the new slice. Assuming that the Unix system time corresponding to the starting position of the slice is 1692597601s, the slice is named 1692597601 / 5*5.ts, that is, 1692597600.ts.

[0045] Step 5: When the content library triggers slice alignment next time, repeat step 3 to ensure that the newly added node M is aligned with the reference node.

[0046] Step 6: If the status of the reference node becomes unavailable, the content library will reselect one from the remaining central nodes as the reference node and mark it.

[0047] The slice alignment process is as follows (e.g. Figure 3 ):

[0048] S1: When slice alignment is triggered, the reference node returns the starting position information of the most recent N slices (N is 3 in the example in the figure), including the starting position I frame md5 and the corresponding timestamp [GOP0:{md0,t0},GOP5:{md5,t5},GOP10:{md10,t10}].

[0049] S2: The content library sends the slice starting position information returned by the reference node to the unaligned node.

[0050] S3: After receiving the alignment task, the unaligned node traverses the GOP from the current position forward, compares the slice starting position information sent by the matching content library, and searches for the alignment point. When GOP10 is matched, its timestamp is set to t10, and the next segmentation point GOP15 is predicted based on the expected slice duration (5s in the example in the figure), and its timestamp information is set to t10+5. After successful alignment, the slicing mode of the node is adjusted to the duration mode, that is, when the slice duration is equal to the expected duration (5s), the slice is segmented. The slice naming also takes the value after the start time of the slice is aligned with the expected slice duration. The GOP refers to Group of Pictures, a group of continuous pictures, and the first picture is an I frame.

[0051] S4: If the alignment fails, the unaligned nodes remain in the Unix system clock-based segmentation mode and will be compared and adjusted the next time the slice alignment is triggered.

[0052] In summary, the content library periodically obtains the alignment status of the distributed live broadcast nodes, issues alignment tasks for unaligned nodes, and uses the benchmark node as a reference to adjust the slice starting position and segmentation strategy to ensure that the node slice is aligned with the benchmark node in terms of naming and content. It is not affected by network delays, network fluctuations, etc., and can achieve seamless switching between multiple nodes of distributed live broadcast services, ensuring high availability and high concurrency of streaming media services. In addition, after the slices are aligned, the live broadcast service node generates slices according to the slice duration, which can ensure that the subsequently generated slices are continuously aligned. As the running time of the live broadcast service increases, there is no situation where the slice deviation between nodes gradually increases. The alignment status is maintained by each live broadcast service node, and the content library only triggers checks and task issuance. The functions are decoupled and easy to expand and maintain. For unaligned nodes, the alignment operation will only be triggered once, with low overhead.

[0053] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solutions of the present invention may be modified or replaced by equivalents without departing from the spirit and scope of the technical solutions of the present invention, which should all be included in the scope of the claims of the present invention.

Claims

1. A method for aligning slices of a distributed live broadcast service. It is characterized in that The following steps are involved: Step 1: The content library periodically obtains the alignment status of the distributed live broadcast service nodes; Step 2: If there is no marked reference node, randomly select one from the central nodes as the reference node; Step 3: For the unaligned nodes, the content library issues an alignment task, adjusts the slice starting position of the unaligned nodes according to the slice starting position information provided by the reference node, and adjusts the slice strategy of the unaligned nodes to be sliced ​​according to the slice duration to ensure that the slices of the unaligned nodes are aligned with those of the reference nodes; Step 4: The nodes newly added to the live broadcast service cluster are divided into shards based on the Unix system clock; Step 5: When the content library triggers slice alignment next time, repeat step 3 to ensure that the newly added node M is aligned with the reference node; Step 6: If the status of the reference node becomes unavailable, the content library will reselect one from the remaining central nodes as the reference node and mark it.

2. The method for aligning slices of a distributed live broadcast service as claimed in claim 1, Features: The content library refers to a content management system, which is responsible for the access and management of video content, as well as status detection, configuration distribution, slice alignment and node management of multiple nodes of distributed live broadcast services.

3. The method for aligning slices of a distributed live broadcast service as claimed in claim 1, Features: The role of the reference node is to provide an alignment basis for other nodes.

4. The method for aligning slices of a distributed live broadcast service as claimed in claim 1, Features: When the slices are segmented based on the Unix system clock in step 4, if the expected slice duration is 5 seconds, the slice segmentation points are distributed at the first I frame after the time point that is an integer multiple of 5 seconds, and the slice name is the value after the start time of the slice is aligned with the expected slice duration.

5. The method for aligning slices of a distributed live broadcast service as claimed in claim 1, Features: The slice alignment process is: S1: When slice alignment is triggered, the reference node returns the starting position information of the most recent N slices; S2: The content library sends the slice start position information returned by the reference node to the unaligned node; S3: After receiving the alignment task, the unaligned node traverses the GOP from the current position forward, compares the slice start position information sent by the matching content library, and searches for the alignment point; S4: If the alignment fails, the unaligned nodes remain in the Unix system clock-based segmentation mode and will be compared and adjusted the next time the slice alignment is triggered.

6. The method for aligning slices of a distributed live broadcast service as claimed in claim 5, Features: The N is 3, and the starting position information includes the starting position I frame md5 and the corresponding timestamp [GOP0: {md0, t0}, GOP5: {md5, t5}, GOP10: {md10, t10}].

7. The method for aligning slices of a distributed live broadcast service as claimed in claim 6, Features: The I frame refers to a key frame, which uses intra-frame compression and can be decoded into a complete picture alone without relying on other pictures.

8. The method for aligning slices of a distributed live broadcast service as claimed in claim 5, Features: The GOP refers to Group of Pictures, a group of continuous pictures, and the first picture is an I frame.

9. The method for aligning slices of a distributed live broadcast service as claimed in claim 5, Features: In S3, when GOP10 is matched, its timestamp is set to t10. At the same time, the next segmentation point is predicted to be GOP15 according to the expected slice duration, and its timestamp information is set to t10+5. After successful alignment, the slice mode of the node is adjusted to the duration mode, that is, when the slice duration is equal to the expected duration, the slice is segmented, and the slice name is also taken from the value after the start time of the slice is aligned with the expected slice duration.

10. The method for aligning slices of a distributed live broadcast service as claimed in claim 9, Features: The expected duration is 5 seconds.