Live broadcast service system and live broadcast connection establishment methodTechnical Field
The invention relates to the technical field of communication, in particular to a live broadcast server system and a live broadcast connection establishing method.
Background
In the network live broadcast field, audiences can enjoy live broadcast programs of different anchor broadcasters through corresponding live broadcast application software and interact with the anchor broadcasters.
In order to realize the interaction between the audience and the anchor, a connection between the audience and the anchor to be connected needs to be established first, generally, since live broadcast has real-time performance, the media server allocated to the anchor is dynamically changed, that is, the anchor reallocates the media server every live broadcast, and therefore, the connection process between the audience and the anchor to be connected can be described as follows: the audience terminal initiates a network request through the signaling channel to firstly obtain the media information (IP address and service port) of the media server corresponding to the anchor to be connected from the media front-end server, and then the audience terminal establishes connection with the media server based on the media information. After the connection is established, the audience terminal can present the live broadcast content corresponding to the anchor to be connected.
In order to improve the user experience of the audience, the live content requires the presentation of the second time at the audience, however, the above description can see that the time consumption from the request initiation to the live picture presentation at the audience is mainly divided into three parts: 1. a spectator end acquires media information required by connecting a media server; 2. establishing connection with a media server according to the media information; 3. and receiving and displaying the media stream data pushed by the media server. The first of the three parts takes up to 600ms, which is more than half of the time for the presentation of the entire live content, and thus presents a great challenge for realizing the second of the entire live content.
Disclosure of Invention
The embodiment of the invention provides a live broadcast service system and a live broadcast connection establishing method, and effectively shortens the connection time consumption of the connection between an intelligent terminal and a media server corresponding to a to-be-connected anchor when the live broadcast connection of the intelligent terminal is realized through the live broadcast service system.
In a first aspect, an embodiment of the present invention provides a live broadcast service system, including:
the media server farm includes at least one media server and a guidance process associated with each of the media servers;
and the guiding process is used for determining a target media server corresponding to the anchor to be connected included in the access request after receiving the access request of the intelligent terminal, and establishing the connection between the target media server and the intelligent terminal.
In a second aspect, an embodiment of the present invention provides a method for establishing a live broadcast connection, where the method is executed by the live broadcast service system provided in the first aspect of the present invention, and includes:
the intelligent terminal generates an access request after determining the anchor to be connected and sends the access request to a guide process corresponding to the pre-acquired guide process address;
and after receiving an access request of the intelligent terminal, the guiding process determines a target media server corresponding to the anchor to be connected from the same media server group and establishes the connection between the target media server and the intelligent terminal.
In the above-mentioned live broadcast service system and the establishment method of live broadcast connection, the live broadcast service system specifically includes: the media server farm includes at least one media server and a guidance process associated with each of the media servers; and the guiding process is used for determining a target media server corresponding to the anchor to be connected included in the access request after receiving the access request of the intelligent terminal, and establishing the connection between the target media server and the intelligent terminal. According to the technical scheme, compared with the prior art, the media server group is additionally provided with the guide process, the intelligent terminal serving as the audience terminal can send the access request to the guide process, so that the target media server corresponding to the anchor to be connected on the intelligent terminal is determined in the media server group, the connection with the intelligent terminal is established, the establishment of live broadcast connection is realized through the live broadcast service system, the time consumption for firstly acquiring media information of the media server in the connection process of the intelligent terminal and the media server is saved, sufficient time is provided for realizing the second output of live broadcast content corresponding to the anchor to be connected, the second output success rate of live broadcast pictures in live broadcast application is improved, and the experience of audience users is improved.
Drawings
Fig. 1 is a schematic diagram of an architecture of a live broadcast service system according to an embodiment of the present invention;
fig. 2 is a schematic diagram of an architecture of a live broadcast service system according to a second embodiment of the present invention;
fig. 3 is a schematic diagram of another live broadcast service system provided in the second embodiment;
fig. 4 is a schematic flowchart of a method for establishing a live broadcast connection according to a third embodiment of the present invention;
fig. 5 shows an interaction flowchart of the connection establishment between the intelligent terminal and the target media server of the anchor to be connected.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, embodiments of the present invention will be described in detail with reference to the accompanying drawings. It should be understood that the described embodiments are only some embodiments of the invention, and not all embodiments. In addition, the embodiments and features of the embodiments in the present invention may be combined with each other without conflict.
Example one
Fig. 1 is a schematic structural diagram of a live broadcast service system according to an embodiment of the present invention, and as shown in fig. 1, the live broadcast service system includes: the intelligent terminal 11 and the media server group 12, the media server group 12 includes at least onemedia server 121 and a guidingprocess 122 associated with eachmedia server 121; the guidingprocess 122 is configured to, after receiving an access request of the intelligent terminal 11, determine atarget media server 121 corresponding to the anchor to be connected included in the access request, and establish a connection between thetarget media server 121 and the intelligent terminal 11.
It should be noted that the live broadcast service system provided in this embodiment is mainly used to implement connection between the intelligent terminal 11 held by the audience user and themedia server 121 corresponding to the anchor to be interacted with by the audience user in the live broadcast scene. Specifically, the application scenario can be described as follows: when the audience user wants to perform live broadcast interaction, an anchor to be subjected to live broadcast interaction can be selected firstly through the intelligent terminal 11 provided with the live broadcast interaction client of the audience user, the anchor is equivalent to an anchor to be connected on the intelligent terminal 11, and before the audience user enters a live broadcast room of the anchor to be connected, the intelligent terminal 11 needs to be connected with themedia server 121 corresponding to a background end of the anchor to be connected firstly.
In this embodiment, the intelligent terminal 11 may be a mobile phone, a tablet, a notebook, or the like, is installed with a live interactive client, and is displayed with an online anchor list, the audience user may select an anchor to be interacted from the online anchor list, and the intelligent terminal 11 may determine the anchor selected by the audience user as an anchor to be connected.
In this embodiment, the media server group 12 may be regarded as a service background that provides live broadcast services for an audience and a director in live broadcast application, amedia server 121 included in the media server group 12 in this embodiment is equivalent to an actual service in the live broadcast service, and may provide live broadcast services for an audience user and a director in the live broadcast application, themedia server 121 is often deployed in a machine room, and themedia server 121 deployed in the same machine room is regarded as one media server group 12 in this embodiment.
Compared with the existing live broadcast service system, when live broadcast connection is implemented, the core of this embodiment is that aguide process 122 is added to the media server group 12 in the same machine room, so that when a to-be-connected main broadcast exists on the intelligent terminal 11, an access request is directly sent to theguide process 122, theguide process 122 determines atarget media server 121 corresponding to the to-be-connected main broadcast according to synchronization information associated with eachmedia server 121, and establishes connection between the intelligent terminal 11 and thetarget media server 121.
Specifically, after the intelligent terminal 11 determines that the anchor to be connected exists, in order to enable the audience user to enter the live broadcast room of the anchor to be connected to interact with the anchor, the intelligent terminal 11 may send an access request to theguidance process 122 in the media server cluster 12, and after receiving the access request, theguidance process 122 may determine atarget media server 121 corresponding to the anchor to be connected from the media server cluster 12, and establish a connection between thetarget media server 121 and the intelligent terminal 11, where the access request includes related information of the anchor to be connected.
It should be noted that, amedia server 121 correspondingly exists in the media server group 12 for the anchor in the online anchor list displayed on the intelligent terminal 11, themedia server 121 corresponding to the anchor can provide service support for online live broadcast to the anchor, and themedia server 121 providing service support for the anchor contains anchor information of the corresponding anchor, and the anchor information can be used as a unique identifier (such as an ID of the anchor) of the anchor and is used for identifying the anchor. The relevant information of the anchor to be connected included in the access request sent by the intelligent terminal 11 to theguidance process 122 may be a unique identifier of the anchor.
In the present embodiment, a guidingprocess 122 is associated with eachmedia server 121, and includes the anchor information of the anchor corresponding to eachmedia server 121. Thus, after receiving the access request, the guidingprocess 122 may obtain the anchor information about the anchor to be connected in the access request, and may determine onetarget media server 121 corresponding to the anchor to be connected from the media server group 12 according to the synchronization information associated with eachmedia server 121.
Further, in the embodiment, the guidingprocess 122 added to the media server group 12 preferably includes synchronizing the media information with eachmedia server 121, and for eachmedia server 121, the media information provided by the guiding process preferably includes an IP address and a port of themedia server 121 and anchor information of an anchor served by themedia server 121. The guidingprocess 122 corresponds to an anchor message including an IP address, a port, and an anchor served by eachmedia server 121.
On the basis of the foregoing embodiment, the guidingprocess 122 may be specifically configured to, after receiving an access request of the intelligent terminal 11, obtain target anchor information included in the access request, where the target anchor information is anchor information of an anchor to be connected; determining target media information including target anchor information from the media information, and taking themedia server 121 with the target media information as atarget media server 121; and establishing the connection between thetarget media server 121 and the intelligent terminal 11 according to the IP address and the port in the target media information.
It is understood that the guidingprocess 122 may search, from the media information synchronized thereon, whether the anchor information of the anchor to be connected is included, when the anchor information of the anchor to be connected exists in one of the media information, the media information may be recorded as target media information, and themedia server 121 referred by the target media information is regarded as thetarget media server 121, and finally, the connection between thetarget media server 121 and the intelligent terminal 11 may be established according to the IP address and the port of themedia server 121 in the target media information.
Further, thetarget media server 121 is configured to send media stream data corresponding to the anchor to be connected to the intelligent terminal 11 after establishing connection with the intelligent terminal 11, so that the intelligent terminal 11 displays live content corresponding to the media stream data.
In this embodiment, thetarget media server 121 provides a service support of online live broadcast for the anchor to be connected, and thus includes media stream data generated when the anchor to be connected performs online live broadcast, in this embodiment, after the connection between thetarget media server 121 and the intelligent terminal 11 is established through the guidingprocess 122, thetarget media server 121 directly pushes the media stream data of the live broadcast room associated with the anchor to be connected to the intelligent terminal 11, so that the intelligent terminal 11 can perform operations such as decoding, aligning, and rendering processing after receiving the media stream data, and finally present the live broadcast content of the anchor to be connected to the audience user in the form of pictures and sounds on the media stream data.
It should be noted that the intelligent terminal 11 is connected to thetarget media server 121 based on UDP/TCP protocol. That is, the intelligent terminal 11 and thetarget media server 121 may be connected by using a UDP/TCP protocol through thetarget guidance process 122, and meanwhile, the intelligent terminal 11 and thetarget media server 121 may also implement subsequent data interaction based on the UDP/TCP protocol.
Compared with the prior art, the live broadcast service system provided by the embodiment of the invention has the advantages that theguide process 122 is additionally arranged in the media server group 12, the intelligent terminal 11 serving as the audience terminal can send an access request to theguide process 122, so that thetarget media server 121 corresponding to the anchor broadcast to be connected on the intelligent terminal 11 is determined in the media server group 12, the connection with the intelligent terminal 11 is established, the live broadcast connection is established through the live broadcast service system, the time consumption for firstly acquiring the media information of themedia server 121 in the connection process of the intelligent terminal 11 and themedia server 121 is saved, further, sufficient time is provided for realizing the second output of the live broadcast content corresponding to the anchor broadcast to be connected, the second output success rate of the live broadcast picture in the live broadcast application is improved, and the user experience of the audience is improved.
In an optional embodiment of this embodiment, the intelligent terminal 11 in the live service system may further determine, according to a predetermined push model or a selected operation of the viewer user, a anchor to be connected from the currently displayed anchor list. Wherein at least one anchor to be connected can be determined. And the intelligent terminal 11 may generate an access request after determining that the anchor is to be connected, and then send the access request to theguidance process 122 corresponding to thepre-acquired guidance process 122 address, so as to determine thetarget media server 121 of the anchor is to be connected through theguidance process 122, and establish a connection between the intelligent terminal 11 and thetarget media server 121.
In this optional embodiment, an online anchor list may be displayed in a live client started on the intelligent terminal 11 for the selection of the audience user, the online anchor list may include an anchor that the audience user pays attention to, and at this time, the anchor selected by the audience user from the online anchor list may be used as an anchor to be connected; in addition, the intelligent terminal 11 of this embodiment may also directly push an online anchor list according to a predetermined push model on the media background 12, and randomly select an anchor from the online anchor list as an anchor to be connected. The intelligent terminal 11 may determine at least one anchor to be connected according to selection of the audience user or intelligent push, and thus, in the live broadcast service system of this embodiment, thetarget media server 121 corresponding to each anchor to be connected is determined, so that connection between the intelligent terminal 11 and eachtarget media server 121 is achieved.
Furthermore, in this alternative embodiment, theguidance process 122 included in the media server farm 12 is provided with aguidance process 122 address, which may be understood as an address for identifying aguidance process 122 access road force on the media server farm 12. The intelligent terminal 11 may obtain the address of the guidingprocess 122 in advance, and after determining that the anchor to be connected exists, generate an access request including information related to the anchor to be connected, and may send the access request to thecorresponding guiding process 122 through the obtained address of the guidingprocess 122.
This optional embodiment specifically optimizes the determination mode of the anchor to be connected and the allowable number of the anchors to be connected, and defines that the access request can be sent to the corresponding guidingprocess 122 through the pre-acquired guidingprocess 122 address. This optional embodiment provides the prerequisite information of connection establishment for the realization of the live connection of the intelligent terminal 11 in the live service system, which is equivalent to the trigger condition of the live connection establishment, and ensures the effective implementation of the live connection establishment of the intelligent terminal 11.
Meanwhile, as a parallel optional embodiment of the above optional embodiments of this embodiment, the live broadcast system may further include a resource allocation server and an anchor terminal (neither shown in fig. 1), specifically, the anchor terminal is configured to send a resource allocation request of an anchor to be served to the resource allocation server; the resource allocation server is configured to select onemedia server 121 from the media server group 12 as aselected media server 121 of the anchor to be served after receiving the resource allocation request. Accordingly, the selectedmedia server 121 is used to synchronize media information formed based on the anchor information of the anchor to be served into a guidingprocess 122 belonging to the same media server farm 12.
In this optional embodiment, the live broadcast service system further includes a anchor terminal on which an anchor client facing an anchor user is installed, and the live broadcast service system further includes a resource allocation server for performing server allocation to the anchor terminal.
For example, in this optional embodiment, an anchor with an online live broadcast requirement may be used as a to-be-serviced anchor, and an anchor terminal held by the to-be-serviced anchor may send a resource allocation request corresponding to the to-be-serviced anchor to a resource allocation server. A resource allocation policy for resource allocation is set on the resource allocation server, and themedia server 121 may be allocated to the anchor to be served according to the resource allocation policy and the information carried in the resource allocation request. The resource allocation policy may define in what manner (for example, divided by the form of the region where the anchor is located) or in what criteria (for example, criteria that the distance value between the region where the anchor is to be served and the region where themedia server 121 is deployed is not higher than a set threshold value, and the like) the allocation of themedia server 121 for the anchor to be served is performed.
As described above, the present embodiment may record themedia server 121 selected by the resource allocation server for the anchor to be served as the selectedmedia server 121. The selectedmedia server 121 exists in the media server group 12, and can associate the server information (such as an IP address and a port) of the selected media server with the corresponding anchor information of the anchor to be served to form media information for recording, and the selectedmedia server 121 performs local recording of the media information and synchronizes the media information to theguiding process 122 belonging to the same media server group 12.
The above optional embodiment of this embodiment provides a specific implementation that the live broadcast service system performs media server allocation for the anchor having the online live broadcast requirement, which is equivalent to a determination method of required association information between the anchor to be connected and the media server when the intelligent terminal performs live broadcast connection, so that specific content of media information included in the guidance process is clarified, basic information required by live broadcast connection is provided, and effective connection between the intelligent terminal and a target media server corresponding to the anchor to be connected is ensured.
Example two
Fig. 2 is a schematic structural diagram of a live broadcast service system according to a second embodiment of the present invention, where the first embodiment of the present invention is optimized based on the foregoing, as shown in fig. 2, the present embodiment includes anintelligent terminal 20 and a media server group 23, and the live broadcast service system further includes: a signaling channel 21 and a media front-end server 22; theintelligent terminal 20 is connected to the media front-end server 22 through the signaling channel 21, and the media front-end server 22 is connected to the media server group 23. Specifically, the media front-end server 22 is configured to, when receiving a first guiding process address obtaining request sent by theintelligent terminal 20, feed back a guiding process address of aguiding process 232 in the media server group 23 to theintelligent terminal 20 through the signaling channel 21.
In this embodiment, the key for establishing the connection between theintelligent terminal 20 and the target media server 231 corresponding to the anchor to be connected is accessing theguiding process 232, and the access from theintelligent terminal 20 to theguiding process 232 specifically depends on the guiding process address, and the guiding process address possessed when the intelligent terminal sends the access request to theguiding process 232 in this embodiment may be obtained by the media front-end server 22 in advance. The media front-end server 22 may specifically be understood as a server on which theintelligent terminal 20 depends on information interaction with a server of the live broadcast application before establishing connection with the media server 231, and the signaling channel 21 and the media front-end server 22 may be integrally regarded as a signaling background to connect theintelligent terminal 20 and the media server cluster 23.
Specifically, for theintelligent terminal 20, after the intelligent terminal 20 starts the installed live broadcast client based on the click trigger of the viewer user, a guiding process address acquisition request may be first sent to the media front-end server 22 through the signaling channel 21, and then a guiding process address fed back by the media front-end server 22 may be received, and theintelligent terminal 20 may receive and pre-store the guiding process address, where the guiding process address acquisition request may include the terminal identification information of theintelligent terminal 20.
For the media front-end server 22, it specifically establishes a connection with the media server group 23, may obtain a guidance process address of theguidance process 232 in the media server group 23, and may then send the guidance process address to theintelligent terminal 20 corresponding to the terminal identification information according to the terminal identification information included in the guidance process address acquisition request.
It should be noted that, in this embodiment, the precondition for acquiring the address of the guiding process is that the live broadcast server system includes one media server group 23, which is different from a case where the subsequent live broadcast server system includes at least two media server groups 23, and this embodiment records the address of the guiding process as the first address of the guiding process acquiring request.
The live broadcast service system provided by the embodiment of the invention embodies the implementation mode of the intelligent terminal for acquiring the lead process address, provides basic information support for the establishment of the live broadcast connection between the intelligent terminal and the target media server, and ensures the integrity of the live broadcast connection establishment scheme.
Further, fig. 3 is a schematic diagram of an architecture of another live broadcast service system provided in the second embodiment of the present invention. As shown in fig. 3, the media server farm 34 further includes at least oneaudio media server 341, at least onevideo media server 342, anaudio guide process 343 associated with each of theaudio media servers 341, and avideo guide process 344 associated with each of thevideo media servers 342. Meanwhile, the media front-end server 33 further specifically includes an audio front-end server 331, a video front-end server 332, and an integration process 333, wherein the signalingchannel 32 is connected to the audio front-end server 331 and the video front-end server 332 through the integration process 333, respectively.
As can be seen from fig. 3, the audio front-end server 331 is specifically connected to theaudio guidance process 343 in the media server farm 34, and the video front-end server 332 is specifically connected to thevideo guidance process 344 in the media server farm 34. Based on the connection relationship given in fig. 3, the audio front-end server 331 may obtain the audio guidance process address of theaudio guidance process 343, and the video front-end server 332 may also obtain the video guidance process address of thevideo guidance process 344. When the integration process 333 receives the guidance process address acquisition request sent by theintelligent terminal 31, the integration process 333 may integrate the audio guidance process address and the video guidance process address to form a guidance process address, and the guidance process address is fed back to theintelligent terminal 31 through the signalingchannel 32.
In the second embodiment of the live broadcast service system under the system architecture, the media server group realizes separate service support for multimedia information, specifically deploys an audio media server for audio service support, deploys a video media server for video service support, and simultaneously associates the audio media server with the audio guide process and associates the video media server with the video guide process, thereby integrally ensuring effective implementation of live broadcast connection application in live broadcast application software.
As an optional embodiment of the second embodiment of the present invention, the second embodiment further optimizes that the live broadcast service system includes at least two media server clusters, wherein the media front-end server is respectively connected to each of the media server clusters.
In the live server system given in this optional embodiment, the media front-end server is further configured to determine a target media server group from each media server group according to a second guidance process address acquisition request sent by the intelligent terminal, and feed back a guidance process address of a guidance process in the target media server group to the intelligent terminal through the signaling channel.
It should be noted that, in the live broadcast service system including at least two media server groups, an access request is also generated after the anchor to be connected is determined on the intelligent terminal, and the access request can also be sent to the corresponding guide process according to the pre-obtained guide process address. It can be seen that the key for connecting the intelligent terminal with the target media server corresponding to the anchor to be connected still lies in the acquisition of the address of the guiding process. Specifically, the intelligent terminal is first required to send a second guiding process address acquisition request to the media front-end server, and the media front-end server can find a target media server group corresponding to the second guiding process address acquisition request from the plurality of connected media server groups and feed back a guiding process address of a guiding process in the target media server group to the intelligent terminal. The method is different from the method for acquiring the guide process address sent by the intelligent terminal when the live broadcast service system comprises one media server group, and the guide process address acquired request sent by the intelligent terminal under a plurality of media server groups is recorded as a second guide process address acquired request.
It will be appreciated that in the live service system given in this alternative embodiment, when there are multiple media server clusters in the live service system, each media server cluster may be considered to include at least one media server and a guidance process associated with each media server in the same media server cluster. In this embodiment, it can be considered that a plurality of media server groups form a media background for supporting live broadcast services, each media server group can be respectively regarded as a machine room for performing distributed division in different regions, each machine room is deployed with a plurality of media servers and a guidance process associated with each media server, and each machine room is correspondingly provided with a region deployment information, so that the media server groups in different regions have different region deployment information.
For the media front-end server, the media front-end server may analyze the region information of the terminal of the intelligent terminal included in the received second guiding process address acquisition request, and then may compare the region information of the terminal with the region deployment information of each media server group, thereby selecting a target media server group from the multimedia server groups, where the region deployment information matches the region information of the terminal, and finally may feed back the guiding process address of the guiding process added in the target media server group to the intelligent terminal.
It should be noted that, after the intelligent terminal sends the second guidance process address acquisition request to the media front-end server each time, the intelligent terminal may only receive the guidance process address corresponding to the guidance process included in one media server group selected by the media front-end server from all the media server groups.
Further, the intelligent terminal may be specifically configured to send the second guiding process address acquisition request to the media front-end server at a set update period, where the second guiding process address acquisition request includes information of a region where the terminal is located.
In this embodiment, the timing when the intelligent terminal first sends the second guidance address acquisition request to the media front-end server may be after the installed live broadcast client is started, so as to first acquire a guidance process address required for accessing the guidance process. Further, in order to ensure the accuracy of the guiding process address prestored in the intelligent terminal, in this embodiment, the intelligent terminal periodically updates the guiding process address in the operation process of the live broadcast client, specifically, the intelligent terminal may repeatedly send the second guiding process address acquisition request to the media front-end server at a set update period (e.g., 15 minutes, 30 minutes, or 1 hour, etc.), so that the second guiding process address acquisition request sent by each update may be corresponded to, and the guiding process address correspondingly fed back by the media front-end server is received.
It can be known that the second guidance address obtaining request includes the region information where the terminal of the intelligent terminal is located, the media front-end server may determine a media server group matched with the region of the intelligent terminal from each machine room of the media backend 3 according to the region information where the terminal is located, the matched media server group may be marked as a target media server group, and a guidance process address provided by a guidance process added in the target media server group may be fed back to the intelligent terminal through a signaling channel.
Further, the media front-end server may be specifically configured to acquire region deployment information corresponding to each media server group on the media background, and extract region information where the terminal in the second guiding process address acquisition request is located; taking a media server group corresponding to the region deployment information matched with the region information of the terminal as a target media server group; and feeding back the guiding process address of the guiding process in the target media server group to the intelligent terminal through the signaling channel.
Generally, when the location of the audience user does not change, the region information of the terminal of the intelligent terminal held by the audience user does not change, and at this time, if the guiding process address is received in a set updating period, the currently received guiding process address may be the same as the guiding process address received in the previous updating period; however, when the location of the viewer user and the location of the intelligent terminal held by the viewer user change, the region information of the terminal corresponding to the intelligent terminal also changes, and at this time, in the operation of receiving the address of the guiding process in the set updating period, the currently received address of the guiding process may be different from the address of the guiding process received in the previous updating period, because: the media server group in the live broadcast service system, which is matched with the changed region information of the terminal, may be changed, so that the currently determined guiding process address of the media front-end server should be the guiding process address matched with the changed region information of the terminal.
The second embodiment of the present invention provides a live broadcast service system according to the above-mentioned optional embodiment, which embodies an implementation manner in which an intelligent terminal acquires a guide process address when a plurality of media server groups are included, perfects an implementation process of live broadcast connection establishment for audience users, provides basic information support for execution of connection establishment, and ensures integrity of a connection establishment technical scheme.
As another optional embodiment of the second embodiment, the second embodiment further optimizes the live broadcast service system on the basis of the above embodiment, and specifically, in the live broadcast service system, the intelligent terminal 21 may be further configured to send a request for updating a guide process address to the media front-end server when it is monitored that the connection with the target media server fails; the media front-end server is further used for determining a new target media server group matched with the anchor to be connected from each media server group according to the guiding process address updating request, and feeding back a new guiding process address of a new guiding process in the new target media server group to the intelligent terminal; and the intelligent terminal is used for sending an access request to a new guide process corresponding to the new guide process address so as to determine a new target media server from the new target media server group through the new guide process and establish connection.
It can be understood that, in practical applications, the target media server pre-allocated by the anchor to be connected existing on the intelligent terminal 21 may not be included in the target media server group corresponding to the currently obtained guiding process address of the intelligent terminal 21, that is, after the access request is sent to the guiding process corresponding to the obtained guiding process address, the media server group to which the guiding process belongs may not include the target media server corresponding to the anchor to be connected. At this time, the guidance process receiving the access request cannot find the target media server matched with the anchor to be connected in the home media server group, so that the connection between the intelligent terminal 21 and the target media server cannot be successfully established.
In this embodiment, when the guiding process does not determine the target media server corresponding to the anchor to be connected, the guiding process may send information that the connection establishment with the target media server corresponding to the anchor to be connected fails to the intelligent terminal 21, at this time, the intelligent terminal 21 may generate a guiding process address update request, where the guiding process address update request includes anchor information of the anchor to be connected, the anchor information may specifically include an anchor ID and region information where the anchor is located, and the guiding process address update request may also be received by the media front-end server 222.
Correspondingly, the media front-end server 222 may obtain anchor information in the guiding process address updating request, and then may search the resource allocation cache table to determine a new target media server group where a new target media server matched with the anchor information is located; after determining the new target media server group, the media front-end server 222 may determine a guiding process added in the new target media server group as a new guiding process, and determine a guiding process address of the new guiding process as a new guiding process address to feed back to the intelligent terminal 21, where the resource allocation cache table may be understood as an allocation log, which is a global variable set on the resource allocation server on the media backend 23, after the resource allocation server in the media backend allocates the media server to the anchor, the anchor information of the anchor and the allocated media server may be synchronously recorded in the resource allocation cache table, and when the anchor exits the direct broadcast, the relevant record of the anchor is deleted from the resource allocation cache table.
After receiving the new guiding process address, the intelligent terminal may send an access request to a new guiding process corresponding to the new guiding process address, so as to determine a new target media server from the new target media server group through the new guiding process and establish a connection.
The live broadcast service system provided by the optional embodiment provides the operation of updating the guide process address when the connection establishment with the target media server fails, and ensures that the connection with the target media server is realized through the updated guide process address.
EXAMPLE III
Fig. 4 is a schematic flow chart of a live broadcast connection establishment method according to a third embodiment of the present invention, where the live broadcast connection establishment method is suitable for a situation where an intelligent terminal establishes a connection with a media server in a media background when a main broadcast to be connected exists on the intelligent terminal, and the method can be implemented by the live broadcast service system provided in the first embodiment or the second embodiment, where the live broadcast service system can be implemented by software and/or hardware, and the intelligent terminal in the live broadcast service system can be a mobile phone, a tablet, a notebook, or the like having a live broadcast interaction function.
As shown in fig. 4, a method for establishing a live broadcast connection provided by the third embodiment includes:
s301, the intelligent terminal generates an access request after determining the anchor to be connected and sends the access request to a guide process corresponding to the pre-acquired guide process address.
In this embodiment, in order to implement connection with a target media server corresponding to an anchor to be connected, the intelligent terminal in the provided live broadcast service system may specifically generate an access request after detecting that the selected anchor to be connected exists, and send the access request to a guidance process corresponding to a guidance process address acquired in advance; the guide process address can be understood as an address used for identifying a guide process access path in a media server group, a guide process accessed by the intelligent terminal can be additionally arranged in the media server group, and the media server group comprises at least one media server and can form a machine room on a live broadcast service background.
For example, for an intelligent terminal, after an audience user selects an anchor to be subjected to live broadcast interaction in an online anchor list displayed by the audience user, the anchor may be determined as an anchor to be connected, so that an access request including relevant information of the anchor to be connected may be generated, and the access request is sent to a guidance process corresponding to an acquired guidance process address.
S302, after receiving an access request of the intelligent terminal, the guiding process determines a target media server corresponding to the anchor to be connected from the same media server group, and establishes connection between the target media server and the intelligent terminal.
For example, the guiding process belongs to a media server group, and the guiding process may obtain anchor information of an anchor to be connected, determine a target media server corresponding to the anchor to be connected in the media server group to which the guiding process belongs according to the anchor information, and establish a connection between the guiding process and the intelligent terminal through an IP address and a port of the target media server, where the anchor information of the anchor to be connected may be a unique identifier for identifying the anchor to be connected, for example, an anchor ID of the anchor to be connected.
In addition, on the basis of the live broadcast service system provided in the foregoing embodiment, fig. 5 shows an interaction flowchart for establishing a connection between an intelligent terminal and a target media server of an anchor to be connected, and as shown in fig. 5, the interaction flowchart shows terminals and servers participating in interaction in the live broadcast service system, which may include an intelligent terminal serving as an audience, a signaling channel, a media front-end server, a media server group participating in data interaction, and a guidance process included in the media server group and a target media server corresponding to the anchor to be connected, specifically, the process of establishing the live broadcast connection may be expressed as:
and S1, the intelligent terminal sends a guiding process address acquisition request to the media front-end server through a signaling channel according to the set updating period.
And S2, the media front-end server determines the guiding process address based on the guiding process address acquisition request.
And S3, the media front-end server feeds the guiding process address back to the intelligent terminal through a signaling channel.
It should be noted that the above-mentioned S1 to S3 can be regarded as an implementation process of the process-oriented address acquisition.
S4, the intelligent terminal obtains the currently selected anchor to be connected and generates an access request containing anchor information corresponding to the anchor to be connected.
And S5, the intelligent terminal sends the access request to a corresponding guide process of the guide process.
S6, the guiding process establishes the connection between the intelligent terminal and the target media server corresponding to the anchor in the media server group to which the intelligent terminal is to be connected.
And S7, the target media server connected with the audience terminal sends the media stream data to the audience terminal.
And S8, the audience end displays the live broadcast content corresponding to the media stream data.
The above-mentioned S4 to S8 may be regarded as a realization process of the intelligent terminal establishing a connection with the target media server through a guiding process additionally provided in the media server group.
The establishment method of live broadcast connection provided by the third embodiment of the present invention is based on the live broadcast service system provided by the above-mentioned embodiment of the present invention, compared with the prior art, the media server group in the live broadcast service system is additionally provided with the guide process, the intelligent terminal as the audience terminal can obtain a guide process address in advance and access the guide process corresponding to the guide process address, so that a connection can be established with a target media server corresponding to the anchor to be connected in the media server group to which the guiding process belongs, thereby realizing the establishment of the live broadcast connection, saving the time consumption for acquiring the media information in the connection process of the intelligent terminal and the media server by using the method, and then sufficient time is provided for realizing the second output of the live broadcast content corresponding to the anchor to be connected, so that the second output success rate of the live broadcast picture in the live broadcast application is improved, and the user experience of audiences is improved.
It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present invention and the technical principles employed. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.