CN113852593B - Deployment system and method for distributed streaming media cluster - Google Patents

Deployment system and method for distributed streaming media cluster Download PDF

Info

Publication number
CN113852593B
CN113852593B CN202110819201.4A CN202110819201A CN113852593B CN 113852593 B CN113852593 B CN 113852593B CN 202110819201 A CN202110819201 A CN 202110819201A CN 113852593 B CN113852593 B CN 113852593B
Authority
CN
China
Prior art keywords
streaming media
stream
streaming
media service
service instance
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
CN202110819201.4A
Other languages
Chinese (zh)
Other versions
CN113852593A (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.)
Inspur Communication Technology Co Ltd
Original Assignee
Inspur Software 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 Inspur Software Technology Co Ltd filed Critical Inspur Software Technology Co Ltd
Priority to CN202110819201.4A priority Critical patent/CN113852593B/en
Publication of CN113852593A publication Critical patent/CN113852593A/en
Application granted granted Critical
Publication of CN113852593B publication Critical patent/CN113852593B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/60Network streaming of media packets
    • H04L65/75Media network packet handling
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/40Support for services or applications

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The invention provides a deployment system and a deployment method of a distributed streaming media cluster, which relate to the technical field of multimedia, wherein the system comprises: the second streaming media cluster is deployed in the first streaming media cluster, and the service address of the streaming media service is one; the streaming media service instance which is pushed out analyzes a corresponding pulling address according to the pushing address when the media stream sender pushes out stream, and sends the pulling address to the second streaming media cluster; the pulled streaming media service instance acquires the actual pushing streaming media service instance corresponding to the pulling address when the media stream sender pulls the streaming media through the second streaming media cluster, pulls the media stream from the actual pushing streaming media service instance, and pushes the pulled media stream to the media stream receiver.

Description

