WO2020211614A1 - 一种转发媒体包的方法、转发服务器及存储介质 - Google Patents

一种转发媒体包的方法、转发服务器及存储介质 Download PDF

Info

Publication number
WO2020211614A1
WO2020211614A1 PCT/CN2020/081261 CN2020081261W WO2020211614A1 WO 2020211614 A1 WO2020211614 A1 WO 2020211614A1 CN 2020081261 W CN2020081261 W CN 2020081261W WO 2020211614 A1 WO2020211614 A1 WO 2020211614A1
Authority
WO
WIPO (PCT)
Prior art keywords
forwarded
rtp media
priority
media packet
packet
Prior art date
Application number
PCT/CN2020/081261
Other languages
English (en)
French (fr)
Inventor
陈泽贤
Original Assignee
腾讯科技(深圳)有限公司
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 腾讯科技(深圳)有限公司 filed Critical 腾讯科技(深圳)有限公司
Priority to EP20791500.0A priority Critical patent/EP3958525A4/en
Publication of WO2020211614A1 publication Critical patent/WO2020211614A1/zh
Priority to US17/344,163 priority patent/US11876720B2/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/62Queue scheduling characterised by scheduling criteria
    • H04L47/625Queue scheduling characterised by scheduling criteria for service slots or service orders
    • H04L47/6275Queue scheduling characterised by scheduling criteria for service slots or service orders based on priority
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/24Traffic characterised by specific attributes, e.g. priority or QoS
    • 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
    • H04L65/403Arrangements for multi-party communication, e.g. for conferences
    • 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/65Network streaming protocols, e.g. real-time transport protocol [RTP] or real-time control protocol [RTCP]
    • 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/80Responding to QoS
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M3/00Automatic or semi-automatic exchanges
    • H04M3/42Systems providing special services or facilities to subscribers
    • H04M3/487Arrangements for providing information services, e.g. recorded voice services or time announcements
    • H04M3/493Interactive information services, e.g. directory enquiries ; Arrangements therefor, e.g. interactive voice response [IVR] systems or voice portals
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/30Routing of multiclass traffic
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/32Flow control; Congestion control by discarding or delaying data units, e.g. packets or frames

