Search

CN-116541553-B - Video scheduling method, device, equipment and readable storage medium

CN116541553BCN 116541553 BCN116541553 BCN 116541553BCN-116541553-B

Abstract

The application discloses a video scheduling method, a device, equipment and a readable storage medium, which comprise the steps of obtaining a plurality of pieces of data of a video file to be stored, storing the plurality of pieces of data in a resource node cluster, recording storage addresses of the plurality of pieces of data, determining a logic block strategy of the video file to be stored, generating a logic block mapping relation table corresponding to the video file to be stored according to the logic block strategy, the plurality of pieces of data and the storage addresses of the plurality of pieces of data, and storing the logic block mapping relation table corresponding to the video file to be stored. Therefore, the application can schedule the video file in the dimension of the logical block by logically partitioning the video file and generating the logical block mapping relation table of the video file, thereby adapting the storage capacity of the resource node when storing the video file, avoiding massive scheduling requests during scheduling and further improving the efficiency of video scheduling.

Inventors

  • CAO WEN

Assignees

  • 湖南快乐阳光互动娱乐传媒有限公司

Dates

Publication Date
20260505
Application Date
20230531

Claims (10)

  1. 1. A method for video scheduling, the method comprising: acquiring a plurality of pieces of fragment data of a video file to be stored; Storing the plurality of fragment data in a resource node cluster, and recording storage addresses of the plurality of fragment data; determining a logic block strategy of the video file to be stored; Virtual blocking is carried out on the video file to be stored according to the logic blocking strategy, so that a plurality of logic blocks of the video file to be stored are obtained; generating a logic block mapping relation table corresponding to the video file to be stored according to the logic block strategy, the plurality of pieces of data and the storage addresses of the plurality of pieces of data, wherein the logic block mapping relation table comprises the corresponding relation between a plurality of logic blocks and the plurality of pieces of data and the storage addresses of the plurality of pieces of data, and each logic block at least corresponds to one piece of data; and storing a logic block mapping relation table corresponding to the video file to be stored.
  2. 2. The method according to claim 1, wherein determining the logical block mapping table corresponding to the video file to be stored according to the logical block policy, the plurality of pieces of data, and the storage addresses of the plurality of pieces of data includes: Determining the corresponding piece of data of each logic block; and generating the logic block mapping relation table according to each logic block, the corresponding relation between each logic block and the fragment data and the storage address of the fragment data.
  3. 3. The method according to claim 1, wherein storing the logical partition mapping relationship table corresponding to the video file to be stored includes: Generating identification information of the video file to be stored and a strategy number of the logic block strategy; Generating a corresponding relation between the logic block mapping relation table, the identification information and the strategy number; And storing the logic block mapping relation table and the corresponding relation between the logic block mapping relation table, the identification information and the strategy number in a memory.
  4. 4. The method of claim 3, wherein after storing the logical block mapping table corresponding to the video file to be stored, the method further comprises: acquiring the searching times of a stored logic block mapping relation table every preset period; And transferring the logical block mapping relation table corresponding to the searching times lower than the preset threshold value from the memory to the local storage for storage.
  5. 5. The method according to claim 1, wherein the method further comprises: Receiving a video scheduling request sent by terminal equipment, wherein the video scheduling request comprises identification information of a target video file; searching a logic relation mapping table corresponding to the target video file according to the identification information of the target video file; Acquiring a storage address of target fragment data corresponding to the target video file according to a logical relation mapping table corresponding to the target video file; acquiring the target fragment data from the resource node cluster according to the storage address of the target fragment data; and sending the target fragment data to the terminal equipment.
  6. 6. The method of claim 5, wherein the video scheduling request further comprises a policy number; Searching a logical relation mapping table corresponding to the target video file according to the identification information of the target video file, including: And searching a logic relation mapping table corresponding to the target video file according to the identification information of the target video file and the strategy number.
  7. 7. A video scheduling apparatus, the apparatus comprising: an acquisition unit for acquiring a plurality of pieces of fragment data of a video file to be stored; A storage unit, configured to store the plurality of fragment data in a resource node cluster, and record storage addresses of the plurality of fragment data; The determining unit is used for determining the logic block strategy of the video file to be stored; Generating a logic block mapping relation table corresponding to the video file to be stored according to the logic block strategy, the plurality of piece data and storage addresses of the plurality of piece data, wherein the logic block mapping relation table comprises the corresponding relation between the plurality of logic blocks and the plurality of piece data and the storage addresses of the plurality of piece data, and each logic block at least corresponds to one piece data; And the storage unit is also used for storing the logic block mapping relation table corresponding to the video file to be stored.
  8. 8. The apparatus of claim 7, wherein the apparatus further comprises: The receiving unit is used for receiving a video scheduling request sent by the terminal equipment, wherein the video scheduling request comprises identification information of a target video file; The searching unit is used for searching a logic relation mapping table corresponding to the target video file according to the identification information of the target video file; The obtaining unit is further configured to obtain a storage address of target fragment data corresponding to the target video file according to a logical relationship mapping table corresponding to the target video file; The obtaining unit is further configured to obtain the target fragment data from the resource node cluster according to a storage address of the target fragment data; and the sending unit is used for sending the target fragment data to the terminal equipment.
  9. 9. A computer device comprises a memory, a processor, and a bus system; Wherein the memory is used for storing programs; The processor being adapted to execute a program in the memory to implement the method of any one of claims 1 to 6; The bus system is used for connecting the memory and the processor so as to enable the memory and the processor to communicate.
  10. 10. A computer readable storage medium storing instructions which, when run on a computer, cause the computer to perform the method of any one of claims 1 to 6.