Deployment system and method for distributed streaming media cluster
Technical Field
The invention relates to the technical field of multimedia, in particular to a system and a method for deploying a distributed streaming media cluster.
Background
Today, where video monitoring applications are popular, the requirement of accessing tens of thousands of network cameras and simultaneously meeting the requirement of thousands of people for real-time audio and video on demand is increasing, which requires distributed and clustered deployment for streaming media services, and dynamic expansion and fault tolerance recovery is achieved, for example, using a container arrangement platform Kubernetes and a coordination service Zookeeper providing distributed synchronization. The Kubernetes, abbreviated as K8s, is an open source and is used for managing containerized applications on multiple hosts in a cloud platform, and the purpose of the Kubernetes is to enable the containerized applications to be deployed simply and efficiently, and the Kubernetes provides a mechanism for application deployment, planning, updating and maintenance. The ZooKeeper is a distributed, open source distributed application coordination service, is an open source implementation of Chubbby, is an important component of Hadoop and Hbase, is software for providing consistency service for distributed application, and provides functions including: configuration maintenance, domain name service, distributed synchronization, group service, etc.
However, when a plurality of streaming media Service instances, for example, four streaming media Service instances A, B, C, D, are deployed in a Kubernetes cluster, as shown in fig. 1, each streaming media Service instance uniformly distributes services to the outside through a streaming media Service (Service), a media stream sender pushes a real-time media stream to a streaming media Service instance B, but when a media stream receiver makes a stream pulling request through a stream pulling address, the streaming media Service routes the request to a streaming media Service instance D, that is, the media Service instance actually pushed is not the same as the media Service instance receiving the stream pulling request of the user, so that a situation that the media stream receiver cannot pull the stream occurs.
In order to solve the above problem that the media stream receiver cannot pull the stream when deploying a plurality of streaming media service instances, a new deployment architecture of the distributed streaming media cluster needs to be proposed.
Disclosure of Invention
The invention provides a deployment system and a deployment method of a distributed streaming media cluster, which are used for solving the defect that a streaming receiver cannot pull a stream when a plurality of streaming media service examples are deployed in the prior art, and realizing the purposes of considering the elasticity expansion, fault tolerance recovery and stability and practicability of a video monitoring system.
The invention provides a deployment system of a distributed streaming media cluster, which comprises the following components: a media stream sender, a media stream receiver and a first streaming media cluster, wherein streaming media service and a plurality of streaming media service instances are deployed in the first streaming media cluster, each streaming media service instance externally issues service through the streaming media service, the media stream sender pushes media stream to the streaming media service instance through the streaming media service, and the media stream receiver pulls media stream from the streaming media service instance through the streaming media service, and the method further comprises the following steps:
the second streaming media cluster is deployed in the first streaming media cluster, and the service address of the streaming media service is one;
the streaming media service instance which is pushed analyzes a corresponding pulling address according to a pushing address when the media stream sender pushes the stream, and sends the pulling address to the second streaming media cluster;
the pulled streaming media service instance obtains the actual pushed streaming media service instance corresponding to the pulling address when the media stream sender pulls the streaming media through the second streaming media cluster, pulls the media stream from the actual pushed streaming media service instance by the pulled streaming media service instance, and pushes the pulled media stream to the media stream receiver, wherein the actual pushed streaming media service instance is the pushed streaming media service instance when the media stream sender pushes, or is the idle and online streaming media service instance.
According to the deployment system of the distributed streaming media cluster, the streaming media service instance obtains the address and the corresponding mapping relation between the streaming addresses, and sends the streaming addresses and the mapping relation to the second streaming media cluster.
According to the deployment system of the distributed streaming media cluster, the pull stream address and the mapping relation are sent to the second streaming media cluster in the form of JSON format data, and the second streaming media cluster stores the JSON format data.
According to the deployment system of the distributed streaming media cluster, the media stream sender pushes the streaming media stream to the streaming media service through the push address, and pushes the media stream to one of the online streaming media service instances through the forwarding of the streaming media service, and the pushed streaming media service instance analyzes the corresponding pull address according to the push address when the media stream sender pushes the streaming media stream.
According to the deployment system of the distributed streaming media cluster, the streaming media receiver pulls streaming media from the streaming media service through the pulling address, and pulls media stream from one online streaming media service instance through forwarding of the streaming media service;
when the pulled streaming media service instance is the streaming media service instance of the actual push stream, the pulled streaming media service instance pushes a media stream to the media stream receiver through forwarding of the streaming media service;
when the pulled streaming media service instance is not the streaming media service instance of the actual push stream, the pulled streaming media service instance pulls a media stream from the streaming media service instance of the actual push stream, and pushes the pulled media stream to the media stream receiver through forwarding of the streaming media service.
According to the deployment system of the distributed streaming media cluster, the first streaming media cluster adopts a Kubernetes cluster.
According to the deployment system of the distributed streaming media cluster, the second streaming media cluster adopts a Zookeeper cluster.
According to the deployment system of the distributed streaming media cluster, the type of the streaming media service adopts a load equalizer.
According to the deployment system of the distributed streaming media cluster, the streaming media service acquires a streaming request from the media streaming receiver, forwards the streaming request to one of the online streaming media service instances through a load balancing algorithm, and pushes the media streaming to the media streaming receiver.
The invention also provides a deployment method of the distributed streaming media cluster, which comprises the following steps:
the media stream sender pushes stream to the streaming media service through a push stream address, and pushes the media stream to one of the online streaming media service instances through forwarding of the streaming media service;
the streaming media service instance which is pushed analyzes a corresponding pulling address according to a pushing address when the media stream sender pushes, acquires the address of the streaming media service instance and a mapping relation between the pulling addresses, and sends the pulling address and the mapping relation to the second streaming media cluster;
the media stream receiver pulls a stream from the streaming media service through a pulling address and pulls a media stream from one of the online streaming media service instances through forwarding of the streaming media service;
the second streaming media cluster obtains the streaming media service instance of the actual push stream corresponding to the pull stream address when the streaming media receiver pulls the stream, and judges whether the streaming media service instance which is pulled is the streaming media service instance of the actual push stream;
when the pulled streaming media service instance is the streaming media service instance of the actual push stream, the pulled streaming media service instance pushes a media stream to the media stream receiver through forwarding of the streaming media service;
when the pulled streaming media service instance is not the streaming media service instance of the actual push stream, the pulled streaming media service instance pulls a media stream from the streaming media service instance of the actual push stream, and pushes the pulled media stream to the media stream receiver through forwarding of the streaming media service.
The invention also provides an electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the steps of the deployment method of the distributed streaming media cluster are realized when the processor executes the program.
The present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the method of deployment of a distributed streaming media cluster as described in any of the above.
The invention provides a deployment system and a method of a distributed streaming media cluster, which provide a non-perception streaming forwarding service for users, and the deployment system and the method of the distributed streaming media cluster provide a non-perception streaming forwarding service for users, analyze a corresponding streaming address of a streaming media service instance in a streaming media sender streaming process by deploying a second streaming media service cluster in the first streaming media cluster, acquire a mapping relation between the streaming address and the streaming media service instance address, store the streaming media service instance address through the second streaming media cluster, acquire the streaming media service instance address of an actual streaming media according to the streaming address when a streaming media streaming receiver pulls a streaming media stream, further know which streaming media service instance is actually pushed, directly push a real-time media stream or pull a media stream from the streaming media service instance of the actual streaming media stream by the streaming media service instance, push the pulled media stream to the streaming media stream receiver, realize the distributed cluster deployment of the streaming media service instance, solve the problem that the streaming media instance is not pushed by the streaming media service instance in a cluster environment, and realize the fact that the streaming media instance is not pushed by the streaming media stream by the streaming address, and provide a better flexible and more stable monitoring system for the cloud-based on the cloud monitoring system.
Drawings
In order to more clearly illustrate the invention or the technical solutions of the prior art, the following description will briefly explain the drawings used in the embodiments or the description of the prior art, and it is obvious that the drawings in the following description are some embodiments of the invention, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic diagram of a media stream receiver acquiring a media stream sent by a media stream sender when deploying a plurality of streaming media service instances in the prior art;
fig. 2 is a schematic structural diagram of a deployment system of a distributed streaming media cluster according to the present invention;
FIG. 3 is a schematic diagram of a media stream receiver acquiring a media stream sent by a media stream sender in a distributed streaming media cluster deployment system provided by the present invention;
fig. 4 is a flow chart of a deployment method of a distributed streaming media cluster provided by the invention;
fig. 5 is a schematic structural diagram of an electronic device provided by the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The deployment system of the distributed streaming media cluster according to the present invention will be described below with reference to fig. 2 and 3, where the system includes not only the streaming media sender 100, the streaming media receiver 200, and the first streaming media cluster 300 shown in fig. 1, where the streaming media service 310 and the plurality of streaming media service instances 320 are deployed in the first streaming media cluster 300, specifically, when at least two streaming media service instances 320 are deployed in the first streaming media cluster 300, the number of streaming media service instances 320 is related to the number of access paths of the network camera, each streaming media service instance 320 issues a service to the outside through the streaming media service 310, the streaming media sender 100 pushes a media stream to the streaming media service instance 320 through the streaming media service 310, and the streaming media receiver 200 pulls the media stream from the streaming media service instance 320 through the streaming media service 310, and further includes:
the second streaming media cluster 330 deployed in the first streaming media cluster 300 has one service address of the streaming media service 310, that is, the streaming media service 320 is exposed to the outside, and for the media streaming sender 100 and the media streaming receiver 200, there is only one service address of the streaming media service 310.
The pushed streaming service instance 320 resolves a corresponding pull address according to the push address when the media stream sender 100 performs push, and sends the pull address to the second streaming media cluster 330. The method comprises the following specific steps: the media stream sender 100 pushes the media stream to the streaming media service 310 through the push address, and pushes the media stream to one of the online streaming media service instances 320 through forwarding of the streaming media service 310, and the pushed streaming media service instance 320 analyzes the corresponding pull address according to the push address when the media stream sender 100 pushes.
Meanwhile, in this process, the streaming media service instance 320 obtains the mapping relationship between the address and the corresponding streaming address, and sends the streaming address and the mapping relationship to the second streaming media cluster 330.
In this embodiment, the pull address and the mapping relationship are sent to the second streaming media cluster 330 as JSON format data, and the second streaming media cluster 330 stores the JSON format data.
JSON (JavaScript Object Notation) is a lightweight data exchange format, which is based on a subset of the object profile specifications (ECMAScript) formulated by the european computer institute, and uses a text format that is completely independent of the programming language to store and represent data, and the concise and clear hierarchical structure makes JSON an ideal data exchange language, easy for a person to read and write, and easy for a machine to parse and generate, and effectively improves network transmission efficiency.
The pulled streaming media service instance 320 obtains, through the second streaming media cluster 330, the actual pushed streaming media service instance 320 corresponding to the pulling address when the media streaming sender 100 pulls, the pulled streaming media service instance 320 pulls the media stream from the actual pushed streaming media service instance 320, and pushes the pulled media stream to the media streaming receiver 200, where the actual pushed streaming media service instance 320 is the pushed streaming media service instance 320 when the media streaming sender 100 pulls, or is the idle and online streaming media service instance 320. The method comprises the following specific steps: the media stream receiver 200 pulls the media stream from the streaming media service 310 through the pull address and from one of the online streaming media service instances 320 through forwarding of the streaming media service 310;
wherein, when the pulled streaming media service instance 320 is the streaming media service instance 320 of the actual push stream, the pulled streaming media service instance 320 pushes the media stream to the media stream receiver 200 through the forwarding of the streaming media service 310;
when the pulled streaming media service instance 320 is not the actual push streaming media service instance 320, the pulled streaming media service instance 320 pulls a media stream from the actual push streaming media service instance 320 and pushes the pulled media stream to the media stream receiver 200 through forwarding by the streaming media service 310.
In this embodiment, the first streaming media cluster 300 adopts a Kubernetes cluster, the second streaming media cluster 330 adopts a Zookeeper cluster, wherein the Kubernetes cluster provides automatic deployment, capacity expansion, fault tolerance, health check and anomaly recovery of the Zookeeper cluster and the streaming media Service cluster, and meanwhile, a Service component is used as the streaming media Service 310 to provide Service registration and discovery, automatic routing and load balancing, in this embodiment, the type of the streaming media Service 310 adopts a load balancer (LoadBalancer), so that the streaming media Service 310 obtains a pull stream request from the media stream receiver 200 and forwards the pull stream request to one of the online streaming media Service instances 320 through a load balancing algorithm, and the streaming media Service instance 320 pushes a media stream to the media stream receiver 200 to become the streaming media Service instance 320 which is eventually pushed to the media stream receiver 200, and when the streaming media Service instance 320 is not actually pushed, but is a streaming media Service instance 320 for streaming media transfer; the Zookeeper cluster provides a configuration center function, saves mapping relation data between a pull stream address and an address of a streaming media service instance 320, and simultaneously provides synchronous data configuration for each streaming media service instance 320; the streaming media cluster is responsible for providing a push address for the media stream sender 100 and a pull address for the media stream receiver 200, so as to forward the media stream sent by the media stream sender 100 to the media stream receiver 200; media stream sender 100 includes webcams, webcams (Network Video Recorder, NVR), other platforms, etc.; the media stream receiver 200 represents a user audio and video monitoring on-demand terminal, etc.
According to the deployment system of the distributed streaming media cluster, a non-perceived streaming forwarding service is provided for a user, a streaming address corresponding to a streaming media service instance 320 in a streaming process of a media streaming sender 100 is analyzed through a second streaming media service cluster 330 in the first streaming media cluster 300, a mapping relation between the streaming address and the streaming media service instance 320 address is obtained, the streaming media service is stored through the second streaming media cluster 330, then when the streaming is carried out by a media streaming receiver 200, the streaming media service instance 320 address of an actual streaming is obtained according to the streaming address when the streaming receiver 200 pulls a streaming, and then the streaming media instance 320 which is actually pushed is known, the streaming media instance 320 which is actually pushed is the bottom, the streaming media instance 320 which is currently pulled is directly pushed by the streaming media instance 320 which is actually pushed by the streaming media instance, the streaming media instance 310 is pushed by the streaming media instance, the streaming media instance 320, the streaming media is distributed and the streaming media service is deployed to a streaming media receiver 200, and the problem that the streaming media instance is not actually pushed by the streaming media instance in the streaming environment is better than the streaming media instance which is actually pushed by the streaming media instance, and the streaming media instance is better in a streaming environment, and the monitoring system is more flexible and the stability is better, and the stability is better is achieved, and the system is not supported by the monitoring system.
The deployment method of the distributed streaming media cluster of the present invention is described below with reference to fig. 4, and includes the following steps:
s100, the media stream sender 100 pushes a stream to the streaming media service 310 through the push address, and pushes the media stream to one of the online streaming media service instances 320 through forwarding of the streaming media service 310.
S200, the streaming media service instance 320 of the pushed stream analyzes the corresponding pulling address according to the pushing address when the media stream sender 100 pushes the stream, and the streaming media service instance 320 obtains the mapping relationship between the address and the corresponding pulling address and sends the pulling address and the mapping relationship to the second streaming media cluster 330.
S300, the media stream receiver 200 pulls the media stream from the streaming service 310 through the pulling address, and pulls the media stream from one of the online streaming service instances 320 through forwarding of the streaming service 310.
S400, the second streaming media cluster 330 acquires the streaming media service instance 320 of the actual push corresponding to the pull address when the streaming media receiver 200 pulls, and determines whether the pulled streaming media service instance 320 is the streaming media service instance 320 of the actual push.
S500, when the pulled streaming media service instance 320 is the streaming media service instance 320 that is actually pushed, the pulled streaming media service instance 320 pushes the media stream to the media stream receiver 200 through forwarding of the streaming media service 310.
S600, when the pulled streaming media service instance 320 is not the streaming media service instance 320 actually pushed, the pulled streaming media service instance 320 pulls the media stream from the streaming media service instance 320 actually pushed, and pushes the pulled media stream to the media stream receiver 200 through forwarding of the streaming media service 310.
According to the distributed streaming media cluster deployment system, a non-perceived streaming media forwarding service is provided for a user, a corresponding streaming address of a streaming media service instance 320 in a streaming media sender 100 streaming process is analyzed through the step S200, a mapping relation between the streaming address and the streaming media service instance 320 address is obtained and stored through the second streaming media service cluster 330, then in the step S400, the streaming media service instance 320 address of an actual streaming media is obtained according to the streaming address when a media stream receiver 200 pulls streaming, and then the streaming media service instance 320 which is actually pushed at the bottom is known, a corresponding step S500 or a corresponding step S600 is executed, distributed cluster deployment of streaming media service is realized, the problem that real-time media stream cannot be forwarded when the actual streaming media service instance is not the same streaming media service instance which is pushed in a cluster environment is solved, and the flexible expansion, the fault-tolerant recovery and the stability of a video monitoring system are considered, and the practicability are better provided for the cloud side integrated video monitoring system for constructing a great number of paths.
Fig. 5 illustrates a physical schematic diagram of an electronic device, as shown in fig. 5, which may include: processor 810, communication interface (Communications Interface) 820, memory 830, and communication bus 840, wherein processor 810, communication interface 820, memory 830 accomplish communication with each other through communication bus 840. Processor 810 may invoke logic instructions in memory 830 to perform a method of deployment of a distributed streaming media cluster, the method comprising the steps of:
s100, the media stream sender 100 pushes stream to the streaming media service 310 through a push address, and pushes media stream to one of the online streaming media service instances 320 through forwarding of the streaming media service 310;
s200, the streaming media service instance 320 which is pushed analyzes a corresponding pulling address according to a pushing address when the media stream sender 100 pushes, the streaming media service instance 320 obtains the address and a mapping relation between the corresponding pulling addresses, and sends the pulling address and the mapping relation to the second streaming media cluster 330;
s300, the media stream receiver 200 pulls a stream from the streaming media service 310 through a pulling address, and pulls a media stream from one of the online streaming media service instances 320 through forwarding of the streaming media service 310;
s400, the second streaming media cluster 330 acquires the streaming media service instance 320 of the actual push corresponding to the pull address when the streaming media receiver 200 pulls the stream, and determines whether the streaming media service instance 320 being pulled is the streaming media service instance 320 of the actual push;
s500, when the pulled streaming media service instance 320 is the streaming media service instance 320 that is actually pushed, the pulled streaming media service instance 320 pushes a media stream to the media stream receiver 200 through forwarding of the streaming media service 310;
s600, when the pulled streaming media service instance 320 is not the streaming media service instance 320 actually pushed, the pulled streaming media service instance 320 pulls a media stream from the streaming media service instance 320 actually pushed, and pushes the pulled media stream to the media stream receiver 200 through forwarding of the streaming media service 310.
Further, the logic instructions in the memory 830 described above may be implemented in the form of software functional units and may be stored in a computer-readable storage medium when sold or used as a stand-alone product. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
In another aspect, the present invention also provides a computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions which, when executed by a computer, enable the computer to perform a method of deploying a distributed streaming media cluster provided by the methods described above, the method comprising the steps of:
s100, the media stream sender 100 pushes stream to the streaming media service 310 through a push address, and pushes media stream to one of the online streaming media service instances 320 through forwarding of the streaming media service 310;
s200, the streaming media service instance 320 which is pushed analyzes a corresponding pulling address according to a pushing address when the media stream sender 100 pushes, the streaming media service instance 320 obtains the address and a mapping relation between the corresponding pulling addresses, and sends the pulling address and the mapping relation to the second streaming media cluster 330;
s300, the media stream receiver 200 pulls a stream from the streaming media service 310 through a pulling address, and pulls a media stream from one of the online streaming media service instances 320 through forwarding of the streaming media service 310;
s400, the second streaming media cluster 330 acquires the streaming media service instance 320 of the actual push corresponding to the pull address when the streaming media receiver 200 pulls the stream, and determines whether the streaming media service instance 320 being pulled is the streaming media service instance 320 of the actual push;
s500, when the pulled streaming media service instance 320 is the streaming media service instance 320 that is actually pushed, the pulled streaming media service instance 320 pushes a media stream to the media stream receiver 200 through forwarding of the streaming media service 310;
s600, when the pulled streaming media service instance 320 is not the streaming media service instance 320 actually pushed, the pulled streaming media service instance 320 pulls a media stream from the streaming media service instance 320 actually pushed, and pushes the pulled media stream to the media stream receiver 200 through forwarding of the streaming media service 310.
In yet another aspect, the present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, is implemented to perform the above-described method of deploying distributed streaming media clusters, the method comprising the steps of:
s100, the media stream sender 100 pushes stream to the streaming media service 310S100 through a push address, the media stream sender 100 pushes stream to the streaming media service 310 through the push address, and pushes media stream to one of the online streaming media service instances 320 through forwarding of the streaming media service 310;
s200, the streaming media service instance 320 which is pushed analyzes a corresponding pulling address according to a pushing address when the media stream sender 100 pushes, the streaming media service instance 320 obtains the address and a mapping relation between the corresponding pulling addresses, and sends the pulling address and the mapping relation to the second streaming media cluster 330;
s300, the media stream receiver 200 pulls a stream from the streaming media service 310 through a pulling address, and pulls a media stream from one of the online streaming media service instances 320 through forwarding of the streaming media service 310;
s400, the second streaming media cluster 330 acquires the streaming media service instance 320 of the actual push corresponding to the pull address when the streaming media receiver 200 pulls the stream, and determines whether the streaming media service instance 320 being pulled is the streaming media service instance 320 of the actual push;
s500, when the pulled streaming media service instance 320 is the streaming media service instance 320 that is actually pushed, the pulled streaming media service instance 320 pushes a media stream to the media stream receiver 200 through forwarding of the streaming media service 310;
s600, when the pulled streaming media service instance 320 is not the streaming media service instance 320 actually pushed, the pulled streaming media service instance 320 pulls a media stream from the streaming media service instance 320 actually pushed, and pushes the pulled media stream to the media stream receiver 200 through forwarding of the streaming media service 310.
The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
From the above description of the embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus necessary general hardware platforms, or of course may be implemented by means of hardware. Based on this understanding, the foregoing technical solution may be embodied essentially or in a part contributing to the prior art in the form of a software product, which may be stored in a computer readable storage medium, such as ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method described in the respective embodiments or some parts of the embodiments.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present invention, and are not limiting; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. A deployment system of a distributed streaming media cluster, comprising: a media stream sender (100), a media stream receiver (200) and a first streaming media cluster (300), wherein the first streaming media cluster (300) is configured with a streaming media service (310) and a plurality of streaming media service instances (320), each streaming media service instance (320) issues services to the outside through the streaming media service (310), the media stream sender (100) pushes a media stream to the streaming media service instance (320) through the streaming media service (310), and the media stream receiver (200) pulls the media stream from the streaming media service instance (320) through the streaming media service (310), and the method is characterized by further comprising:
-a second streaming media cluster (330) deployed within said first streaming media cluster (300), and wherein the service address of said streaming media service (310) is one;
the streaming media service instance (320) which is pushed analyzes a corresponding pulling address according to a pushing address when the media stream sender (100) pushes, and sends the pulling address to the second streaming media cluster (330);
the pulled streaming media service instance (320) obtains, through the second streaming media cluster (330), the streaming media service instance (320) of the actual push stream corresponding to the pull stream address when the media stream sender (100) pulls the streaming media, the pulled streaming media service instance (320) pulls the media stream from the streaming media service instance (320) of the actual push stream, and pushes the pulled media stream to the media stream receiver (200), where the streaming media service instance (320) of the actual push stream is the streaming media service instance (320) of the pushed stream when the media stream sender (100) pulls, or is the streaming media service instance (320) that is idle and online.
2. The deployment system of a distributed streaming media cluster according to claim 1, wherein the streaming media service instance (320) obtains a mapping relationship between a streaming media service instance address and the corresponding streaming address, and sends the streaming address and the mapping relationship to the second streaming media cluster (330).
3. The deployment system of distributed streaming media clusters according to claim 2, wherein the pull addresses and the mapping relationship are sent to the second streaming media cluster (330) in JSON format data, and the second streaming media cluster (330) stores the JSON format data.
4. The deployment system of a distributed streaming media cluster according to claim 2, wherein the media stream sender (100) pushes a stream to the streaming media service (310) through a push address, and pushes a media stream to one of the online streaming media service instances (320) through forwarding of the streaming media service (310), and the pushed streaming media service instance (320) resolves a corresponding pull address according to the push address when the media stream sender (100) performs push.
5. The deployment system of a distributed streaming media cluster according to claim 2, wherein the media stream receiver (200) pulls a stream from the streaming media service (310) through a pull stream address and pulls a media stream from one of the online streaming media service instances (320) through forwarding of the streaming media service (310);
wherein when the streaming media service instance (320) being pulled is the streaming media service instance (320) being actually pushed, the streaming media service instance (320) being pulled pushes a media stream to the media stream receiver (200) through forwarding of the streaming media service (310);
when the streamed streaming service instance (320) is not the streaming media service instance (320) of the actual push, the streamed streaming service instance (320) pulls media streams from the streaming media service instance (320) of the actual push and pushes the pulled media streams to the media stream receiver (200) through forwarding of the streaming media service (310).
6. The distributed streaming media cluster deployment system of claim 1, wherein the first streaming media cluster (300) employs a Kubernetes cluster.
7. The distributed streaming media cluster deployment system of claim 1, wherein the second streaming media cluster (330) employs a Zookeeper cluster.
8. The distributed streaming media cluster deployment system of claim 1, wherein the streaming media service (310) is of a type employing a load balancer.
9. The distributed streaming media cluster deployment system of claim 8, wherein the streaming media service (310) obtains a pull request from the media streaming receiver (200) and forwards the pull request to one of the online streaming media service instances (320) through a load balancing algorithm, the streaming media service instance (320) pushing a media stream to the media streaming receiver (200).
10. A method for deploying a distributed streaming media cluster implemented by a deployment system based on the distributed streaming media cluster according to any one of claims 1-9, comprising the steps of:
-said media stream sender (100) pushing a stream to said streaming media service (310) by means of a push address and pushing a media stream to one of said online streaming media service instances (320) by means of forwarding of said streaming media service (310);
the streaming media service instance (320) which is pushed analyzes a corresponding pulling address according to a pushing address when the media stream sender (100) pushes, the streaming media service instance (320) obtains a mapping relation between the streaming media service instance address and the corresponding pulling address, and sends the pulling address and the mapping relation to the second streaming media cluster (330);
-the media stream receiver (200) pulls a stream from the streaming media service (310) by means of a pull address and pulls a media stream from one of the online streaming media service instances (320) by means of forwarding of the streaming media service (310);
the second streaming media cluster (330) obtains the streaming media service instance (320) of the actual push stream corresponding to the pull stream address when the media stream receiver (200) pulls the stream, and judges whether the streaming media service instance (320) which is pulled is the streaming media service instance (320) of the actual push stream;
when the streaming media service instance (320) being pulled is the streaming media service instance (320) being actually pushed, the streaming media service instance (320) being pulled pushes a media stream to the media stream receiver (200) through forwarding of the streaming media service (310);
when the streamed streaming service instance (320) is not the streaming media service instance (320) of the actual push, the streamed streaming service instance (320) pulls media streams from the streaming media service instance (320) of the actual push and pushes the pulled media streams to the media stream receiver (200) through forwarding of the streaming media service (310).
CN202110819201.4A 2021-07-20 2021-07-20 Deployment system and method for distributed streaming media cluster Active CN113852593B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110819201.4A CN113852593B (en) 2021-07-20 2021-07-20 Deployment system and method for distributed streaming media cluster

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110819201.4A CN113852593B (en) 2021-07-20 2021-07-20 Deployment system and method for distributed streaming media cluster