Definitions

  • the embodiment of the present application provides a method for forwarding media packets, which is executed by a forwarding server, and includes:
  • the embodiment of the present application provides a forwarding server, including:
  • the receiving module is used to receive RTP media packets to be forwarded
  • An analysis module for determining the type of the RTP media packet to be forwarded
  • a processing module configured to determine the priority of the RTP media packet to be forwarded according to the type of the RTP media packet to be forwarded;
  • the forwarding module is configured to forward the received RTP media packets to be forwarded and the RTP media packets with higher priority among the RTP media packets currently being forwarded.
  • the forwarding module is also used to:
  • the priority of the RTP media packet being forwarded is equal to the priority of the received RTP media packet to be forwarded, and the RTP media packet currently being forwarded and the source end corresponding to the received RTP media packet to be forwarded If they are different, mix the RTP media packet currently being forwarded and the received RTP media packet to be forwarded;
  • the analysis module is specifically used for:
  • the type of the RTP media packet to be forwarded is determined according to the PT field and the CSRC field in the header of the RTP media packet to be forwarded.
  • the types of RTP media packets include at least call voice packets, IVR voice packets, and DTMF packets;
  • the analysis module is specifically used for:
  • determining that the RTP media packet to be forwarded is a DTMF packet
  • determining that the RTP media packet to be forwarded is an IVR voice packet
  • the RTP media packet to be forwarded is a call voice packet.
  • the embodiment of the present application provides a computer-readable storage medium that stores a computer program executable by a computer device, and when the program runs on the computer device, the computer device executes the steps of the method for forwarding a media package.
  • FIG. 1 is a schematic diagram of an application scenario provided by an embodiment of the application
  • FIG. 4 is a schematic flowchart of a method for forwarding media packets according to an embodiment of the application
  • FIG. 5 is a schematic diagram of an RTP media packet header provided by an embodiment of this application.
  • FIG. 7 is a schematic diagram of a process for determining the type of RTP media package according to an embodiment of the application.
  • FIG. 8 is a schematic diagram of a process for determining the type of an RTP media package according to an embodiment of the application.
  • FIG. 10 is a schematic flowchart of a method for forwarding media packets according to an embodiment of this application.
  • FIG. 11 is a schematic flowchart of a method for forwarding media packets according to an embodiment of the application.
  • FIG. 12 is a schematic flowchart of a method for forwarding media packets according to an embodiment of this application.
  • FIG. 13 is a schematic structural diagram of a forwarding server provided by an embodiment of this application.
  • FIG. 14 is a schematic structural diagram of a computing device provided by an embodiment of this application.
  • Converged communication refers to the integration of communication technology and information technology.
  • Communication technology services refer to various services of traditional telecommunication networks, such as telephone services, short message services, conference calls, call centers, etc.
  • Information technology services refer to various IP services, such as instant messaging (IM); video and application sharing, such as video surveillance, information sharing, and download services; and Internet services, such as e-mail and voice mail.
  • IM instant messaging
  • video and application sharing such as video surveillance, information sharing, and download services
  • Internet services such as e-mail and voice mail.
  • PSTN Public Switched Telephone Network
  • public switched telephone network a commonly used old telephone system, that is, the telephone network commonly used in our daily lives.
  • RTP Real-time Transport Protocol
  • Real-time Transport Protocol is a network transmission protocol. It was announced by the IETF Multimedia Transport Working Group in RFC 1889 in 1996, and then updated in RFC 3550.
  • DTMF Dual Tone Multi Frequency, dual-tone multi-frequency signal, a kind of user signaling between the telephone and the exchange in the telephone system, usually used to send the called number.
  • RFC2833 A mainstream DTMF transmission method. It is an in-band detection method. It is transmitted through RTP, and the RFC2833 data packet is marked by a special rtpPayloadType, namely TeleponeEvent.
  • the inventor of this application found that in the traditional public switched telephone network, there are fewer parties and fewer types of media packages involved. For example, when users on both sides communicate, only media packages are involved.
  • Package and Interactive Voice Response (IVR) package The preset strategy is used to control that only the receiver plays the IVR language before answering the call, and ends playing the IVR language after answering the call. Therefore, there will not be a situation where two media packets arrive at the forwarding device at the same time, and the forwarding device only needs to forward the received media packets directly.
  • the business process of a voice call is more complicated, and the call may involve multiple parties, such as a multi-party conference call. There are also many types of media packages involved.
  • voice media packages such as call voice and IVR language
  • non-voice media packages such as DTMF.
  • Converged communication platforms cannot use policies to control the order in which all media packets arrive at the forwarding device.
  • signals triggered by the user side such as DTMF
  • the user may be in the entire conversation.
  • Triggering is highly random and cannot be controlled by strategy. This may cause multiple media packets to reach the forwarding device at the same time, and when the forwarding device forwards multiple media packets to the receiver at the same time, the receiver cannot parse and cannot hear the sound.
  • the forwarding server when multiple media packets arrive at the forwarding server at the same time, it is because the forwarding server does not do processing and directly forwards it, which causes the receiver to not hear the sound.
  • the forwarding server when the forwarding server receives the RTP media packet to be forwarded, it determines the type of the RTP media packet to be forwarded, determines the priority of the RTP media packet to be forwarded according to the type of the RTP media packet to be forwarded, and then prioritizes it.
  • the method for forwarding media packets in the embodiments of the present application can be applied to convergent communication scenarios, such as call centers, multi-party teleconferences, and video conferences.
  • the call center scenario shown in FIG. 1 includes a call center device 101, a converged communication platform 102, an operator server 103, and a user terminal 104.
  • the call center device 101 is an electronic device with network communication capabilities, and the electronic device may be a smart phone, a tablet computer, or a portable personal computer.
  • the call application program is pre-installed on the call center device 101.
  • the customer service staff can enter the user number in the dial pad displayed in the calling application, and then click the dial button.
  • the functions of the calling application include a workbench, an address book, and a client library.
  • the workbench interface is displayed.
  • the workbench interface includes a dialing keyboard and call records. The customer service staff can click to enter the user number in the dialing keyboard interface.
  • the workbench interface displays the user number dialed by the customer service staff, and then click the dial button to call the user.
  • the customer service staff can also click the address book option, query the user number in the address book, and then call the user by clicking the user number in the address book.
  • the call center device 101 sends a call request carrying the user number to the converged communication platform 102, and the converged communication platform 102 sends the call request to the operator server 103, and the operator server 103 forwards the call request to the user terminal 104 according to the user number.
  • the converged communication platform 102 can forward the call voice media stream between the customer service staff and the user.
  • the converged communication platform 102 can also provide IVR voice services and DTMF services.
  • the converged communication platform 102 sends the IVR voice media stream to the operator server 103, and the operator server 103 forwards the IVR voice media stream to the user terminal 104, and plays the IVR voice on the user terminal 104.
  • the converged communication platform 102 determines the DTMF media stream according to the keys entered by the user, and then determines the next step of the user according to the DTMF media stream.
  • the converged communication platform 102 may be a server or a server cluster or cloud computing center composed of several servers, and the client 104 may be a smart phone.
  • the call center device 101 is connected to the converged communication platform 102 through a wireless network, the converged communication platform 102 is connected to the operator server 103 through the wireless network, and the operator server 103 is connected to the user terminal 104 through the wireless network.
  • the system architecture diagram of the converged communication platform 102 is shown in FIG. 3.
  • the converged communication platform 102 includes a forwarding server 1021, a policy control module 1022, an IVR service module 1023, and a DTMF service module 1024.
  • the call center device 101 sends the call voice media stream of the customer service staff to the forwarding server 1021.
  • the IVR service module 1023 generates an IVR voice media stream, and sends the IVR voice media stream to the forwarding server 1021.
  • the DTMF service module 1024 generates a DTMF media stream, and sends the DTMF media stream to the forwarding server 1021.
  • the policy control module 1022 can control the sequence of the call voice media stream and the IVR voice media stream arriving at the forwarding server 1021, for example, the IVR voice is played first, and then the call is made. However, during the call, the call voice media stream, IVR voice media stream, and DTMF signal may also cross reach the forwarding server 1021.
  • the forwarding server 1021 When the forwarding server 1021 receives multiple media streams at the same time, it forwards the media stream with the highest priority and discards the media stream with the lower priority, so that the media stream forwarded by the operator server 103 to the user end 104 is one media stream, which prevents users The terminal 104 cannot parse multiple media streams, so that the user cannot hear the sound.
  • an embodiment of the present application provides a flow of a method for forwarding media packets.
  • the flow of the method can be executed by a forwarding server, such as As shown in Figure 4, it includes the following steps:
  • Step S401 Receive a real-time transport protocol RTP media packet to be forwarded.
  • Step S402 Determine the type of the RTP media packet to be forwarded.
  • RTP media packets are media packets that are forwarded using the RTP protocol, and RTP media packets can be classified into different types according to different classification rules.
  • the types of RTP media packets can be divided into three types: call voice packets, IVR voice packets, and DTMF packets.
  • the types of RTP media packets can also be divided into two types: voice packets and non-voice packets.
  • the types of RTP media packets can also be divided into two types: call voice packets and non-call voice packets.
  • Step S403 Determine the priority of the RTP media packet to be forwarded according to the type of the RTP media packet to be forwarded.
  • the priority of each type of RTP media packet is preset. For example, when the types of RTP media packets are divided into three types: call voice packets, IVR voice packets, and DTMF packets, since IVR voice packets are generally used to control the call flow, the IVR voice packets can be set as the first priority. In the current mainstream RFC2833 mode, DTMF packets have a higher priority than call voice packets, so DTMF packets can be set to the second priority and call voice packets to the third priority. For another example, when the types of RTP media packets are divided into two types: voice packets and non-voice packets, the voice packets can be set as the first priority, and the non-voice packets can be set as the second priority.
  • the call voice packets can be set to the first priority and the non-call voices to the second priority.
  • query the preset priority according to the type of the RTP media packet to be forwarded to determine the priority of the RTP media packet to be forwarded.
  • the types of RTP media packets are divided into three types: call voice packets, IVR voice packets, and DTMF packets
  • the type of RTP media packets to be forwarded is call voice packets
  • the priority of the call voice packet can be determined as the third priority.
  • the type of RTP media packet is divided into two types: voice packet and non-voice packet
  • the type of RTP media packet to be forwarded is a call voice packet
  • the type of RTP media packet to be forwarded is a voice packet
  • the type of the media packet can determine the priority of the call voice packet as the first priority.
  • Step S404 Forward the received RTP media packet to be forwarded and the RTP media packet with a higher priority among the RTP media packets currently being forwarded.
  • the forwarding server when the forwarding server receives the RTP packet to be forwarded, there is still the RTP packet to be forwarded in the forwarding server. At this time, the priority of the received RTP packet to be forwarded and the RTP media packet being forwarded is compared, Determine the RTP media packet with higher priority, and then forward the RTP media packet with higher priority, and then forward the RTP media packet with the highest priority each time.
  • the forwarding server When the forwarding server receives multiple media packets, it forwards the RTP media packets with the highest priority first, so that the forwarding server only forwards one media packet to the receiving end, avoiding the receiving end from being unable to parse the multiple media packets and unable to hear the sound. Problem, to ensure that the user's call is going on normally, thereby improving the user experience.
  • the embodiment of the present application when determining the type of the RTP media packet to be forwarded, includes at least the following three implementation manners:
  • the type of the RTP media packet to be forwarded is determined according to the PT field and the CSRC field in the header of the RTP media packet to be forwarded.
  • the format of the RTP media packet header is shown in FIG. 5, the RTP media packet header includes a PT field, and voice packets and non-voice packets can be distinguished by the value of the PT field.
  • the value of the PT field corresponding to the voice packet and the DTMF packet is determined, and the value of the PT field is used to distinguish the voice packet from the DTMF packet.
  • determining the type of received RTP media packets to be forwarded includes the following steps:
  • Step S601 Obtain the value of the PT field in the header of the RTP media packet to be forwarded.
  • Step S602 When the value of the PT field is the first preset value, it is determined that the RTP media packet to be forwarded is a DTMF packet.
  • Step S603 When the value of the PT field is the second preset value, the value of the CSRC field in the header of the RTP media packet to be forwarded is obtained.
  • Step S604 When the value of the CSRC field is the third preset value, it is determined that the RTP media packet to be forwarded is an IVR voice packet.
  • Step S605 When the value of the CSRC field is the fourth preset value, it is determined that the RTP media packet to be forwarded is a call voice packet.
  • the type of the RTP media packet to be forwarded is determined according to the PT field in the header of the RTP media packet to be forwarded.
  • the type of RTP media packets to be forwarded can be determined directly according to the value of the PT field.
  • determining the type of the received RTP media packet to be forwarded includes the following steps:
  • Step S701 Obtain the value of the PT field in the header of the RTP media packet to be forwarded.
  • Step S702 When the value of the PT field is the first preset value, it is determined that the RTP media packet to be forwarded is not a voice packet.
  • Step S703 When the value of the PT field is the second preset value, it is determined that the RTP media packet voice packet is to be forwarded.
  • the type of the RTP media packet to be forwarded is determined according to the CSRC field in the header of the RTP media packet to be forwarded.
  • the type of RTP media packet to be forwarded can be determined directly according to the value of the CSRC field.
  • determining the type of the RTP media packet to be forwarded includes the following steps:
  • Step S801 Obtain the value of the CSRC field in the header of the RTP media packet to be forwarded.
  • Step S802 When the value of the CSRC field is the third preset value, it is determined that the RTP media packet to be forwarded is a non-talk voice packet.
  • Step S803 When the value of the CSRC field is the fourth preset value, it is determined that the RTP media packet to be forwarded is a call voice packet.
  • the forwarding server when the forwarding server receives the media packet to be forwarded, it can determine the type of the media packet to be forwarded according to the value of the specific field in the header of the media packet to be forwarded, and then further determine the media packet to be forwarded.
  • the priority of the media packet facilitates subsequent determination of the media packet to be forwarded according to the priority of the media packet to be forwarded.
  • the forwarding server may forward the received RTP media packet to be forwarded and the RTP media packet with a higher priority among the RTP media packets currently being forwarded according to the following rules:
  • the received RTP media packet to be forwarded is discarded.
  • the priority of the IVR voice packet is higher than the priority of the DTMF packet. If the RTP media packet currently being forwarded is an IVR voice packet, and the received RTP media packet to be forwarded is a DTMF packet, the received DTMF packet is discarded .
  • the RTP media packet currently being forwarded is discarded, and the received RTP media packet to be forwarded is forwarded.
  • the priority of the DTMF packet is higher than the priority of the call voice packet. If the RTP media packet currently being forwarded is a call voice packet, and the received RTP media packet to be forwarded is a DTMF packet, the call currently being forwarded is discarded Voice packets, and forward the received DTMF packets.
  • the forwarding server is currently in the initial state, and when the received RTP media packet to be forwarded is a call voice packet, the received call voice packet is forwarded.
  • the forwarding server discards the RTP media packet currently being forwarded and forwards the received RTP media packet
  • the RTP media packet to be forwarded is updated, and the priority indication information is updated according to the priority of the received RTP media packet to be forwarded.
  • the RTP media packet currently being forwarded is a call voice packet
  • the received RTP media packet to be forwarded is a DTMF packet
  • the call voice packet is discarded
  • the DTMF packet is forwarded
  • the current priority indication information of the forwarding server is updated to the indication The priority of the DTMF packet.
  • the current priority indication information of the forwarding server indicates the priority of the initial state, and the received RTP media packet to be forwarded is a call voice packet, the current priority indication information of the forwarding server is updated to indicate the call voice packet priority.
  • the priority indication information is not updated.
  • the priority indication information is not updated.
  • the priority indication information of the forwarding server By setting the priority indication information of the forwarding server, it is used to indicate the priority of the RTP media packet that is being forwarded, so when the forwarding server receives the media packet to be forwarded, it can quickly determine the current RTP media packet according to the priority indication information. The priority is then further compared with the priority of the received RTP media packet to be forwarded to determine the RTP media packet to be forwarded preferentially, thereby improving the efficiency of forwarding the media packet.
  • the cumulative number of discarded received RTP media packets to be forwarded is accumulated, and when the cumulative number is greater than a preset threshold, the priority indicated by the priority indication information is lowered and the cumulative discarded reception is restarted The number of RTP media packets to be forwarded.
  • the priority indicated by the priority indication information can be adjusted to the second priority of the current priority, or the priority indicated by the priority indication information can be adjusted to the lowest level, and the priority can also be indicated
  • the priority indicated by the information is adjusted to another preset priority, such as the priority of the currently received RTP media packet to be forwarded.
  • the setting of the RTP media package includes four priority levels, which are sorted from high to low according to the priority levels as first priority, second priority, third priority, and fourth priority.
  • the current priority indication information is set to indicate the first priority.
  • the priority indication information may be updated to indicate the second priority.
  • the priority indication information may also be updated to indicate the fourth priority, and the priority indication information may also be updated to the third priority.
  • the priority of the RTP media packet currently being forwarded is higher than the priority of the received RTP media packet to be forwarded, discard the received RTP media packet to be forwarded, and accumulate the discarded received RTP media packet to be forwarded.
  • the cumulative value is greater than the preset threshold, the priority indicated by the priority indication information is lowered. Therefore, when the end packet of the media stream currently being forwarded is lost, the priority indicated by the priority indication information can still be lowered to avoid priority indication
  • the information always indicates high priority and affects the forwarding of low priority media packets.
  • the priority indicated by the priority indication information is adjusted to the lowest level.
  • step S404 when the priority of the RTP media packet currently being forwarded is equal to the priority of the received RTP media packet to be forwarded, this embodiment of the present application provides at least the following two implementations of forwarding RTP media packets the way:
  • the priority of the RTP media packet currently being forwarded is equal to the priority of the received RTP media packet to be forwarded, and the RTP media packet currently being forwarded corresponds to the received RTP media packet to be forwarded
  • the source ends are different, the RTP media packet currently being forwarded and the received RTP media packet to be forwarded are mixed, and the mixed RTP media packet is forwarded to the receiving end.
  • RTP media packet set the type of RTP media packet into two types: voice packet and non-voice packet. If the RTP media packet to be forwarded is an IVR voice packet, and the RTP media packet currently being forwarded is a call voice packet, it is currently being forwarded
  • the types of the RTP media packets received and the RTP media packets to be forwarded are both voice packets, and the priority is the priority corresponding to the voice packet. Since IVR voice packets and call voice packets correspond to different sources and are two RTP media packets, the IVR voice packets and call voice packets are mixed into one RTP media packet, and then the mixed RTP media packets are forwarded to the receiving end At this time, the receiving end can hear IVR voice and call voice at the same time.
  • the type of the set RTP media packet is divided into three types: call voice packet, IVR voice packet and DTMF packet. If the RTP media packet to be forwarded is the call voice packet A sent by the user terminal 1, the RTP media currently being forwarded The packet is the call voice packet B sent by the user terminal 2, and the types of the RTP media packet currently being forwarded and the received RTP media packet to be forwarded are both call voice packets, and the priority is the priority corresponding to the call voice packet.
  • the source terminal corresponding to the call voice package A is user terminal 1
  • the source terminal corresponding to the call voice package B is user terminal 2
  • the call voice package A and the call voice package B are two RTP media packets
  • the call voice package A It is mixed with the call voice packet B into an RTP media packet, and then the mixed RTP media packet is forwarded to the receiving end.
  • the receiving end can hear the user of user end 1 and the user of user end 2 talking at the same time.
  • the priority of the RTP media packet currently being forwarded is equal to the priority of the received RTP media packet to be forwarded, and the RTP media packet currently being forwarded corresponds to the received RTP media packet to be forwarded
  • the received RTP media packet to be forwarded is forwarded after the forwarding of the currently forwarded RTP media packet is completed.
  • the type of the set RTP media packet is divided into three types: call voice packet, IVR voice packet and DTMF packet.
  • the RTP media packet to be forwarded is the call voice packet A sent by the user terminal 1
  • the RTP media currently being forwarded The packet is the call voice packet B sent by the user terminal 1
  • the RTP media packet currently being forwarded and the received RTP media packet to be forwarded are both call voice packets
  • the priority is the priority corresponding to the call voice packet. Since the source end corresponding to call voice packet A and call voice packet B are both user end 1, which is an RTP media packet, the call voice packet B is first forwarded to the receiving end, and then the call voice packet A is forwarded to the receiving end. When the time, the receiving end can hear the user of user end 1 talking.
  • RTP media packets of the same priority of different channels When RTP media packets of the same priority of different channels appear, the RTP media packets of different channels of the same priority are mixed, thereby avoiding the direct forwarding of RTP media packets of different channels with the same priority to the user side, so that the user side Unable to parse the multi-channel media package.
  • the forwarding server includes a first state, a second state, a third state, and a fourth state.
  • the first state indicates the initial state
  • the second state indicates that the call voice packet is being forwarded
  • the current priority indication information of the forwarding server indicates the call voice packet
  • the third state indicates that the DTMF packet is being forwarded
  • the current priority indication information of the forwarding server indicates the priority of the DTMF packet
  • the fourth state indicates that the IVR voice packet is being forwarded
  • the current priority indication information of the forwarding server indicates the IVR voice packet Priority.
  • the type of the RTP media packet to be forwarded is determined according to the value of the PT field and the value of the CSRC field in the header of the RTP media packet to be forwarded.
  • the forwarding server adopts different processing methods according to the different priorities of the received RTP media packets to be forwarded:
  • the current state of the forwarding server is the first state. If an IVR voice packet is received, the state of the forwarding server is switched from the first state to the fourth state, and the current priority indication information is updated to indicate the IVR voice packet Priority of forwarding IVR voice packets. If a DTMF packet is received, the state of the forwarding server is switched from the first state to the third state, the current priority indication information is updated to indicate the priority of the DTMF packet, and the DTMF packet is forwarded. If the call voice packet is received, the state of the forwarding server is switched from the first state to the second state, the current priority indication information is updated to indicate the priority of the call voice packet, and the call voice packet is forwarded.
  • the current state of the forwarding server is the fourth state. If a DTMF packet is received, since the priority of the DTMF packet is lower than the priority of the IVR voice packet, the received DTMF packet is discarded and the first accumulated The value is increased by 1. Determine whether the first cumulative value is greater than the first preset threshold, and set the first preset threshold to 20. If it is greater, the state of the forwarding server switches from the fourth state to the first state, and the current priority indication information is updated to the initial state The priority of the state, otherwise continue to forward IVR voice packets. If a call voice packet is received, because the priority of the call voice packet is lower than the priority of the IVR voice packet, the received call voice packet is discarded, and the first cumulative value is increased by 1.
  • the state of the forwarding server switches from the fourth state to the first state, and the current priority indication information is updated to the initial state The priority of the state, otherwise continue to forward IVR voice packets. If the end packet is received, the state of the forwarding server is switched from the fourth state to the first state, and the current priority indication information is updated to the priority of the initial state.
  • the current state of the forwarding server is the third state. If an IVR voice packet is received, since the priority of the IVR voice packet is higher than the priority of the DTMF packet, the state of the forwarding server is switched from the third state to the fourth state. Status, update the current priority indication information to indicate the priority of the IVR voice packet, discard the DTMF packet being forwarded, and forward the IVR voice packet. If a call voice packet is received, because the priority of the call voice packet is lower than the priority of the DTMF packet, the received call voice packet is discarded, and the second cumulative value is increased by 1. Determine whether the second cumulative value is greater than the second preset threshold, and set the second preset threshold to 5.
  • the state of the forwarding server is switched from the third state to the second state, and the current priority indication information is updated to call The priority of the voice packet, otherwise continue to forward the DTMF packet. If the end packet is received, the state of the forwarding server is switched from the third state to the first state, and the current priority indication information is updated to the priority of the initial state.
  • the current state of the forwarding server is the second state. If an IVR voice packet is received, since the priority of the IVR voice packet is higher than the priority of the call voice packet, the state of the forwarding server is switched from the second state to the second state. Four states: update the current priority indication information to indicate the priority of the IVR voice packet, discard the call voice packet being forwarded, and forward the IVR voice packet. If a DTMF packet is received, since the priority of the DTMF packet is higher than the priority of the call voice packet, the state of the forwarding server switches from the second state to the third state, and the current priority indication information is updated to indicate the priority of the DTMF packet , Discard the call voice packet that is being forwarded, and forward the DTMF packet. If the end packet is received, the state of the forwarding server is switched from the second state to the first state, and the current priority indication information is updated to the priority of the initial state.
  • the forwarding server When the forwarding server receives multiple media packets, it preferentially forwards the RTP media packet with the highest priority among the RTP media packets to be forwarded, so that the forwarding server only forwards one media packet to the receiving end, which prevents the receiving end from being unable to Resolve the problem of the inability to hear the sound of multi-channel media packets. On the other hand, it ensures that important media packets are forwarded first, thereby ensuring the normal progress of user calls and improving user experience.
  • the forwarding server 1300 includes:
  • the receiving module 1301 is used to receive RTP media packets to be forwarded;
  • the analysis module 1302 is configured to determine the type of the RTP media packet to be forwarded
  • the processing module 1303 is configured to determine the priority of the RTP media packet to be forwarded according to the type of the RTP media packet to be forwarded;
  • the forwarding module 1304 is configured to forward the received RTP media packet to be forwarded and the RTP media packet with a higher priority among the RTP media packets currently being forwarded.
  • the forwarding module 1304 is specifically configured to:
  • the forwarding module 1304 is also used to:
  • the priority indication information is updated according to the priority of the received RTP media packet to be forwarded.
  • the forwarding module 1304 is also used to:
  • the forwarding module is further configured to: adjust the priority indicated by the priority indication information to the lowest priority, or a priority lower than the current priority indicated by the priority indication information, or The priority of the currently received RTP media packet to be forwarded.
  • the forwarding module 1304 is also used to:
  • the priority indicated by the priority indication information is adjusted to the lowest level.
  • the forwarding module 1304 is also used to:
  • the analysis module 1302 is specifically configured to:
  • the type of the RTP media packet to be forwarded is determined according to the PT field and the CSRC field in the header of the RTP media packet to be forwarded.
  • the types of RTP media packets include at least call voice packets, IVR voice packets, and DTMF packets;
  • the analysis module 1302 is specifically used for:
  • determining that the RTP media packet to be forwarded is a DTMF packet
  • determining that the RTP media packet to be forwarded is an IVR voice packet
  • the RTP media packet to be forwarded is a call voice packet.
  • an embodiment of the present application provides a computing device. As shown in FIG. 14, it includes at least one processor 1401 and a memory 1402 connected to the at least one processor.
  • the embodiment of the present application does not limit the processor.
  • the specific connection medium between the 1401 and the memory 1402 is, for example, the connection between the processor 1401 and the memory 1402 through a bus in FIG. 14.
  • the bus can be divided into address bus, data bus, control bus, etc.
  • the memory 1402 stores instructions that can be executed by at least one processor 1401, and the at least one processor 1401 can execute the steps included in the aforementioned method for forwarding media packets by executing the instructions stored in the memory 1402.
  • the processor 1401 is the control center of the computing device, which can use various interfaces and lines to connect to various parts of the terminal device, and forward the media by running or executing instructions stored in the memory 1402 and calling data stored in the memory 1402. package.
  • the processor 1401 may include one or more processing units, and the processor 1401 may integrate an application processor and a modem processor.
  • the application processor mainly processes the operating system, user interface, and application programs.
  • the adjustment processor mainly deals with wireless communication. It can be understood that the foregoing modem processor may not be integrated into the processor 1401.
  • the processor 1401 and the memory 1402 may be implemented on the same chip, and in some embodiments, they may also be implemented on separate chips.
  • the processor 1401 may be a general-purpose processor, such as a central processing unit (CPU), a digital signal processor, an application specific integrated circuit (ASIC), a field programmable gate array or other programmable logic devices, discrete gates or transistors Logic devices and discrete hardware components can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of the present application.
  • the general-purpose processor may be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of the present application may be directly embodied as being executed and completed by a hardware processor, or executed and completed by a combination of hardware and software modules in the processor.
  • the memory 1402 can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules.
  • the memory 1402 may include at least one type of storage medium, for example, may include flash memory, hard disk, multimedia card, card-type memory, random access memory (Random Access Memory, RAM), static random access memory (Static Random Access Memory, SRAM), Programmable Read Only Memory (PROM), Read Only Memory (ROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), magnetic memory, magnetic disk, optical disk and many more.
  • the memory 1402 is any other medium that can be used to carry or store desired program codes in the form of instructions or data structures and that can be accessed by a computer, but is not limited thereto.
  • the memory 1402 in the embodiment of the present application may also be a circuit or any other device capable of realizing a storage function for storing program instructions and/or data.
  • the embodiments of the present application provide a computer-readable storage medium that stores a computer program executable by a computer device.
  • the program runs on the computer device, the computer device executes the forwarding medium.
  • the steps of the package method are described below.
  • the embodiments of the present application may be provided as methods or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, this application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.
  • a computer-usable storage media including but not limited to disk storage, CD-ROM, optical storage, etc.
  • These computer program instructions can also be stored in a computer-readable memory that can guide a computer or other programmable data processing equipment to work in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture including the instruction device.
  • the device implements the functions specified in one process or multiple processes in the flowchart and/or one block or multiple blocks in the block diagram.
  • These computer program instructions can also be loaded on a computer or other programmable data processing equipment, so that a series of operation steps are executed on the computer or other programmable equipment to produce computer-implemented processing, so as to execute on the computer or other programmable equipment.
  • the instructions provide steps for implementing functions specified in a flow or multiple flows in the flowchart and/or a block or multiple blocks in the block diagram.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Telephonic Communication Services (AREA)

Abstract

本申请实施例提供了一种转发媒体包的方法及转发服务器,该方法包括:转发服务器在接收到待转发RTP媒体包时,确定待转发RTP媒体包的类型,然后根据待转发RTP媒体包的类型确定待转发RTP媒体包的优先级,并转发接收到的所述待转发RTP媒体包以及当前正在转发的RTP媒体包中优先级较高的RTP媒体包。

Description

一种转发媒体包的方法、转发服务器及存储介质
本申请要求于2019年4月16日提交中国专利局、申请号为201910303532.5、名称为“一种转发媒体包的方法及转发服务器”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请实施例涉及通信技术领域,尤其涉及一种转发媒体包的方法、转发服务器及存储介质。
背景
在普通的两人通话场景中,涉及的媒体包的类型较少且在通话过程中有严格的先后顺序。因此,可以通过策略控制确定多类媒体包到达转发设备的顺序和时间,由转发设备根据顺序转发媒体包。但是在融合通信场景下,语音通话的业务流程较复杂,不仅涉及多种不同类型的媒体包,同时不同类型的媒体包交叉使用的情况较多。
技术内容
本申请实施例提供了一种转发媒体包的方法,由转发服务器执行,包括:
接收待转发RTP媒体包;
确定所述待转发RTP媒体包的类型;
根据所述待转发RTP媒体包的类型确定所述待转发RTP媒体包的优先级;
转发接收到的所述待转发RTP媒体包以及当前正在转发的RTP媒体包中优先级较高的RTP媒体包。
本申请实施例提供了一种转发服务器,包括:
接收模块,用于接收待转发RTP媒体包;
分析模块,用于确定所述待转发RTP媒体包的类型;
处理模块,用于根据所述待转发RTP媒体包的类型确定所述待转发RTP媒 体包的优先级;
转发模块,用于转发接收到的所述待转发RTP媒体包以及当前正在转发的RTP媒体包中优先级较高的RTP媒体包。
在一些实施例中,所述转发模块还用于:
如果所述正在转发的RTP媒体包的优先级等于所述接收到的待转发RTP媒体包的优先级,且所述当前正在转发的RTP媒体包和接收到的待转发RTP媒体包对应的源端不同,则将所述当前正在转发的RTP媒体包和所述接收到的待转发RTP媒体包进行混合;
将混合后的RTP媒体包转发至接收端。
在一些实施例中,所述分析模块具体用于:
根据所述待转发RTP媒体包包头中的PT字段和CSRC字段确定所述待转发RTP媒体包的类型。
在一些实施例中,RTP媒体包的类型至少包括通话语音包、IVR语音包和DTMF包;
所述分析模块具体用于:
获取所述待转发RTP媒体包包头中PT字段的值;
在所述PT字段的值为第一预设值时,确定所述待转发RTP媒体包为DTMF包;
在所述PT字段的值为第二预设值时,获取所述待转发RTP媒体包包头中CSRC字段的值;
在所述CSRC字段的值为第三预设值时,确定所述待转发RTP媒体包为IVR语音包;
在所述CSRC字段的值为第四预设值时,确定所述待转发RTP媒体包为通话语音包。
本申请实施例提供了一种计算设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述程序时实现转发媒体包的方法的步骤。
本申请实施例提供了一种计算机可读存储介质,其存储有可由计算机设备执行的计算机程序,当所述程序在计算机设备上运行时,使得所述计算机设备执 行转发媒体包的方法的步骤。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简要介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域的普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1为本申请实施例提供的一种应用场景示意图;
图2为本申请实施例提供的一种呼叫应用程序的界面示意图;
图3为本申请实施例提供的一种融合通信平台的系统架构图;
图4为本申请实施例提供的一种转发媒体包的方法的流程示意图;
图5为本申请实施例提供的一种RTP媒体包包头的示意图;
图6为本申请实施例提供的一种确定RTP媒体包的类型的流程示意图;
图7为本申请实施例提供的一种确定RTP媒体包的类型的流程示意图;
图8为本申请实施例提供的一种确定RTP媒体包的类型的流程示意图;
图9为本申请实施例提供的一种转发媒体包的方法的流程示意图;
图10为本申请实施例提供的一种转发媒体包的方法的流程示意图;
图11为本申请实施例提供的一种转发媒体包的方法的流程示意图;
图12为本申请实施例提供的一种转发媒体包的方法的流程示意图;
图13为本申请实施例提供的一种转发服务器的结构示意图;
图14为本申请实施例提供的一种计算设备的结构示意图。
实施方式
为了使本申请的目的、技术方案及有益效果更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。
为了方便理解,下面对本申请实施例中涉及的名词进行解释。
融合通信:指通信技术和信息技术的融合。通信技术类的业务是指传统电信网的各类业务,例如电话业务、短信业务、会议电话、呼叫中心等。信息技术类 的业务是指IP类的各种业务,例如即时通信(IM);视频和应用共享,如视频监控、信息共享、下载业务;以及互联网业务,如电子邮件、语音邮件等。
PSTN:Public Switched Telephone Network,公共交换电话网络,一种常用旧式电话系统,即我们日常生活中常用的电话网。
RTP:Real-time Transport Protocol,实时传输协议,是一个网络传输协议,它是由IETF的多媒体传输工作小组1996年在RFC 1889中公布的,后在RFC3550中进行更新。
DTMF:Dual Tone Multi Frequency,双音多频信号,电话系统中电话机与交换机之间的一种用户信令,通常用于发送被叫号码。
RFC2833:一种主流的DTMF传送方式,为带内检测方式,通过RTP传输,由特殊的rtpPayloadType即TeleponeEvent来标示RFC2833数据包。
在具体实践过程中,本申请的发明人发现,传统的公共交换电话网络中,通话方较少且涉及的媒体包的类型较少,比如,两侧用户通信时,涉及的媒体包只有通话媒体包和互动式语音应答(InteractiveVoice Response,简称IVR)包。在通话过程中,采用预设的策略控制只有接收方接听电话前播放IVR语言,接听电话后结束播放IVR语言。因此,不会出现两路媒体包同时到达转发设备的情况,转发设备只需直接对接收的媒体包进行转发即可。但是在融合通信场景中,语音通话的业务流程较复杂,通话可能涉及多方,比如多方电话会议。涉及的媒体包的类型也较多,比如既包括通话语音和IVR语言等语音类媒体包,还可能包括DTMF等非语音媒体包。不同类型的媒体包交叉使用的情况特别多,融合通信平台不能采用策略控制所有媒体包到达转发设备的顺序,特别对于DTMF这种由用户侧触发的信号来说,用户在整个通话过程中都可能触发,随机性较强,无法通过策略进行控制。这样就可能导致多路媒体包同时到达转发设备,转发设备将多路媒体包同时转发至接收方时,将导致接收方无法解析而听到不到声音。
考虑到当多路媒体包同时到达转发服务器时,是因为转发服务器不做处理直接转发导致接收方听不到声音。鉴于此,本申请实施例中,转发服务器在接收到待转发RTP媒体包时,确定待转发RTP媒体包的类型,根据待转发RTP媒体包的类型确定待转发RTP媒体包的优先级,然后优先转发接收的所有待转发RTP媒体包中优先级最高的RTP媒体包,使转发服务器只转发一路媒体包至接收端, 从而避免接收端因无法解析多路媒体包而无法听到声音的问题。
本申请实施例中的转发媒体包的方法可以应用于融合通信场景,比如呼叫中心、多方电话会议、视频会议等。示例性地,如图1所示的呼叫中心场景中,包括呼叫中心设备101、融合通信平台102、运营商服务器103以及用户端104。
呼叫中心设备101为具备网络通信能力的电子设备,该电子设备可以是智能手机、平板电脑或便携式个人计算机等等。呼叫中心设备101上预先安装呼叫应用程序。客服人员可以在呼叫应用程序中显示的拨号键盘中输入用户号码,然后点击拨打按键。示例性地,如图2所示,呼叫应用程序的功能包括工作台、通讯录以及客户库。当客服人员点击工作台选项时,显示工作台界面。工作台界面中包括拨号键盘和通话记录,客服人员可以在拨号键盘界面中点击输入用户号码,工作台界面显示客服人员拨打的用户号码,然后点击拨打按键呼叫用户。客服人员也可以点击通讯录选项,在通讯录中查询用户号码,然后通过点击通讯录中用户号码呼叫用户。
呼叫中心设备101发送携带用户号码的通话请求至融合通信平台102,融合通信平台102将通话请求发送至运营商服务器103,运营商服务器103根据用户号码将通话请求转发至用户端104。在通话过程中,融合通信平台102可以转发客服人员和用户之间的通话语音媒体流。融合通信平台102还可以提供IVR语音服务以及DTMF服务。融合通信平台102发送IVR语音媒体流至运营商服务器103,由运营商服务器103将IVR语音媒体流转发至用户端104,在用户端104播放IVR语音。用户根据IVR语音的提示输入不同按键时,融合通信平台102根据用户输入的按键确定DTMF媒体流,之后再根据DTMF媒体流确定处理用户下一步的需求。融合通信平台102可以是一台服务器或若干台服务器组成的服务器集群或云计算中心,用户端104可以是智能手机。呼叫中心设备101通过无线网络与融合通信平台102连接,融合通信平台102通过无线网络与运营商服务器103连接,运营商服务器103通过无线网络与用户端104连接。
进一步地,在图1所示的应用场景图中,融合通信平台102的系统架构图如图3所示,融合通信平台102包括转发服务器1021、策略控制模块1022、IVR服务模块1023、DTMF服务模块1024。
呼叫中心设备101发送客服人员的通话语音媒体流至转发服务器1021。IVR 服务模块1023产生IVR语音媒体流,并将IVR语音媒体流发送至转发服务器1021。DTMF服务模块1024产生DTMF媒体流,并将DTMF媒体流发送至转发服务器1021。在建立通话时,策略控制模块1022可以控制通话语音媒体流和IVR语音媒体流到达转发服务器1021的顺序,比如先播放IVR语音,再进行通话。但是在通话过程中,通话语音媒体流、IVR语音媒体流以及DTMF信号也可能会出现交叉到达转发服务器1021的情况。转发服务器1021在同时接收到多路媒体流时,转发优先级最高的媒体流,丢弃优先级低的媒体流,从而使得运营商服务器103转发至用户端104的媒体流为一路媒体流,避免用户端104不能解析多路媒体流,使得用户听不到声音。
基于图1所示的应用场景图和图3所示的融合通信平台的系统架构示意图,本申请实施例提供了一种转发媒体包的方法的流程,该方法的流程可以由转发服务器执行,如图4所示,包括以下步骤:
步骤S401,接收待转发实时传输协议RTP媒体包。
步骤S402,确定待转发RTP媒体包的类型。
具体地,RTP媒体包为采用RTP协议进行转发的媒体包,根据不同的分类规则可以将RTP媒体包分为不同的类型。比如,RTP媒体包的类型可以分为通话语音包、IVR语音包和DTMF包三种类型。RTP媒体包的类型也可以分为语音包和非语音包两种类型。RTP媒体包的类型还可以分为通话语音包和非通话语音包两种类型。
步骤S403,根据待转发RTP媒体包的类型确定待转发RTP媒体包的优先级。
在一些实施例中,预先设定各个类型的RTP媒体包的优先级。比如,RTP媒体包的类型分为通话语音包、IVR语音包和DTMF包三种类型时,由于IVR语音包一般用于控制呼叫流程,因此可以将IVR语音包设定为第一优先级。在目前主流的RFC2833方式下,DTMF包优先级高于通话语音包,因此可以将DTMF包设定为第二优先级,将通话语音包设定为第三优先级。又比如,RTP媒体包的类型分为语音包和非语音包两种类型时,可以将语音包设定为第一优先级,将非语音包设定为第二优先级。又比如,RTP媒体包的类型分为通话语音包和非通话语音包两种类型时,可以将通话语音包设定为第一优先级,将非通话语音设定为第二优先级。在确定待转发RTP媒体包的类型后,根据待转发RTP媒体包的类 型查询预设的优先级可以确定待转发RTP媒体包的优先级。
示例性地,当RTP媒体包的类型分为通话语音包、IVR语音包和DTMF包三种类型时,若待转发RTP媒体包为通话语音包,则待转发RTP媒体包的类型为通话语音包,根据待转发RTP媒体包的类型可以确定通话语音包的优先级为第三优先级。
示例性地,当RTP媒体包的类型分为语音包和非语音包两种类型时,若待转发RTP媒体包为通话语音包,则待转发RTP媒体包的类型为语音包,根据待转发RTP媒体包的类型可以确定通话语音包的优先级为第一优先级。
示例性地,当RTP媒体包的类型分为通话语音包和非通话语音包两种类型时,若待转发RTP媒体包为通话语音包,则待转发RTP媒体包的类型为语音包,根据待转发RTP媒体包的类型可以确定通话语音包的优先级为第一优先级。
步骤S404,转发接收到的所述待转发RTP媒体包以及当前正在转发的RTP媒体包中优先级较高的RTP媒体包。
在一些实施例中,如果所述当前正在转发的RTP媒体包的优先级高于所述接收到的待转发RTP媒体包的优先级,则丢弃所述接收到的待转发RTP媒体包,所述当前正在转发的RTP媒体包的优先级由优先级指示信息指示;如果所述当前正在转发的RTP媒体包的优先级低于所述接收到的待转发RTP媒体包的优先级,则丢弃所述当前正在转发的RTP媒体包,并转发接收到的待转发RTP媒体包。
具体实施中,转发服务器在接收到待转发RTP包时,转发服务器中还存在正在转发的待转发RTP包,此时,比较接收到的待转发RTP包和正在转发的RTP媒体包的优先级,确定优先级较高的RTP媒体包,然后转发优先级较高的RTP媒体包,进而每次转发的都是优先级最高的RTP媒体包。
由于转发服务器在接收到多路媒体包时,优先转发优先级最高的RTP媒体包,使转发服务器只转发一路媒体包至接收端,避免接收端因无法解析多路媒体包而无法听到声音的问题,保证用户通话正常进行,从而提升用户体验。
在一些实施例中,在上述步骤S402中,确定待转发RTP媒体包的类型时,本申请实施例至少包括以下三种实施方式:
在一种可能的实施方式中,根据待转发RTP媒体包包头中的PT字段和 CSRC字段确定待转发RTP媒体包的类型。
具体地,RTP媒体包包头的格式如图5所示,RTP媒体包包头中包括PT字段,语音包和非语音包可以采用PT字段的值进行区分。比如,在信令协商阶段确定语音包和DTMF包各自对应的PT字段的值,采用PT字段的值区分语音包和DTMF包。
由于语音包可以细分为不同类型的语音包,比如语音包包括通话语音包和IVR语音包,通话语音包和IVR语音包使用共同的PT字段的值,因此需要进一步进行区分。本申请实施例中采用CSRC字段的值来区分不同类型的语音包。CSRC原本是用来标志对一个RTP混合器产生的新包有贡献的所有RTP包的源,而通话语音包不包含该字段,因此可以采用CSRC字段的值区分通话语音包和非通话语音包。比如,将IVR语音包中CSRC字段定义为CSRC=0xFFFFFFFE,为了明确指出一路IVR语音已经结束,定义了一种结束包,其CSRC=0xFFFFFFFF。根据CSRC字段的值可以区分通话语音包和IVR语音包。
示例性地,如图6所示,当RTP媒体包的类型包括通话语音包、IVR语音包和DTMF包三种类型时,确定接收的待转发RTP媒体包的类型包括以下步骤:
步骤S601,获取待转发RTP媒体包包头中PT字段的值。
步骤S602,在PT字段的值为第一预设值时,确定待转发RTP媒体包为DTMF包。
步骤S603,在PT字段的值为第二预设值时,获取待转发RTP媒体包包头中CSRC字段的值。
步骤S604,在CSRC字段的值为第三预设值时,确定待转发RTP媒体包为IVR语音包。
步骤S605,在CSRC字段的值为第四预设值时,确定待转发RTP媒体包为通话语音包。
在一种可能的实施方式中,根据待转发RTP媒体包包头中的PT字段确定待转发RTP媒体包的类型。
当RTP媒体包按照语音包和非语音包进行分类时,可以直接根据PT字段的值确定待转发RTP媒体包的类型。示例性地,如图7所示,当RTP媒体包的类型包括语音包和非语音包两个类型时,确定接收的待转发RTP媒体包的类型 包括以下步骤:
步骤S701,获取待转发RTP媒体包包头中PT字段的值。
步骤S702,在PT字段的值为第一预设值时,确定待转发RTP媒体包非语音包。
步骤S703,在PT字段的值为第二预设值时,确定待转发RTP媒体包语音包。
在一种可能的实施方式中,根据待转发RTP媒体包包头中的CSRC字段确定待转发RTP媒体包的类型。
当RTP媒体包按照通话语音包和非通话语音包进行分类时,可以直接根据CSRC字段的值确定待转发RTP媒体包的类型。示例性地,如图8所示,当RTP媒体包的类型包括通话语音包和非通话语音包时,确定待转发RTP媒体包的类型包括以下步骤:
步骤S801,获取待转发RTP媒体包包头中CSRC字段的值。
步骤S802,在CSRC字段的值为第三预设值时,确定待转发RTP媒体包为非通话语音包。
步骤S803,在CSRC字段的值为第四预设值时,确定待转发RTP媒体包为通话语音包。
由于采用媒体包包头中的特定字段区分媒体包,故转发服务器在接收到待转发媒体包时,可以根据待转发媒体包包头中特定字段的值确定待转发媒体包的类型,然后进一步确定待转发媒体包的优先级,便于后续根据待转发媒体包的优先级确定转发的媒体包。
在一些实施例中,在步骤S404中,转发服务器可以按照以下规则转发接收的所述待转发RTP媒体包以及当前正在转发的RTP媒体包中优先级较高的RTP媒体包:
如果当前正在转发的RTP媒体包的优先级高于接收到的待转发RTP媒体包的优先级,则丢弃接收到的待转发RTP媒体包。
示例性地,IVR语音包的优先级高于DTMF包的优先级,若当前正在转发的RTP媒体包为IVR语音包,接收到的待转发RTP媒体包为DTMF包时,丢弃接收到的DTMF包。
如果当前正在转发的RTP媒体包的优先级低于接收到的待转发RTP媒体包的优先级,则丢弃当前正在转发的RTP媒体包,并转发接收到的待转发RTP媒体包。
示例性地,DTMF包的优先级高于通话语音包的优先级,若当前正在转发的RTP媒体包为通话语音包,接收到的待转发RTP媒体包为DTMF包时,丢弃当前正在转发的通话语音包,并转发接收到的DTMF包。
示例性地,转发服务器当前为初始状态,接收到的待转发RTP媒体包为通话语音包时,转发接收到的通话语音包。
由于转发服务器在接收到待转发媒体包时,根据正在转发的媒体包和接收到的待转发媒体包之间的优先级,确定优先转发的媒体包,从而使得转发服务器只转发一路媒体包,避免用户端接收到多路媒体包无法解析而听不到声音。
在一些实施例中,转发服务器在判断正在转发的媒体包和接收到的待转发媒体包之间的优先级关系之前,可以根据优先级指示信息确定当前正在转发的RTP媒体包的优先级,其中,优先级指示信息用于指示当前正在转发的RTP媒体包的优先级。比如,当转发服务器正在转发IVR语音包时,转发服务器当前的优先级指示信息指示IVR语音包的优先级。当转发服务器为初始状态时,转发服务器当前的优先级指示信息指示初始状态的优先级,一般来说,初始状态的优先级为最低优先级。
若转发服务器当前正在转发的RTP媒体包改变时,转发服务器当前的优先级指示信息指示的优先级也随之更新。
在一种可能的实施方式中,如果当前正在转发的RTP媒体包的优先级低于接收到的待转发RTP媒体包的优先级,转发服务器则丢弃当前正在转发的RTP媒体包,并转发接收到的待转发RTP媒体包,并根据接收到的待转发RTP媒体包的优先级来更新优先级指示信息。
示例性地,当前正在转发的RTP媒体包为通话语音包,接收到的待转发RTP媒体包为DTMF包,丢弃通话语音包,并转发DTMF包,将转发服务器当前的优先级指示信息更新为指示DTMF包的优先级。
示例性地,若转发服务器当前的优先级指示信息指示初始状态的优先级,接收到的待转发RTP媒体包为通话语音包,则将转发服务器当前的优先级指示 信息更新为指示通话语音包的优先级。
在一些实施例中,当前正在转发的RTP媒体包的优先级高于接收到的待转发RTP媒体包的优先级时,丢弃接收到的待转发RTP媒体包,继续转发正在转发的RTP媒体包,由于正在转发的RTP媒体包没有改变,所以不更新优先级指示信息。
示例性地,若当前正在转发的RTP媒体包为IVR语音包,接收到的待转发RTP媒体包为DTMF包时,不更新优先级指示信息。
通过设置转发服务器的优先级指示信息,用于指示正在转发的RTP媒体包的优先级,故转发服务器接收到待转发媒体包时,可以根据优先级指示信息快速确定当前正在转发的RTP媒体包的优先级,然后进一步与接收的待转发RTP媒体包的优先级进行比较,确定优先转发的RTP媒体包,从而提高转发媒体包的效率。
在一些实施例中,由于转发服务器当前正在转发的RTP媒体包的优先级高于接收到的待转发RTP媒体包的优先级时,不更新优先级指示信息,故在当前正在转发的RTP媒体包转发结束后,为了避免在接收到比当前的优先级指示信息指示的优先级低的待转发RTP媒体包时,仍旧丢弃接收的待转发RTP媒体包,需要降低优先级指示信息指示的优先级。鉴于此,本申请实施例提供了至少两种降低优先级指示信息指示的优先级的实施方式:
在一种可能的实施方式中,累计丢弃的接收到的待转发RTP媒体包的数量,当累计的数量大于预设阈值时,调低优先级指示信息指示的优先级并重新开始累计丢弃的接收到的待转发RTP媒体包的数量。
在一些实施例中,所述当累计的数量大于预设阈值时,调低所述优先级指示信息指示的优先级,可以包括:将所述优先级指示信息指示的优先级调整为最低优先级,或者比所述优先级指示信息指示的当前优先级低的优先级,或者当前接收到的待转发RTP媒体包的优先级。
具体地,当前正在转发的RTP媒体包的优先级高于接收到的待转发RTP媒体包的优先级时,丢弃接收到的待转发RTP媒体包,累计值加1,依次类推。当累计值大于预设阈值,可以将优先级指示信息指示的优先级调整至当前优先级的次优先级,也可以将优先级指示信息指示的优先级调整至最低级,还可以将优先 级指示信息指示的优先级调整至其他预设优先级,例如当前接收到的待转发RTP媒体包的优先级。
示例性地,设定RTP媒体包包括四个优先级,按照优先级从高到低排序分别为第一优先级、第二优先级、第三优先级、第四优先级。设定当前的优先级指示信息指示第一优先级,当累计值大于预设阈值,可以将优先级指示信息更新为指示第二优先级。也可以将优先级指示信息更新为指示第四优先级,还可以将优先级指示信息更新为第三优先级。由于当前正在转发的RTP媒体包的优先级高于接收到的待转发RTP媒体包的优先级时,丢弃接收到的待转发RTP媒体包,并累计丢弃的接收到的待转发RTP媒体包,当累计值大于预设阈值时,调低优先级指示信息指示的优先级,故在当前正在转发的媒体流的结束包丢失时,仍旧能调低优先级指示信息指示的优先级,避免优先级指示信息始终指示高优先级而影响低优先级媒体包的转发。
在一种可能的实施方式中,当接收到的待转发RTP媒体包中包含会话结束标志符时,将优先级指示信息指示的优先级调整到最低级。
具体地,一段媒体流在转发结束后,采用携带会话结束标识的RTP媒体包标识结束媒体流的传输。示例性地,IVR语音中定义了一种结束包,会话结束标志符为CSRC=0xFFFFFFFF,当转发服务器接收到IVR语音包中包含会话结束标志符CSRC=0xFFFFFFFF时,将当前的优先级指示信息指示的优先级调整到最低级。由于当接收到的待转发RTP媒体包中包含会话结束标志符时,说明当前正在转发媒体流转发结束,此时将优先级指示信息指示的优先级调整到最低级时,便于顺利转发其他类型的媒体包。
在一些实施例中,在步骤S404中,当前正在转发的RTP媒体包的优先级等于接收到的待转发RTP媒体包的优先级时,本申请实施例至少提供以下两种转发RTP媒体包的实施方式:
在一种可能的实施方式中,当前正在转发的RTP媒体包的优先级等于接收到的待转发RTP媒体包的优先级,且当前正在转发的RTP媒体包和接收到的待转发RTP媒体包对应的源端不同时,将当前正在转发的RTP媒体包和接收到的待转发RTP媒体包进行混合,将混合后的RTP媒体包转发至接收端。
示例性地,设定RTP媒体包的类型分为语音包和非语音包两种类型,若待 转发RTP媒体包为IVR语音包,当前正在转发的RTP媒体包为通话语音包,则当前正在转发的RTP媒体包和接收到的待转发RTP媒体包的类型均为语音包,优先级均为语音包对应的优先级。由于IVR语音包和通话语音包对应的源端不同,为两路RTP媒体包,则将IVR语音包和通话语音包混合为一路RTP媒体包,然后将混合为一路的RTP媒体包转发至接收端,此时,接收端可以同时听到IVR语音和通话语音。
示例性地,设定RTP媒体包的类型分为通话语音包、IVR语音包和DTMF包三种类型,若待转发RTP媒体包为用户端1发送的通话语音包A,当前正在转发的RTP媒体包为用户端2发送的通话语音包B,则当前正在转发的RTP媒体包和接收到的待转发RTP媒体包的类型均为通话语音包,优先级均为通话语音包对应的优先级。由于通话语音包A对应的源端为用户端1,通话语音包B对应的源端为用户端2,因此通话语音包A和通话语音包B为两路RTP媒体包,则将通话语音包A和通话语音包B混合为一路RTP媒体包,然后将混合为一路的RTP媒体包转发至接收端,此时,接收端可以同时听到用户端1的用户和用户端2的用户在说话。
在一种可能的实施方式中,当前正在转发的RTP媒体包的优先级等于接收到的待转发RTP媒体包的优先级,且当前正在转发的RTP媒体包和接收到的待转发RTP媒体包对应的源端相同时,在当前正在转发的RTP媒体包转发结束后,转发接收到的待转发RTP媒体包。
示例性地,设定RTP媒体包的类型分为通话语音包、IVR语音包和DTMF包三种类型,若待转发RTP媒体包为用户端1发送的通话语音包A,当前正在转发的RTP媒体包为用户端1发送的通话语音包B,则当前正在转发的RTP媒体包和接收到的待转发RTP媒体包的类型均为通话语音包,优先级均为通话语音包对应的优先级。由于通话语音包A和通话语音包B对应的源端都为用户端1,为一路RTP媒体包,则先将通话语音包B转发至接收端,然后将通话语音包A转发至接收端,此时,接收端可以听到用户端1的用户在说话。
由于在出现不同路的优先级相同的RTP媒体包时,将不同路的优先级相同RTP媒体包进行混合,从而避免将优先级相同的不同路的RTP媒体包直接转发至用户端,使用户端无法解析多路媒体包的问题。
为了更好的解释本申请实施例,下面结合具体的实施场景描述本申请实施例提供的一种转发媒体包的方法,该方法由转发服务器执行,设定RTP媒体包的类型分为通话语音包、IVR语音包和DTMF包三种类型,IVR语音包的优先级高于DTMF包的优先级,DTMF包的优先级高于通话语音包的优先级。转发服务器包括第一状态、第二状态、第三状态、第四状态,其中,第一状态表示初始状态,第二状态表示正在转发通话语音包,转发服务器当前的优先级指示信息指示通话语音包的优先级,第三状态表示正在转发DTMF包,转发服务器当前的优先级指示信息指示DTMF包的优先级,第四状态表示正在转发IVR语音包,转发服务器当前的优先级指示信息指示IVR语音包的优先级。根据待转发RTP媒体包包头中PT字段的值和CSRC字段的值确定待转发RTP媒体包的类型。转发服务器在上述四种状态下,根据接收的待转发RTP媒体包的不同优先级采取不同的处理方式:
如图9所示,转发服务器当前的状态为第一状态,若接收到IVR语音包,转发服务器的状态从第一状态切换至第四状态,将当前的优先级指示信息更新为指示IVR语音包的优先级,转发IVR语音包。若接收到DTMF包,转发服务器的状态从第一状态切换至第三状态,将当前的优先级指示信息更新为指示DTMF包的优先级,转发DTMF包。若接收到通话语音包,转发服务器的状态从第一状态切换至第二状态,将当前的优先级指示信息更新为指示通话语音包的优先级,转发通话语音包。
如图10所示,转发服务器当前的状态为第四状态,若接收到DTMF包,由于DTMF包的优先级低于IVR语音包的优先级,则丢弃接收到的DTMF包,同时将第一累计值加1。判断第一累积值是否大于第一预设阈值,设定第一预设阈值为20,若大于,转发服务器的状态从第四状态切换至第一状态,将当前的优先级指示信息更新为初始状态的优先级,否则继续转发IVR语音包。若接收到通话语音包,由于通话语音包的优先级低于IVR语音包的优先级,则丢弃接收到的通话语音包,同时将第一累计值加1。判断第一累积值是否大于第一预设阈值,设定第一预设阈值为20,若大于,转发服务器的状态从第四状态切换至第一状态,将当前的优先级指示信息更新为初始状态的优先级,否则继续转发IVR语音包。若接收到结束包,转发服务器的状态从第四状态切换至第一状态,将当前的 优先级指示信息更新为初始状态的优先级。
如图11所示,转发服务器当前的状态为第三状态,若接收到IVR语音包,由于IVR语音包的优先级高于DTMF包的优先级,转发服务器的状态从第三状态切换至第四状态,将当前的优先级指示信息更新为指示IVR语音包的优先级,丢弃正在转发的DTMF包,转发IVR语音包。若接收到通话语音包,由于通话语音包的优先级低于DTMF包的优先级,则丢弃接收到的通话语音包,同时将第二累计值加1。判断第二累积值是否大于第二预设阈值,设定第二预设阈值为5,若大于,转发服务器的状态从第三状态切换至第二状态,将当前的优先级指示信息更新为通话语音包的优先级,否则继续转发DTMF包。若接收到结束包,转发服务器的状态从第三状态切换至第一状态,将当前的优先级指示信息更新为初始状态的优先级。
如图12所示,转发服务器当前的状态为第二状态,若接收到IVR语音包,由于IVR语音包的优先级高于通话语音包的优先级,转发服务器的状态从第二状态切换至第四状态,将当前的优先级指示信息更新为指示IVR语音包的优先级,丢弃正在转发的通话语音包,转发IVR语音包。若接收到DTMF包,由于DTMF包的优先级高于通话语音包的优先级,转发服务器的状态从第二状态切换至第三状态,将当前的优先级指示信息更新为指示DTMF包的优先级,丢弃正在转发的通话语音包,转发DTMF包。若接收到结束包,转发服务器的状态从第二状态切换至第一状态,将当前的优先级指示信息更新为初始状态的优先级。
由于转发服务器在接收到多路媒体包时,优先转发接收的各个待转发RTP媒体包中优先级最高的RTP媒体包,使转发服务器只转发一路媒体包至接收端,一方面避免接收端因无法解析多路媒体包而无法听到声音的问题,另一方面保证了重要的媒体包优先转发,从而保证用户通话正常进行,提升用户体验。
基于相同的技术构思,本申请实施例提供了一种转发服务器,如图13所示,该转发服务器1300包括:
接收模块1301,用于接收待转发RTP媒体包;
分析模块1302,用于确定所述待转发RTP媒体包的类型;
处理模块1303,用于根据所述待转发RTP媒体包的类型确定所述待转发RTP媒体包的优先级;
转发模块1304,用于转发接收到的所述待转发RTP媒体包以及当前正在转发的RTP媒体包中优先级较高的RTP媒体包。
在一些实施例中,所述转发模块1304具体用于:
如果所述当前正在转发的RTP媒体包的优先级高于接收到的待转发RTP媒体包的优先级,则丢弃接收到的待转发RTP媒体包,所述当前正在转发的RTP媒体包的优先级由优先级指示信息指示;
如果所述当前正在转发的RTP媒体包的优先级低于接收到的待转发RTP媒体包的优先级,则丢弃当前正在转发的RTP媒体包,并转发接收到的待转发RTP媒体包。
在一些实施例中,所述转发模块1304还用于:
如果所述当前正在转发的RTP媒体包的优先级低于接收到的待转发RTP媒体包的优先级,则根据所述接收到的待转发RTP媒体包的优先级来更新优先级指示信息。
在一些实施例中,所述转发模块1304还用于:
累计丢弃的所述接收到的待转发RTP媒体包的数量;
当累计的数量大于预设阈值时,调低所述优先级指示信息指示的优先级并重新开始累计丢弃的所述接收到的待转发RTP媒体包的数量。
在一些实施例中,所述转发模块还用于:将所述优先级指示信息指示的优先级调整为最低优先级,或者比所述优先级指示信息指示的当前优先级低的优先级,或者当前接收到的待转发RTP媒体包的优先级。
在一些实施例中,所述转发模块1304还用于:
当所述接收到的待转发RTP媒体包中包含会话结束标志符时,将所述优先级指示信息指示的优先级调整到最低级。
在一些实施例中,所述转发模块1304还用于:
当前正在转发的RTP媒体包的优先级等于接收到的待转发RTP媒体包的优先级,且当前正在转发的RTP媒体包和接收到的待转发RTP媒体包对应的源端不同时,将所述当前正在转发的RTP媒体包和所述接收到的待转发RTP媒体包进行混合;
将混合后的RTP媒体包转发至接收端。
在一些实施例中,所述分析模块1302具体用于:
根据所述待转发RTP媒体包包头中的PT字段和CSRC字段确定所述待转发RTP媒体包的类型。
在一些实施例中,RTP媒体包的类型至少包括通话语音包、IVR语音包和DTMF包;
所述分析模块1302具体用于:
获取所述待转发RTP媒体包包头中PT字段的值;
在所述PT字段的值为第一预设值时,确定所述待转发RTP媒体包为DTMF包;
在所述PT字段的值为第二预设值时,获取所述待转发RTP媒体包包头中CSRC字段的值;
在所述CSRC字段的值为第三预设值时,确定所述待转发RTP媒体包为IVR语音包;
在所述CSRC字段的值为第四预设值时,确定所述待转发RTP媒体包为通话语音包。
基于相同的技术构思,本申请实施例提供了一种计算设备,如图14所示,包括至少一个处理器1401,以及与至少一个处理器连接的存储器1402,本申请实施例中不限定处理器1401与存储器1402之间的具体连接介质,图14中处理器1401和存储器1402之间通过总线连接为例。总线可以分为地址总线、数据总线、控制总线等。
在本申请实施例中,存储器1402存储有可被至少一个处理器1401执行的指令,至少一个处理器1401通过执行存储器1402存储的指令,可以执行前述的转发媒体包的方法中所包括的步骤。
其中,处理器1401是计算设备的控制中心,可以利用各种接口和线路连接终端设备的各个部分,通过运行或执行存储在存储器1402内的指令以及调用存储在存储器1402内的数据,从而转发媒体包。可选的,处理器1401可包括一个或多个处理单元,处理器1401可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器1401中。 在一些实施例中,处理器1401和存储器1402可以在同一芯片上实现,在一些实施例中,它们也可以在独立的芯片上分别实现。
处理器1401可以是通用处理器,例如中央处理器(CPU)、数字信号处理器、专用集成电路(Application Specific Integrated Circuit,ASIC)、现场可编程门阵列或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件,可以实现或者执行本申请实施例中公开的各方法、步骤及逻辑框图。通用处理器可以是微处理器或者任何常规的处理器等。结合本申请实施例所公开的方法的步骤可以直接体现为硬件处理器执行完成,或者用处理器中的硬件及软件模块组合执行完成。
存储器1402作为一种非易失性计算机可读存储介质,可用于存储非易失性软件程序、非易失性计算机可执行程序以及模块。存储器1402可以包括至少一种类型的存储介质,例如可以包括闪存、硬盘、多媒体卡、卡型存储器、随机访问存储器(Random Access Memory,RAM)、静态随机访问存储器(StaticRandom Access Memory,SRAM)、可编程只读存储器(Programmable Read Only Memory,PROM)、只读存储器(ReadOnly Memory,ROM)、带电可擦除可编程只读存储器(Electrically Erasable Programmable Read-Only Memory,EEPROM)、磁性存储器、磁盘、光盘等等。存储器1402是能够用于携带或存储具有指令或数据结构形式的期望的程序代码并能够由计算机存取的任何其他介质,但不限于此。本申请实施例中的存储器1402还可以是电路或者其它任意能够实现存储功能的装置,用于存储程序指令和/或数据。
基于相同的技术构思,本申请实施例提供了一种计算机可读存储介质,其存储有可由计算机设备执行的计算机程序,当所述程序在计算机设备上运行时,使得所述计算机设备执行转发媒体包的方法的步骤。
本领域内的技术人员应明白,本申请的实施例可提供为方法、或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。
本申请是参照根据本申请实施例的方法、设备(系统)、和计算机程序产品 的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。
尽管已描述了本申请的优选实施例,但本领域内的技术人员一旦得知了基本创造性概念,则可对这些实施例作出另外的变更和修改。所以,所附权利要求意欲解释为包括优选实施例以及落入本申请范围的所有变更和修改。
显然,本领域的技术人员可以对本申请进行各种改动和变型而不脱离本申请的精神和范围。这样,倘若本申请的这些修改和变型属于本申请权利要求及其等同技术的范围之内,则本申请也意图包含这些改动和变型在内。

Claims (17)

  1. 一种转发媒体包的方法,由转发服务器执行,包括:
    接收待转发RTP媒体包;
    确定所述待转发RTP媒体包的类型;
    根据所述待转发RTP媒体包的类型确定所述待转发RTP媒体包的优先级;
    转发接收到的所述待转发RTP媒体包以及当前正在转发的RTP媒体包中优先级较高的RTP媒体包。
  2. 如权利要求1所述的方法,其中,所述转发接收到的所述待转发RTP媒体包以及当前正在转发的RTP媒体包中优先级较高的RTP媒体包,包括:
    如果所述当前正在转发的RTP媒体包的优先级高于所述接收到的待转发RTP媒体包的优先级,则丢弃所述接收到的待转发RTP媒体包,所述当前正在转发的RTP媒体包的优先级由优先级指示信息指示;
    如果所述当前正在转发的RTP媒体包的优先级低于所述接收到的待转发RTP媒体包的优先级,则丢弃所述当前正在转发的RTP媒体包,并转发接收到的待转发RTP媒体包。
  3. 如权利要求2所述的方法,其中,还包括:
    如果所述当前正在转发的RTP媒体包的优先级低于所述接收到的待转发RTP媒体包的优先级,则根据所述接收到的待转发RTP媒体包的优先级来更新所述优先级指示信息。
  4. 如权利要求2所述的方法,其中,丢弃所述接收到的待转发RTP媒体包之后,还包括:
    累计丢弃的所述接收到的待转发RTP媒体包的数量;
    当累计的数量大于预设阈值时,调低所述优先级指示信息指示的优先级并重新开始累计丢弃的所述接收到的待转发RTP媒体包的数量。
  5. 如权利要求4所述的方法,其中,所述当累计的数量大于预设阈值时,调低所述优先级指示信息指示的优先级,包括:
    将所述优先级指示信息指示的优先级调整为最低优先级,或者比所述优先级指示信息指示的当前优先级低的优先级,或者当前接收到的待转发RTP媒体 包的优先级。
  6. 如权利要求2所述的方法,其中,还包括:
    当所述接收到的待转发RTP媒体包中包含会话结束标志符时,将所述优先级指示信息指示的优先级调整到最低级。
  7. 如权利要求2~6任一项所述的方法,其中,还包括:
    如果所述当前正在转发的RTP媒体包的优先级等于所述接收到的待转发RTP媒体包的优先级,且所述当前正在转发的RTP媒体包和所述接收到的待转发RTP媒体包对应的源端不同,则将所述当前正在转发的RTP媒体包和所述接收到的待转发RTP媒体包进行混合;
    将混合后的RTP媒体包转发至接收端。
  8. 如权利要求1~7任一项所述的方法,其中,所述确定所述待转发RTP媒体包的类型,包括:
    根据所述待转发RTP媒体包包头中的PT字段和CSRC字段确定所述待转发RTP媒体包的类型。
  9. 如权利要求8所述的方法,其中,RTP媒体包的类型至少包括通话语音包、IVR语音包和DTMF包;
    所述根据所述待转发RTP媒体包包头中的PT字段和CSRC字段确定所述待转发RTP媒体包的类型,包括:
    获取所述待转发RTP媒体包包头中PT字段的值;
    在所述PT字段的值为第一预设值时,确定所述待转发RTP媒体包为DTMF包;
    在所述PT字段的值为第二预设值时,获取所述待转发RTP媒体包包头中CSRC字段的值;
    在所述CSRC字段的值为第三预设值时,确定所述待转发RTP媒体包为IVR语音包;
    在所述CSRC字段的值为第四预设值时,确定所述待转发RTP媒体包为通话语音包。
  10. 一种转发服务器,包括:
    接收模块,用于接收待转发RTP媒体包;
    分析模块,用于确定所述待转发RTP媒体包的类型;
    处理模块,用于根据所述待转发RTP媒体包的类型确定所述待转发RTP媒体包的优先级;
    转发模块,用于转发接收到的所述待转发RTP媒体包以及当前正在转发的RTP媒体包中优先级较高的RTP媒体包。
  11. 如权利要求10所述的转发服务器,其中,所述转发模块具体用于:
    如果所述当前正在转发的RTP媒体包的优先级高于接收到的待转发RTP媒体包的优先级,则丢弃所述接收到的待转发RTP媒体包,所述当前正在转发的RTP媒体包的优先级由优先级指示信息指示;
    如果所述当前正在转发的RTP媒体包的优先级低于所述接收到的待转发RTP媒体包的优先级,则丢弃所述当前正在转发的RTP媒体包,并转发接收到的待转发RTP媒体包。
  12. 如权利要求11所述的转发服务器,其中,所述转发模块还用于:
    如果所述当前正在转发的RTP媒体包的优先级低于所述接收到的待转发RTP媒体包的优先级,则根据所述接收到的待转发RTP媒体包的优先级来更新所述优先级指示信息。
  13. 如权利要求11所述的转发服务器,其中,所述转发模块还用于:
    累计丢弃的所述接收到的待转发RTP媒体包的数量;
    当累计的数量大于预设阈值时,调低所述优先级指示信息指示的优先级并重新开始累计丢弃的所述接收到的待转发RTP媒体包的数量。
  14. 如权利要求13所述的转发服务器,其中,所述转发模块还用于:将所述优先级指示信息指示的优先级调整为最低优先级,或者比所述优先级指示信息指示的当前优先级低的优先级,或者当前接收到的待转发RTP媒体包的优先级。
  15. 如权利要求11所述的转发服务器,其中,所述转发模块还用于:
    当所述接收到的待转发RTP媒体包中包含会话结束标志符时,将所述优先级指示信息指示的优先级调整到最低级。
  16. 一种计算设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述程序时实现权利要求1~9任一项所述方法的步骤。
  17. 一种计算机可读存储介质,其存储有可由计算机设备执行的计算机程序,当所述程序在计算机设备上运行时,使得所述计算机设备执行权利要求1~9任一项所述方法的步骤。
