Data exchange method and apparatus, and device

By establishing a terminal port association relationship in the media forwarding server, data forwarding is realized, which solves the problem of port resource occupation of the streaming media server and increases the number of terminal connections.

WO2024222574A1PCT designated stage expired Publication Date: 2024-10-31VIVO MOBILE COMM CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/088724
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-04-24
Filing Date
2024-04-19
Publication Date
2024-10-31

AI Technical Summary

Technical Problem

In the existing technology, the streaming media server needs to provide a dedicated port for each pair of terminals for data interaction, which results in a large amount of public network port resources being occupied and limits the maximum number of terminal connections that the server can support.

Method used

By receiving the information sent by the terminal in the media forwarding server, establishing the port association relationship between the terminals, and realizing data forwarding, only one public network port is needed to realize data transmission between any two terminals, saving port resources.

Benefits of technology

It realizes the reuse of public network ports, increases the maximum number of terminal connections that the server can support, and optimizes resource utilization.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024088724_31102024_PF_FP_ABST
    Figure CN2024088724_31102024_PF_FP_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of communications, and discloses a data exchange method and apparatus, and a device. The data exchange method comprises: receiving first information sent by a first terminal and second information sent by a second terminal, wherein the first information comprises a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to a first port, and the second information comprises a second terminal identifier corresponding to the second terminal, a second destination terminal identifier, and port information corresponding to a second port; when the first destination terminal identifier matches the second terminal identifier and the second destination terminal identifier matches the first terminal identifier, establishing an association relationship between the first port and the second port on the basis of the port information corresponding to the first port and the port information corresponding to the second port; and performing data exchange between the first terminal and the second terminal according to the association relationship.
Need to check novelty before this filing date? Find Prior Art

Description

Data interaction method, device and equipment

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS

[0002] This application claims priority to Chinese patent application No. 202310453075.4, filed on April 24, 2023, entitled “Data interaction method, device and apparatus,” the entire contents of which are incorporated herein by reference. Technical Field

[0003] The present application belongs to the field of communication technology, and specifically relates to a data interaction method, device and equipment. Background Art

[0004] With the development of communication technology, more and more people choose to communicate through audio and video calls.

[0005] Currently, audio and video calls between two terminals require data processing and forwarding through a streaming server. When any two terminals make a call, the streaming server needs to provide dedicated ports to enable data exchange between any two terminals. Therefore, the number of ports provided by the streaming server needs to be the same as the number of call terminals, which results in a large amount of streaming server port resources being occupied. Since streaming server port resources are limited, the mode of each call occupying some dedicated ports greatly restricts the maximum number of terminal connections that the streaming server can support.

[0006] Summary of the Invention

[0007] The purpose of the embodiments of the present application is to provide a data interaction method, device, equipment and storage medium that can save public network port resources and increase the maximum number of terminal connections that a server can support.

[0008] In a first aspect, an embodiment of the present application provides a data interaction method, applied to a server, the method comprising:

[0009] receiving first information sent by a first terminal and second information sent by a second terminal, wherein the first information includes a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to the first port, and the second information includes a second terminal identifier corresponding to the second terminal, a second destination terminal identifier, and port information corresponding to the second port;

[0010] When the first destination terminal identifier matches the second terminal identifier, and the second destination terminal identifier matches the first terminal identifier, establishing an association relationship between the first port and the second port based on the port information corresponding to the first port and the port information corresponding to the second port;

[0011] Data is exchanged between the first terminal and the second terminal according to the association relationship.

[0012] In a second aspect, an embodiment of the present application provides a data interaction method, applied to a first terminal, the method comprising:

[0013] Acquire a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to the first port;

[0014] Sending first information including the first terminal identifier, the first destination terminal identifier, and port information corresponding to the first port to a server, so that the server establishes an association relationship between the first port and the second port of the second terminal according to the first information and second information sent by the second terminal;

[0015] Based on the association relationship, data interaction is performed with the second terminal through the server.

[0016] In a third aspect, an embodiment of the present application provides a data interaction device, applied to a server, comprising:

[0017] an information receiving module, configured to receive first information sent by a first terminal and second information sent by a second terminal, wherein the first information includes a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to the first port, and the second information includes a second terminal identifier corresponding to the second terminal, a second destination terminal identifier, and port information corresponding to the second port;

[0018] a relationship establishing module, configured to establish an association relationship between the first port and the second port based on the port information corresponding to the first port and the port information corresponding to the second port, when the first destination terminal identifier matches the second terminal identifier and the second destination terminal identifier matches the first terminal identifier;

[0019] A data interaction module is configured to perform data interaction between the first terminal and the second terminal according to the association relationship.

[0020] In a fourth aspect, an embodiment of the present application provides a data interaction device, applied to a first terminal, the device comprising:

[0021] An information acquisition module, configured to acquire a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to the first port;

[0022] an information sending module, configured to send first information including the first terminal identifier, the first destination terminal identifier, and port information corresponding to the first port to a server, so that the server establishes an association relationship between the first port and the second port of the second terminal based on the first information and second information sent by the second terminal;

[0023] An information interaction module is used to interact with the second terminal through the server based on the association relationship.

[0024] In a fifth aspect, an embodiment of the present application provides an electronic device comprising a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the programs or instructions are executed by the processor, the steps of the method described in the first aspect or the second aspect are implemented.

[0025] In a sixth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the steps of the method described in the first aspect or the second aspect are implemented.

[0026] In the seventh aspect, an embodiment of the present application provides a chip, which includes a processor and a communication interface, the communication interface and the processor are coupled, and the processor is used to run programs or instructions to implement the method described in the first aspect or the second aspect.

[0027] In an eighth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and executed by at least one processor to implement the method described in the first aspect or the second aspect.

[0028] In a ninth aspect, an embodiment of the present application further provides an electronic device configured to execute the steps of the method described in the first aspect or the second aspect.

[0029] In an embodiment of the present application, by setting up a data forwarding service, receiving a first message sent by a first terminal and a second message sent by a second terminal, when the first destination terminal identifier in the first message matches the second terminal identifier in the second message, and the second destination terminal identifier in the second message matches the first terminal identifier in the first message, an association relationship is established between the first port provided by the first terminal and the second port provided by the second terminal, and the association relationship is used to forward data, thereby realizing data interaction between the first terminal and the second terminal. In this way, the server no longer needs to provide a dedicated data transmission port for each pair of terminals, but only needs to provide a port on the public network, receive the data that the terminal needs to transmit through the port, and forward data based on the association relationship between the terminal ports, thereby realizing data transmission between any two terminals, realizing the reuse of public network ports, saving public network port resources, and increasing the maximum number of terminal connections that the server can support. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] FIG1 is a schematic diagram of an architecture adapted by a data interaction method in related art;

[0031] FIG2 is a schematic diagram of an architecture adapted by the data interaction method provided in an embodiment of the present application;

[0032] FIG3 is a flow chart of a data interaction method provided by an embodiment of the present application;

[0033] FIG4 is a flow chart of a data interaction method provided by an embodiment of the present application;

[0034] FIG5 is a structural block diagram of a data interaction device provided by an embodiment of the present application;

[0035] FIG6 is a structural block diagram of a data interaction device provided by an embodiment of the present application;

[0036] FIG7 is a structural block diagram of an electronic device provided by an embodiment of the present application;

[0037] FIG8 is a schematic diagram of the hardware structure of an electronic device implementing an embodiment of the present application. DETAILED DESCRIPTION

[0038] The following will be combined with the accompanying drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the embodiments described are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field are within the scope of protection of this application.

[0039] The terms "first," "second," and the like in the specification and claims of this application are used to distinguish similar objects, and are not used to describe a specific order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate, so that the embodiments of this application can be implemented in an order other than that illustrated or described herein, and that the objects distinguished by "first," "second," and the like are generally of the same type, and do not limit the number of objects; for example, the first object can be one or more. In addition, the term "and / or" in the specification and claims refers to at least one of the connected objects, and the character " / " generally indicates that the objects connected are in an "or" relationship.

[0040] The following first explains the technical terms that may be involved in this application:

[0041] RTP (Realtime Transport Protocol): The RTP standard defines two sub-protocols, RTP and RTCP (Realtime Transport Control Protocol), for transmitting real-time data streams such as audio and video over unicast or multicast networks. Protocol packets are primarily transmitted over a network address and a pair of ports. One sub-protocol is used for media data streams, and the other is used for control data streams.

[0042] SIP (Session Initiation Protocol): Mainly used for signaling interaction in streaming media sessions, controlling the establishment, calling, updating, and destruction of the entire session.

[0043] SDP (Session Description Protocol): It is mainly used to negotiate the configuration parameters of media streams between terminals and is often transmitted to the other end as the message body of the signaling protocol along with the signaling.

[0044] ACK (Acknowledge character): In data communications, a transmission control character sent by the data receiving end to the data sending end. It indicates that the received data has been confirmed to be received correctly.

[0045] Currently, audio and video calls between two terminals require data processing and forwarding through a streaming media server. The streaming media service system uses SDP to negotiate audio and video parameter information. Therefore, a total of four ports are required, of which audio occupies two ports, transmitting the audio stream (also known as audio RTP) and the corresponding control packet (also known as audio RTCP) respectively. Video also occupies two ports, transmitting the video stream (also known as video RTP) and the corresponding control packet (also known as video RTCP) respectively.

[0046] As shown in Figure 1, when two terminals communicate, terminal 11 and streaming server 12 need to establish an RTP session. Terminal 11 also determines a pair of destination transport addresses. The destination transport address consists of a network address and four ports. Two of these four ports are used to transmit audio RTP packets and audio RTCP packets, and two are used to transmit video RTP packets and video RTCP packets.

[0047] In other words, any call between any two terminals requires a dedicated port on the streaming server to enable data exchange between them. For example, one call requires four ports on the streaming server, two calls require eight ports, and so on. The streaming server needs as many ports as there are pairs of terminals communicating. This results in a significant use of public network port resources. However, due to limited server port resources, the model of each call occupying a number of dedicated ports significantly limits the maximum number of terminal connections that the streaming server can support.

[0048] In order to solve the above technical problems, the present application provides a data interaction method, apparatus, device and storage medium. The data interaction method provided by the present application can be applied to the architecture shown in FIG2 , and will be described in detail in conjunction with FIG2 .

[0049] FIG2 is a schematic diagram of an architecture adapted by the data interaction method provided in an embodiment of the present application.

[0050] As shown in Figure 2, the architecture diagram may include a first terminal 21, a second terminal 22, a signaling server 23, a streaming media server 24, and a media forwarding server 25. The first terminal 21 and the second terminal 22 may be any terminal device such as a mobile phone or a computer. In addition to the first terminal 21 and the second terminal 22, the architecture may also include multiple other terminals (not shown in Figure 2), which are not limited here. Furthermore, the signaling server 23 may be a server in a streaming media service system for receiving and forwarding SIP signaling, the streaming media server 24 may be a server in a streaming media service system for controlling terminal calls and processing call data, and the media forwarding server 25 is a server provided in an embodiment of the present application for forwarding data between any two terminals.

[0051] For example, before first terminal 21 calls second terminal 22, or before second terminal 22 calls first terminal 21, first terminal 21 needs to send its registration information to signaling server 23 via SIP signaling. Signaling server 23 forwards the received registration information to streaming server 24, which processes the registration information of first terminal 21 and registers first terminal 21 online. Similarly, second terminal 22 also needs to register by sending SIP signaling to signaling server 23.

[0052] Based on the above architecture, the data interaction method provided in the embodiment of the present application is described in detail below through specific embodiments and their application scenarios in combination with the accompanying drawings.

[0053] It should be noted that the data interaction method provided in the embodiment of the present application can be executed by a data interaction device. In the embodiment of the present application, the data interaction method provided in the embodiment of the present application is described by taking the data interaction device executing the data interaction method as an example.

[0054] FIG3 is a flow chart of a data interaction method provided by an embodiment of the present application. The data interaction method can be applied to a server, such as the media forwarding server 25 in FIG2 .

[0055] As shown in FIG3 , the data interaction method may include steps S310 - S340 , which are described in detail below.

[0056] S310, receiving first information sent by a first terminal and second information sent by a second terminal, wherein the first information includes a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to the first port, and the second information includes a second terminal identifier corresponding to the second terminal, a second destination terminal identifier, and port information corresponding to the second port.

[0057] In an embodiment of the present application, before the first terminal and the second terminal formally interact with each other, the media forwarding server may first receive a first message sent by the first terminal and a second message sent by the second terminal, wherein the first message and the second message may be sent to the media forwarding server in the form of an RTP extension message.

[0058] Here, the first information may include the first terminal identifier corresponding to the first terminal, the first destination terminal identifier, and the port information corresponding to the first port, and the second information may include the second terminal identifier corresponding to the second terminal, the second destination terminal identifier, and the port information corresponding to the second port. The first terminal identifier may be an identifier that can uniquely identify the first terminal. The first destination terminal identifier may be a unique identifier of the destination terminal to which the first terminal needs to make a call. Similarly, the second terminal identifier may be an identifier that can uniquely identify the second terminal. The second destination terminal identifier may be a unique identifier of the destination terminal to which the second terminal needs to make a call. For example, the terminal identifier may be a mobile phone number, a MAC (Media Access Control) address, or the like.

[0059] In addition, the first port is a port configured in the first terminal for data exchange, and the second port is a port configured in the second terminal for data exchange. The port information may be, for example, a port number.

[0060] In some embodiments, the first port may include a first audio port and a first video port, and the second port may include a second audio port and a second video port. The first audio port and the second audio port may, for example, be audio RTP ports for sending and receiving audio RTP / RTCP data. The first video port and the second video port may, for example, be video RTP ports for sending and receiving video RTP / RTCP data.

[0061] Of course, when only an audio or video call is conducted, the first port and the second port may also include only one type of port, which is not limited here.

[0062] For example, as shown in Figure 2, before a first terminal 21 and a second terminal 22 send audio and video data to each other, the first terminal 21 first sends its own terminal identifier, the destination terminal identifier, its own audio RTP port information, its own video RTP port information, and other information via an RTP extension message to the media forwarding server 25. The media forwarding server 25 parses and registers the RTP extension message sent by the first terminal 21. Similarly, the media forwarding server 25 parses and registers the RTP extension message sent by the second terminal 22.

[0063] S320: When the first destination terminal identifier matches the second terminal identifier and the second destination terminal identifier matches the first terminal identifier, an association relationship is established between the first port and the second port based on the port information corresponding to the first port and the port information corresponding to the second port.

[0064] In the embodiment of the present application, after receiving information sent by the first terminal and the second terminal, the media forwarding server may match its own terminal identifier and the destination terminal identifier contained in the information of both parties.

[0065] Specifically, it can be that the first destination terminal identifier sent by the first terminal is matched with the second terminal identifier sent by the second terminal to determine whether the terminal that needs to transmit data with the first terminal is the second terminal, and the second destination terminal identifier sent by the second terminal is matched with the first terminal identifier sent by the first terminal to determine whether the terminal that needs to transmit data with the second terminal is the first terminal.

[0066] Exemplarily, as shown in FIG2 , after parsing and registering the RTP extension messages sent by the first terminal 21 and the second terminal 22 respectively, the media forwarding server 25 may cross-match its own terminal identifier and the destination terminal identifier carried in the messages of both parties to obtain a matching result.

[0067] In the embodiment of the present application, matching may be a matching result obtained when the terminal identifiers are the same, and mismatching may be a matching result obtained when the terminal identifiers are different.

[0068] In addition, the association relationship between the first port and the second port may be established by associating and saving the port information of the first port with the port information corresponding to the second port, and when one of the port information is queried, the other associated and saved port information may be obtained.

[0069] For example, as shown in FIG2 , if the destination terminal identifier of the first terminal 21 is the same as the terminal identifier of the second terminal 22, and the destination terminal identifier of the second terminal 22 is the same as the terminal identifier of the first terminal 21, then the data of the first terminal 21 will be sent to the second terminal 22, and the data of the second terminal 22 will be sent to the first terminal 21. In this way, the media forwarding server 25 can match the port information of the first port and the second port, indicating that subsequent data from the first terminal 21 will be sent to the second port of the second terminal 22, and data from the second terminal 22 will be sent to the first port of the first terminal 21.

[0070] In addition, in some embodiments, when the first port includes a first audio port and a first video port, and the second port includes a second audio port and a second video port, the above S320 may specifically include:

[0071] Establishing an association relationship between the first audio port and the second audio port based on the port information of the first audio port and the port information of the second audio port;

[0072] An association relationship between the first video port and the second video port is established based on the port information of the first video port and the port information of the second video port.

[0073] Exemplarily, the media forwarding server may correspond and associate the port information of the first audio port with the port information of the second audio port to establish an association relationship between the first audio port of the first terminal and the second audio port of the second terminal, and may also correspond and associate the port information of the first video port with the port information of the second video port to establish an association relationship between the first video port of the first terminal and the second video port of the second terminal.

[0074] In this way, by establishing an association relationship between the two audio ports and the two video ports respectively, it can be ensured that the audio and video RTP / RTCP data of the first terminal can be correctly forwarded to the second terminal respectively, and it can be ensured that the audio and video RTP / RTCP data of the second terminal can be correctly forwarded to the first terminal respectively, thereby improving the reliability of data transmission.

[0075] In addition, after the audio and video port information of the first terminal corresponds to the audio and video port information of the second terminal, this port association relationship can be recorded and maintained in the media forwarding server as a basis for data forwarding during subsequent data interaction.

[0076] S330: Perform data exchange between the first terminal and the second terminal according to the association relationship.

[0077] Here, the first terminal and the second terminal can transmit data to each other.

[0078] For example, when a first terminal sends data to a second terminal, the media forwarding server can forward the data sent by the first terminal to the second port based on the association between the first and second ports. Similarly, when the second terminal sends data to the first terminal, the media forwarding server can forward the data sent by the second terminal to the first port based on the association between the first and second ports, thereby enabling data exchange between the first and second terminals. In this way, the media forwarding server only needs to provide one port to receive data sent by the first and second terminals, thereby enabling data forwarding between different ports within the media forwarding server.

[0079] Thus, by setting up a data forwarding service, receiving the first information sent by the first terminal and the second information sent by the second terminal, when the first destination terminal identifier in the first information matches the second terminal identifier in the second information, and the second destination terminal identifier in the second information matches the first terminal identifier in the first information, an association relationship is established between the first port provided by the first terminal and the second port provided by the second terminal, and the association relationship is used to forward data, thereby realizing data interaction between the first terminal and the second terminal. In this way, the server no longer needs to provide a dedicated data transmission port for each pair of terminals, but only needs to provide a port on the public network, receive the data that the terminal needs to transmit through the port, and forward data based on the association relationship between the terminal ports, thereby realizing data transmission between any two terminals, realizing the reuse of public network ports, saving public network port resources, and increasing the maximum number of terminal connections that the server can support.

[0080] Based on this, in some implementations, the above S330 may specifically include:

[0081] receiving first data sent by a first terminal from a first port;

[0082] Determining a second port associated with the first port according to the association relationship;

[0083] forwarding the first data to the second port to send the first data to the second terminal;

[0084] and / or,

[0085] receiving second data sent by the second terminal from the second port;

[0086] Determining, based on the association relationship, a first port associated with the second port;

[0087] The second data is forwarded to the first port to send the second data to the first terminal.

[0088] Here, a target port may be set in the media forwarding server. The target port may be a port set on the public network by the streaming media service system for receiving and sending data sent by each terminal. The data may include at least one of audio data and video data. The audio data may include at least one of audio RTP data and audio RTCP data, and the video data may include at least one of video RTP data and video RTCP data.

[0089] For example, as shown in FIG2 , after the first terminal 21 sends the RTP extension message and receives the ACK confirmation message sent by the media forwarding server 25, it begins to send audio and video RTP / RTCP data normally to a media port provided by the media forwarding server 25 and set on the public network, so as to send the data to the media forwarding server 25. At this time, the media forwarding server 25 has already determined the forwarding destination of the audio and video data of the first terminal 21 through step S320, and then forwards the data according to the associated port information registered and saved in the server, and finally forwards the audio and video RTP / RTCP data of the first terminal 21 to the second terminal 22. The same applies when the second terminal 22 sends audio and video RTP / RTCP data to the first terminal 21, which will not be repeated here. At this point, the first terminal 21 and the second terminal 22 begin two-way audio and video RTP / RTCP data interaction.

[0090] In this way, each terminal only needs to know a target port provided by the media forwarding server to realize audio and video calls between any two terminals, thus realizing port multiplexing.

[0091] Based on this, in some embodiments, when the second port includes a second audio port and a second video port, if the first data includes first audio data and first video data, the step of forwarding the first data to the second port may specifically include:

[0092] forwarding the first audio data to the second audio port;

[0093] The first video data is forwarded to the second video port.

[0094] Here, the first audio data and the first video data may be forwarded to different types of second ports, respectively. Specifically, the first audio data may be forwarded to the second audio port, and the first video data may be forwarded to the second video port.

[0095] Exemplarily, the media forwarding server may forward the audio RTP / RTCP data sent by the first terminal to the audio port of the second terminal, and forward the video RTP / RTCP data sent by the first terminal to the video port of the second terminal.

[0096] In this way, the audio data and video data sent by the first terminal are forwarded to different ports of the second terminal respectively, which can improve the reliability of data transmission.

[0097] Similarly, in some embodiments, when the first port includes a first audio port and a first video port, if the first data includes first audio data and first video data, the step of forwarding the second data to the first port may specifically include:

[0098] forwarding the second audio data to the first audio port;

[0099] The second video data is forwarded to the first video port.

[0100] Here, the second audio data and the second video data may be forwarded to different types of first ports, respectively. Specifically, the second audio data may be forwarded to the first audio port, and the second video data may be forwarded to the first video port.

[0101] Exemplarily, the media forwarding server may forward the audio RTP / RTCP data sent by the second terminal to the audio port of the first terminal, and forward the video RTP / RTCP data sent by the second terminal to the video port of the first terminal.

[0102] In this way, the audio data and video data sent by the second terminal are forwarded to different ports of the first terminal respectively, which can improve the reliability of data transmission.

[0103] FIG4 is a flow chart of a data interaction method provided by an embodiment of the present application. The data interaction method can be applied to a terminal, such as the first terminal 21 or the second terminal 22 in FIG2 .

[0104] As shown in FIG4 , the data interaction method may include:

[0105] S410, obtaining a first terminal identifier corresponding to a first terminal, a first destination terminal identifier, and port information corresponding to a first port;

[0106] S420, sending first information including the first terminal identifier, the first destination terminal identifier, and port information corresponding to the first port to the server, so that the server establishes an association relationship between the first port and the second port of the second terminal based on the first information and second information sent by the second terminal;

[0107] S430: Based on the association relationship, data is exchanged with the second terminal through the server.

[0108] For the above explanations, please refer to the relevant parts of the aforementioned embodiments and will not be repeated here.

[0109] Thus, by sending a first message including a first terminal identifier, a first target terminal identifier, and port information corresponding to the first port to the server, the server establishes an association relationship between the first port of the first terminal and the second port of the second terminal based on the first message sent by the first terminal and the second message sent by the second terminal, and then uses this association relationship to forward data and realize data interaction between the first terminal and the second terminal. In this way, the server no longer needs to provide a dedicated data transmission port for each pair of terminals, but only needs to provide a port on the public network. Each terminal, such as the first terminal, can send or receive data to be transmitted through this port, and based on the association relationship between the terminal ports, data transmission between any two terminals is realized, thereby realizing the reuse of public network ports, saving public network port resources, and increasing the maximum number of terminal connections that the server can support.

[0110] In some implementations, before the above S420, the data interaction method provided in the embodiment of the present application may further include:

[0111] Acquire first terminal address information and first configuration parameters corresponding to the first terminal;