Publications (2)

Publication Number Publication Date
CN113852593A CN113852593A (en) 2021-12-28
CN113852593B true CN113852593B (en) 2023-07-11

Family

ID=78975133

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110819201.4A Active CN113852593B (en) 2021-07-20 2021-07-20 Deployment system and method for distributed streaming media cluster

Country Status (1)

Country Link
CN (1) CN113852593B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106850581A (en) * 2017-01-04 2017-06-13 网宿科技股份有限公司 The distribution backup method of interactive live broadcast stream media data, system and server
WO2017096841A1 (en) * 2015-12-07 2017-06-15 乐视控股(北京)有限公司 Stream pulling control method, device and system
CN109450911A (en) * 2018-11-26 2019-03-08 武汉虹信技术服务有限责任公司 A kind of across a network stream medium data transmission system and method
CN111355971A (en) * 2020-02-20 2020-06-30 北京金山云网络技术有限公司 Live streaming transmission method and device, CDN server and computer readable medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017096841A1 (en) * 2015-12-07 2017-06-15 乐视控股(北京)有限公司 Stream pulling control method, device and system
CN106850581A (en) * 2017-01-04 2017-06-13 网宿科技股份有限公司 The distribution backup method of interactive live broadcast stream media data, system and server
CN109450911A (en) * 2018-11-26 2019-03-08 武汉虹信技术服务有限责任公司 A kind of across a network stream medium data transmission system and method
CN111355971A (en) * 2020-02-20 2020-06-30 北京金山云网络技术有限公司 Live streaming transmission method and device, CDN server and computer readable medium