PCT/CN2020/081261 2019-04-16 2020-03-26 一种转发媒体包的方法、转发服务器及存储介质 WO2020211614A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP20791500.0A EP3958525A4 (en) 2019-04-16 2020-03-26 METHOD OF FORWARDING MEDIA PACKAGES, FORWARDING SERVER AND STORAGE MEDIUM
US17/344,163 US11876720B2 (en) 2019-04-16 2021-06-10 Media packet forwarding method, forwarding server, and storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910303532.5A CN110198279B (zh) 2019-04-16 2019-04-16 一种转发媒体包的方法及转发服务器
CN201910303532.5 2019-04-16

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US17/344,163 Continuation US11876720B2 (en) 2019-04-16 2021-06-10 Media packet forwarding method, forwarding server, and storage medium

Publications (1)

Publication Number Publication Date
WO2020211614A1 true WO2020211614A1 (zh) 2020-10-22

Family

ID=67751969

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/081261 WO2020211614A1 (zh) 2019-04-16 2020-03-26 一种转发媒体包的方法、转发服务器及存储介质

Country Status (4)

Country Link
US (1) US11876720B2 (zh)
EP (1) EP3958525A4 (zh)
CN (1) CN110198279B (zh)
WO (1) WO2020211614A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110198279B (zh) * 2019-04-16 2022-05-20 腾讯科技(深圳)有限公司 一种转发媒体包的方法及转发服务器

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103733580A (zh) * 2011-08-18 2014-04-16 Vid拓展公司 用于分组差别化的方法和系统
US20140307624A1 (en) * 2013-04-15 2014-10-16 Samsung Electronics Co., Ltd. Method and apparatus for scheduling video traffic in wireless communication system
CN106454201A (zh) * 2016-09-13 2017-02-22 国网天津市电力公司 一种基于ims 网络的视频会议接入服务质量保证方法
CN107147653A (zh) * 2017-05-22 2017-09-08 福建星网智慧科技股份有限公司 一种媒体分发级联方法及系统
CN110198279A (zh) * 2019-04-16 2019-09-03 腾讯科技(深圳)有限公司 一种转发媒体包的方法及转发服务器

Family Cites Families (21)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6614781B1 (en) * 1998-11-20 2003-09-02 Level 3 Communications, Inc. Voice over data telecommunications network architecture
US7233605B1 (en) * 1998-11-30 2007-06-19 Cisco Technology, Inc. Method and apparatus for minimizing delay induced by DTMF processing in packet telephony systems
US6947417B2 (en) * 2001-06-29 2005-09-20 Ip Unity Method and system for providing media services
US7272658B1 (en) * 2003-02-13 2007-09-18 Adobe Systems Incorporated Real-time priority-based media communication
CN1783835A (zh) * 2004-11-30 2006-06-07 西门子(中国)有限公司 一种在Internet网络中逐跳识别实时业务的方法
US20080037440A1 (en) * 2006-06-29 2008-02-14 Politowicz Timothy J Detecting voice over internet protocol traffic
US7929466B2 (en) * 2006-10-20 2011-04-19 The Boeing Company Prioritized channel assignment for wireless links
CN101409609A (zh) 2007-10-09 2009-04-15 北京信威通信技术股份有限公司 一种无线系统中高效可靠传输语音的方法及装置
CN101471854A (zh) * 2007-12-29 2009-07-01 华为技术有限公司 一种转发报文的方法及装置
US8265022B2 (en) * 2009-02-10 2012-09-11 Apple Inc. Apparatus and methods for transmission of emergency call data over wireless networks
JP5152110B2 (ja) * 2009-06-19 2013-02-27 富士通株式会社 パケット解析方法、プログラム及び装置
CA2681525A1 (en) * 2009-09-29 2011-03-29 Eileen A. Fraser Direct marketing system for matching caller value to risk and revenue
CN101742001B (zh) * 2009-11-19 2012-04-18 杭州华三通信技术有限公司 一种ip电话与ivr间数据信息交互方法、系统及装置
CN102195948B (zh) * 2010-03-15 2014-12-03 华为技术有限公司 数据处理方法、策略及计费执行功能和网关设备
KR20120084202A (ko) * 2011-01-19 2012-07-27 삼성전자주식회사 멀티미디어 데이터 패킷을 송신하는 방법 및 장치
US9001701B1 (en) * 2011-11-03 2015-04-07 Cisco Technology, Inc. Priority assignment and signaling of scalable video in a switch based system
US20140297805A1 (en) * 2013-03-29 2014-10-02 Alcatel-Lucent India Limited Method and apparatus for assigning priority levels to streams by a network element in a communications network
CN106302377B (zh) * 2015-06-29 2019-10-15 华为技术有限公司 媒体会话处理方法和相关设备及通信系统
CN106453312A (zh) * 2016-10-14 2017-02-22 沈阳化工大学 一种基于时隙的工业无线网络mac协议设计方法
JP7000988B2 (ja) * 2018-05-21 2022-01-19 富士通株式会社 パケット転送装置及びパケット転送方法
US11032092B2 (en) * 2018-06-20 2021-06-08 Mitel Networks Corporation System and method for recording and reviewing mixed-media communications

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103733580A (zh) * 2011-08-18 2014-04-16 Vid拓展公司 用于分组差别化的方法和系统
US20140307624A1 (en) * 2013-04-15 2014-10-16 Samsung Electronics Co., Ltd. Method and apparatus for scheduling video traffic in wireless communication system
CN106454201A (zh) * 2016-09-13 2017-02-22 国网天津市电力公司 一种基于ims 网络的视频会议接入服务质量保证方法
CN107147653A (zh) * 2017-05-22 2017-09-08 福建星网智慧科技股份有限公司 一种媒体分发级联方法及系统
CN110198279A (zh) * 2019-04-16 2019-09-03 腾讯科技(深圳)有限公司 一种转发媒体包的方法及转发服务器

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP3958525A4