Description

Video scheduling method, device, equipment and readable storage medium Technical Field The present application relates to the field of video data processing, and more particularly, to a video scheduling method, apparatus, device, and readable storage medium. Background Video scheduling refers to various techniques for capturing, recording, processing, storing, transmitting, and reproducing a series of still images as electrical signals. In the existing video scheduling process, the problem that the scheduling dimension is too thick or too thin is often encountered. If the original slice is used as the dimension for scheduling, a next slice access address is required to be requested to a scheduler for each access, massive scheduling requests are generated, access delay is increased, massive scheduling requests cause huge access pressure to the resource node, the task processing efficiency of the resource node is greatly reduced, and the efficiency of the whole video scheduling is low. Disclosure of Invention The embodiment of the application provides a video scheduling method, a device, equipment and a readable storage medium, which can adapt to the storage capacity of a resource node when a video file is stored, and can avoid massive scheduling requests generated during scheduling, thereby improving the video scheduling efficiency. In view of this, an embodiment of the present application provides a video scheduling method, including: acquiring a plurality of pieces of fragment data of a video file to be stored; Storing the plurality of fragment data in a resource node cluster, and recording storage addresses of the plurality of fragment data; determining a logic block strategy of the video file to be stored; generating a logic block mapping relation table corresponding to the video file to be stored according to the logic block strategy, the plurality of pieces of data and the storage addresses of the plurality of pieces of data, wherein the logic block mapping relation table comprises the corresponding relation between a plurality of logic blocks and the plurality of pieces of data and the storage addresses of the plurality of pieces of data, and each logic block at least corresponds to one piece of data; and storing a logic block mapping relation table corresponding to the video file to be stored. Optionally, the determining the logical block mapping relationship table corresponding to the video file to be stored according to the logical block policy, the plurality of pieces of data, and the storage addresses of the plurality of pieces of data includes: partitioning the video file to be stored according to the logic partitioning strategy to obtain a plurality of logic partitions of the video file to be stored; Determining the corresponding piece of data of each logic block; and generating the logic block mapping relation table according to each logic block, the corresponding relation between each logic block and the fragment data and the storage address of the fragment data. Optionally, the storing the logical partition mapping relationship table corresponding to the video file to be stored includes: Generating identification information of the video file to be stored and a strategy number of the logic block strategy; Generating a corresponding relation between the logic block mapping relation table, the identification information and the strategy number; And storing the logic block mapping relation table and the corresponding relation between the logic block mapping relation table, the identification information and the strategy number in a memory. Optionally, after the storing the logical partition mapping relationship table corresponding to the video file to be stored, the method further includes: acquiring the searching times of a stored logic block mapping relation table every preset period; And transferring the logical block mapping relation table corresponding to the searching times lower than the preset threshold value from the memory to the local storage for storage. Optionally, the method further comprises: Receiving a video scheduling request sent by terminal equipment, wherein the video scheduling request comprises identification information of a target video file; searching a logic relation mapping table corresponding to the target video file according to the identification information of the target video file; Acquiring a storage address of target fragment data corresponding to the target video file according to a logical relation mapping table corresponding to the target video file; acquiring the target fragment data from the resource node cluster according to the storage address of the target fragment data; and sending the target fragment data to the terminal equipment. Optionally, the video scheduling request further includes a policy number; Searching a logical relation mapping table corresponding to the target video file according to the identification information of the target video f