Also Published As

Publication number Publication date
CN113852593A (en) 2021-12-28

Similar Documents

Publication Publication Date Title
US10158557B2 (en) Stream creation with limited topology information
US20140164477A1 (en) System and method for providing horizontal scaling of stateful applications
US20090319686A1 (en) Communication route selecting method and apparatus
CN105656653A (en) Network access method of newly added node in distributed coordination system, device and system
US9094270B2 (en) Content transmission architecture
CN105281947A (en) Techniques for transforming legacy networks into SDN-enabled networks
US20110246658A1 (en) Data exchange optimization in a peer-to-peer network
US20170257289A1 (en) Method and system to dynamically enable sdn network learning capability in a user-defined cloud network
CN109379209B (en) Method and device for upgrading storage service of video network
US20120096136A1 (en) Method and apparatus for sharing contents using information of group change in content oriented network environment
CN105376292A (en) Explicit strategy feedback in name-based forwarding
CN101662508B (en) Method for data transmission based on point-to-point protocol, device and system thereof
US20150127721A1 (en) Server network address selection based on network characteristics of service providers
CN107959704B (en) Data processing method and home gateway
US20200099735A1 (en) System and method for mesh network streaming
US20220070507A1 (en) Method for distributing audio/video stream in audio/video stream distribution system, and dynamic parent node
CN113852593B (en) Deployment system and method for distributed streaming media cluster
CN109768957A (en) A kind of processing method and system of monitoring data
CN110187903A (en) A kind of upgrade method and device
US8630186B2 (en) Systems and methods for transmission of trigger-based alarm indication suppression messages
CN106878826B (en) Method for forwarding P2P-like real-time video
US20120216233A1 (en) Virtual network constructing apparatus and method
CN114710680B (en) Distributed server cluster for video encoding and decoding
US11863592B2 (en) Active speaker tracking using a global naming scheme
CN110418101B (en) Information sharing method and device

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
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20240905

Address after: 266107 No. 2, Xiangtan Road, Danshan Industrial Park, Chengyang District, Qingdao, Shandong

Patentee after: Inspur Communication Technology Co.,Ltd.

Country or region after: China

Address before: 250100 building S02, Inspur Science Park, No. 1036, Inspur Road, high tech Zone, Jinan, Shandong

Patentee before: Inspur Software Technology Co.,Ltd.

Country or region before: China