CN110430480B - System and method for streaming media cloud storage synchronization - Google Patents

System and method for streaming media cloud storage synchronization Download PDF

Info

Publication number
CN110430480B
CN110430480B CN201910733225.0A CN201910733225A CN110430480B CN 110430480 B CN110430480 B CN 110430480B CN 201910733225 A CN201910733225 A CN 201910733225A CN 110430480 B CN110430480 B CN 110430480B
Authority
CN
China
Prior art keywords
media
cloud storage
data
module
media stream
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910733225.0A
Other languages
Chinese (zh)
Other versions
CN110430480A (en
Inventor
滑国青
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Mailing Information Technology Co ltd
Original Assignee
Shenzhen Mailing Information Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Mailing Information Technology Co ltd filed Critical Shenzhen Mailing Information Technology Co ltd
Priority to CN201910733225.0A priority Critical patent/CN110430480B/en
Publication of CN110430480A publication Critical patent/CN110430480A/en
Application granted granted Critical
Publication of CN110430480B publication Critical patent/CN110430480B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/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/27Server based end-user applications
    • H04N21/274Storing end-user multimedia data in response to end-user request, e.g. network recorder
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/4302Content synchronisation processes, e.g. decoder synchronisation
    • H04N21/4307Synchronising the rendering of multiple content streams or additional data on devices, e.g. synchronisation of audio on a mobile phone with the video output on the TV screen
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/433Content storage operation, e.g. storage operation in response to a pause request, caching operations
    • H04N21/4334Recording operations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/47End-user applications
    • H04N21/472End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content
    • H04N21/47202End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content for requesting content on demand, e.g. video on demand
    • 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
    • H04N21/8456Structuring of content, e.g. decomposing content into time segments by decomposing the content in the time domain, e.g. in time segments

Abstract

The invention discloses a streaming media cloud storage synchronization system, which comprises a network camera, a media server and a cloud storage server, wherein the network camera, the media server and the cloud storage server are interconnected through an IP network, and a method for batch index supplement transmission of the network camera of the streaming media cloud storage synchronization system, an on-demand method aiming at a cloud storage synchronization function of the streaming media cloud storage synchronization system and a method for cloud storage missing data synchronization of the streaming media cloud storage synchronization system. The invention can make the request and search operation more accurate and rapid by preprocessing the fragment, the packet and the mark of the streaming media, and can continuously transmit the breakpoint by taking the terminal position as the initial condition through the time point of the last received packet or the storage position information of the last packet at the equipment end under the condition of unstable network, and can realize the update synchronization of the streaming media data while requesting.

Description

System and method for streaming media cloud storage synchronization
Technical Field
The invention belongs to the technical field of streaming media, and particularly relates to a system and a method for cloud storage synchronization of streaming media.
Background
With the popularity of the network cameras, people have higher and higher requirements on the reliable storage of video data, and most of the network cameras support the storage of videos in the SD card of the camera and on local NVR (network video recorder) equipment at present; however, local camera equipment and NVR equipment are easily damaged or destroyed, and a cloud storage server generally has the characteristics of high performance and high reliability, and is convenient for realizing friend circle sharing of video, so that the demand of people on storage of video on the cloud is continuously increased. However, the video is stored in the cloud storage, and a public network is required to be used, and the network bandwidth, the network stability and the network interruption become the most serious challenge of the cloud storage. At present, a common cloud storage system in the industry has no data synchronization capability, so that when the network state of cloud storage data is not good, the data is often incomplete. The market urgently needs a system which has strong adaptability to the network state and simultaneously supports the cloud storage data synchronization capability.
Disclosure of Invention
The invention provides a system and a method for synchronizing streaming media cloud storage to overcome the defects of the prior art, and solves the problems of incomplete transmission data due to poor network state.
In order to achieve the purpose, the invention adopts the following technical scheme: a system for cloud storage synchronization of streaming media is characterized by comprising a network camera, a media server and a cloud storage server, wherein the network camera, the media server and the cloud storage server are interconnected through an IP network;
the network camera is used for generating streaming media data and uploading the streaming media data to the media server;
the media server is used for receiving the streaming media data uploaded by the network camera, screening the media data required to be stored in the cloud storage and transferring the media data to the cloud storage server; processing a playing request of a client;
the network camera comprises a media stream sampling module, a media stream local storage module, a media stream cloud storage management module, a media stream on-demand module and/or a media stream live broadcast module and a network camera central controller which is respectively connected with the media stream sampling module, the media stream local storage module, the media stream cloud storage management module, the media stream on-demand module and/or the media stream live broadcast module;
the media server comprises a cloud storage media channel management module, a cloud storage media stream storage management module, a cloud storage on-demand module and a media server central controller which is respectively connected with the cloud storage media channel management module, the cloud storage media stream storage management module and the cloud storage on-demand module;
the cloud storage server is used for providing access and retrieval service of streaming media data.
The media stream sampling module is configured to:
collecting a media stream;
carrying out fragmentation and grouping processing on the media stream;
respectively setting characteristic marks and numbering;
finally, the fragments are sent to a media stream live broadcast module and a media stream local storage module;
the feature marks are marks including a mobile detection mark and a cloud video mark.
The media stream live broadcast module is used for receiving the input of the media stream adoption module and uploading the media stream to a media server or a playing client in real time according to a media stream live broadcast condition or a connection control requirement of the media stream cloud storage management module and a set strategy;
the established policy is:
the user broadcasts the missing data of the cloud storage video clip preferentially;
new missing data takes precedence.
The media stream live broadcast module is also used for enabling a media channel of the cloud storage to be combined with a live broadcast media channel when live broadcast streams pass through the media server.
The media stream local storage module: management for local storage media; the system is also used for writing the real-time media stream data into local storage or retrieving and extracting the stored media data; during storage, the media stream data are organized into a packet index part and a packet data part and then stored respectively; the index part can be used for carrying out retrieval and extraction on the grouped marking information according to time; particularly, the cloud video marks in the index can be used as retrieval basis of cloud storage synchronous data;
the media stream on-demand module: the management work of creating and deleting the media channel for on-demand; the media server is also used for retrieving media data meeting the conditions from the media stream local storage module according to the on-demand conditions and sending the media data to the client through an on-demand media channel or forwarding the media data through the media server; the media server can also synchronize the missing media data in the cloud storage by using the on-demand module;
the media stream cloud storage management module: for connection management, configuration management with the media server; a generation strategy of a cloud storage video mark; and the cloud storage missing data index information batch synchronization function.
The cloud storage media channel management module: the system comprises a media server, a cloud storage media channel, a data sharing and distribution module, a data distribution module and a data distribution module, wherein the media server is used for storing media data and transmitting the media data to the cloud storage media channel; the media stream storage management module is also used for forwarding the media stream related to the cloud storage media stream storage management module;
the established policy is:
the user broadcasts the missing data of the cloud storage video clip preferentially;
new missing data takes precedence.
The cloud storage media stream storage management module: the integrity checking work for receiving the whole sequence and grouping of the cloud storage media stream fragments is carried out; the system is also used for writing the media stream into the cloud storage server according to the index and the data; the cloud storage system is also used for initiating synchronous retransmission management work of the cloud storage missing data;
the cloud storage on-demand module is: the method is used for on-demand playback of the cloud storage video; and the network camera equipment is also used for initiating a missing data on-demand request to the corresponding network camera equipment when the on-demand data only contains the index information and the corresponding data is not synchronized to the cloud storage.
A method for batch index supplementary transmission of network cameras of a streaming media cloud storage synchronization system comprises the following steps:
periodically attempting to connect with the media server;
after the connection is successful, sending a cloud storage batch index supplementary transmission request to the media server, attaching a formatting ID parameter of the current storage medium, and entering the cloud storage synchronization state into an index batch supplementary transmission stage;
receiving interruption position information of a media server about cloud storage and/or a time point of last receiving a packet and/or storage position information of the last packet at a device end; requesting to acquire all grouping index information with cloud video marks from a local storage module by taking the interruption position information and/or the time point of the last received grouping and/or the storage position information of the last grouped at the equipment end as initial conditions, and acquiring in batches if the grouping index entries have huge data;
compressing and packaging the obtained grouped index list, sending the compressed grouped index list to a media server, and responding to a confirmation message after the media server receives the message;
sequentially sending the grouped index lists in batches, and entering a real-time synchronization stage until all grouped indexes are sent;
the media stream live broadcast module uploads live broadcast media stream data in real time, and the local storage module uploads storage index information of live broadcast media stream packets through a signaling channel.
An on-demand method for a cloud storage synchronization function of a streaming media cloud storage synchronization system comprises the following steps:
and receiving the on-demand request, checking request parameters, finding that the request is a cloud storage synchronous on-demand request, extracting a formatting number and grouping position information, and recording the formatting number and the grouping position information in an on-demand request control block structure. And judging whether the format number is consistent with the format number of the local storage medium. If not, the requested data is invalid, and then an error is returned; if the position information of the group is consistent with the position information of the group, the index information of the group is obtained; if the acquisition is failed, the grouped data are covered, the failure is returned, if the acquisition is successful, the fragmented data are read according to the index information, each fragment header information is uploaded through the cloud storage on-demand media channel and is filled with the fragment number, the group number and the group position information, and the server performs data integrity check through the group statistical information; if the media channel does not support the additional information, uploading the additional information through the media signaling channel;
reading the thumbnail fragment data, and uploading the thumbnail fragment data through a cloud storage on-demand media channel; filling fragment numbers and grouping position information during uploading, and marking thumbnail mark bits for the media server to identify the special fragments;
and closing the on-demand media channel until all the requested packets are uploaded.
A method for synchronizing cloud storage missing data of a streaming media cloud storage synchronization system comprises the following steps:
a user sends a cloud storage on-demand request and sends the on-demand request to a media server;
the media server searches for an index of the actual data in the cloud storage server, and sends a cloud storage on-demand request to the network camera according to a certain priority ordering strategy to synchronize the missing data;
the priority ordering policy of the missing data is as follows:
the user broadcasts the missing data of the cloud storage video clip preferentially;
new missing data takes precedence;
the network video camera receives the cloud storage synchronous on-demand request and returns the information of the sending on-demand playing address to the media server;
the media server is connected with the playing address, establishes a playing media channel, plays on demand, and simultaneously proposes the index information of each packet from the playing stream and reassembles the packet data;
matching the indexes of the actual data, writing the data into the cloud storage server, and completing the updating synchronization work of the missing data.
The invention has the beneficial effects that:
by the aid of the segmentation, grouping and marking preprocessing of the streaming media, live broadcast, local video storage and cloud storage are controlled independently, a data source can be shared, and transmission redundancy of data is reduced; by dividing the data into two parts of indexes and data, when cloud storage is synchronized, the indexes are synchronized firstly, and then the data are synchronized, so that rapidness and integrity of data retrieval when a client accesses the cloud storage are guaranteed; the cloud storage data synchronization method in an on-demand mode ensures continuous transmission at any time at a breakpoint and maximum smooth network bandwidth, and can achieve real-time high-priority data which are urgently lost in synchronization when a client plays a cloud storage video.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
FIG. 1 is a system networking diagram of an embodiment of the invention;
FIG. 2 is a block diagram of an embodiment of the present invention;
FIG. 3 is a schematic diagram of a slice composition sequence of a real-time media stream packet according to an embodiment of the present invention;
fig. 4 is a schematic flow chart of cloud storage missing data synchronization according to an embodiment of the present invention;
fig. 5 is a schematic flow chart of cloud storage batch index supplementary transmission according to an embodiment of the present invention.
Detailed Description
The technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. It is to be understood that the embodiments described are only some embodiments of the invention, and not all embodiments. All other embodiments, which can be obtained by a person skilled in the art without inventive effort based on the embodiments of the present invention, are within the scope of the present invention.
As shown in fig. 1, a system for streaming media cloud storage synchronization is characterized by comprising a network camera, a media server, and a cloud storage server, wherein the network camera, the media server, and the cloud storage server are interconnected through an IP network;
the network camera is used for generating streaming media data and uploading the streaming media data to the media server;
the media server is used for receiving the streaming media data uploaded by the network camera, screening the media data required to be stored in the cloud storage and transferring the media data to the cloud storage server; processing a playing request of a client;
example 1: as shown in fig. 2, the network camera includes a media stream sampling module, a media stream local storage module, a media stream cloud storage management module, a media stream on-demand module, a media stream live broadcast module, and a network camera central controller respectively connected to the media stream sampling module, the media stream local storage module, the media stream cloud storage management module, the media stream on-demand module, and the media stream live broadcast module;
the media server comprises a cloud storage media channel management module, a cloud storage media stream storage management module, a cloud storage on-demand module and a media server central controller which is respectively connected with the cloud storage media channel management module, the cloud storage media stream storage management module and the cloud storage on-demand module;
the cloud storage server is used for providing access to streaming media data and retrieval service.
Example 2: the network camera comprises a media stream sampling module, a media stream local storage module, a media stream cloud storage management module, a media stream on-demand module and a network camera central controller which is respectively connected with the media stream sampling module, the media stream local storage module, the media stream cloud storage management module and the media stream on-demand module;
the media server comprises a cloud storage media channel management module, a cloud storage media stream storage management module, a cloud storage on-demand module and a media server central controller which is respectively connected with the cloud storage media channel management module, the cloud storage media stream storage management module and the cloud storage on-demand module;
the cloud storage server is used for providing access to streaming media data and retrieval service.
Example 3: the network camera comprises a media stream sampling module, a media stream local storage module, a media stream cloud storage management module, a media stream live broadcast module and a network camera central controller which is respectively connected with the media stream sampling module, the media stream local storage module, the media stream cloud storage management module and the media stream live broadcast module;
the media server comprises a cloud storage media channel management module, a cloud storage media stream storage management module, a cloud storage on-demand module and a media server central controller which is respectively connected with the cloud storage media channel management module, the cloud storage media stream storage management module and the cloud storage on-demand module;
the cloud storage server is used for providing access to streaming media data and retrieval service.
The search service here is a service in which a user searches on a cloud storage server through information such as a feature tag or noun information. This is a routine skill of those skilled in the art and will not be described in detail here.
Example 4: media stream sampling module for
Collecting a media stream;
carrying out fragmentation and grouping processing on the media stream;
respectively setting characteristic marks (marks including a mobile detection mark and a cloud video mark) and numbering;
and finally, sending the fragments to a media stream live broadcast module and a media stream local storage module.
As shown in fig. 3, in the media stream sampling module of the network camera, the media stream data is fragmented and grouped and numbered. Slicing as a basic transmission unit of media stream data, such as a video I frame, P frame or audio frame; a packet is a set of slices, and slices divided into a packet all have the same packet number. Different packets have different numbers. A packet consists of an I-frame slice, followed by its associated sequence of P-frame slices, and all audio slices within this packet period. The packet is a basic unit of local storage or cloud storage, and the description information, namely the index information, stored in the media stream is described based on the packet.
The media stream slice adds slice header information before the original slice data. The slice header includes the following information: the method comprises the following steps of (1) fragment type, fragment timestamp, a group number to which a fragment belongs, a fragment number, a fragment mark, a code stream channel in which the fragment is located and the like; and each module carries out operations such as media stream data forwarding, issuing, storage judgment and the like according to the fragment header.
A slicing flag consisting of a plurality of flag bits; the cloud video recording system comprises a cloud video recording mark bit for marking whether the fragment is allowed to be uploaded to cloud storage, and other similar mark bits comprise a mobile detection mark, a face detection mark and the like which respectively occupy one bit. The generation source of the cloud video marking bit is a media stream cloud storage management module. When the media stream is stored in the local storage, the cloud video recording mark bit must be stored together, and cannot be lost. It will serve as a basis for retrieving data relating to the local storage of the cloud storage.
Example 5: the media stream live broadcast module is used for receiving the input of the media stream adoption module and according to the live broadcast conditions of the media stream or the connection control requirements of the media stream cloud storage management module, according to a set strategy (the missing data of the cloud storage video recording segment requested by the user is prior; the new missing data is prior)
Uploading the media stream to a media server or a playing client in real time;
the media stream live broadcasting module is also used for enabling the media channel of the cloud storage to be combined with the live media channel when the live stream passes through the media server.
In a media stream live broadcast module of a network camera, when media fragments are received, media channels of all live broadcast media streams need to be traversed, and then the fragments are written into one by one. If the media channel of the cloud storage is already established and the fragment has the cloud recording flag bit, the fragment can be written into the media channel of the cloud storage.
In a media stream live broadcast module of a network camera, if a fragment belongs to a high-definition code stream channel, when all the fragments in the same group are sent, a low-definition thumbnail is actively generated to serve as a browsing thumbnail of the group, the thumbnail is coded into a video fragment and marked with a thumbnail mark bit, and the video fragment is inserted into the tail end of the grouped media stream and is identified by a media server. The insertion position of the thumbnail fragment may be at the start position or any intermediate position of the packet media stream, and if the insertion position is at this position, the thumbnail should be generated when the I-frame fragment of the packet is received. The thumbnail can be extracted from the low-definition stream or a low-resolution snapshot picture can be generated immediately after the generation of the group I frame. The thumbnail is generated on the network camera and sent to the cloud storage, so that the process that the media server transcodes the high-definition media stream into the low-definition thumbnail can be omitted, and the burden of the media server is relieved.
After the data of the media stream packet related to each cloud storage is transmitted, a media stream live broadcast module of the network camera generates statistical information about the packet. The statistical information includes: the total length of the grouped data, the sum of the number and the length of the grouped video fragments, the sum of the number and the total length of the fragments with cloud video marks in the groups, the grouping mark information and the like, the grouping number to which the statistical information belongs and the like. This grouping statistics may be attached to the thumbnail fragment or the next fragment (if the thumbnail is not needed for cloud storage) and sent together over the media channel. If the media channel does not support the sending of the statistical data, the statistical data can also be sent to the media server through the media signaling channel. The media server checks the integrity of the received packet data based on the statistics.
And the media stream live broadcast module of the network camera multiplexes all live broadcast media channels and cloud storage channels sent to the same media server. When multi-channel live broadcast and cloud storage coexist, only one live broadcast media stream data is uploaded, and therefore the requirement on network bandwidth is greatly reduced. The key point is that a cloud video mark and a live video mark are arranged on a media fragment. When a live broadcast media channel and a cloud storage channel exist in the media server at the same time, the network camera uniformly writes data into the live broadcast media channel (or the cloud storage channel), and the media server performs multi-channel distribution processing through the marking bit.
Example 6: the media stream local storage module: management for local storage media; the system is also used for writing the real-time media stream data into local storage or retrieving and extracting the stored media data; during storage, the media stream data are organized into a packet index part and a packet data part and then stored respectively; the index part can be used for carrying out retrieval and extraction on the grouped marking information according to time; particularly, the cloud video marks in the index can be used as the retrieval basis of the cloud storage synchronous data.
The local storage module of the media stream of the network camera takes the packet as a storage unit. Generating grouping index information according to the grouping statistical information; stored on the storage medium separately from the packet data. The data volume of the grouping index information is small, and the grouping index information is used for quick retrieval. The packet index information includes packet data location information, packet flags, start and end timestamps of the packet video, packet length, and other packet statistics information. The location information has unique number information in the present storage medium. The packet flag is obtained by performing or operation on a flag of the fragment, wherein the flag necessarily contains a cloud video flag bit.
When the managed storage medium is formatted, the media stream local storage module of the network camera generates a random formatting number and stores the random formatting number in a certain fixed position of the storage medium. This formatting number is used to solve the problem that the packet index position information is valid only after one formatting.
In a media stream local storage module of the network camera, after writing a group into a storage medium each time, whether the group has a cloud video mark or not is judged, and if so, the index information of the group is sent to a media server through a cloud storage signaling channel. If data loss occurs when receiving live stream packets, the media server may record index information of the packets to the cloud storage first, and then retransmit the lost packet data in an on-demand manner. The uploaded packet index information should include formatting number information. In case the media medium of the device has been replaced or reformatted when the media server requests retransmission at a later time, the wrong data is retrieved.
In the media stream local storage module, the browsing thumbnail of the packet needs to be saved, and the fragment is generated and inserted at the beginning of the packet data or appended to the end. And records the data position of the thumbnail in the grouping index information.
Example 7: media stream on demand module: the management work of creating and deleting the media channel for on-demand; the media server is also used for retrieving media data meeting the conditions from the media stream local storage module according to the on-demand conditions and sending the media data to the client through an on-demand media channel or forwarding the media data through the media server; the media server can also synchronize the missing media data on the cloud storage by using the on-demand module.
In the media stream on-demand module, an on-demand service aiming at the cloud storage synchronization function is provided.
An on-demand method for a cloud storage synchronization function of a streaming media cloud storage synchronization system comprises the following steps:
step 1: and receiving the on-demand request, checking request parameters, finding that the request is a cloud storage synchronous on-demand request, extracting information such as a formatting number, grouping position information and the like, and recording the information in an on-demand request control block structure. And judging whether the format number is consistent with the format number of the local storage medium. If not, the requested data is invalid, and then an error is returned; if yes, go to step 2
Step 2: and according to the position information of the packet, the index information of the packet is obtained. If the acquisition fails, the packet data is covered, and failure is returned. If the acquisition is successful, reading the fragment data one by one according to the index information, and uploading the fragment data through a cloud storage on-demand media channel; during uploading, the fragment number, the grouping number and the grouping position information are filled in each fragment header information. This information will help the media server reassemble the packet data and match the missing packets. Packet statistics and complete index information are also uploaded along with the attachment to a slice of the packet, but it is suggested that the attachment be to a key frame slice. And through grouping statistical information, the server can conveniently carry out data integrity verification. If the media channel does not support the incidental information, uploading may be through the media signaling channel.
And step 3: reading the thumbnail fragment data, and uploading the thumbnail fragment data through a cloud storage on-demand media channel; when uploading, not only the fragment number and the grouping position information are filled, but also the thumbnail mark bit is marked for the media server to identify the special fragment.
And 4, step 4: repeating the step 2-3; and closing the on-demand media channel until all the requested packets are uploaded.
Example 8: media stream cloud storage management module: for connection management, configuration management with the media server; a generation strategy of a cloud storage video mark; and the cloud storage missing data index information batch synchronization function.
The media stream cloud storage management module of the network camera can supplement and transmit all index information of local cloud storage video packets from the breakpoint position of network interruption. The index information helps the media server to further complete the supplementary transmission of the missing data. The method comprises a method for synchronizing the cloud storage missing data of the streaming media cloud storage synchronization system.
As shown in fig. 4, a method for synchronizing missing data in cloud storage of a streaming media cloud storage synchronization system includes the following steps:
step 1: periodic attempts to connect with the media server.
Step 2: and after the connection is successful, sending a cloud storage synchronization request to the media server, and attaching the formatting ID parameter of the current storage medium. At the moment, the cloud storage synchronization state enters an index breakpoint continuous transmission stage.
And step 3: receiving interruption position information of the media server about cloud storage (the interruption position information is either a time point of last received packet or storage position information of last packet at the device side); and then requesting to acquire all the grouping index information with the cloud video marks from the local storage module by taking the interrupt position information as an initial condition. This grouped index entry may be acquired in batches if the data is large.
And 4, step 4: and compressing and packaging the obtained grouping index list, sending the grouping index list to a media server, and responding to a confirmation message after the media server receives the message.
And 5: and sequentially sending the grouped index lists in batches until all grouped indexes are sent. And entering a real-time synchronization stage.
And entering a real-time synchronization stage. The media stream live broadcast module can upload live broadcast media stream data in real time, and the local storage module also starts to continuously upload storage index information of live broadcast media stream packets through the signaling channel.
The media stream cloud storage management module of the network camera can switch an all-day video uploading cloud storage mode or a video uploading cloud mode with a certain time length triggered by other various events (such as a mobile detection event) according to the setting of a user, and finally controls a cloud video switching variable when the modes or the events are generated. And then the on or off value of the cloud video switch is set to the marking bit of the media fragment through the media stream acquisition module.
Example 9: the cloud storage media channel management module: the system is used for managing the cloud storage media channel and realizing data sharing and distribution of the cloud storage media channel and a live broadcast channel of a media server by a set strategy (the missing data of a user on-demand cloud storage video clip is prior; the new missing data is prior); the media stream storage management module is also used for forwarding the media stream related to the cloud storage media stream storage management module;
when receiving a cloud video media stream fragment, the cloud storage media channel management module of the media server can recombine a media stream packet according to the packet real-time statistical information and fragment number information attached to the fragment and verify the integrity of the packet;
example 10: the cloud storage media stream storage management module: the integrity checking work for receiving the whole sequence and grouping of the cloud storage media stream fragments is carried out; the system is also used for writing the media stream into the cloud storage server according to the index and the data; the cloud storage system is also used for initiating synchronous retransmission management work of the cloud storage missing data;
when the cloud storage media stream storage management module of the media server receives the media stream packet data, if the data is incomplete, the cloud storage media stream storage management module can know the missing degree of the data by analyzing the packet statistical information and decide whether to tolerate the incompleteness, and generally, if only a small number of P frame fragments or a small number of audio data are lost, the data can be considered to be basically complete; under the condition that the data is determined to be seriously lost, the packet is discarded, the cloud storage corresponding packet can be marked as lost according to the storage index information of the packet which arrives through the signaling channel, the storage index information of the packet is stored in the cloud storage server index area, and then a data synchronous supplementary transmission request is initiated in the subsequent time.
The cloud storage media stream storage management module of the media server can store the index information and the data information of the received media stream packet data into the cloud storage separately. And the index information is used for searching the fast cloud storage video.
The cloud storage media stream storage management module of the media server can receive a cloud storage index breakpoint continuous transmission request of the network camera at the just-established stage of cloud storage connection and return the time point of the breakpoint or the storage index position information of the breakpoint. When the batch index data after the breakpoint arrives, the grouped index information can be marked as a data missing state and stored in an index area of the cloud storage server.
The cloud storage media stream storage management module of the media server can receive a cloud storage data synchronization request of the network camera, then search an index of missing data in cloud storage, send a cloud storage on-demand request to the network camera according to a certain priority ordering strategy, and perform synchronization of the missing data in batches. The prioritization policy for missing data is: (1) the method comprises the steps that a user broadcasts the missing data of the cloud storage video clip preferentially (2) the new missing data preferentially,
Example 11: the cloud storage on-demand module is: the method is used for on-demand playback of the cloud storage video; and the network camera equipment is also used for initiating a missing data on-demand request to the corresponding network camera equipment when the on-demand data only contains the index information and the corresponding data is not synchronized to the cloud storage.
Example 12:
as shown in fig. 5, a method for batch index retransmission of network cameras of a streaming media cloud storage synchronization system includes:
periodically attempting to connect with the media server;
after the connection is successful, sending a cloud storage batch index supplementary transmission request to the media server, attaching a formatting ID parameter of the current storage medium, and entering the cloud storage synchronization state into an index batch supplementary transmission stage;
receiving interruption position information of the media server about cloud storage (a time point of last receiving a packet, storage position information at the device side of the last packet); requesting to acquire all grouping index information with cloud video marks from a local storage module by taking interrupt position information (a time point of last receiving a grouping and storage position information of the last grouping at an equipment end) as an initial condition, and acquiring in batches if the grouping index entries have huge data;
compressing and packaging the obtained grouped index list, sending the compressed grouped index list to a media server, and responding to a confirmation message after the media server receives the message;
sequentially sending the grouped index lists in batches, and entering a real-time synchronization stage until all grouped indexes are sent;
the media stream live broadcast module uploads live broadcast media stream data in real time, and the local storage module uploads storage index information of live broadcast media stream packets through a signaling channel.
In summary, the invention, through the preprocessing of the fragmentation, grouping and marking of the streaming media, not only makes the control of live broadcast, local video storage and cloud storage independent, but also can share one data source, thereby reducing the transmission redundancy of data; by dividing the data into two parts of indexes and data, when cloud storage is synchronized, the indexes are synchronized firstly, and then the data are synchronized, so that rapidness and integrity of data retrieval when a client accesses the cloud storage are guaranteed; the cloud storage data synchronization method in an on-demand mode ensures continuous transmission at any time at a breakpoint and maximum smooth network bandwidth, and can achieve real-time high-priority data which are urgently lost in synchronization when a client plays a cloud storage video.
The above-described embodiments do not limit the scope of the present invention. Any modification, equivalent replacement, and improvement made within the spirit and principle of the above-described embodiments should be included in the protection scope of the technical solution.

Claims (8)

1. A system for cloud storage synchronization of streaming media is characterized by comprising a network camera, a media server and a cloud storage server, wherein the network camera, the media server and the cloud storage server are interconnected through an IP network;
the network camera is used for generating media stream data and uploading the stream media data to the media server;
the media server is used for receiving the streaming media data uploaded by the network camera, screening the media streaming data required to be stored in the cloud storage and transferring the media streaming data to the cloud storage server; processing a playing request of a client;
the network camera comprises a media stream sampling module, a media stream local storage module, a media stream cloud storage management module, a media stream on-demand module and/or a media stream live broadcast module and a network camera central controller which is respectively connected with the media stream sampling module, the media stream local storage module, the media stream cloud storage management module, the media stream on-demand module and/or the media stream live broadcast module;
the media server comprises a cloud storage media channel management module, a cloud storage media stream storage management module, a cloud storage on-demand module and a media server central controller which is respectively connected with the cloud storage media channel management module, the cloud storage media stream storage management module and the cloud storage on-demand module;
the cloud storage server is used for providing streaming media data access and retrieval service in cloud storage;
the media stream sampling module is configured to:
collecting a media stream;
the media stream is processed by fragmentation and grouping, and the grouping is a set of fragments;
respectively setting characteristic marks on the fragments and numbering the fragments;
sending the fragments to a media stream live broadcast module and a media stream local storage module;
the feature mark is a cloud video mark; and the cloud video recording mark is used for marking whether the fragment is allowed to be uploaded to the cloud storage.
2. The system for streaming media cloud storage synchronization according to claim 1, wherein the media stream live broadcast module is configured to receive an input of the media stream sampling module, and upload a media stream to a media server or a playing client in real time according to a media stream live broadcast condition or a connection control requirement of the media stream cloud storage management module and a predetermined policy;
the established policy is:
the user broadcasts the missing data of the cloud storage video clip preferentially; or
New missing data takes precedence.
3. The system for cloud storage synchronization of streaming media as claimed in claim 1, wherein said media streaming live module is configured to use a channel in combination with a live media channel of cloud storage when live streaming is performed through the media server.
4. The system for streaming media cloud storage synchronization of claim 1, wherein the media stream local storage module: management for local storage media; the system is also used for writing the real-time media stream data into local storage or retrieving and extracting the stored media data; during storage, the media stream data are organized into a packet index part and a packet data part and then are stored respectively;
and/or the media stream on demand module: the management work of creating and deleting the media channel for on-demand; the media server is also used for retrieving media data meeting the conditions from the media stream local storage module according to the on-demand conditions and sending the media data to the client through an on-demand media channel or forwarding the media data through the media server; the media server synchronizes the missing media data in the cloud storage by using the on-demand module;
and/or the media stream cloud storage management module: for connection management, configuration management with the media server; storing a generation strategy of a cloud storage video mark; and the batch synchronization function of cloud storage missing data index information is realized.
5. The system for streaming media cloud storage synchronization of claim 1, wherein the cloud storage media channel management module: the system comprises a media server, a cloud storage media channel, a data sharing and distribution module, a data distribution module and a data distribution module, wherein the media server is used for storing media data and transmitting the media data to the cloud storage media channel; the media stream storage management module is also used for forwarding the media stream related to the cloud storage media stream storage management module;
the established policy is:
the user broadcasts the missing data of the cloud storage video clip preferentially; or
New missing data takes precedence;
and/or the cloud storage media stream storage management module: the integrity checking work for receiving the whole sequence and grouping of the cloud storage media stream fragments is carried out; the system is also used for writing the media stream into the cloud storage server according to the index and the data; the cloud storage system is also used for initiating synchronous retransmission management work of the cloud storage missing data;
and/or the cloud storage on-demand module: the method is used for on-demand playback of the cloud storage video; and the network camera equipment is also used for initiating a missing data on-demand request to the corresponding network camera equipment when the on-demand data only contains the index information and the corresponding data is not synchronized to the cloud storage.
6. The method for batch index retransmission of the network cameras of the streaming media cloud storage synchronization system according to any one of claims 1 to 5, comprising:
periodically attempting to connect with the media server;
after the connection is successful, sending a cloud storage batch index supplementary transmission request to the media server, attaching a formatting ID parameter of the current storage medium, and entering the cloud storage synchronization state into an index batch supplementary transmission stage;
receiving interruption position information of a media server about cloud storage and/or a time point of last receiving a packet and/or storage position information of the last packet at a device end; requesting a local storage module to acquire all grouping index information with cloud video marks by taking interrupt position information and/or a time point of receiving a grouping last and/or storage position information of the grouping last at an equipment end as initial conditions, compressing and packaging an acquired grouping index list, and then sending the compressed grouping index list to a media server, wherein the media server responds to a confirmation message after receiving the message;
sequentially sending the grouped index lists in batches, and entering a real-time synchronization stage until all grouped indexes are sent;
the media stream live broadcast module uploads live broadcast media stream data in real time, and the local storage module uploads storage index information of live broadcast media stream packets through a signaling channel.
7. The on-demand method for the cloud storage synchronization function of the streaming media cloud storage synchronization system according to any one of claims 1 to 5:
receiving a request for requesting, checking request parameters, finding that the request is a cloud storage synchronous request for requesting, extracting a formatting number and grouping position information, and recording the formatting number and the grouping position information in a request for requesting control block structure;
judging whether the formatting number is consistent with the formatting number of the local storage medium, if not, returning an error if the requested data is invalid; if the position information of the group is consistent with the position information of the group, the index information of the group is obtained; if the acquisition is failed, the grouped data are covered, the failure is returned, if the acquisition is successful, the fragmented data are read according to the index information, each fragment header information is uploaded through the cloud storage on-demand media channel and is filled with the fragment number, the group number and the group position information, and the server performs data integrity check through the group statistical information; if the media channel does not support the additional information, uploading the additional information through the media signaling channel;
reading the thumbnail fragment data, and uploading the thumbnail fragment data through a cloud storage on-demand media channel; filling fragment numbers and grouping position information during uploading, and marking thumbnail mark bits for the media server to identify the special fragments;
and closing the on-demand media channel until all the requested packets are uploaded.
8. The method for synchronizing the cloud storage missing data of the streaming media cloud storage synchronization system according to any one of claims 1 to 5, wherein the method comprises the following steps:
a user sends a cloud storage on-demand request and sends the on-demand request to a media server;
the media server searches for an index of the actual data in the cloud storage server, and sends a cloud storage on-demand request to the network camera according to a certain priority ordering strategy to synchronize the missing data;
the priority ordering policy of the missing data is as follows: the user broadcasts the missing data of the cloud storage video clip preferentially; new missing data takes precedence;
the network camera receives the cloud storage synchronous on-demand request and returns the information of the sending on-demand playing address to the media server;
the media server is connected with the playing address, establishes a playing media channel, plays on demand, and simultaneously proposes the index information of each packet from the playing stream and reassembles the packet data;
matching the indexes of the actual data, writing the data into the cloud storage server, and completing the updating synchronization work of the missing data.
CN201910733225.0A 2019-08-09 2019-08-09 System and method for streaming media cloud storage synchronization Active CN110430480B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910733225.0A CN110430480B (en) 2019-08-09 2019-08-09 System and method for streaming media cloud storage synchronization

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910733225.0A CN110430480B (en) 2019-08-09 2019-08-09 System and method for streaming media cloud storage synchronization

Publications (2)

Publication Number Publication Date
CN110430480A CN110430480A (en) 2019-11-08
CN110430480B true CN110430480B (en) 2022-02-18

Family

ID=68413504

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910733225.0A Active CN110430480B (en) 2019-08-09 2019-08-09 System and method for streaming media cloud storage synchronization

Country Status (1)

Country Link
CN (1) CN110430480B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111432151B (en) * 2020-01-20 2022-08-23 杭州海康威视数字技术股份有限公司 Video data storage method, device, equipment and storage medium
CN111629283B (en) * 2020-05-14 2023-04-07 武汉群宇科技有限公司 Multi-stream media gateway service system and method
CN112118085B (en) * 2020-09-01 2023-03-03 中国电子科技集团公司第二十八研究所 Reliable transmission device and method under short wave channel
CN114157678A (en) * 2020-09-08 2022-03-08 中国移动通信有限公司研究院 Data transmission method, terminal equipment and data storage system

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101754001A (en) * 2008-11-29 2010-06-23 华为技术有限公司 Video data priority confirming method, device and system
CN103136242A (en) * 2011-11-28 2013-06-05 上海可鲁系统软件有限公司 Method and device for storing and reading multi-source data index
CN105808589A (en) * 2014-12-31 2016-07-27 中国电信股份有限公司 File processing method and apparatus
CN106060173A (en) * 2016-07-22 2016-10-26 恒业智能信息技术(深圳)有限公司 Cluster type photographing data storage system based on cloud storage
CN107404525A (en) * 2017-07-24 2017-11-28 郑州云海信息技术有限公司 Video data access method, platform and system
CN107566321A (en) * 2016-06-30 2018-01-09 南京中兴新软件有限责任公司 The sending method of file, apparatus and system

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7962640B2 (en) * 2007-06-29 2011-06-14 The Chinese University Of Hong Kong Systems and methods for universal real-time media transcoding
US8896715B2 (en) * 2010-02-11 2014-11-25 Microsoft Corporation Generic platform video image stabilization
US8503539B2 (en) * 2010-02-26 2013-08-06 Bao Tran High definition personal computer (PC) cam
CN104469395B (en) * 2014-12-12 2017-11-07 华为技术有限公司 Image transfer method and device
US9993729B2 (en) * 2015-08-19 2018-06-12 Sony Interactive Entertainment America Llc User save data management in cloud gaming
CN106301708A (en) * 2016-07-28 2017-01-04 乐视控股(北京)有限公司 Processing method and processing device when a kind of information sends unsuccessfully

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101754001A (en) * 2008-11-29 2010-06-23 华为技术有限公司 Video data priority confirming method, device and system
CN103136242A (en) * 2011-11-28 2013-06-05 上海可鲁系统软件有限公司 Method and device for storing and reading multi-source data index
CN105808589A (en) * 2014-12-31 2016-07-27 中国电信股份有限公司 File processing method and apparatus
CN107566321A (en) * 2016-06-30 2018-01-09 南京中兴新软件有限责任公司 The sending method of file, apparatus and system
CN106060173A (en) * 2016-07-22 2016-10-26 恒业智能信息技术(深圳)有限公司 Cluster type photographing data storage system based on cloud storage
CN107404525A (en) * 2017-07-24 2017-11-28 郑州云海信息技术有限公司 Video data access method, platform and system

Also Published As

Publication number Publication date
CN110430480A (en) 2019-11-08

Similar Documents

Publication Publication Date Title
CN110430480B (en) System and method for streaming media cloud storage synchronization
JP3793941B2 (en) Video server device and video delivery method thereof in video delivery system
CN110489484B (en) Data synchronization method and device, readable storage medium and electronic equipment
CN110121059B (en) Monitoring video processing method, device and storage medium
RU2527210C1 (en) Method and system for transmitting data from web server to client terminal devices via wireless local area communication network
CN102550020A (en) Method for retransmission using checksums for identifying lost data packets
CN109634988B (en) Monitoring polling method and device
CN110519635B (en) Audio and video media stream converging method and system of wireless cluster system
CN110300120A (en) The hierarchical synchronization method and system of reverse data under the conditions of a kind of physical isolation
CN110381030B (en) Method and device for processing synchronization request
KR102035912B1 (en) Method And Apparatus for Repairing and Detecting Packet Loss
WO2014075453A1 (en) Method and system for frame loss control and retransmission in real-time streaming media uploading
CN111447392B (en) Data transmission method, device, server and computer readable storage medium
CN111629283B (en) Multi-stream media gateway service system and method
CN110545405A (en) video transmission method and system based on video network
CN110381128B (en) Uploading method and cloud storage model suitable for streaming media file
CN109802992B (en) Method and device for reading and writing resource change log
CN112601052A (en) Video resource integration system applied to internal sharing platform
CN110012063B (en) Data packet processing method and system
CN109587524B (en) Method and device for synchronizing video networking resources to Internet terminal
CN109802990B (en) Resource log reading and writing method and device for reducing data redundancy
CN102438182A (en) Method and device for analyzing video stream
EP2106640B1 (en) Method for packet-switching transmission of media data and device for processing media data
CN110691214B (en) Data processing method and device for business object
CN110557611B (en) Information synchronization method, device and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant