CN114979261B - Service interaction method, terminal, server and system - Google Patents

Service interaction method, terminal, server and system Download PDF

Info

Publication number
CN114979261B
CN114979261B CN202110205950.8A CN202110205950A CN114979261B CN 114979261 B CN114979261 B CN 114979261B CN 202110205950 A CN202110205950 A CN 202110205950A CN 114979261 B CN114979261 B CN 114979261B
Authority
CN
China
Prior art keywords
quic
service
server
proxy server
module
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110205950.8A
Other languages
Chinese (zh)
Other versions
CN114979261A (en
Inventor
冯敬涛
陈方贵
郭建伟
丁建坤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN202110205950.8A priority Critical patent/CN114979261B/en
Publication of CN114979261A publication Critical patent/CN114979261A/en
Application granted granted Critical
Publication of CN114979261B publication Critical patent/CN114979261B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/16Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
    • H04L69/164Adaptation or special uses of UDP protocol
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/30Definitions, standards or architectural aspects of layered protocol stacks
    • H04L69/32Architecture of open systems interconnection [OSI] 7-layer type protocol stacks, e.g. the interfaces between the data link level and the physical level
    • H04L69/322Intralayer communication protocols among peer entities or protocol data unit [PDU] definitions
    • H04L69/326Intralayer communication protocols among peer entities or protocol data unit [PDU] definitions in the transport layer [OSI layer 4]

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer And Data Communications (AREA)

Abstract

The embodiment of the application is suitable for the technical field of communication, and provides a service interaction method, a terminal, a server and a system, wherein the method comprises the following steps: a QUIC proxy module in the terminal establishes a QUIC tunnel between the QUIC proxy module and a QUIC proxy server, and the QUIC proxy server is communicated with a service server through a TCP link; the application program in the terminal sends a service request message to the QUIC proxy module; the QUIC proxy module transmits the service request message to the QUIC proxy server through the QUIC tunnel; the QUIC proxy server transmits the service request message to the service server through the TCP link. By adopting the method, the problem of high difficulty in integrating the QUIC protocol in the client and the server in the prior art can be solved.

Description

Service interaction method, terminal, server and system
Technical Field
The embodiment of the application relates to the technical field of communication, in particular to a service interaction method, a terminal, a server and a system.
Background
In the field of computers, a client-server (C/S) mode employing a two-layer architecture is a relatively common network structure. In the C/S mode, the server is responsible for data management, and the client is responsible for completing interaction tasks with users. Typically, the client and server communicate using primarily the transmission control protocol (transmission control protocol, TCP) or the user datagram protocol (user datagram protocol, UDP). The TCP protocol mainly depends on a message retransmission mechanism on a link channel, and has high reliability. But with the TCP protocol, the burden of maintaining links is heavy. Although the UDP protocol avoids these burdens, it cannot guarantee the reliability of message transmission.
The low-latency internet transport layer protocol (quick UDP internet connection, QUIC) based on UDP well solves the problems faced by the TCP protocol and the UDP protocol, reduces the burden of maintaining links, and improves the reliability of message transmission.
However, the QUIC protocol is applied for communication, and both the client and the server are required to support the QUIC protocol. Furthermore, the QUIC protocol needs to be integrated for different application programs, and centralized processing cannot be performed. The integration process of the QUIC protocol is difficult and the cost is high.
Disclosure of Invention
The business interaction method, the terminal, the server and the system provided by the embodiment of the application are used for solving the problems of higher difficulty and higher cost of integrating the QUIC protocol between the client and the server in the prior art, improving the three-way handshake overhead caused by business interaction between the client and the server by using TCP (transmission control protocol) link, reducing the difficulty of integrating the QUIC protocol in the client and the server and facilitating the integration and use of the QUIC technology.
In order to achieve the above purpose, the embodiment of the present application adopts the following technical scheme:
In a first aspect, a service interaction method is provided, including:
a QUIC proxy module in the terminal establishes a QUIC tunnel between the QUIC proxy module and a QUIC proxy server, and the QUIC proxy server is communicated with a service server through a TCP link;
the application program in the terminal sends a service request message to the QUIC proxy module;
The QUIC proxy module transmits the service request message to the QUIC proxy server through the QUIC tunnel;
The QUIC proxy server transmits the service request message to the service server through the TCP link.
The service interaction method provided by the embodiment of the application has the following beneficial effects:
The terminal in the embodiment of the application can use the QUIC technology to carry out service interaction with the service server, and can improve the overhead of three-way handshake caused by carrying out service interaction by using TCP link; secondly, by using the QUIC proxy server, the method does not establish a direct QUIC tunnel between the terminal and the service server, but establishes the QUIC tunnel between the QUIC proxy module at the terminal side and the QUIC proxy server, thereby effectively reducing the difficulty of integrating the QUIC protocol in the client and the service server, solving the dependence on the intermediate network in the QUIC deployment process and facilitating the integration and use of the QUIC technology; thirdly, according to the method, a plurality of services can share the QUIC proxy server, thereby being beneficial to realizing decoupling of the QUIC technology and the services and being beneficial to deployment and evolution of the service.
In a possible implementation manner of the first aspect, after the transmission of the service request message to the service server by the qic proxy server through the TCP link, the method further includes: the service server processes the service request message to obtain a service response message; the service server sends the service response message to the QUIC proxy server through the TCP link; the QUIC proxy server forwards the service response message to the QUIC proxy module through the QUIC tunnel; the QUIC proxy module sends the service response message to the application program.
In a possible implementation manner of the first aspect, when an application program in the terminal sends a service request message to the qic proxy module, the application program may establish an internal TCP link with the qic proxy module; in this way, the application can send the service request message to the QUIC proxy module via the internal TCP link. The internal TCP link between the application and the QUIC proxy module can be maintained all the time after the establishment. When the terminal is in cell switching or network switching, the internal TCP link between the application program and the QUIC proxy module is not affected, and the stability of service processing can be maintained.
In a possible implementation manner of the first aspect, when the qic proxy module transmits the service request message to the qic proxy server through the qic tunnel, the qic proxy module needs to encapsulate the service request message according to a qic protocol requirement to obtain a first qic data packet; the QUIC proxy module then transmits the first QUIC data packet to the QUIC proxy server via the QUIC tunnel. In this way, the QUIC technology can be used for transmitting messages between the terminal and the QUIC proxy server, which is helpful for reducing the three-way handshake overhead caused by the use of the TCP protocol by the terminal.
In a possible implementation manner of the first aspect, when the qic proxy server transmits the service request message to the service server through the TCP link, the qic proxy server needs to decapsulate the first qic data packet to obtain the service request message, where the service request message carries address information of the service server; then, the QUIC proxy server transmits the service request message to the service server through the TCP link according to the address information. The above address information may be an IP address of a service server, for example. After the first qic packet is decapsulated by the qic proxy server, it may determine, according to the IP address, to which TCP link the service request message obtained after decapsulation needs to be sent.
In a possible implementation manner of the first aspect, when the quit proxy server forwards the service response message to the quit proxy module through the quit tunnel, the service response message needs to be encapsulated according to a quit protocol requirement to obtain a second quit data packet; the QUIC proxy server then forwards the second QUIC data packet to the QUIC proxy module via the QUIC tunnel.
In a possible implementation manner of the first aspect, after the quit proxy module receives a second quit packet forwarded by the quit proxy server, the second quit packet may be decapsulated to obtain the service response message; the QUIC proxy module may then send the service reply message to the application via an internal TCP link.
In a second aspect, a service interaction method is provided, where the method is applied to a terminal, and the method includes:
a QUIC proxy module in the terminal establishes a QUIC tunnel between the QUIC proxy module and a QUIC proxy server, and the QUIC proxy server is communicated with a service server through a TCP link;
the application program in the terminal sends a service request message to the QUIC proxy module;
The QUIC proxy module transmits the service request message to the QUIC proxy server through the QUIC tunnel, and the QUIC proxy server forwards the service request message to the service server through the TCP link.
In a possible implementation manner of the second aspect, the sending, by the application program in the terminal, a service request message to the QUIC proxy module includes: the application program establishes an internal TCP link with the QUIC proxy module; the application program sends the service request message to the QUIC proxy module through the internal TCP link.
In a possible implementation manner of the second aspect, the quit proxy module may further receive a second quit packet forwarded by the quit proxy server, where the second quit packet is obtained by the quit proxy server by encapsulating the service response message according to a quit protocol requirement after receiving the service response message returned by the service server for the service request message; the QUIC proxy module decapsulates the second QUIC data packet to obtain the service response message; the QUIC proxy module sends the service response message to the application program.
In a possible implementation manner of the second aspect, when the QUIC proxy module sends the service response message to the application program, the service response message may be sent to the application program through an established internal TCP link.
In a third aspect, a service interaction method is provided, where the method is applied to a proxy server, and the proxy server is a qic proxy server, and the method includes:
responding to a request of a QUIC proxy module in a terminal to establish a QUIC tunnel, wherein the QUIC proxy server establishes the QUIC tunnel between the QUIC proxy module and the QUIC proxy module, and the QUIC proxy server communicates with a service server through a TCP link;
The QUIC proxy server receives a first QUIC data packet sent by the QUIC proxy module through the QUIC tunnel, wherein the first QUIC data packet is obtained by encapsulating a service request message generated by an application program in the terminal according to the QUIC protocol requirement by the QUIC proxy module;
The QUIC proxy server decapsulates the first QUIC data packet to obtain the service request message;
The QUIC proxy server forwards the service request message to the service server via the TCP link.
In a possible implementation manner of the third aspect, after the quit proxy server forwards the service request message to the service server through the TCP link, the quit proxy server may further receive a service response message returned by the service server for the service request message through the TCP link; the QUIC proxy server encapsulates the service response message according to the QUIC protocol requirement to obtain a second QUIC data packet; and the QUIC proxy server forwards the second QUIC data packet to the QUIC proxy module through the QUIC tunnel, and the QUIC proxy module is used for sending the service response message to the application program after the second QUIC data packet is unpacked to obtain the service response message.
In a fourth aspect, a service interaction device is provided, where the device may be applied to a terminal, and the device may specifically include the following modules: a QUIC proxy module 1201, a service request message sending module 1202, wherein:
the QUIC proxy module is used for establishing a QUIC tunnel between the QUIC proxy module and a QUIC proxy server, and the QUIC proxy server is communicated with the service server through a TCP link.
And the service request message sending module is used for sending the service request message generated by the application program in the terminal to the QUIC proxy module.
The QUIC proxy module is further configured to transmit the service request message to the QUIC proxy server through the QUIC tunnel, and the QUIC proxy server forwards the service request message to the service server through the TCP link.
In a possible implementation manner of the fourth aspect, the apparatus further includes an internal TCP link establishment module. The internal TCP link establishment module is used for establishing an internal TCP link between the application program and the QUIC proxy module.
The service request message sending module is specifically configured to send the service request message to the QUIC proxy module through the internal TCP link.
In a possible implementation manner of the fourth aspect, the quit proxy module is further configured to receive a second quit packet forwarded by the quit proxy server, where the second quit packet is obtained by the quit proxy server by encapsulating the service response message according to a quit protocol requirement after receiving the service response message returned by the service server for the service request message.
The QUIC proxy module is further configured to decapsulate the second QUIC data packet to obtain the service response message; and sending the service response message to the application program.
In a possible implementation manner of the fourth aspect, the QUIC proxy module is specifically configured to send the service response message to the application program through an internal TCP link.
In a fifth aspect, a service interaction device is provided, where the service interaction device may be applied to a qic proxy server, and the service interaction device may specifically include the following modules: the device comprises a QUIC tunnel establishment module 1301, a first QUIC data packet receiving module 1302, a first QUIC data packet decapsulating module 1303 and a service request message forwarding module 1304, wherein:
The QUIC tunnel establishment module is used for responding to the request of the QUIC proxy module in the terminal for establishing the QUIC tunnel, establishing the QUIC tunnel between the QUIC proxy server and the QUIC proxy module, and the QUIC proxy server is communicated with the service server through a TCP link.
The first QUIC data packet receiving module is configured to receive, through the QUIC tunnel, a first QUIC data packet sent by the QUIC proxy module, where the first QUIC data packet is obtained by encapsulating, by the QUIC proxy module, a service request message generated by an application program in the terminal according to a QUIC protocol requirement.
And the first QUIC data packet decapsulation module is used for decapsulating the first QUIC data packet to obtain the service request message.
And the service request message forwarding module is used for forwarding the service request message to the service server through the TCP link.
In a possible implementation manner of the fifth aspect, the service request message forwarding module is specifically configured to: receiving a service response message returned by the service server aiming at the service request message through the TCP link; according to the QUIC protocol requirements, the service response message is packaged to obtain a second QUIC data packet; and forwarding the second QUIC data packet to the QUIC proxy module through the QUIC tunnel, wherein the QUIC proxy module is used for sending the service response message to the application program after the second QUIC data packet is unpacked to obtain the service response message.
In a sixth aspect, there is provided a terminal comprising a memory, a processor and a computer program stored in the memory and executable on the processor, the processor implementing the business interaction method of any of the second aspects when executing the computer program.
In a seventh aspect, there is provided a computer storage medium comprising computer instructions which, when run on a terminal, perform the business interaction method of any of the second aspects.
In an eighth aspect, there is provided a computer program product which, when run on a computer, causes the computer to perform the business interaction method of any of the second aspects.
In a ninth aspect, there is provided a server comprising a memory, a processor and a computer program stored in said memory and executable on said processor, said server being a qic proxy server, said processor implementing the business interaction method according to any of the third aspects when executing said computer program.
A tenth aspect provides a computer storage medium comprising computer instructions which, when run on a server, perform the business interaction method of any of the third aspects.
In an eleventh aspect, there is provided a computer program product which, when run on a computer, causes the computer to perform the business interaction method of any of the third aspects.
A twelfth aspect provides a service interaction system, including a terminal, and a server for performing service interaction with the terminal, where the server includes a proxy server and a service server, the terminal is the terminal in the sixth aspect, the proxy server is the QUIC proxy server in the ninth aspect, and a QUIC proxy module is integrated in the terminal. Wherein:
The QUIC proxy module is used for establishing a QUIC tunnel with the QUIC proxy server, receiving service request information generated by an application program in the terminal, transmitting the service request information to the QUIC proxy server through the QUIC tunnel, and communicating the QUIC proxy server with the service server through a TCP link.
The QUIC proxy server is used for transmitting the service request message to the service server through the TCP link.
In a possible implementation manner of the twelfth aspect, the service server is configured to process the service request message to obtain a service response message; and sending the service response message to the QUIC proxy server through the TCP link.
The QUIC proxy server is further used for forwarding the service response message to the QUIC proxy module through the QUIC tunnel.
The QUIC proxy module is also used for sending the service response message to the application program.
In a possible implementation manner of the twelfth aspect, the qic proxy module is specifically configured to establish an internal TCP link with the application program; and receiving the service request message sent by the application program through the internal TCP link.
In a possible implementation manner of the twelfth aspect, the quit proxy module is specifically configured to encapsulate the service request message according to a quit protocol requirement, so as to obtain a first quit packet; and transmitting the first QUIC data packet to the QUIC proxy server through the QUIC tunnel.
In a possible implementation manner of the twelfth aspect, the quit proxy server is specifically configured to decapsulate the first quit packet to obtain the service request message, where the service request message carries address information of the service server.
The QUIC proxy server is specifically configured to transmit the service request message to the service server through the TCP link according to the address information.
In a possible implementation manner of the twelfth aspect, the quit proxy server is specifically configured to encapsulate the service response message according to a quit protocol requirement, to obtain a second quit packet; and forwarding the second QUIC data packet to the QUIC proxy module through the QUIC tunnel.
In a possible implementation manner of the twelfth aspect, the quit proxy module is specifically configured to decapsulate the second quit packet to obtain the service response message; and sending the service response message to the application program through an internal TCP link.
In a thirteenth aspect, a chip is provided, the chip comprising a processor, which may be a general-purpose processor or a special-purpose processor. The processor is configured to support the terminal to perform the relevant steps, so as to implement the service interaction method in any one of the second aspects.
In a fourteenth aspect, a chip is provided, the chip comprising a processor, which may be a general-purpose processor or a special-purpose processor. Wherein the processor is configured to support the server to perform the relevant steps to implement the service interaction method according to any one of the third aspects.
It will be appreciated that the advantages of the second to fourteenth aspects may be found in the relevant description of the first aspect, and are not described here again.
Drawings
FIG. 1 is a schematic diagram of a business interaction process based on the TCP protocol;
FIG. 2 is a schematic diagram of a business interaction process based on the QUIC protocol;
Fig. 3 is a schematic diagram of a system architecture to which the service interaction method provided by the embodiment of the present application is applicable;
Fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present application;
FIG. 5 is a block diagram of a software architecture of an electronic device according to an embodiment of the present application;
Fig. 6 is a schematic step diagram of a service interaction method according to an embodiment of the present application;
FIG. 7 is a schematic diagram of a business interaction flow provided by an embodiment of the present application;
Fig. 8 is a schematic diagram of an application scenario of a service interaction method according to an embodiment of the present application;
fig. 9 is a schematic diagram of another application scenario of the service interaction method provided by the embodiment of the present application;
FIG. 10 is a schematic step diagram of another business interaction method according to an embodiment of the present application;
FIG. 11 is a schematic step diagram of another business interaction method according to an embodiment of the present application;
Fig. 12 is a block diagram of a service interaction device according to an embodiment of the present application;
Fig. 13 is a block diagram of another service interaction device according to an embodiment of the present application;
FIG. 14 is a block diagram of a business interaction system according to an embodiment of the present application;
fig. 15 is a block diagram of a server according to an embodiment of the present application.
Detailed Description
In order to clearly describe the technical solution of the embodiments of the present application, in the embodiments of the present application, the words "first", "second", etc. are used to distinguish the same item or similar items having substantially the same function and effect. For example, the first terminal, the second terminal, and the like are only for distinguishing between different terminal devices, and are not limited in number and order of execution.
It should be noted that, in the embodiments of the present application, words such as "exemplary" or "such as" are used to mean serving as an example, instance, or illustration. Any embodiment or design described herein as "exemplary" or "e.g." in an embodiment of the present application is not to be taken as preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "such as" is intended to present related concepts in a concrete fashion.
The service scenario described in the embodiment of the present application is for more clearly describing the technical solution of the embodiment of the present application, and does not constitute a limitation on the technical solution provided by the embodiment of the present application, and as a person of ordinary skill in the art can know that, with the appearance of a new service scenario, the technical solution provided by the embodiment of the present application is applicable to similar technical problems.
In the embodiments of the present application, "at least one" means one or more, and "a plurality" means two or more. "and/or", describes an association relationship of an association object, and indicates that there may be three relationships, for example, a and/or B, and may indicate: a alone, a and B together, and B alone, wherein a, B may be singular or plural. The character "/" generally indicates that the context-dependent object is an "or" relationship. "at least one of" or the like means any combination of these items, including any combination of single item(s) or plural items(s). For example, at least one (one) of a, b, or c may represent: a, b, c, a-b, a-c, b-c, or a-b-c, wherein a, b, c may be single or plural.
The steps involved in a service interaction method provided by the embodiment of the present application are merely examples, not all steps are necessarily performed, or not all the contents in each information or message are necessarily selected, and may be increased or decreased as needed in the use process.
The same steps or technical features having the same function in the embodiments of the present application may be referred to and referred to between different embodiments.
In order to facilitate understanding of the service interaction method provided by the embodiment of the present application, first, a description is made of related knowledge.
TCP protocol based business interaction process
As shown in fig. 1, a schematic diagram of a service interaction process based on the TCP protocol is shown. In fig. 1, a client 101 and a service server 102 are included. Wherein the client 101 may be a certain application in the terminal. Before the client 101 and the service server 102 perform service interaction by using a link established based on the TCP protocol, a three-way handshake is required to establish a link between the two. Namely, the processes of S11, S12, S13 shown in fig. 1.
In the first handshake, i.e. the S11 (TCP SYN) procedure shown in fig. 1, the client 101 actively requests to establish a link with the traffic server 102. In this process, the client 102 sends a synchronization sequence number (synchronize sequence numbers, SYN) to the traffic server 102.
In the second handshake, i.e. the S12 (TCP ACK, SYN) procedure shown in fig. 1, after the service server 102 receives the SYN sent by the client 101, it will send a SYN as a reply to the client 101, indicating that a request from the client 101 has been received.
In the third handshake, i.e. the S13 (TCP ACK) process shown in fig. 1, after receiving the SYN sent by the service server 102, the client 101 will respond to the service server 102, indicating that a returned message from the service server 102 has been received.
To this end, a link between the client 101 and the service server 102 is established. Then, the service interaction procedure between the client 101 and the service server 102 may be as shown in S14 and S15 in fig. 1.
In S14, the client 101 may send a service request (TCP request) to the service server 102 based on the established TCP link.
In S15, the service server 102 processes the service request of the client 101, and returns the processing result to the client 101 (request response).
The client 101 and the service server 102 perform service interaction by adopting the interaction process shown in fig. 1, and the service interaction mainly depends on a message retransmission mechanism on a link channel, so that the reliability of message transmission can be effectively ensured. The burden of maintaining TCP links between the client 101 and the service server 102 is heavy, including handshake overhead in establishing links between the client 101 and the service server 102, and link congestion control, etc.
On the other hand, in the service interaction process based on the UDP protocol, although the above-mentioned burden of the TCP protocol can be avoided, the reliability of the message transmission cannot be ensured. Therefore, in order to integrate the advantages of the TCP protocol and the UDP protocol and at the same time avoid the respective drawbacks, as a low-latency internet transmission protocol based on UPD improvement, the qic solves well the problems of the burden of maintaining the link and the reliable transmission of the message.
(II) QUIC protocol-based service interaction procedure
As shown in fig. 2, a schematic diagram of a service interaction process based on the QUIC protocol is shown. In fig. 2 (a), a client 201 and a service server 202 are included. When the client 201 and the service server 202 perform service interaction by adopting the QUIC protocol, it is required to ensure that both the client 201 and the service server 202 can support the QUIC protocol.
However, the process of integrating the QUIC protocol in the client 201 and the service server 202 is very heavy, difficult and costly. Further, the integration of the qic protocol on the client 201 side requires separate processing for different applications, and cannot be centralized. That is, for the integration process of the QUIC protocol, it is visible to the service and cannot be perceived.
On the other hand, as shown in fig. 2 (b), if the service interaction between the client 201 and the service server 202 needs to pass through the intermediate network 203 such as the content distribution network (content delivery network, CDN) or the edge computing node, the quit protocol does not support the intermediate network, the service interaction process cannot be performed normally, which is not beneficial to the evolution of the service.
Therefore, in order to solve the above-mentioned problems in the process of service interaction using the qic protocol, the embodiments of the present application provide a service interaction method, in which a direct link between a client and a service server is shielded by a proxy manner, a qic tunnel is established between the client and a qic proxy server, and the qic proxy server provides a qic protocol transmission service of an intermediate network layer for a service request of the client. Furthermore, the QUIC proxy server may also provide protocol conversion services so that interactions between the QUIC proxy server and the business server may be implemented using non-QUIC protocols. For example, the transmission of messages between the QUIC proxy server and the traffic server may be performed using the TCP protocol.
Fig. 3 is a schematic diagram of a system architecture to which the service interaction method according to the embodiment of the present application is applicable. In fig. 3, a terminal 301, a QUIC proxy server 302 and a service server 303 are included. Among them, the service server 303 may provide various service services such as service 1, service 2, … …, service N, and so on shown in fig. 3.
As shown in fig. 3, a quit agent module 3011 may be integrated in the terminal 301, and the quit agent module 3011 may be generated based on a quit agent software development kit (software development kit, SDK). Terminal 301 may provide front-end access to services and various applications in terminal 301 may be able to establish a QUIC tunnel, tunnel IF1 in FIG. 3, with QUIC proxy server 302 via QUIC proxy module 3011. Various applications in terminal 301 may communicate with QUIC proxy server 302 based on tunnel IF1.
The QUIC proxy server 302 may be used for unpacking and packing of QUIC tunnels and maintain link convergence with the traffic server 303. The business server 303 may be used to provide final services of the business, such as web page content, search results, and the like. Communication between the QUIC proxy server 302 and the traffic server 303 may be implemented based on the TCP protocol.
Specifically, multiple links IF2 may be established between the QUIC proxy server 302 and the traffic server 303 based on the TCP protocol, each link IF2 being used to transmit messages for one traffic service. The qic proxy server 302 may decapsulate the first message transmitted by an application in the terminal 301 via the tunnel IF1 after receiving the first message. The first message may be obtained by encapsulating the original service request message by the quit proxy module 3011 in the terminal 301 according to requirements of the quit protocol. Thus, the process of decapsulating the first message may be regarded as a process of restoring the original service request message. The QUIC proxy server 302 may then transmit the decapsulated first message (original service request message) to the service server 303 based on the link IF 2. For example, QUIC proxy server 302 may transmit a service request message to the server for providing service 1 in service server 303 by based on link IF 2. After processing the service request message, the service server 303 may send a second message to the qic proxy server 302 as a response to the service request message. The QUIC proxy server 302 may, after receiving the second message, tunnel package the second message as required by the QUIC protocol. Then, the qic proxy server 302 may send the encapsulated second message to the qic proxy module 3011 in the terminal 301 through the tunnel IF1, and the qic proxy module 3011 on the terminal 301 side decapsulates the encapsulated second message. The second message after the decapsulation is a response message of the service server 303 to the original service request message of a certain application in the terminal 301.
The service interaction procedure between the terminal 301 and the service server 303 is thus completed.
In an embodiment of the present application, the terminal 301 in fig. 3 may be an electronic device such as a mobile phone, a tablet computer, a wearable device, a vehicle-mounted device, an AR/VR device, a notebook computer, a personal computer (personal computer, PC), a netbook, a Personal Digital Assistant (PDA), and the like. The embodiment of the application does not limit the specific type of the electronic equipment.
By way of example, fig. 4 shows a schematic structural diagram of an electronic device 400. The structure of the terminal 301 described above may refer to the structure of the electronic device 400.
Electronic device 400 may include a processor 410, an external memory interface 420, an internal memory 421, a universal serial bus (universal serial bus, USB) interface 430, a charge management module 440, a power management module 441, a battery 442, an antenna 1, an antenna 2, a mobile communication module 450, a wireless communication module 460, an audio module 470, a speaker 470A, a receiver 470B, a microphone 470C, an ear-piece interface 470D, a sensor module 480, keys 490, a motor 491, an indicator 492, a camera 493, a display screen 494, and a user identification module (subscriber identification module, SIM) card interface 495, among others. Among other things, the sensor module 480 may include a pressure sensor 480A, a gyroscope sensor 480B, a barometric pressure sensor 480C, a magnetic sensor 480D, an acceleration sensor 480E, a distance sensor 480F, a proximity light sensor 480G, a fingerprint sensor 480H, a temperature sensor 480J, a touch sensor 480K, an ambient light sensor 480L, a bone conduction sensor 480M, and the like.
It should be understood that the illustrated structure of the embodiment of the present application does not constitute a specific limitation on the electronic device 400. In some embodiments of the application, electronic device 400 may include more or fewer components than shown, or may combine certain components, or split certain components, or a different arrangement of components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
Processor 410 may include one or more processing units. For example, the processor 410 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (IMAGE SIGNAL processor, ISP), a controller, a video codec, a digital signal processor (DIGITAL SIGNAL processor, DSP), a baseband processor, and/or a neural-Network Processor (NPU), etc. The different processing units may be separate devices or may be integrated in one or more processors.
The controller can generate operation control signals according to the instruction operation codes and the time sequence signals to finish the control of instruction fetching and instruction execution.
A memory may also be provided in the processor 410 for storing instructions and data. In some embodiments of the application, the memory in processor 410 is a cache memory. The memory may hold instructions or data that the processor 410 has just used or recycled. If the processor 410 needs to reuse the instruction or data, it may be called directly from the memory. Repeated accesses are avoided, reducing the latency of the processor 410 and thus improving the efficiency of the system.
In some embodiments of the application, the processor 410 may include one or more interfaces. The interfaces may include an integrated circuit (inter-INTEGRATED CIRCUIT, I2C) interface, an integrated circuit built-in audio (inter-INTEGRATED CIRCUIT SOUND, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous receiver transmitter (universal asynchronous receiver/transmitter, UART) interface, a mobile industry processor interface (mobile industry processor interface, MIPI), a general-purpose input/output (GPIO) interface, a subscriber identity module (subscriber identity module, SIM) interface, and/or a universal serial bus (universal serial bus, USB) interface, etc.
The I2C interface is a bi-directional synchronous serial bus comprising a serial data line (SERIAL DATA LINE, SDA) and a serial clock line (derail clock line, SCL). In some embodiments of the application, the processor 410 may contain multiple sets of I2C buses. The processor 410 may be coupled to the touch sensor 480K, charger, flash, camera 493, etc., respectively, through different I2C bus interfaces. For example, the processor 410 may couple the touch sensor 480K through an I2C interface, causing the processor 410 to communicate with the touch sensor 480K through an I2C bus interface, implementing the touch functionality of the electronic device 400.
The I2S interface may be used for audio communication. In some embodiments of the application, the processor 410 may contain multiple sets of I2S buses. The processor 410 may be coupled to the audio module 470 via an I2S bus to enable communication between the processor 410 and the audio module 470. In some embodiments of the present application, the audio module 470 may transmit an audio signal to the wireless communication module 460 through the I2S interface, so as to implement a function of answering a call through the bluetooth headset.
PCM interfaces may also be used for audio communication to sample, quantize and encode analog signals. In some embodiments of the present application, the audio module 470 and the wireless communication module 460 may be coupled by a PCM bus interface. In some embodiments of the present application, the audio module 470 may also transmit audio signals to the wireless communication module 460 through the PCM interface, so as to implement a function of answering a call through the bluetooth headset.
The UART interface is a universal serial data bus for asynchronous communications. The bus may be a bi-directional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments of the present application, a UART interface is typically used to connect the processor 410 with the wireless communication module 460. For example, the processor 410 communicates with a bluetooth module in the wireless communication module 460 through a UART interface to implement bluetooth functions. In some embodiments of the present application, the audio module 470 may transmit an audio signal to the wireless communication module 460 through a UART interface, so as to implement a function of playing music through a bluetooth headset.
The MIPI interface may be used to connect the processor 410 with peripheral devices such as the display screen 494, the camera 493, and the like. The MIPI interfaces include camera serial interfaces (CAMERA SERIAL INTERFACE, CSI), display serial interfaces (DISPLAY SERIAL INTERFACE, DSI), and the like.
In some embodiments of the present application, processor 410 and camera 493 communicate via a CSI interface to implement the photographing function of electronic device 400. The processor 410 and the display screen 494 communicate via a DSI interface to implement the display functions of the electronic device 400.
The GPIO interface may be configured by software. The GPIO interface may be configured as a control signal or as a data signal. In some embodiments of the present application, a GPIO interface may be used to connect the processor 410 with the camera 493, display screen 494, wireless communication module 460, audio module 470, sensor module 480, and the like. The GPIO interface may also be configured as an I2C interface, an I2S interface, a UART interface, an MIPI interface, etc.
The USB interface 430 is an interface conforming to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, or the like. The USB interface 430 may be used to connect a charger to charge the electronic device 400, or may be used to transfer data between the electronic device 400 and a peripheral device. The USB interface 430 may also be used to connect headphones through which audio is played. The interface may also be used to connect other electronic devices, such as AR devices, etc.
It should be understood that the interfacing relationship between the modules illustrated in the embodiments of the present application is only illustrative, and is not meant to limit the structure of the electronic device 400. In other embodiments of the present application, the electronic device 400 may also employ different interfaces in the above embodiments, or a combination of interfaces.
The charge management module 440 is configured to receive a charge input from a charger. The charger can be a wireless charger or a wired charger. In some wired charging embodiments, the charge management module 440 may receive a charging input of a wired charger through the USB interface 430. In some wireless charging embodiments, the charge management module 440 may receive wireless charging input through a wireless charging coil of the electronic device 400. The battery 442 may be charged by the charge management module 440, and the electronic device may be powered by the power management module 441.
The power management module 441 is configured to connect the battery 442, the charge management module 440, and the processor 410. The power management module 441 receives input from the battery 442 and/or the charge management module 440 to power the processor 410, the internal memory 421, the display screen 494, the camera 493, the wireless communication module 460, and the like. The power management module 441 may also be configured to monitor battery capacity, battery cycle times, battery health (leakage, impedance), and other parameters.
In other embodiments, the power management module 441 may also be disposed in the processor 410. In other embodiments, the power management module 441 and the charge management module 440 may be disposed in the same device.
The wireless communication function of the electronic device 400 may be implemented by the antenna 1, the antenna 2, the mobile communication module 450, the wireless communication module 460, a modem processor, a baseband processor, and the like.
The antennas 1 and 2 are used for transmitting and receiving electromagnetic wave signals. Each antenna in electronic device 400 may be used to cover a single or multiple communication bands. Different antennas may also be multiplexed to improve the utilization of the antennas. For example, the antenna 1 may be multiplexed into a diversity antenna of a wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
The mobile communication module 450 may provide a solution for wireless communication, including 2G/3G/4G/5G, as applied to the electronic device 400. The mobile communication module 450 may include at least one filter, switch, power amplifier, low noise amplifier (low noise amplifier, LNA), or the like. The mobile communication module 450 may receive electromagnetic waves from the antenna 1, perform processes such as filtering and amplifying on the received electromagnetic waves, and transmit the electromagnetic waves to the modem processor for demodulation. The mobile communication module 450 may amplify the signal modulated by the modem processor, and convert the signal into electromagnetic waves through the antenna 1 to radiate the electromagnetic waves.
In some embodiments of the present application, at least some of the functional modules of the mobile communication module 450 may be provided in the processor 410. In some embodiments of the present application, at least some of the functional modules of the mobile communication module 450 may be provided in the same device as at least some of the modules of the processor 410.
The modem processor may include a modulator and a demodulator. The modulator is used for modulating the low-frequency baseband signal to be transmitted into a medium-high frequency signal. The demodulator is used for demodulating the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low frequency baseband signal to a baseband processor for processing. The low frequency baseband signal is processed by the baseband processor and then transferred to the application processor. The application processor outputs sound signals through audio devices (not limited to speaker 470A, receiver 470B, etc.) or displays images or video through display screen 494.
In some embodiments of the application, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be provided in the same device as the mobile communication module 450 or other functional module, independent of the processor 410.
The wireless communication module 460 may provide solutions for wireless communication including wireless local area network (wireless local area networks, WLAN) (e.g., wi-Fi network, WIRELESS FIDELITY), bluetooth (BT), global navigation satellite system (global navigation SATELLITE SYSTEM, GNSS), frequency modulation (frequency modulation, FM), near Field Communication (NFC), infrared (IR), etc. applied to the electronic device 400. The wireless communication module 460 may be one or more devices that integrate at least one communication processing module. The wireless communication module 460 receives electromagnetic waves via the antenna 2, frequency modulates and filters the electromagnetic wave signals, and transmits the processed signals to the processor 410. The wireless communication module 460 may also receive a signal to be transmitted from the processor 410, frequency modulate and amplify the signal, and convert the signal into electromagnetic waves to radiate the electromagnetic waves through the antenna 2.
In some embodiments of the present application, antenna 1 and mobile communication module 450 of electronic device 400 are coupled, and antenna 2 and wireless communication module 460 are coupled, such that electronic device 400 may communicate with a network and other devices through wireless communication techniques. The wireless communication techniques can include a Global System for Mobile communications (global system for mobile communications, GSM), general packet radio service (GENERAL PACKET radio service, GPRS), code division multiple access (code division multiple access, CDMA), wideband code division multiple access (wideband code division multiple access, WCDMA), time division code division multiple access (time-division code division multiple access, TD-SCDMA), long term evolution (long term evolution, LTE), BT, GNSS, WLAN, NFC, FM, and/or IR techniques, among others. The GNSS may include a global satellite positioning system (global positioning system, GPS), a global navigation satellite system (global navigation SATELLITE SYSTEM, GLONASS), a beidou satellite navigation system (beidou navigation SATELLITE SYSTEM, BDS), a Quasi Zenith Satellite System (QZSS) SATELLITE SYSTEM, and/or a satellite based augmentation system (SATELLITE BASED AUGMENTATION SYSTEMS, SBAS).
The electronic device 400 implements display functions through a GPU, a display screen 494, an application processor, and the like. The GPU is a microprocessor for image processing, and is connected to the display screen 494 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 410 may include one or more GPUs that execute program instructions to generate or change display information.
The display screen 494 is used to display images, videos, and the like. The display screen 494 includes a display panel. The display panel may employ a Liquid Crystal Display (LCD) CRYSTAL DISPLAY, an organic light-emitting diode (OLED), an active-matrix organic LIGHT EMITTING diode (AMOLED), a flexible light-emitting diode (FLED), miniled, microLed, micro-oLed, a quantum dot LIGHT EMITTING diodes (QLED), or the like. In some embodiments of the application, the electronic device 400 may include 1 or N display screens 494, where N is a positive integer greater than 1.
The electronic device 400 may implement a photographing function through an ISP, a camera 493, a video codec, a GPU, a display screen 494, an application processor, and the like.
The ISP is used to process the data fed back by the camera 493. For example, when photographing, the shutter is opened, light is transmitted to the camera photosensitive element through the lens, the optical signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing, so that the electrical signal is converted into an image visible to naked eyes. ISP can also perform algorithm optimization on noise, brightness and skin color of the image. The ISP can also optimize parameters such as exposure, color temperature, etc. of the photographed scene. In some embodiments of the application, an ISP may be provided in the camera 493.
The camera 493 is used to capture still images or video. The object generates an optical image through the lens and projects the optical image onto the photosensitive element. The photosensitive element may be a charge coupled device (charge coupled device, CCD) or a Complementary Metal Oxide Semiconductor (CMOS) phototransistor. The photosensitive element converts the optical signal into an electrical signal, which is then transferred to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV, or the like format. In some embodiments of the present application, electronic device 400 may include 1 or N cameras 493, where N is a positive integer greater than 1.
The digital signal processor is used for processing digital signals, and can process other digital signals besides digital image signals. For example, when the electronic device 400 is selecting a frequency bin, the digital signal processor is used to fourier transform the frequency bin energy, or the like.
Video codecs are used to compress or decompress digital video. The electronic device 400 may support one or more video codecs. Thus, the electronic device 400 may play or record video in a variety of encoding formats, such as moving picture experts group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, MPEG4, and the like.
The NPU is a neural-network (NN) computing processor, and can rapidly process input information by referencing a biological neural network structure, for example, referencing a transmission mode between human brain neurons, and can also continuously perform self-learning. Applications such as intelligent recognition of the electronic device 400, e.g., image recognition, face recognition, voice recognition, text understanding, etc., may be implemented by the NPU.
The external memory interface 420 may be used to connect an external memory card, such as a Micro SD card, to enable expansion of the memory capabilities of the electronic device 400. The external memory card communicates with the processor 410 through an external memory interface 420 to implement data storage functions. For example, files such as music, video, etc. are stored in an external memory card.
The internal memory 421 may be used to store computer-executable program code that includes instructions. The internal memory 421 may include a storage program area and a storage data area. The storage program area may store an operating system, an application program (such as a sound playing function, an image playing function, etc.) required for at least one function, and the like. The storage data area may store data created during use of the electronic device 400 (e.g., audio data, phonebook, etc.), and so on.
In addition, the internal memory 421 may include a high-speed random access memory, and may also include a nonvolatile memory. Such as at least one disk storage device, flash memory device, universal flash memory (universal flash storage, UFS), etc.
The processor 410 performs various functional applications and data processing of the electronic device 400 by executing instructions stored in the internal memory 421 and/or instructions stored in a memory provided in the processor.
Electronic device 400 may implement audio functionality through audio module 470, speaker 470A, receiver 470B, microphone 470C, headphone interface 470D, and an application processor, among others. Such as music playing, recording, etc.
The audio module 470 is used to convert digital audio information into an analog audio signal output and also to convert an analog audio input into a digital audio signal. The audio module 470 may also be used to encode and decode audio signals. In some embodiments of the present application, the audio module 470 may be disposed in the processor 410, or some functional modules of the audio module 470 may be disposed in the processor 410.
Speaker 470A, also referred to as a "horn," is used to convert audio electrical signals into sound signals. The electronic device 400 may listen to music, or to hands-free conversations, through the speaker 470A.
A receiver 470B, also referred to as a "earpiece," is used to convert the audio electrical signal into a sound signal. When electronic device 400 is answering a telephone call or voice message, voice may be received by placing receiver 470B in close proximity to the human ear.
Microphone 470C, also referred to as a "microphone" or "microphone", is used to convert sound signals into electrical signals. When making a call or transmitting voice information, the user can sound near the microphone 470C through the mouth, inputting a sound signal to the microphone 470C. The electronic device 400 may be provided with at least one microphone 470C. In other embodiments, the electronic device 400 may be provided with two microphones 470C, which may implement noise reduction in addition to collecting sound signals. In other embodiments, the electronic device 400 may also be provided with three, four, or more microphones 470C to enable collection of sound signals, noise reduction, identification of sound sources, directional recording, etc.
The headphone interface 470D is for connecting a wired headphone. Earphone interface 470D may be a USB interface 430 or a 3.5mm open mobile electronic device platform (open mobile terminal platform, OMTP) standard interface, a american cellular telecommunications industry association (cellular telecommunications industry association of the USA, CTIA) standard interface.
The pressure sensor 480A is used for sensing a pressure signal, and can convert the pressure signal into an electrical signal. In some embodiments, pressure sensor 480A may be disposed on display screen 494. The pressure sensor 480A is of various kinds, such as a resistive pressure sensor, an inductive pressure sensor, a capacitive pressure sensor, and the like. The capacitive pressure sensor may be a capacitive pressure sensor comprising at least two parallel plates with conductive material. When a force is applied to the pressure sensor 480A, the capacitance between the electrodes changes. The electronic device 400 determines the strength of the pressure from the change in capacitance. When a touch operation is applied to the display screen 494, the electronic apparatus 400 detects the touch operation intensity according to the pressure sensor 480A. The electronic device 400 may also calculate the location of the touch based on the detection signal of the pressure sensor 480A.
In some embodiments of the present application, touch operations that act on the same touch location, but with different touch operation intensities, may correspond to different operation instructions. For example, when a touch operation with a touch operation intensity smaller than a first pressure threshold acts on the short message application icon, an instruction to view the short message is executed. And executing an instruction for newly creating the short message when the touch operation with the touch operation intensity being greater than or equal to the first pressure threshold acts on the short message application icon.
The gyro sensor 480B may be used to determine a motion gesture of the electronic device 400. In some embodiments of the application, the angular velocity of electronic device 400 about three axes (i.e., the x, y, and z axes) may be determined by gyro sensor 480B. The gyro sensor 480B may be used for photographing anti-shake. For example, when the shutter is pressed, the gyro sensor 480B detects the shake angle of the electronic device 400, calculates the distance to be compensated by the lens module according to the angle, and makes the lens counteract the shake of the electronic device 400 through the reverse motion, so as to realize anti-shake. The gyro sensor 480B may also be used for navigating, somatosensory game scenes.
The air pressure sensor 480C is used to measure air pressure. In some embodiments of the application, electronic device 400 calculates altitude, aids in positioning and navigation from barometric pressure values measured by barometric pressure sensor 480C.
The magnetic sensor 480D includes a hall sensor. The electronic device 400 may detect the opening and closing of the flip holster using the magnetic sensor 480D. In some embodiments of the present application, when the electronic device 400 is a flip machine, the electronic device 400 may detect opening and closing of the flip according to the magnetic sensor 480D, and further set the characteristics of automatic unlocking of the flip according to the detected opening and closing state of the holster or the opening and closing state of the flip.
The acceleration sensor 480E may detect the magnitude of acceleration of the electronic device 400 in various directions (typically three axes). The magnitude and direction of gravity may be detected when the electronic device 400 is stationary. The electronic equipment gesture recognition method can also be used for recognizing the gesture of the electronic equipment, and is applied to horizontal and vertical screen switching, pedometers and other applications.
A distance sensor 480F for measuring distance. The electronic device 400 may measure the distance by infrared or laser. In some embodiments of the application, for example, shooting a scene, the electronic device 400 may range using the distance sensor 480F to achieve fast focus.
Proximity light sensor 480G may include, for example, a Light Emitting Diode (LED) and a light detector, for example, a photodiode. The light emitting diode may be an infrared light emitting diode. The electronic device 400 emits infrared light outwards through the light emitting diode. The electronic device 400 detects infrared reflected light from nearby objects using a photodiode. When sufficient reflected light is detected, it may be determined that an object is in the vicinity of the electronic device 400. When insufficient reflected light is detected, the electronic device 400 may determine that there is no object in the vicinity of the electronic device 400. The electronic device 400 may detect that the user holds the electronic device 400 near the ear to talk using the proximity light sensor 480G, so as to automatically extinguish the screen for power saving purposes. The proximity light sensor 480G may also be used in holster mode, pocket mode to automatically unlock and lock the screen.
The ambient light sensor 480L is used to sense ambient light level. The electronic device 400 may adaptively adjust the brightness of the display screen 494 based on the perceived ambient light level. The ambient light sensor 480L may also be used to automatically adjust white balance during photographing. Ambient light sensor 480L may also cooperate with proximity light sensor 480G to detect whether electronic device 400 is in a pocket to prevent false touches.
The fingerprint sensor 480H is used to collect a fingerprint. The electronic device 400 may utilize the collected fingerprint characteristics to realize fingerprint unlocking, access an application lock, fingerprint photographing, fingerprint incoming call answering, and the like.
The temperature sensor 480J detects temperature. In some embodiments of the application, the electronic device 400 performs a temperature processing strategy using the temperature detected by the temperature sensor 480J. For example, when the temperature reported by temperature sensor 480J exceeds a threshold, electronic device 400 performs a reduction in performance of a processor located in the vicinity of temperature sensor 480J in order to reduce power consumption to implement thermal protection. In other embodiments, when the temperature is below another threshold, the electronic device 400 heats the battery 442 to avoid the low temperature causing the electronic device 400 to be abnormally shut down. In other embodiments, when the temperature is below a further threshold, the electronic device 400 performs boosting of the output voltage of the battery 442 to avoid abnormal shutdown caused by low temperatures.
Touch sensor 480K, also referred to as a "touch device". The touch sensor 480K may be disposed on the display screen 494, and the touch sensor 480K and the display screen 494 form a touch screen, which is also called a "touch screen". The touch sensor 480K is used to detect a touch operation acting thereon or thereabout. The touch sensor may communicate the detected touch operation to the application processor to determine the touch event type. Visual output related to touch operations may be provided through the display screen 494. In other embodiments, the touch sensor 480K may also be disposed on a surface of the electronic device 400 at a different location than the display screen 494.
Bone conduction sensor 480M may acquire a vibration signal. In some embodiments of the application, bone conduction sensor 480M may acquire a vibration signal of a human vocal tract vibrating bone mass. The bone conduction sensor 480M may also contact the pulse of the human body to receive the blood pressure pulsation signal.
In some embodiments of the application, bone conduction sensor 480M may also be provided in the headset, in combination with the bone conduction headset. The audio module 470 may parse out a voice signal based on the vibration signal of the sound part vibration bone block obtained by the bone conduction sensor 480M, so as to implement a voice function. The application processor can analyze heart rate information based on the blood pressure beat signals acquired by the bone conduction sensor 480M, so that a heart rate detection function is realized.
The keys 490 include a power-on key, a volume key, etc. The keys 490 may be mechanical keys or touch keys. Electronic device 400 may receive key inputs, generate key signal inputs related to user settings and function controls of electronic device 400.
The motor 491 may generate a vibration cue. The motor 491 may be used for incoming call vibration alerting as well as for touch vibration feedback. For example, touch operations acting on different applications (e.g., photographing, audio playing, etc.) may correspond to different vibration feedback effects. The motor 491 may also correspond to different vibration feedback effects by touch operations applied to different areas of the display screen 494. Different application scenarios (e.g., time alert, receipt information, alarm clock, game, etc.) may also correspond to different vibration feedback effects. The touch vibration feedback effect may also support customization.
The indicator 492 may be an indicator light, which may be used to indicate a state of charge, a change in charge, or an indication message, missed call, notification, or the like.
The SIM card interface 495 is used to connect to a SIM card. The SIM card may be inserted into the SIM card interface 495 or removed from the SIM card interface 495 to enable contact and separation with the electronic device 400. The electronic device 400 may support 1 or N SIM card interfaces, N being a positive integer greater than 1. The SIM card interface 495 may support Nano SIM cards, micro SIM cards, and the like. The same SIM card interface 495 may be used to insert multiple cards simultaneously. The types of the plurality of cards may be the same or different. The SIM card interface 495 may also be compatible with different types of SIM cards. The SIM card interface 495 may also be compatible with external memory cards. The electronic device 400 interacts with the network through the SIM card to realize functions such as communication and data communication. In some embodiments of the application, the electronic device 400 employs an eSIM (i.e., an embedded SIM card). The eSIM card can be embedded in the electronic device 400 and cannot be separated from the electronic device 400.
The software system of the electronic device 400 may employ a layered architecture, an event driven architecture, a microkernel architecture, a microservice architecture, or a cloud architecture. Embodiments of the application are configured in a layered mannerThe system is an example illustrating the software architecture of the electronic device 400.
Fig. 5 is a software architecture block diagram of an electronic device 400 according to an embodiment of the application.
The layered architecture divides the software into several layers, each with distinct roles and branches. The layers communicate with each other through a software interface. In some embodiments of the application, willThe system is divided into four layers, namely an application program layer, an application program framework layer and a/>, from top to bottomRuntime (/ >)Runtime) and system libraries, and a kernel layer.
The application layer may include a series of application packages.
As shown in fig. 5, the application package may include applications for cameras, gallery, calendar, talk, map, navigation, WLAN, bluetooth, music, video, short messages, etc.
The application framework layer provides an application programming interface (application programming interface, API) and programming framework for the application of the application layer. The application framework layer includes a number of predefined functions.
As shown in fig. 5, the application framework layer may include a window manager, a content provider, a view system, a phone manager, a resource manager, a notification manager, and the like.
The window manager is used for managing window programs. The window manager may obtain the display screen size, determine if there is a status bar, lock the screen, intercept the screen, etc.
The content provider is used to store and retrieve data and make such data accessible to applications. The data may include video, images, audio, calls made and received, browsing history and bookmarks, phonebooks, etc.
The view system includes visual controls, such as controls to display text, controls to display pictures, and the like. The view system may be used to build applications. The display interface may be composed of one or more views. For example, a display interface including a text message notification icon may include a view displaying text and a view displaying a picture.
The telephony manager is used to provide the communication functions of the electronic device 400. For example, management of call status (including on, off, etc.).
The resource manager provides various resources for the application program, such as localization strings, icons, pictures, layout files, video files, and the like.
The notification manager allows the application to display notification information in a status bar, can be used to communicate notification type messages, can automatically disappear after a short dwell, and does not require user interaction. Such as notification managers are used to inform of download completion, message alerts, etc. The notification manager may also be a notification in the form of a chart or scroll bar text that appears on the system top status bar, such as a notification of a background running application, or a notification that appears on the screen in the form of a dialog window. Such as prompting text messages in status bars, sounding prompts, vibrating electronic devices, flashing indicator lights, etc.
Run time includes a core library and virtual machines. /(I)Runtime is responsible for/>Scheduling and management of the system.
The core library consists of two parts: one part is a function which needs to be called by java language, and the other part isIs a core library of (a).
The application layer and the application framework layer run in a virtual machine. The virtual machine executes java files of the application program layer and the application program framework layer as binary files. The virtual machine is used for executing functions such as management of object life cycle, stack management, thread management, security and exception management, garbage collection and the like.
The system library may include a plurality of functional modules. For example, surface manager (surface manager), media Libraries (Media Libraries), three-dimensional graphics processing Libraries (e.g., openGL ES), 2D graphics engines (e.g., SGL), and the like.
The surface manager is used to manage the display subsystem and provides a fusion of 2D and 3D layers for multiple applications.
Media libraries support a variety of commonly used audio, video format playback and recording, still image files, and the like. The media library may support a variety of audio and video encoding formats, such as MPEG4, h.264, MP3, AAC, AMR, JPG, PNG, etc.
The three-dimensional graphic processing library is used for realizing three-dimensional graphic drawing, image rendering, synthesis, layer processing and the like.
The 2D graphics engine is a drawing engine for 2D drawing.
The kernel layer is a layer between hardware and software. The inner core layer at least comprises a display driver, a camera driver, an audio driver and a sensor driver.
The service interaction method provided by the embodiment of the application is described below by taking the terminal with the hardware structure/software structure as an example.
Referring to fig. 6, a schematic step diagram of a service interaction method provided by an embodiment of the present application is shown, where the method specifically may include the following steps:
s601, after an application program in the terminal is started, a QUIC proxy module in the terminal establishes a QUIC tunnel with a QUIC proxy server.
It should be noted that, the application program installed in the terminal may include a plurality of application programs, and each application program may perform service interaction with a corresponding service server. Thus, the service server may also comprise a plurality. For convenience of explanation, an embodiment of the present application will be described by taking a certain application 61 as an example. The application 61 is installed in the terminal 60, and a server providing a corresponding service to the application 61 is a business server 64.
In an embodiment of the present application, a QUIC proxy module 62 is integrated in the terminal 60, and the QUIC proxy module 62 may be generated based on an SDK capable of supporting the QUIC protocol. Illustratively, an SDK capable of supporting the QUIC protocol may be installed in the terminal 60 to configure the QUIC proxy module 62 for providing support for the QUIC protocol for the terminal 60.
After the application 61 in the terminal 60 is started, the qic proxy module 62 may establish a qic tunnel with the qic proxy server 63.
Illustratively, the QUIC proxy module 62 sends a message to the QUIC proxy server 63 requesting establishment of the QUIC tunnel, and the QUIC proxy server 63 returns a reply message to the QUIC proxy module 62 for the QUIC tunnel establishment message, thereby establishing the QUIC tunnel therebetween.
Fig. 7 is a schematic diagram of a service interaction flow provided in an embodiment of the present application. The protocol types used by the applications and the QUIC proxy module in the terminal corresponding to the steps in FIG. 6 to establish links with each other when performing service interactions with the QUIC proxy server and the service server are shown in FIG. 7.
Accordingly, the establishment of the qic tunnel corresponding to the qic proxy module 62 in S601 with the qic proxy server 63 is the process shown in S702 and S703 in fig. 7. Wherein S702 represents that the qic proxy module 62 sends a message requesting to establish a qic tunnel to the qic proxy server 63; s703 denotes that the QUIC proxy server 63 returns a response message to the QUIC proxy module 62.
In the embodiment of the application, the QUIC proxy module 62 in the terminal 60 is used to establish a QUIC tunnel with the QUIC proxy server 63 and to transmit messages based on the QUIC protocol. The message transmission between the application 61 and the QUIC proxy module 62 can be implemented based on the original protocol. For example, the application 61 and the QUIC agent module 62 may communicate messages based on the TCP protocol.
Thus, after the application 61 is started, the application 61 may establish an internal TCP link with the QUIC proxy module 62 before the QUIC proxy module 62 establishes a QUIC tunnel with the QUIC proxy server 63. That is, the process shown in S701 in fig. 7.
After the QUIC tunnel establishment between the QUIC proxy module 62 and the QUIC proxy server 63 is completed, the QUIC proxy module 62 may notify the application 61 that the QUIC tunnel is ready, as shown by S704 in FIG. 7.
S602, the application program generates a service request message and sends the service request message to the QUIC proxy module based on the TCP link.
In an embodiment of the present application, the service request message generated by the application 61 may be transmitted based on an internal TCP link between the application 61 and the QUIC proxy module 62. As shown in S705 in fig. 7, the procedure is a service request procedure based on the TCP protocol.
Specifically, the application 61 handshakes with the QUIC proxy module 62 via an internal TCP link before using the QUIC tunnel. The application 61 then sends the service request message to the QUIC proxy module 62 for processing via the internal TCP link.
S603, the QUIC proxy module performs tunnel encapsulation on the received service request message according to the QUIC protocol requirement.
When the QUIC proxy module 62 uses the QUIC tunnel to transmit a message to the QUIC proxy server 63, the transmitted message should meet the requirements associated with the QUIC protocol.
Therefore, after receiving the service request message sent by the application 61, the quit proxy module 62 may tunnel-encapsulate it according to the quit protocol requirements to obtain the first quit packet. This process is also referred to as tunnel packing process shown in S706 in fig. 7.
In the embodiment of the present application, the service request message sent by the application 61 is a TCP message. The QUIC proxy module 62 tunnels the service request message according to the QUIC protocol requirements, i.e. encapsulates the TCP message into a UDP message. The packet structure of the encapsulated UDP message is as follows: 20 bytes of IP data head+8 bytes of UDP data head+1-51 bytes of QUIC tunnel encapsulation data, wherein the payload part is a TCP message. The IP header is used to indicate the destination IP of the message, that is, the address of the service server 64 to which the service request message needs to be sent.
S604, the QUIC proxy module sends the packaged service request message to the QUIC proxy server based on the established QUIC tunnel.
Since the encapsulated service request message (first quit packet) has satisfied the transmission requirements of the quit protocol, the quit proxy module 62 may send it to the quit proxy server 63 via the established quit tunnel. The process by which the QUIC proxy module 62 sends the encapsulated service request message to the QUIC proxy server 63 belongs to the QUIC protocol-based service request process shown as S707 in fig. 7.
S605, the QUIC proxy server performs tunnel decapsulation on the received encapsulated service request message to obtain an original service request message.
In the embodiment of the present application, the link between the QUIC proxy server 63 and the QUIC proxy module 62 is a QUIC tunnel link established based on the QUIC protocol, and the link between the QUIC proxy server 63 and the service server 64 may be a link established based on the original protocol. Such as links established based on the TCP protocol.
Therefore, as shown in S708 in fig. 7, the QUIC proxy server 63 needs to tunnel-decapsulate (tunnel-decapsulate) the encapsulated service request message after it is received. The purpose of the QUIC proxy server 63 tunneling the encapsulated service request message is to restore the UDP message to a TCP message. The recovered TCP message is the service request message sent by the application 61.
S606, the QUIC proxy server sends the service request message to the service server based on the TCP link.
In the present embodiment, the link between the QUIC proxy server 63 and the service server 64 is a TCP link. After decapsulating the encapsulated service request message to obtain the service request message belonging to the TCP message, the QUIC proxy server 63 may send the service request message to the service server 64 through the TCP link. This process is also referred to as a TCP protocol-based service request process shown in S709 in fig. 7.
S607, the service server returns a service response message to the QUIC proxy server based on the TCP link.
In the embodiment of the application, the acknowledgement by the service server 64 to the service request message sent by the QUIC proxy server 63 will also be implemented by means of an established TCP link between the two. That is, the service server 64 processes the service request message and then transmits a service response to the QUIC proxy server 63 via the TCP link. This procedure is also referred to as a TCP protocol-based service reply procedure shown in S710 in fig. 7.
S608, the QUIC proxy server tunnels the received service response message according to the QUIC protocol requirement.
In the embodiment of the present application, the service response sent by the service server 64 to the qic proxy server 63 belongs to a TCP packet, and cannot be directly sent to the qic module 62. Therefore, as shown in S711 in fig. 7, after receiving the service response message in the TCP message format returned by the service server 64, the quit proxy server 63 needs to tunnel-encapsulate the service response message according to the quit protocol, and encapsulates the TCP message into a UDP message, thereby obtaining a second quit packet (tunnel encapsulation). And the load of the encapsulated UDP message is the TCP message.
S609, the QUIC proxy server sends the packaged service response message to the QUIC proxy module based on the established QUIC tunnel.
In an embodiment of the present application, the QUIC tunnel established between the QUIC proxy module 62 and the QUIC proxy server 63 may be maintained at all times. After completing the tunnel encapsulation of the traffic response message in TCP format, the quitc proxy server 63 may send the encapsulated traffic response message in UDP format (second quitc packet) to the quitc proxy module 62 through the established quitc tunnel. This process is also referred to as the QUIC protocol-based service response process shown in S712 in fig. 7.
In a possible implementation manner of the embodiment of the present application, the quench proxy server 63 may be configured with an intra-message routing table, through which the correspondence between each TCP link and the quench tunnel is recorded. After the quit proxy server 63 receives and encapsulates the service response message sent by the service server 64 through the TCP link, the quit tunnel corresponding to the TCP link for transmitting the service response message can be determined by looking up the internal routing table of the message. The encapsulated traffic trace message is then transmitted to the QUIC proxy module 62 via the found QUIC tunnel.
S610, the QUIC proxy module performs tunnel decapsulation on the received encapsulated service response message to obtain an original service response message.
As shown in S713 in fig. 7, after receiving the service response message in UDP format (the second quench packet), the quench proxy module 62 needs to tunnel decapsulate (tunnel decapsulate) it to obtain the original service response message, that is, the service response message in TCP format.
S611, the QUIC proxy module sends the service reply message to the application program based on the TCP link.
In the embodiment of the present application, the QUIC proxy module 62 may forward the service response message sent by the service server 64 to the application 61 through an internal TCP link, so as to complete the whole service interaction process. The quitc proxy module 62 forwards the service response message to the application 61 through the TCP link, that is, the service response procedure based on the TCP protocol shown as S714 in fig. 7.
In the embodiment of the application, the terminal can use the QUIC technology to carry out service interaction with the service server, so that the overhead of three-way handshake caused by service interaction by using TCP link can be improved; secondly, by using the QUIC proxy server, the embodiment of the application establishes the QUIC tunnel between the QUIC proxy module at the terminal side and the QUIC proxy server instead of establishing a direct QUIC tunnel between the terminal and the service server, thereby effectively reducing the difficulty of integrating the QUIC protocol in the client and the service server, solving the dependence on an intermediate network in the QUIC deployment process and facilitating the integration and use of the QUIC technology; thirdly, according to the service interaction method provided by the embodiment of the application, a plurality of services can share the QUIC proxy server, thereby being beneficial to realizing decoupling of the QUIC technology and the services and being beneficial to deployment and evolution of service.
In order to facilitate understanding of the service interaction method provided by the embodiment of the present application, a specific application process of the method is described below in conjunction with an application scenario.
Fig. 8 is a schematic diagram of an application scenario of a service interaction method according to an embodiment of the present application, where the application scenario is a process schematic diagram of service interaction between a plurality of terminals sharing a qic proxy server and each terminal and a service server in a mobile application scenario. In the application scenario shown in fig. 8, a terminal 801, a terminal 802, a QUIC proxy server 803, and a service server 804 are included.
The service interaction procedure between the terminal 801 and the service server 804 may include the following steps:
1.1, the QUIC proxy module 8011 is integrated in the terminal 801, and an application program in the terminal 801 can establish a TCP link with the QUIC proxy module 8011 through a local loop (local loop) interface.
1.2, The QUIC proxy module 8011 establishes a QUIC tunnel with the QUIC proxy server 803. Referring to fig. 8, the qic tunnel between the qic proxy module 8011 and the qic proxy server 803 is qic tunnel 1.
1.3, The first application in terminal 801 sends and receives traffic messages over the TCP link established with the quitc proxy module 8011. Illustratively, after the first application in the terminal 801 generates the first service request message, it sends the first service request message to the qic proxy module 8011 through the established TCP link.
1.4, The quit proxy module 8011 in the terminal 801 performs quit tunnel packing on the received first service request message, and sends the first service request message to the quit proxy server 803 through the quit tunnel 1.
1.5, The QUIC proxy server 803 unpacks the first service request message, and transmits the unpacked first service request message to the corresponding service through the TCP link established between the QUIC proxy server and the service server 804.
1.6, After the service server 804 processes the first service request message, a first service response message is generated. The service server 804 sends the first service reply message to the QUIC proxy server 803 via a TCP link.
1.7, After receiving the first service response message, the quit proxy server 803 packages the first service response message through a quit tunnel, and sends the first service response message to the quit proxy module 8011 in the terminal 801 through the quit tunnel 1.
1.8, The QUIC proxy module 8011 unpacks the received first service response message, and then sends the first service response message to the first application program through the TCP link established with the first application program.
Similarly, the service interaction procedure between the terminal 802 and the service server 804 in fig. 8 may include the following steps:
2.1, the QUIC proxy module 8021 is integrated in the terminal 802, and the application program in the terminal 802 can establish TCP link with the QUIC proxy module 8021 through a local loop (local loop) interface.
2.2, QUIC proxy module 8021 establishes a QUIC tunnel with QUIC proxy server 803. Referring to fig. 8, the qic tunnel between the qic proxy module 8021 and the qic proxy server 803 is qic tunnel 2.
2.3, The second application in the terminal 802 sends and receives service messages via the TCP link established with the QUIC proxy module 8021. Illustratively, after the second application in the terminal 802 generates the second service request message, it sends it to the QUIC proxy module 8021 via the established TCP link.
2.4, The quit proxy module 8021 in the terminal 802 performs quit tunnel packing on the received second service request message, and sends the second service request message to the quit proxy server 803 through the quit tunnel 2.
2.5, The QUIC proxy server 803 unpacks the second service request message and transmits the unpacked second service request message to the corresponding service through the TCP link established between the QUIC proxy server and the service server 804.
2.6, After the service server 804 processes the second service request message, a second service response message is generated. The service server 804 sends the second service reply message to the QUIC proxy server 803 via a TCP link.
After receiving the second service response message, the quit proxy 803 packages the second service response message through a quit tunnel, and sends the second service response message to the quit proxy 8021 in the terminal 802 through the quit tunnel 2.
The QUIC proxy module 8021 unpacks the received second service response message and then sends the second service response message to the second application program through the TCP link established with the second application program.
In the application scene, the QUIC technology is used, so that the problem of unstable network of the last kilometer of the wireless network can be greatly solved, and the problem of service experience reduction in densely populated areas caused by factors such as network congestion and network jitter is solved. In the application scenario, the terminal 801 and the terminal 802 may share the quit proxy server 803, and the TCP link between the quit proxy server 803 and the service server 804 may also be multiplexed, so that the problem of high integration difficulty caused by integrating quits for each service is solved.
Fig. 9 is a schematic diagram of another application scenario of the service interaction method provided by the embodiment of the present application, where the application scenario is a schematic diagram of a process of performing service interaction between service servers of a terminal when the terminal performs cell handover or network handover in a fast moving scenario. In the application scenario shown in fig. 9, a terminal 901, a QUIC proxy server 902 and a service server 903 are included. Wherein the quit agent module 9011 is integrated in the terminal 901.
In general, in a fast moving scenario, when a terminal performs a cell switch or a network switch, based on a TCP service, a user IP may change due to the cell switch or the network switch, so that a TCP link is interrupted, and a link needs to be re-established and a service flow being processed is interrupted. A common Internet of vehicles scene, and a vehicle-mounted mobile phone application scene. The service interaction method provided by the embodiment of the application can effectively solve the problems.
Referring to fig. 9, when a cell handover occurs in a fast moving scenario, a service interaction procedure with a service server 903 may include the following steps:
3.1, the terminal 901 performs service interaction with the service server 903 in the cell 1, and the procedure may refer to the description of the service interaction between the terminal 801 or the terminal 802 and the service server 804 in the foregoing examples, which is not repeated herein.
3.2, Terminal 901 is on a fast moving bearer and cell handover occurs. For example, a handover is made from cell 1 to cell 2 shown in fig. 9. Since the application in terminal 901 establishes a TCP link with the QUIC proxy module 9011 based on the local loop interface, this link is not interrupted with a cell handover or network handover.
3.3 After the cell handover is completed, the terminal 901 performs service interaction with the service server 903 in the cell 2, and the process is similar to the service interaction between the terminal 901 and the service server 903 in the cell 1, and the description of the service interaction between the terminal 801 or the terminal 802 and the service server 804 in the foregoing example may also be referred to, which is not repeated herein. The traffic interaction between the application in terminal 901 and traffic server 903 may remain stable and no cell switch may be perceived.
Referring to fig. 10, a schematic step diagram of another service interaction method provided by the embodiment of the present application is shown, where the method may be applied to a terminal, and the method may specifically include the following steps:
S1001, a QUIC proxy module in the terminal establishes a QUIC tunnel with a QUIC proxy server, and the QUIC proxy server communicates with a service server through a TCP link.
S1002, the application program in the terminal sends a service request message to the QUIC proxy module.
S1003, the QUIC proxy module transmits the service request message to the QUIC proxy server through the QUIC tunnel, and the QUIC proxy server forwards the service request message to the service server through the TCP link.
S1004, the QUIC proxy module receives a second QUIC data packet forwarded by the QUIC proxy server, and the second QUIC data packet is obtained by packaging the service response message according to the QUIC protocol requirement after the QUIC proxy server receives the service response message returned by the service server aiming at the service request message.
S1005, the QUIC proxy module decapsulates the second QUIC data packet to obtain the service response message.
S1006, the QUIC proxy module sends the service response message to the application program.
It should be noted that, in the foregoing embodiment, the service interaction method provided by the embodiment of the present application is described in terms of the whole system, and in this embodiment, each step executed by the terminal is described, and relevant details may be referred to the description in the foregoing embodiment.
Referring to fig. 11, a schematic step diagram of another service interaction method provided by an embodiment of the present application is shown, where the method may be applied to a proxy server, and the proxy server may be a qic proxy server, and the method may specifically include the following steps:
S1101, responding to a request of establishing a QUIC tunnel by a QUIC proxy module in the terminal, wherein the QUIC proxy server establishes the QUIC tunnel between the QUIC proxy module and the QUIC proxy module, and the QUIC proxy server communicates with a service server through a TCP link.
S1102, the QUIC proxy server receives a first QUIC data packet sent by the QUIC proxy module through the QUIC tunnel, and the first QUIC data packet is obtained by encapsulating a service request message generated by an application program in the terminal according to the QUIC protocol requirement by the QUIC proxy module.
S1103, the QUIC proxy server decapsulates the first QUIC data packet to obtain the service request message.
S1104, the QUIC proxy server forwards the service request message to the service server through the TCP link.
S1105, the QUIC proxy server receives the service response message returned by the service server aiming at the service request message through the TCP link.
S1106, the QUIC proxy server encapsulates the service response message according to the QUIC protocol requirement to obtain a second QUIC data packet.
S1107, the QUIC proxy server forwards the second QUIC data packet to the QUIC proxy module through the QUIC tunnel, and the QUIC proxy module is used for sending the service response message to the application program after the second QUIC data packet is unpacked to obtain the service response message.
It should be noted that, in this embodiment, the steps performed by the qic proxy server are described, and the details of the steps may be referred to as descriptions in the foregoing embodiments.
The embodiment of the application can divide the functional modules of the terminal and the server according to the method example, for example, each functional module can be divided corresponding to each function, and one or more functions can be integrated in one functional module. The integrated modules may be implemented in hardware or in software functional modules. It should be noted that, in the embodiment of the present application, the division of the modules is schematic, which is merely a logic function division, and other division manners may be implemented in actual implementation. Each functional module is described below as an example of division of each function.
Corresponding to the above embodiments, referring to fig. 12, there is shown a block diagram of a service interaction device provided in an embodiment of the present application, where the device may be applied to a terminal in the foregoing embodiments, and the device may specifically include the following modules: a QUIC proxy module 1201, a service request message sending module 1202, wherein:
the QUIC proxy module is used for establishing a QUIC tunnel between the QUIC proxy module and a QUIC proxy server, and the QUIC proxy server is communicated with the service server through a TCP link.
And the service request message sending module is used for sending the service request message generated by the application program in the terminal to the QUIC proxy module.
The QUIC proxy module is further configured to transmit the service request message to the QUIC proxy server through the QUIC tunnel, and the QUIC proxy server forwards the service request message to the service server through the TCP link.
In the embodiment of the application, the device further comprises an internal TCP link establishment module. The internal TCP link establishment module is used for establishing an internal TCP link between the application program and the QUIC proxy module.
The service request message sending module is specifically configured to send the service request message to the QUIC proxy module through the internal TCP link.
In this embodiment of the present application, the quit proxy module is further configured to receive a second quit packet forwarded by the quit proxy server, where the second quit packet is obtained by the quit proxy server encapsulating the service response message according to a quit protocol requirement after receiving the service response message returned by the service server for the service request message.
The QUIC proxy module is further configured to decapsulate the second QUIC data packet to obtain the service response message; and sending the service response message to the application program.
In the embodiment of the application, the QUIC proxy module is specifically configured to send the service response message to the application program through an internal TCP link.
Corresponding to the above embodiments, referring to fig. 13, there is shown a block diagram of another service interaction device provided in the present embodiment, where the device may be applied to the qic proxy server in the above embodiments, and the device may specifically include the following modules: the device comprises a QUIC tunnel establishment module 1301, a first QUIC data packet receiving module 1302, a first QUIC data packet decapsulating module 1303 and a service request message forwarding module 1304, wherein:
The QUIC tunnel establishment module is used for responding to the request of the QUIC proxy module in the terminal for establishing the QUIC tunnel, establishing the QUIC tunnel between the QUIC proxy server and the QUIC proxy module, and the QUIC proxy server is communicated with the service server through a TCP link.
The first QUIC data packet receiving module is configured to receive, through the QUIC tunnel, a first QUIC data packet sent by the QUIC proxy module, where the first QUIC data packet is obtained by encapsulating, by the QUIC proxy module, a service request message generated by an application program in the terminal according to a QUIC protocol requirement.
And the first QUIC data packet decapsulation module is used for decapsulating the first QUIC data packet to obtain the service request message.
And the service request message forwarding module is used for forwarding the service request message to the service server through the TCP link.
In the embodiment of the present application, the service request message forwarding module is specifically configured to: receiving a service response message returned by the service server aiming at the service request message through the TCP link; according to the QUIC protocol requirements, the service response message is packaged to obtain a second QUIC data packet; and forwarding the second QUIC data packet to the QUIC proxy module through the QUIC tunnel, wherein the QUIC proxy module is used for sending the service response message to the application program after the second QUIC data packet is unpacked to obtain the service response message.
It should be noted that, all relevant contents of each step related to the above method embodiment may be cited to the functional description of the corresponding functional module, which is not described herein.
Fig. 14 is a block diagram of a service interaction system according to an embodiment of the present application. The service interaction system comprises a terminal 1401, and a service interaction proxy server 1402 and a service server 1403 which are in communication with the terminal 1401, wherein a QUIC proxy module 141 is integrated in the terminal 1401. Wherein:
The QUIC proxy module is used for establishing a QUIC tunnel with the QUIC proxy server, receiving service request information generated by an application program in the terminal, transmitting the service request information to the QUIC proxy server through the QUIC tunnel, and communicating the QUIC proxy server with the service server through a TCP link.
The QUIC proxy server is used for transmitting the service request message to the service server through the TCP link.
In the embodiment of the application, the service server is used for processing the service request message to obtain a service response message; and sending the service response message to the QUIC proxy server through the TCP link.
The QUIC proxy server is further used for forwarding the service response message to the QUIC proxy module through the QUIC tunnel.
The QUIC proxy module is also used for sending the service response message to the application program.
In the embodiment of the application, the QUIC proxy module is specifically used for establishing an internal TCP link with the application program; and receiving the service request message sent by the application program through the internal TCP link.
In the embodiment of the application, the QUIC proxy module is specifically configured to encapsulate the service request message according to the requirement of the QUIC protocol to obtain a first QUIC data packet; and transmitting the first QUIC data packet to the QUIC proxy server through the QUIC tunnel.
In the embodiment of the present application, the quit proxy server is specifically configured to decapsulate the first quit packet to obtain the service request message, where the service request message carries address information of the service server.
The QUIC proxy server is specifically configured to transmit the service request message to the service server through the TCP link according to the address information.
In the embodiment of the application, the QUIC proxy server is specifically configured to encapsulate the service response message according to the requirement of the QUIC protocol to obtain a second QUIC data packet; and forwarding the second QUIC data packet to the QUIC proxy module through the QUIC tunnel.
In the embodiment of the application, the QUIC proxy module is specifically configured to decapsulate the second QUIC data packet to obtain the service response message; and sending the service response message to the application program through an internal TCP link.
Referring to fig. 15, a schematic diagram of a server according to an embodiment of the present application is shown. The server may be a QUIC proxy server as in the previous embodiments. As shown in fig. 15, the server 1500 includes: a processor 1510, a memory 1520, and a computer program 1521 stored in the memory 1520 and executable on the processor 1510. The processor 1510, when executing the computer program 1521, implements the steps of the service interaction method on the QUIC proxy server side in the above-described respective embodiments, such as steps S1101 to S1107 shown in fig. 11. Or the processor 1510, when executing the computer program 1521, performs the functions of the modules/units in the embodiment of the service interaction device shown in fig. 13, as described above. For example, the functions of modules 1301 through 1304 in fig. 13.
Illustratively, the computer program 1521 may be partitioned into one or more modules/units, which are stored in the memory 1520 and executed by the processor 1510 to perform the business interaction method provided by the embodiments of the present application. The one or more modules/units may be a series of computer program instruction segments capable of performing particular functions, which may be used to describe the execution of the computer program 1521 in the server 1500. For example, the computer program 1521 may be divided into a quit tunnel establishment module, a first quit packet receiving module, a first quit packet decapsulating module, and a service request message forwarding module, where the specific functions of the modules are as follows:
The QUIC tunnel establishment module is used for responding to the request of the QUIC proxy module in the terminal for establishing the QUIC tunnel, establishing the QUIC tunnel between the QUIC proxy server and the QUIC proxy module, and the QUIC proxy server is communicated with the service server through a TCP link.
The first QUIC data packet receiving module is configured to receive, through the QUIC tunnel, a first QUIC data packet sent by the QUIC proxy module, where the first QUIC data packet is obtained by encapsulating, by the QUIC proxy module, a service request message generated by an application program in the terminal according to a QUIC protocol requirement.
And the first QUIC data packet decapsulation module is used for decapsulating the first QUIC data packet to obtain the service request message.
And the service request message forwarding module is used for forwarding the service request message to the service server through the TCP link.
The server 1500 may include, but is not limited to, a processor 1510, a memory 1520. It will be appreciated by those skilled in the art that fig. 15 is merely an example of a server 1500 and is not meant to be limiting as server 1500, and may include more or fewer components than shown, or may combine certain components, or different components, e.g., the server 1500 may also include input and output devices, network access devices, buses, etc.
The Processor 1510 may be a central processing unit (Central Processing Unit, CPU), but may also be other general purpose processors, digital signal processors (DIGITAL SIGNAL Processor, DSP), application SPECIFIC INTEGRATED Circuit (ASIC), off-the-shelf Programmable gate array (Field-Programmable GATE ARRAY, FPGA) or other Programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The storage 1520 may be an internal storage unit of the server 1500, such as a hard disk or a memory of the server 1500. The memory 1520 may also be an external storage device of the server 1500, such as a plug-in hard disk, a smart memory card (SMART MEDIA CARD, SMC), a Secure Digital (SD) card, a flash memory card (FLASH CARD), etc. that are provided on the server 1500. Further, the memory 1520 may also include both internal storage units and external storage devices of the server 1500. The memory 1520 is used to store the computer program 1521 and other programs and data needed by the server 1500. The memory 1520 may also be used to temporarily store data that has been output or is to be output.
The embodiment of the application also provides a terminal, which can be the terminal in the above embodiments, and the terminal comprises a memory, a processor and a computer program stored in the memory and capable of running on the processor, when the processor executes the computer program, the service interaction method at the terminal side in the above embodiments is realized.
The present application also provides a server, which may be the qic proxy server in the foregoing embodiments, and the server includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor, where the processor executes the computer program to implement the service interaction method on the qic proxy server side in the foregoing embodiments.
The embodiment of the application also provides a computer storage medium, wherein the computer storage medium stores computer instructions, and when the computer instructions run on the terminal, the terminal executes the related method steps to realize the service interaction method at the terminal side in the above embodiments.
The embodiment of the application also provides a computer storage medium, wherein the computer storage medium stores computer instructions, and when the computer instructions run on a server, the server is caused to execute the related method steps to realize the service interaction method of the QUIC proxy server side in each embodiment.
The embodiment of the application also provides a computer program product, which when running on a computer, causes the computer to execute the related steps so as to realize the service interaction method at the terminal side in the above embodiments.
The embodiment of the present application also provides a computer program product, which when running on a computer, causes the computer to execute the above related steps, so as to implement the service interaction method at the QUIC proxy server side in the above embodiments.
The embodiment of the application also provides a service interaction system which comprises the terminal, the QUIC proxy server and the service server in each embodiment.
The embodiment of the application also provides a chip which comprises a processor, wherein the processor can be a general-purpose processor or a special-purpose processor. The processor is configured to support the terminal or the server to perform the related steps, so as to implement the service interaction method in each embodiment.
Optionally, the chip further includes a transceiver, where the transceiver is configured to receive control of the processor, and is configured to support the terminal or the server to perform the related steps, so as to implement the service interaction method in the foregoing embodiments.
Optionally, the chip may further comprise a storage medium.
It should be noted that the chip may be implemented using the following circuits or devices: one or more field programmable gate arrays (field programmable GATE ARRAY, FPGA), programmable logic devices (programmable logic device, PLD), controllers, state machines, gate logic, discrete hardware components, any other suitable circuit or circuits capable of performing the various functions described throughout this application.
Finally, it should be noted that: the foregoing is merely illustrative of specific embodiments of the present application, and the scope of the present application is not limited thereto, but any changes or substitutions within the technical scope of the present application should be covered by the scope of the present application.

Claims (16)

1. A business interaction method, comprising:
a QUIC proxy module in the terminal establishes a QUIC tunnel between the QUIC proxy module and a QUIC proxy server, and the QUIC proxy server is communicated with a service server through a TCP link;
an application program in the terminal sends a service request message to the QUIC proxy module, an internal TCP link is established between the application program and the QUIC proxy module, and the application program sends the service request message to the QUIC proxy module through the internal TCP link;
The QUIC proxy module transmits the service request message to the QUIC proxy server through the QUIC tunnel, and an internal message routing table is configured in the QUIC proxy server and is used for recording the corresponding relation between each TCP link and the QUIC tunnel;
the QUIC proxy server transmits the service request message to the service server through the TCP link;
In the process of cell switching of the terminal, the application program is always kept through a TCP link established by a local loop interface and the QUIC proxy module; after the cell switching is completed, the terminal performs service interaction with the service server in the switched cell through a QUIC tunnel between the QUIC proxy module and the QUIC proxy server and TCP connection between the QUIC proxy server and the service server.
2. Method according to claim 1, characterized in that after said QUIC proxy server transmits said service request message to said service server via said TCP link, it further comprises:
the service server processes the service request message to obtain a service response message;
the service server sends the service response message to the QUIC proxy server through the TCP link;
the QUIC proxy server forwards the service response message to the QUIC proxy module through the QUIC tunnel;
the QUIC proxy module sends the service response message to the application program.
3. Method according to claim 1 or 2, wherein said QUIC proxy module transmits said service request message to said QUIC proxy server through said QUIC tunnel, comprising:
The QUIC agent module encapsulates the service request message according to the QUIC protocol requirement to obtain a first QUIC data packet;
The QUIC proxy module transmits the first QUIC data packet to the QUIC proxy server through the QUIC tunnel.
4. A method according to claim 3, wherein said QUIC proxy server transmitting said service request message to said service server via said TCP link, comprising:
The QUIC proxy server decapsulates the first QUIC data packet to obtain the service request message, wherein the service request message carries the address information of the service server;
and the QUIC proxy server transmits the service request message to the service server through the TCP link according to the address information.
5. Method according to claim 2, wherein said QUIC proxy server forwards said service reply message to said QUIC proxy module through said QUIC tunnel, comprising:
the QUIC proxy server encapsulates the service response message according to the QUIC protocol requirement to obtain a second QUIC data packet;
And the QUIC proxy server forwards the second QUIC data packet to the QUIC proxy module through the QUIC tunnel.
6. The method according to claim 5, wherein said QUIC proxy module sends said service reply message to said application program, comprising:
the QUIC proxy module decapsulates the second QUIC data packet to obtain the service response message;
The QUIC proxy module sends the service response message to the application program through an internal TCP link.
7. A service interaction method, which is applied to a terminal, the method comprising:
a QUIC proxy module in the terminal establishes a QUIC tunnel between the QUIC proxy module and a QUIC proxy server, and the QUIC proxy server is communicated with a service server through a TCP link;
an application program in the terminal sends a service request message to the QUIC proxy module, an internal TCP link is established between the application program and the QUIC proxy module, and the application program sends the service request message to the QUIC proxy module through the internal TCP link;
the QUIC proxy module transmits the service request message to the QUIC proxy server through the QUIC tunnel, the QUIC proxy server forwards the service request message to the service server through the TCP link, and an internal message routing table is configured in the QUIC proxy server and is used for recording the corresponding relation between each TCP link and the QUIC tunnel;
In the process of cell switching of the terminal, the application program is always kept through a TCP link established by a local loop interface and the QUIC proxy module; after the cell switching is completed, the terminal performs service interaction with the service server in the switched cell through a QUIC tunnel between the QUIC proxy module and the QUIC proxy server and TCP connection between the QUIC proxy server and the service server.
8. The method of claim 7, wherein the method further comprises:
The QUIC proxy module receives a second QUIC data packet forwarded by the QUIC proxy server, and the second QUIC data packet is obtained by encapsulating the service response message according to the QUIC protocol after the QUIC proxy server receives the service response message returned by the service server aiming at the service request message;
the QUIC proxy module decapsulates the second QUIC data packet to obtain the service response message;
the QUIC proxy module sends the service response message to the application program.
9. The method according to claim 8, wherein said QUIC proxy module sends said service reply message to said application program, comprising:
The QUIC proxy module sends the service response message to the application program through an internal TCP link.
10. A business interaction method, characterized in that it is applied to a proxy server, said proxy server being a QUIC proxy server, said method comprising:
responding to a request of a QUIC proxy module in a terminal to establish a QUIC tunnel, wherein the QUIC proxy server establishes the QUIC tunnel between the QUIC proxy module and the QUIC proxy module, and the QUIC proxy server communicates with a service server through a TCP link;
The QUIC proxy server receives a first QUIC data packet sent by the QUIC proxy module through the QUIC tunnel, the first QUIC data packet is obtained by encapsulating a service request message generated by an application program in the terminal according to the QUIC protocol requirement by the QUIC proxy module, an internal TCP link is established between the application program and the QUIC proxy module, and the application program sends the service request message to the QUIC proxy module through the internal TCP link;
The QUIC proxy server decapsulates the first QUIC data packet to obtain the service request message;
The QUIC proxy server forwards the service request message to the service server through the TCP links, and an internal message routing table is configured in the QUIC proxy server and is used for recording the corresponding relation between each TCP link and the QUIC tunnel;
In the process of cell switching of the terminal, the application program is always kept through a TCP link established by a local loop interface and the QUIC proxy module; after the cell switching is completed, the terminal performs service interaction with the service server in the switched cell through a QUIC tunnel between the QUIC proxy module and the QUIC proxy server and TCP connection between the QUIC proxy server and the service server.
11. Method according to claim 10, characterized in that after said QUIC proxy server forwards said service request message to said service server via said TCP link, it further comprises:
The QUIC proxy server receives a service response message returned by the service server aiming at the service request message through the TCP link;
the QUIC proxy server encapsulates the service response message according to the QUIC protocol requirement to obtain a second QUIC data packet;
And the QUIC proxy server forwards the second QUIC data packet to the QUIC proxy module through the QUIC tunnel, and the QUIC proxy module is used for sending the service response message to the application program after the second QUIC data packet is unpacked to obtain the service response message.
12. A terminal comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the terminal is a terminal according to any of claims 1-9, the processor implementing the business interaction method according to any of claims 7-9 when executing the computer program.
13. A computer storage medium comprising computer instructions which, when run on a terminal, perform the business interaction method of any of claims 7-9.
14. A server comprising a memory, a processor and a computer program stored in said memory and executable on said processor, characterized in that said server is a QUIC proxy server according to any one of claims 1-6 or 10-11, said processor implementing the service interaction method according to any one of claims 10-11 when executing said computer program.
15. A computer storage medium comprising computer instructions which, when run on a server, perform the business interaction method of any of claims 10-11.
16. A service interaction system comprising a terminal and a server for performing service interaction with said terminal, said server comprising a proxy server and a service server, characterized in that said terminal is a terminal as claimed in claim 12 and said proxy server is a QUIC proxy server as claimed in claim 14.
CN202110205950.8A 2021-02-24 2021-02-24 Service interaction method, terminal, server and system Active CN114979261B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110205950.8A CN114979261B (en) 2021-02-24 2021-02-24 Service interaction method, terminal, server and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110205950.8A CN114979261B (en) 2021-02-24 2021-02-24 Service interaction method, terminal, server and system

Publications (2)

Publication Number Publication Date
CN114979261A CN114979261A (en) 2022-08-30
CN114979261B true CN114979261B (en) 2024-06-25

Family

ID=82973787

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110205950.8A Active CN114979261B (en) 2021-02-24 2021-02-24 Service interaction method, terminal, server and system

Country Status (1)

Country Link
CN (1) CN114979261B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115277560B (en) * 2022-09-28 2023-01-17 鹏城实验室 Heterogeneous network fusion transmission method and system based on MPTCP and MPQUIC

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110177128A (en) * 2019-04-15 2019-08-27 深圳前海达闼云端智能科技有限公司 Data transmission system and method for establishing VPN connection, terminal and VPN proxy thereof
CN111865940A (en) * 2020-07-01 2020-10-30 四川速宝网络科技有限公司 Transmission optimization method and device

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8332464B2 (en) * 2002-12-13 2012-12-11 Anxebusiness Corp. System and method for remote network access
CN105376299B (en) * 2015-09-30 2020-12-04 深圳市先河系统技术有限公司 Network communication method, equipment and network attached storage equipment
CN110149388B (en) * 2019-05-16 2023-02-24 北京字节跳动网络技术有限公司 Method, device and equipment for connecting HTTPDNS (hypertext transport protocol version transport protocol DNS) server
CN110545320A (en) * 2019-08-23 2019-12-06 浙江大华技术股份有限公司 Intranet data interaction method and equipment
CN111294399B (en) * 2020-02-04 2023-06-23 网宿科技股份有限公司 Data transmission method and device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110177128A (en) * 2019-04-15 2019-08-27 深圳前海达闼云端智能科技有限公司 Data transmission system and method for establishing VPN connection, terminal and VPN proxy thereof
CN111865940A (en) * 2020-07-01 2020-10-30 四川速宝网络科技有限公司 Transmission optimization method and device

Also Published As

Publication number Publication date
CN114979261A (en) 2022-08-30

Similar Documents

Publication Publication Date Title
US11683850B2 (en) Bluetooth reconnection method and related apparatus
CN113169915A (en) Wireless audio system, audio communication method and equipment
US20240098354A1 (en) Connection establishment method and electronic device
WO2022262492A1 (en) Data downloading method and apparatus, and terminal device
JP7193647B2 (en) Connection establishment method and terminal device
EP4293997A1 (en) Display method, electronic device, and system
CN113810451B (en) Method and device for establishing point-to-point link, first terminal equipment and storage medium
CN114338913B (en) Fault diagnosis method, electronic device and readable storage medium
CN114979261B (en) Service interaction method, terminal, server and system
CN114928898B (en) Method and device for establishing session based on WiFi direct connection
CN113141637B (en) Multipath transmission control method and control device
CN114489876A (en) Text input method, electronic equipment and system
CN114567871A (en) File sharing method and device, electronic equipment and readable storage medium
WO2024104095A1 (en) Data transmission method, apparatus and system
CN113678481A (en) Wireless audio system, audio communication method and equipment
CN116095224B (en) Notification display method and terminal device
WO2023280160A1 (en) Channel switching method and apparatus
WO2024083031A1 (en) Display method, electronic device, and system
CN114423024B (en) WLAN driving framework, assembly method of WLAN driving framework and related equipment
US20240201932A1 (en) Display method, electronic device, and system
CN111801931B (en) Method for switching on and hanging up telephone when call occurs SRVCC switch
CN114816780A (en) Cross-device message packet synchronization method, device, terminal device and medium
CN117251223A (en) Cloud function plug-in configuration and scheduling method, system and electronic equipment
CN113590884A (en) Distributed data searching method and index file sharing method
CN117692693A (en) Multi-screen display method and related equipment

Legal Events

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