[0112] Sending call information for the second terminal to the server for forwarding to the second terminal through the server, wherein the call information includes the first terminal address information and the first configuration parameter, the call information is used to instruct the second terminal to establish the first data processing module according to the first configuration parameter, and instruct the second terminal to send response information to the first terminal through the server according to the first terminal address information, and the first data processing module is used to receive and process data sent by the first terminal;

[0113] receiving a response message sent by the server, wherein the response message includes second terminal address information corresponding to the second terminal and a second configuration parameter;

[0114] A second data processing module is established according to the second configuration parameters, wherein the second data processing module is used to receive and process data sent by the second terminal.

[0115] Here, the first terminal address information may include one or more candidate address information corresponding to the first terminal, and the first configuration parameter may be a parameter related to data processing. For example, when the data is audio or video data, the first configuration parameter may be an audio or video stream configuration parameter. Furthermore, the second terminal address information may include one or more candidate address information corresponding to the second terminal, and the second configuration parameter may be a parameter related to data processing.

[0116] In addition, the call information may be, for example, SIP call signaling, and correspondingly, the response information may be, for example, a SIP call response message.

[0117] For example, as shown in Figure 2, the first terminal 21 organizes and collects its own candidate address information and audio and video stream configuration parameters into SDP information, which is sent to the signaling server 23 as the message body of the SIP call signaling. The signaling server 23 forwards the received SIP call signaling to the streaming server 24. The streaming server 24 parses and processes the SIP call signaling, finds the second terminal 22 being called, and then forwards the SIP call signaling to the second terminal 22 through the signaling server 23.

[0118] The second terminal 22 parses the received SIP call signaling to find the message source, that is, the first terminal 21, and then similarly organizes its own candidate address information and audio and video stream configuration parameters and combines them into SDP information, which is sent to the signaling server 23 as the message body of the SIP call response message; the signaling server 23 forwards the SIP call response message to the streaming server 24. After receiving the SIP call response message, the streaming server 24 parses the SIP call response message to find the destination terminal to which the response message is sent, that is, the first terminal 21, and then forwards the SIP call response message to the first terminal 21 through the signaling server 23.

[0119] At the same time, the second terminal 22 obtains the audio and video media parameters of the first terminal 21 by parsing the received SIP call signaling, and establishes corresponding tasks such as data receiving channel, audio and video codec, etc. by parsing the media parameters, and prepares to receive data sent by the first terminal 21.

[0120] After receiving the SIP call response message from second terminal 22, first terminal 21 confirms that both parties have agreed on the relevant data configuration parameters. First terminal 21 then parses the SIP call response message to obtain the audio and video media parameters of second terminal 22. By parsing the media parameters, it establishes the corresponding data receiving channel, audio and video codecs, and other functions, preparing to receive data from second terminal 22.

[0121] In this way, by mutually transmitting terminal address information and configuration parameters between two terminals that need to communicate, data processing modules can be established on the two terminals respectively to process the subsequently received data.

[0122] In addition, in some implementations, the above S430 may specifically include:

[0123] When the server successfully establishes the association relationship, the first data is sent from the first port to the server, so that the server forwards the first data to the second port of the second terminal according to the association relationship.

[0124] Here, after the first terminal receives the ACK confirmation message sent by the server, it can be determined that the server has successfully established the association relationship between the first port and the second port, and data interaction with the second terminal can be started at this time.

[0125] In this way, after determining that the server has successfully established an association relationship, the first port of the first terminal sends the first data to the server, so that the server can forward the first data based on the association relationship between the first port and the second port. Therefore, there is no need for the server to set up a dedicated port for each call, and data can be sent from the first terminal to the second terminal, thereby realizing the reuse of the public network port.

[0126] In addition, when the second terminal sends data to the first terminal, the second terminal may send the second data to the server from the second port, so that the server forwards the second data to the first port of the first terminal according to the association relationship.

[0127] It should be noted that the application scenarios described in the above-mentioned embodiments of the present disclosure are intended to more clearly illustrate the technical solutions of the embodiments of the present disclosure, and do not constitute a limitation on the technical solutions provided by the embodiments of the present disclosure. Ordinary technicians in this field can know that with the emergence of new application scenarios, the technical solutions provided by the embodiments of the present disclosure are also applicable to similar technical problems.

[0128] Based on the same inventive concept, the present application also provides a data interaction device. The data interaction device provided in the embodiment of the present application is described in detail below with reference to FIG5 and FIG6.

[0129] FIG5 is a block diagram of a data interaction device according to an embodiment of the present application. The data interaction device may be configured on a server, such as the media forwarding server 25 in FIG2 .

[0130] As shown in FIG5 , the data interaction device 500 may include:

[0131] An information receiving module 501 is configured to receive first information sent by a first terminal and second information sent by a second terminal, wherein the first information includes a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to a first port, and the second information includes a second terminal identifier corresponding to the second terminal, a second destination terminal identifier, and port information corresponding to the second port;

[0132] a relationship establishing module 502, configured to establish an association relationship between the first port and the second port based on the port information corresponding to the first port and the port information corresponding to the second port, when the first destination terminal identifier matches the second terminal identifier and the second destination terminal identifier matches the first terminal identifier;

[0133] The data interaction module 503 is configured to perform data interaction between the first terminal and the second terminal according to the association relationship.

[0134] The data interaction device 500 is described in detail below.

[0135] In one embodiment, the data interaction module 503 may specifically include:

[0136] A first receiving submodule, configured to receive first data sent by the first terminal from the first port;

[0137] A first determining submodule, configured to determine the second port associated with the first port according to the association relationship;

[0138] a first forwarding submodule, configured to forward the first data to the second port, so as to send the first data to the second terminal;

[0139] and / or,

[0140] A second receiving submodule, configured to receive second data sent by the second terminal from the second port;

[0141] a second determining submodule, configured to determine the first port associated with the second port according to the association relationship;

[0142] The second forwarding submodule is configured to forward the second data to the first port, so as to send the second data to the first terminal.

[0143] In one embodiment, the first port may include a first audio port and a first video port, and the second port may include a second audio port and a second video port.

[0144] In one embodiment, the relationship establishing module 502 may specifically include:

[0145] a first establishing submodule, configured to establish an association relationship between the first audio port and the second audio port based on the port information of the first audio port and the port information of the second audio port;

[0146] The second establishing submodule is configured to establish an association relationship between the first video port and the second video port based on the port information of the first video port and the port information of the second video port.

[0147] In one embodiment, when the first data includes first audio data and first video data, the first forwarding submodule may specifically include:

[0148] a first forwarding unit, configured to forward the first audio data to the second audio port;

[0149] a second forwarding unit, configured to forward the first video data to the second video port;

[0150] In the case where the second data includes second audio data and second video data, the second forwarding submodule includes:

[0151] a third forwarding unit, configured to forward the second audio data to the first audio port;

[0152] The fourth forwarding unit is configured to forward the second video data to the first video port.

[0153] Thus, by setting up a data forwarding service, receiving the first information sent by the first terminal and the second information sent by the second terminal, when the first destination terminal identifier in the first information matches the second terminal identifier in the second information, and the second destination terminal identifier in the second information matches the first terminal identifier in the first information, an association relationship is established between the first port provided by the first terminal and the second port provided by the second terminal, and the association relationship is used to forward data, thereby realizing data interaction between the first terminal and the second terminal. In this way, the server no longer needs to provide a dedicated data transmission port for each pair of terminals, but only needs to provide a port on the public network, receive the data that the terminal needs to transmit through the port, and forward data based on the association relationship between the terminal ports, thereby realizing data transmission between any two terminals, realizing the reuse of public network ports, saving public network port resources, and increasing the maximum number of terminal connections that the server can support.

[0154] Figure 6 is a block diagram of a data interaction device according to an embodiment of the present application. The data interaction device may be configured in a terminal, such as the first terminal 21 or the second terminal 22 in Figure 2 .

[0155] As shown in FIG6 , the data interaction device 600 may include:

[0156] An information acquisition module 601 is configured to acquire a first terminal identifier corresponding to a first terminal, a first destination terminal identifier, and port information corresponding to a first port;

[0157] An information sending module 602 is configured to send first information including the first terminal identifier, the first destination terminal identifier, and port information corresponding to the first port to a server, so that the server establishes an association between the first port and the second port of the second terminal based on the first information and second information sent by the second terminal;

[0158] The information interaction module 603 is configured to perform data interaction with the second terminal through the server based on the association relationship.

[0159] The data interaction device 600 is described in detail below.

[0160] In one embodiment, the data interaction device 600 further includes:

[0161] a parameter acquisition module, configured to acquire first terminal address information and first configuration parameters corresponding to the first terminal before sending first information including the first terminal identifier, the first destination terminal identifier, and port information corresponding to the first port to the server;

[0162] a terminal calling module, configured to send a call message for the second terminal to a server for forwarding to the second terminal via the server, wherein the call message includes the first terminal address information and the first configuration parameters, the call message is used to instruct the second terminal to establish a first data processing module according to the first configuration parameters, and to instruct the second terminal to send a response message to the first terminal via the server according to the first terminal address information, the first data processing module being configured to receive and process data sent by the first terminal;

[0163] a response receiving module, configured to receive the response information sent by the server, wherein the response information includes second terminal address information corresponding to the second terminal and second configuration parameters;

[0164] A configuration establishment module is used to establish a second data processing module according to the second configuration parameters, wherein the second data processing module is used to receive and process data sent by the second terminal.

[0165] In one embodiment, the information interaction module 603 includes:

[0166] The data sending submodule is configured to send first data from the first port to the server when the server successfully establishes the association relationship, so that the server forwards the first data to the second port of the second terminal according to the association relationship.

[0167] Thus, by sending a first message including a first terminal identifier, a first target terminal identifier, and port information corresponding to the first port to the server, the server establishes an association relationship between the first port of the first terminal and the second port of the second terminal based on the first message sent by the first terminal and the second message sent by the second terminal, and then uses this association relationship to forward data and realize data interaction between the first terminal and the second terminal. In this way, the server no longer needs to provide a dedicated data transmission port for each pair of terminals, but only needs to provide a port on the public network. Each terminal, such as the first terminal, can send or receive data to be transmitted through this port, and based on the association relationship between the terminal ports, data transmission between any two terminals is realized, thereby realizing the reuse of public network ports, saving public network port resources, and increasing the maximum number of terminal connections that the server can support.

[0168] The data interaction device in the embodiments of the present application can be an electronic device or a component in an electronic device, such as an integrated circuit or chip. The electronic device can be a terminal or other device other than a terminal. For example, the electronic device can be a server, a network attached storage (NAS), a personal computer (PC), a cloud server, or a server cluster, etc., which is not specifically limited in the embodiments of the present application.

[0169] The data interaction device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.

[0170] The data interaction device provided in the embodiment of the present application can implement each process implemented by the method embodiment shown in Figures 3 and 4. To avoid repetition, they will not be described here.

[0171] Optionally, as shown in Figure 7, an embodiment of the present application also provides an electronic device 700, including a processor 701 and a memory 702, wherein the memory 702 stores programs or instructions that can be run on the processor 701. When the program or instructions are executed by the processor 701, the various steps of the above-mentioned data interaction method embodiment are implemented and the same technical effect can be achieved. To avoid repetition, they will not be repeated here.

[0172] It should be noted that the electronic devices in the embodiments of the present application include the above-mentioned mobile electronic devices and non-mobile electronic devices.

[0173] FIG8 is a schematic diagram of the hardware structure of an electronic device implementing an embodiment of the present application.

[0174] The electronic device 800 includes but is not limited to components such as a radio frequency unit 801 , a network module 802 , an audio output unit 803 , an input unit 804 , a sensor 805 , a display unit 806 , a user input unit 807 , an interface unit 808 , a memory 809 , and a processor 810 .

[0175] Those skilled in the art will appreciate that the electronic device 800 may further include a power source (e.g., a battery) to power various components. The power source may be logically connected to the processor 810 via a power management system, thereby enabling the power management system to manage charging, discharging, and power consumption. The electronic device structure shown in FIG8 does not limit the electronic device. The electronic device may include more or fewer components than shown, or may combine certain components, or have different component arrangements, which will not be described in detail here.

[0176] In some examples, the processor 810 is used to receive first information sent by a first terminal and second information sent by a second terminal, wherein the first information includes a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to the first port, and the second information includes a second terminal identifier corresponding to the second terminal, a second destination terminal identifier, and port information corresponding to the second port; when the first destination terminal identifier matches the second terminal identifier and the second destination terminal identifier matches the first terminal identifier, an association relationship between the first port and the second port is established based on the port information corresponding to the first port and the port information corresponding to the second port; and data interaction is performed between the first terminal and the second terminal based on the association relationship.

[0177] Optionally, the processor 810 is further used to receive first data sent by the first terminal from the first port; determine the second port associated with the first port based on the association relationship; forward the first data to the second port to send the first data to the second terminal; and / or receive second data sent by the second terminal from the second port; determine the first port associated with the second port based on the association relationship; forward the second data to the first port to send the second data to the first terminal.

[0178] Optionally, the processor 810 is further configured to establish an association relationship between the first audio port and the second audio port based on the port information of the first audio port and the port information of the second audio port; and to establish an association relationship between the first video port and the second video port based on the port information of the first video port and the port information of the second video port.

[0179] Optionally, the processor 810 is further configured to forward the first audio data to the second audio port; forward the first video data to the second video port; forward the second audio data to the first audio port; and forward the second video data to the first video port.

[0180] Thus, by setting up a data forwarding service, receiving the first information sent by the first terminal and the second information sent by the second terminal, when the first destination terminal identifier in the first information matches the second terminal identifier in the second information, and the second destination terminal identifier in the second information matches the first terminal identifier in the first information, an association relationship is established between the first port provided by the first terminal and the second port provided by the second terminal, and the association relationship is used to forward data, thereby realizing data interaction between the first terminal and the second terminal. In this way, the server no longer needs to provide a dedicated data transmission port for each pair of terminals, but only needs to provide a port on the public network, receive the data that the terminal needs to transmit through the port, and forward data based on the association relationship between the terminal ports, thereby realizing data transmission between any two terminals, realizing the reuse of public network ports, saving public network port resources, and increasing the maximum number of terminal connections that the server can support.

[0181] In other examples, the processor 810 is used to obtain a first terminal identifier, a first destination terminal identifier, and port information corresponding to a first port corresponding to a first terminal; send first information including the first terminal identifier, the first destination terminal identifier, and port information corresponding to the first port to a server, so that the server establishes an association relationship between the first port and the second port of the second terminal based on the first information and second information sent by the second terminal; and based on the association relationship, perform data interaction with the second terminal through the server.

[0182] Optionally, the processor 810 is also used to obtain first terminal address information and first configuration parameters corresponding to the first terminal; send call information for the second terminal to the server to forward it to the second terminal through the server, wherein the call information includes the first terminal address information and the first configuration parameters, and the call information is used to instruct the second terminal to establish a first data processing module according to the first configuration parameters, and instruct the second terminal to send response information to the first terminal through the server according to the first terminal address information, and the first data processing module is used to receive and process the data sent by the first terminal; receive the response information sent by the server, wherein the response information includes the second terminal address information and second configuration parameters corresponding to the second terminal; establish a second data processing module according to the second configuration parameters, wherein the second data processing module is used to receive and process the data sent by the second terminal.

[0183] Optionally, the processor 810 is further configured to, when the server successfully establishes the association relationship, send first data from the first port to the server, so that the server forwards the first data to the second port of the second terminal according to the association relationship.

[0184] Thus, by sending a first message including a first terminal identifier, a first target terminal identifier, and port information corresponding to the first port to the server, the server establishes an association relationship between the first port of the first terminal and the second port of the second terminal based on the first message sent by the first terminal and the second message sent by the second terminal, and then uses this association relationship to forward data and realize data interaction between the first terminal and the second terminal. In this way, the server no longer needs to provide a dedicated data transmission port for each pair of terminals, but only needs to provide a port on the public network. Each terminal, such as the first terminal, can send or receive data to be transmitted through this port, and based on the association relationship between the terminal ports, data transmission between any two terminals is realized, thereby realizing the reuse of public network ports, saving public network port resources, and increasing the maximum number of terminal connections that the server can support.

[0185] It should be understood that in an embodiment of the present application, the input unit 804 may include a graphics processing unit (GPU) 8041 and a microphone 8042, and the graphics processor 8041 processes the image data of a static picture or video obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The display unit 806 may include a display panel 8061, and the display panel 8061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 807 includes a touch panel 8071 and at least one of other input devices 8072. The touch panel 8071 is also called a touch screen. The touch panel 8071 may include two parts: a touch detection device and a touch controller. Other input devices 8072 may include, but are not limited to, a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.

[0186] The memory 809 can be used to store software programs and various data. The memory 809 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, applications or instructions required for at least one function (such as a sound playback function, an image playback function, etc.). In addition, the memory 809 may include a volatile memory or a non-volatile memory, or the memory 809 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. Volatile memory can be random access memory (RAM), static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct RAM bus random access memory (DRRAM). The memory 809 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.

[0187] Processor 810 may include one or more processing units. Optionally, processor 810 integrates an application processor and a modem processor. The application processor primarily handles operations related to the operating system, user interface, and application programs, while the modem processor primarily processes wireless communication signals, such as a baseband processor. It is understood that the modem processor may not be integrated into processor 810.

[0188] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the various processes of the above-mentioned data interaction method embodiment are implemented and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0189] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0190] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned data interaction method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0191] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.

[0192] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned data interaction method embodiment and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0193] It should be noted that, in this article, the terms "comprise", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element. In addition, it should be noted that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in the opposite order according to the functions involved. For example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.

[0194] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus the necessary general hardware platform, and of course can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), including a number of instructions for enabling a terminal (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods described in each embodiment of the present application.

[0195] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of this application, ordinary technicians in this field can also make many forms without departing from the purpose of this application and the scope of protection of the claims, all of which are within the protection of this application.

Claims

1. A data interaction method, applied to a server, comprising: Receive first information sent by a first terminal and second information sent by a second terminal, wherein the first information includes a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to a first port, and the second information includes a second terminal identifier corresponding to the second terminal, a second destination terminal identifier, and port information corresponding to a second port; When the first destination terminal identifier matches the second terminal identifier, and the second destination terminal identifier matches the first terminal identifier, establishing an association relationship between the first port and the second port based on the port information corresponding to the first port and the port information corresponding to the second port; Data is exchanged between the first terminal and the second terminal according to the association relationship.

2. The method according to claim 1, wherein: The performing data interaction between the first terminal and the second terminal according to the association relationship includes: receiving first data sent by the first terminal from the first port; Determine, according to the association relationship, the second port associated with the first port; forwarding the first data to the second port to send the first data to the second terminal; and / or, receiving second data sent by the second terminal from the second port; Determine, according to the association relationship, the first port associated with the second port; The second data is forwarded to the first port to send the second data to the first terminal.

3. A data interaction method, applied to a first terminal, comprising: Acquire a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to the first port; sending first information including the first terminal identifier, the first destination terminal identifier, and port information corresponding to the first port to the server, so that the server establishes a second port connection between the first port and the second terminal according to the first information and second information sent by the second terminal The relationship between the mouths; Based on the association relationship, data is exchanged with the second terminal through the server.

4. The method according to claim 3, wherein: Before sending the first information including the first terminal identifier, the first destination terminal identifier, and the port information corresponding to the first port to the server, the method further includes: Acquire first terminal address information and first configuration parameters corresponding to the first terminal; Sending call information for the second terminal to a server, so as to forward the call information to the second terminal through the server, wherein the call information includes the first terminal address information and the first configuration parameter, the call information is used to instruct the second terminal to establish a first data processing module according to the first configuration parameter, and instruct the second terminal to send response information to the first terminal through the server according to the first terminal address information, and the first data processing module is used to receive and process data sent by the first terminal; receiving the response information sent by the server, wherein the response information includes second terminal address information corresponding to the second terminal and a second configuration parameter; A second data processing module is established according to the second configuration parameters, wherein the second data processing module is used to receive and process data sent by the second terminal.

5. The method according to claim 3, wherein: The step of performing data interaction with the second terminal through the server based on the association relationship includes: When the server successfully establishes the association relationship, first data is sent from the first port to the server, so that the server forwards the first data to the second port of the second terminal according to the association relationship.

6. A data interaction device, applied to a server, comprising: an information receiving module, configured to receive first information sent by a first terminal and second information sent by a second terminal, wherein the first information includes a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to a first port, and the second information includes a second terminal identifier corresponding to the second terminal, a second destination terminal identifier, and port information corresponding to the second port; a relationship establishing module, configured to, when the first destination terminal identifier matches the second terminal identifier, and the second destination terminal identifier matches the first terminal identifier, establishing an association relationship between the first port and the second port based on the port information corresponding to the first port and the port information corresponding to the second port; A data interaction module is used to perform data interaction between the first terminal and the second terminal according to the association relationship.

7. The device according to claim 6, wherein: The data interaction module includes: A first receiving submodule, configured to receive first data sent by the first terminal from the first port; A first determining submodule, configured to determine the second port associated with the first port according to the association relationship; a first forwarding submodule, configured to forward the first data to the second port, so as to send the first data to the second terminal; and / or, A second receiving submodule, configured to receive second data sent by the second terminal from the second port; A second determining submodule, configured to determine the first port associated with the second port according to the association relationship; The second forwarding submodule is used to forward the second data to the first port to send the second data to the first terminal.

8. A data interaction device, applied to a first terminal, comprising: An information acquisition module, used to acquire a first terminal identifier corresponding to the first terminal, a first destination terminal identifier, and port information corresponding to the first port; an information sending module, configured to send first information including the first terminal identifier, the first destination terminal identifier, and port information corresponding to the first port to a server, so that the server establishes an association relationship between the first port and the second port of the second terminal according to the first information and second information sent by the second terminal; An information interaction module is used to perform data interaction with the second terminal through the server based on the association relationship.

9. The apparatus according to claim 8, further comprising: The parameter acquisition module is used to send a message including the first terminal identifier, the first Before obtaining the first information of the destination terminal identifier and the port information corresponding to the first port, obtaining the first terminal address information and the first configuration parameter corresponding to the first terminal; a terminal calling module, configured to send calling information for the second terminal to a server, so as to forward the calling information to the second terminal through the server, wherein the calling information includes the address information of the first terminal and the first configuration parameter, the calling information is used to instruct the second terminal to establish a first data processing module according to the first configuration parameter, and to instruct the second terminal to send a response information to the first terminal through the server according to the first terminal address information, and the first data processing module is used to receive and process the data sent by the first terminal; a response receiving module, configured to receive the response information sent by the server, wherein the response information includes second terminal address information corresponding to the second terminal and a second configuration parameter; A configuration establishment module is used to establish a second data processing module according to the second configuration parameters, wherein the second data processing module is used to receive and process data sent by the second terminal.

10. The device according to claim 8, wherein: The information interaction module includes: The data sending submodule is used to send first data from the first port to the server when the server successfully establishes the association relationship, so that the server forwards the first data to the second port of the second terminal according to the association relationship.

11. An electronic device comprising a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the program or instructions are executed by the processor, the steps of the data interaction method as described in any one of claims 1-2 or 3-5 are implemented.

12. A readable storage medium storing a program or instruction, wherein the program or instruction, when executed by a processor, implements the steps of the data interaction method according to any one of claims 1-2 or 3-5.

13. A computer program product, wherein the program product is stored in a storage medium and is executed by at least one processor to implement the steps of the data interaction method according to any one of claims 1-2 or 3-5.

14. An electronic device, configured to execute the steps of the data interaction method as described in any one of claims 1-2 or 3-5.

15. A chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the steps of the data interaction method as described in any one of claims 1-2 or 3-5.

Citation Information

Patent Citations

  • Packet transfer device and communication system

    CN101106524A

  • Data transmission method, data transmission device, data transmission system and electronic equipment

    CN112398845A

  • Uninterrupted transmission of internet protocol transmissions during endpoint changes

    US20150327320A1

  • Content sending method and apparatus, and content receiving method and apparatus

    US20210297462A1