Also Published As

Publication number Publication date
US11876720B2 (en) 2024-01-16
CN110198279A (zh) 2019-09-03
EP3958525A1 (en) 2022-02-23
CN110198279B (zh) 2022-05-20
EP3958525A4 (en) 2022-04-20
US20210306274A1 (en) 2021-09-30

Similar Documents

Publication Publication Date Title
US7995589B2 (en) Controlling voice communications over a data network
US6661886B1 (en) Method and system for real-time monitoring of voice mail during active call
US8670537B2 (en) Adjusting audio volume in a conference call environment
US7457242B2 (en) System for transmitting high quality speech signals on a voice over internet protocol network
EP1942646A2 (en) Multimedia conferencing method and signal
EP2067348B1 (en) Process for scalable conversation recording
US20160269521A1 (en) Communication endpoint call log notification
KR20100021435A (ko) 적극적인 화자 식별
US7460656B2 (en) Distributed processing in conference call systems
US8621003B2 (en) Enhanced application-layer multicast for peer-to-peer conferencing
WO2020211614A1 (zh) 一种转发媒体包的方法、转发服务器及存储介质
US20190215347A1 (en) Apparatus for call management and method thereof
US9148306B2 (en) System and method for classification of media in VoIP sessions with RTP source profiling/tagging
US20180097858A1 (en) Embedded side call sub-channel used in a telecommunication session
US8072909B2 (en) Apparatus and method for notification of a party in a telephone conference
US20060098798A1 (en) Method to selectively mute parties on a conference call
US8625577B1 (en) Method and apparatus for providing audio recording
CN104702807B (zh) 一种VoIP通信系统
CN109479071A (zh) 一种网络电话的处理方法及相关网络设备
US9363368B2 (en) Configurable call recording policy
US8391279B2 (en) Modem and calling packet processing method thereof
KR100598351B1 (ko) 이기종 망간의 다자간 회의 장치
TWI652932B (zh) 用於呼叫管理的方法、裝置及計算機可讀存儲介質
US8693665B1 (en) Method and apparatus for dynamically terminating calls over distinct access links
WO2012152116A1 (zh) 呼叫转接方法、系统及网页服务器

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20791500

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2020791500

Country of ref document: EP

Effective date: 20211116