Data transmission method, apparatus, device, storage medium, and computer program product

By deploying the runtime container, transport container, and management container of the same target container unit in an ARM server, the problems of high data transmission latency and high system switching costs in cloud application scenarios are solved, and more efficient data transmission is achieved.

CN116684351BActive Publication Date: 2026-02-17TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210165089.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-02-22
Publication Date
2026-02-17
Estimated Expiration
2042-02-22

AI Technical Summary

Technical Problem

In cloud application scenarios, long data transmission latency leads to low data transmission efficiency, especially due to the increased transmission distance of audio and video streams between ARM and X86 servers and the high cost of system switching.

Method used

By deploying the running container, transport container, and management container in the same target container unit, and by modifying the packet address and adding the target route identifier, we can ensure that the packet can be directly transmitted to the cloud application client, thereby reducing the physical transmission distance and the number of system switches.

Benefits of technology

It shortens data transmission latency, improves data transmission efficiency in cloud application scenarios, saves the cost of purchasing x86 servers, and reduces system switching costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116684351B_ABST
    Figure CN116684351B_ABST
Patent Text Reader

Abstract

A data transmission method, device, equipment, storage medium and computer program product can be applied to various fields or scenes such as cloud technology, artificial intelligence, block chain, Internet of Vehicles, intelligent transportation, smart home and the like. The method comprises the following steps: when a request data packet sent by a cloud application client is received, changing an external network address of a cloud server in the request data packet into an internal network address of a transmission container to obtain a target data packet; sending the target data packet to the transmission container according to the internal network address of the transmission container; determining a return data packet corresponding to the target data packet through the transmission container, and adding a target routing identifier to the return data packet; the return data packet carries application data, and the application data is multimedia data generated when a cloud application instance in a running container runs; and sending the return data packet to the cloud application client according to the target routing identifier, so that the cloud application client loads the application data. The application embodiment can improve the data transmission efficiency in the cloud application scene.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer, in particular to a data transmission method, a data transmission device, a computer device, a computer readable storage medium and a computer program product. BACKGROUND

[0002] With the rapid development of cloud computing technology, cloud applications also show a trend of vigorous development. In the cloud application scenario, the application program of the cloud application runs in a remote server, and the cloud application client runs in a terminal. The cloud application client only needs to have basic stream media playing ability to play the audio and video code stream received from the remote server. In addition, the cloud application client also sends operation information to the remote server, so that the remote server can implement the operation of the cloud application.

[0003] Compared with the traditional application mode, the cloud application has the advantages of installation-free, download-free and reduced performance requirements for the terminal. However, the cloud application has higher requirements for the delay of data transmission. Therefore, it is necessary to improve the data transmission efficiency in the cloud application scenario. SUMMARY

[0004] The embodiments of the present application provide a data transmission method, device, equipment, storage medium and computer program product, which can improve the data transmission efficiency in the cloud application scenario.

[0005] In one aspect, the embodiments of the present application provide a data transmission method applied to a cloud server, wherein the cloud server includes a transmission container and a running container, and the transmission container and the running container are configured in a same target container unit. The method comprises the following steps:

[0006] When receiving a request data packet sent by a cloud application client, changing an external network address of the cloud server in the request data packet to an internal network address of the transmission container to obtain a target data packet; sending the target data packet to the transmission container according to the internal network address of the transmission container; determining a return data packet corresponding to the target data packet through the transmission container; adding a target routing identifier to the return data packet; wherein the return data packet carries application data, the application data is multimedia data generated when a cloud application instance in the running container runs; the target routing identifier is used to indicate that the transmission object is the cloud application client; and sending the return data packet to the cloud application client according to the target routing identifier, so that the cloud application client loads the application data.

[0007] In one aspect, an embodiment of the present application provides a data transmission apparatus, applied to a cloud server, the cloud server comprising a transmission container and a running container, the transmission container and the running container being configured in a same target container unit, the apparatus comprising:

[0008] a processing unit, configured to change an external network address of the cloud server in a request data packet sent by a cloud application client into an internal network address of the transmission container to obtain a target data packet when the request data packet is received;

[0009] a sending unit, configured to send the target data packet to the transmission container according to the internal network address of the transmission container;

[0010] the processing unit is further configured to determine a return data packet corresponding to the target data packet through the transmission container, and add a target routing identifier to the return data packet, wherein the return data packet carries application data, the application data being multimedia data generated when a cloud application instance in the running container runs, and the target routing identifier is used to indicate that a transmission object is the cloud application client;

[0011] the sending unit is further configured to send the return data packet to the cloud application client according to the target routing identifier, so that the cloud application client loads the application data.

[0012] In one aspect, an embodiment of the present application provides a computer device, comprising a processor, a communication interface and a memory, which are connected with each other, wherein the memory stores a computer program, and the processor is configured to invoke the computer program to execute the data transmission method in any possible implementation manner.

[0013] In one aspect, an embodiment of the present application provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the data transmission method in any possible implementation manner.

[0014] Correspondingly, an embodiment of the present application further provides a computer program product, the computer program product comprising a computer program or computer instructions, and the computer program or computer instructions are executed by a processor to implement the steps of the data transmission method provided by the embodiment of the present application.

[0015] Correspondingly, an embodiment of the present application further provides a computer program, the computer program comprising computer instructions, the computer instructions being stored in a computer readable storage medium, a processor of a computer device reading the computer instructions from the computer readable storage medium, and the processor executing the computer instructions to enable the computer device to execute the data transmission method provided by the embodiment of the present application.

[0016] The cloud server changes the external network address of the cloud server in the request data packet to the internal network address of the transmission container to obtain a target data packet, and sends the target data packet to the transmission container according to the internal network address of the transmission container, so as to determine the return data packet corresponding to the target data packet through the transmission container, wherein the return data packet carries application data, and the application data is multimedia data generated when the cloud application instance in the running container runs, and the target routing identifier is added to the return data packet, so that the return data packet can be sent to the cloud application client, and the cloud application client loads the application data. The above method can return the return data packet to the cloud application client through the target routing identifier, so as to ensure that the cloud application client can load the application data. In addition, the running container and the transmission container are configured in the same target container unit, so that the distance of application data transmission can be shortened in physics, the data transmission delay can be reduced, and the data transmission efficiency in the cloud application scenario can be improved. BRIEF DESCRIPTION OF DRAWINGS

[0017] In order to more clearly illustrate the technical method of the embodiments of the present application, the drawings needed in the embodiment description will be briefly introduced. Obviously, the drawings in the following description are some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.

[0018] Figure 1 A system architecture schematic diagram of a processing scheme provided by the embodiments of the present application is shown in the figure.

[0019] Figure 2 A system architecture schematic diagram of an improved processing scheme provided by the embodiments of the present application is shown in the figure. Figure 1 ;

[0020] Figure 3 A system architecture schematic diagram of an improved processing scheme provided by the embodiments of the present application is shown in the figure. Figure 2 ;

[0021] Figure 4 A network architecture schematic diagram suitable for a data transmission method provided by the embodiments of the present application is shown in the figure.

[0022] Figure 5 A flowchart of a data transmission method provided by the embodiments of the present application is shown in the figure. Figure 1 ;

[0023] Figure 6 A system architecture schematic diagram of a data transmission system provided by the embodiments of the present application is shown in the figure. Figure 1 ;

[0024] Figure 7A flowchart of a data transmission method provided for an embodiment of the present application Figure 2 ;

[0025] Figure 8 A system architecture of a data transmission system provided for an embodiment of the present application Figure 2 ;

[0026] Figure 9 A structural diagram of a data transmission device provided for an embodiment of the present application

[0027] Figure 10 A structural diagram of a computer device provided for an embodiment of the present application. DETAILED DESCRIPTION

[0028] The technical method in the embodiments of the present application will be described clearly and completely in combination with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all the other embodiments obtained by those skilled in the art without creative labor fall within the scope of protection of the present application.

[0029] The terms related to the embodiments of the present application are introduced as follows:

[0030] I. Cloud technology

[0031] Cloud technology (Cloud Technology) is a general term of network technology, information technology, integration technology, management platform technology, application technology and the like applied based on cloud computing business model, which can form a resource pool and be used on demand, flexibly and conveniently. Cloud computing technology will become an important support. The background service of a technical network system needs a large amount of computing and storage resources, such as a video website, a picture website and more portals. With the high development and application of the Internet industry, in the future, every item is likely to have its own identification mark and needs to be transmitted to the background system for logical processing. Different levels of data will be processed separately, and the data of various industries all need strong system support, which can only be realized through cloud computing.

[0032] Cloud computing refers to a delivery and use mode of IT infrastructure, and refers to obtaining required resources in a scalable manner on demand through a network. Broad-sense cloud computing refers to a delivery and use mode of services, and refers to obtaining required services in a scalable manner on demand through a network. Such services can be IT and software, Internet related, or other services. Cloud computing is a product of the development and integration of traditional computer and network technologies such as grid computing, distributed computing, parallel computing, utility computing, network storage technologies, virtualization, load balancing, and the like.

[0033] II. Cloud application

[0034] A cloud application is a subset of cloud computing and is an embodiment of cloud computing technology at the application layer. The working principle of a cloud application is to change the use mode of traditional software local installation and local operation into on-demand service. A new type of application is connected and controlled through an Internet or local area network to complete a business logic or operation task.

[0035] An advantage of a cloud application is that an application program of the cloud application runs in a remote server, a cloud application client runs in a terminal, the remote server performs a computing work of the cloud application, and then transmits a computing result of the cloud application to the cloud application client for display. The cloud application client collects operation information for the cloud application client and transmits the operation information to the remote server to realize operation of the cloud application by the remote server. The cloud application can include cloud gaming, cloud education, cloud security, cloud socialization, and the like. Cloud gaming, as a typical cloud application, has received more and more attention in recent years.

[0036] Cloud gaming, also known as gaming on demand, is an online gaming technology based on cloud computing technology. Cloud gaming technology enables a light terminal with relatively limited graphics processing and data processing capabilities to run high-quality games. In a cloud gaming scenario, a game does not run on a player game terminal, but runs in a remote server, and the remote server renders a game scene into a video and audio stream and transmits the video and audio stream to the player game terminal through a network. The player game terminal does not need to have strong graphics processing and data processing capabilities, but only needs to have basic streaming media playback capabilities and the ability to obtain player input instructions and send the player input instructions to the remote server.

[0037] III. Container

[0038] Kubernetes, commonly referred to as k8s, is used to manage containerized applications across multiple hosts in a cloud platform. The goal of k8s is to make deploying containerized applications simple and efficient. k8s provides a mechanism for application deployment, scheduling, updating, and maintenance. k8s defines a series of building blocks in its design structure, with the goal of providing a mechanism for deploying, maintaining, and scaling applications. The components that make up k8s are designed to be loosely coupled and extensible, allowing them to meet a variety of different workloads. Extensibility is provided in large part by the k8s API, which is primarily used by internal components for extension and by containers running on k8s. A k8s cluster represents a collection of nodes, which can be physical servers or virtual machines.

[0039] A pod is the basic scheduling unit of a k8s cluster. This abstraction allows higher-level abstractions to be composed of containerized components. A pod generally contains one or more containers that are guaranteed to always be co-located on the same host machine and can share resources. Each pod in a k8s cluster is assigned a unique IP address, which allows applications to use the same port without the risk of conflict.

[0040] The biggest feature and advantage of all containers in a pod is that they can share resources, such as sharing the same network namespace and being able to declare the same data storage space. All containers in a pod share the network and port space, meaning they can access and communicate with each other through the local host. They also communicate externally in the same way, eliminating the need for container communication. In addition to the network, the data storage space defined in the pod can be mounted to multiple containers to achieve sharing. Furthermore, resource limits defined in the pod, such as Central Processing Unit (CPU) and Memory, are shared by all containers.

[0041] Four, Artificial Intelligence

[0042] Artificial Intelligence (AI) is the use of digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use knowledge to achieve optimal results. In other words, artificial intelligence is a comprehensive technology of computer science that aims to understand the essence of intelligence and produce a new intelligent machine that can react in a similar way to human intelligence. Artificial intelligence is the design principle and implementation method of various intelligent machines, enabling machines to have perception, reasoning, and decision-making capabilities.

[0043] Five, Blockchain

[0044] Blockchain is a new application mode of distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm and other computer technologies. Blockchain is essentially a decentralized database and is a chain of data blocks associated using cryptography. Each data block contains information about a batch of network transactions and is used to verify the validity of the information (anti-fake) and generate the next block.

[0045] At present, the server layer of cloud computing technology mainly uses X86 servers, which are equipped with X86 processors. X86 refers to a series of central processor instruction set architectures based on Intel 8086 and backward compatible, which use complex instruction sets. Since terminal devices are generally equipped with ARM (Advanced RISC Machine, Advanced RISC Machine) processors, the software applications installed on terminal devices are all compiled based on ARM architecture, which causes problems such as the inability of software applications compiled based on ARM architecture (hereinafter referred to as ARM applications) to run on X86 servers. Although the conversion of ARM's simplified instruction set to X86's complex instruction set can bypass this limitation and allow ARM applications to run on X86 servers, the instruction conversion process will cause excessive performance load and slow running speed. Therefore, please refer to Figure 1 The present application first proposes a processing scheme as follows:

[0046] ①The cloud application client is an application program that provides local services for cloud applications and needs to have basic streaming media playback capabilities to decode and play the acquired audio and video streams.

[0047] ②Start a first container unit (pod1) on an ARM server, which includes a running container and an initialization container. The cloud application instance is running in the running container, and the cloud application instance represents a virtual computing resource, which can include a collection of basic computing components such as CPU (Central Processing Unit), operating system, network, disk, GPU (Graphics Processing Unit), etc. That is, the cloud application instance is a successfully started and actually operable cloud application. The running container is similar to a terminal device in the traditional application mode and can communicate with an application server (such as a game server). The initialization container can help the running container to achieve initialization when the cloud application instance is started.

[0048] ③ Start the second container unit (pod2) on the x86 server. The second container unit includes a transport container and a management container. When the cloud application instance starts, the running container encodes the application screen (e.g., game screen) of the cloud application instance into audio and video streams and sends the audio and video streams to the transport container. The transport container then sends the audio and video streams to the cloud application client, which decodes the audio and video streams and displays the corresponding application screen. Additionally, the operation information of the cloud application client is sent to the transport container, which then sends the operation information to the running container. This allows the running container to inject the operation information into the cloud application instance, enabling operations on the cloud application instance. For example, adding special effects commands can be sent to the command receiving module in the running container, which then injects the commands into the cloud application instance. The management container acts as a manager for a single device. A single device refers to a device that provides services to a single started cloud application client. This device can be created by a business platform built on a Kubernetes cluster using an edge scheduler. Management containers can be used to maintain the creation and destruction of cloud application instances, as well as to create communication connections between the transport container and the cloud application client by providing signaling interaction between the cloud application client and the transport container.

[0049] In one implementation, the transport container can be a WebRTC container. WebRTC (Web Real-time Communication) technology is a technology that enables web browsers to conduct real-time voice or video conversations. A WebRTC container based on WebRTC technology can send audio and video streams encoded for cloud application instances to cloud application clients in real time, and send operation information for cloud application clients to the running container, which can effectively reduce data transmission latency.

[0050] In one embodiment, the running container can be a cloudgame container, which can run the corresponding cloud game instance. The initializer container helps the cloudgame container perform initialization when the cloud game instance starts.

[0051] In one feasible embodiment, the management container can provide an instance service, which can be responsible for managing component state and executing component-related business logic. For example, maintaining the creation and destruction of cloud application instances running in the container.

[0052] In the process of implementing the above scheme, it is found that the audio and video code stream collected by the running container needs to be transmitted to the cloud application client through the ARM server to the X86 server first, which increases the transmission distance of the audio and video code stream at the physical level, resulting in an increase in data transmission delay. Secondly, when the audio and video code stream is sent from the running container in the ARM server to the transmission container in the X86 server, the audio and video code stream needs to be switched from the user state and the kernel state for 4 times, which increases the system switching cost and also increases the data transmission delay, thereby reducing the data transmission efficiency in the cloud application scenario.

[0053] Then, considering that the remaining CPU and memory resources of the ARM server are sufficient to run the transmission container and the management container, the embodiments of the present application are further improved and practiced, and another improved processing scheme is proposed, please refer to Figure 2 In this scheme, the running container, the initialization container, the transmission container and the management container are all deployed in the same target container unit in the ARM server, thereby shortening the transmission distance of the audio and video code stream at the physical level and reducing the data transmission delay. At the same time, the running container and the transmission container in the target container unit are located in the same network and can directly communicate through the configured IP address or container name, thereby reducing the multiple conversions of the audio and video code stream from the user state to the kernel state, reducing the data transmission delay and improving the data transmission efficiency in the cloud application scenario. In addition, since the X86 server is not needed in this scheme, the cost of purchasing the X86 server can also be saved.

[0054] It should be noted that when the running container, the initialization container, the transmission container and the management container are deployed into the same target container unit of the ARM server, there are two problems. Problem 1: Since the ARM application needs to run on an Android system or an iOS system, the operating system virtually output by the running container is also the Android system or the iOS system applicable to the cloud application instance. Since the Android system or the iOS system has its own network program, when the ARM server is equipped with a Linux system or a Windows system, the ARM server and the target container unit are network isolated. At this time, the network used by the target container unit is the network of the Android system or the iOS system, which can be a cluster network such as a k8s cluster network, while the ARM server usually uses a host network. Therefore, it is necessary to break the network isolation between the ARM server and the target container unit, realize the communication between the target container unit and the ARM server, and finally realize the communication between the transmission container and the cloud application client. Problem 2: When the cloud application instance sends a data packet to the application server, and the transmission container sends a data packet to the cloud application client, since the target container unit is the basic scheduling unit of the K8S cluster, they are all based on the level of the target container unit to interact with the ARM server. The ARM server cannot distinguish whether the data packet sent by the target container unit is transmitted to the application server or the cloud application client. For example, please refer to Figure 3 As can be seen, after the data packet is sent from the target container unit to the bridge device (such as an Ethernet bridge), it will not know whether it is to be sent from the tuncat network card to the application server or from the bond1 network card to the cloud application client. At this time, it will be defaulted to send the data packet to the application server, resulting in the failure to send the audio and video code stream to the cloud application client.

[0055] Therefore, the improved processing scheme, specifically represented as a data transmission method, includes: ① for problem 1: when receiving the request data packet sent by the cloud application client, the cloud server changes the external network address of the cloud server in the request data packet to the internal network address of the transmission container to obtain a target data packet; the target data packet is sent to the transmission container according to the internal network address of the transmission container. ② for problem 2: the target data packet is determined by the transmission container to add a target routing identifier to the return data packet; wherein the return data packet carries application data, and the application data is multimedia data (the above-mentioned audio and video code streams) generated when the cloud application instance in the running container runs; the target routing identifier is used to indicate that the transmission object is the cloud application client; according to the target routing identifier, the return data packet is sent to the cloud application client, so that the cloud application client loads the application data. This scheme can break the network isolation between the ARM server and the target container unit, and send the audio and video code streams to the cloud application client through the target routing identifier, so that the transmission container and the running container can run in the same target container unit, to reduce the time delay of data transmission and improve the efficiency of data transmission.

[0056] The data transmission method proposed in the embodiments of the present application can be applied to various fields or scenarios such as cloud technology, artificial intelligence, block chain, Internet of Vehicles, intelligent transportation, smart home, etc. In an implementation manner, the data transmission method can be applied to a cloud technology scenario. The data transmission method can be specifically applied to a cloud computing technology involved in the cloud technology scenario; for example, the data transmission method of the embodiments of the present application can be executed by a cloud server, and the like.

[0057] In another implementation manner, the data transmission method provided by the embodiments of the present application can be applied to an artificial intelligence (AI) scenario. The data transmission method can be specifically applied to one or more of distributed storage and big data processing technologies in artificial intelligence basic technologies involved in the artificial intelligence scenario; for example, in the data transmission method of the embodiments of the present application, the multimedia data can be stored in a distributed storage manner.

[0058] In yet another implementation manner, the data transmission method provided by the embodiments of the present application can be applied to a block chain scenario; for example, the data required for executing the data transmission method can be stored in the form of blocks on the block chain; the data (such as application data, etc.) generated by executing the data transmission method can be stored in the form of blocks on the block chain; in addition, the computer device executing the data transmission method can be a node device in the block chain network.

[0059] Please refer to Figure 4 , Figure 4A schematic diagram of a network architecture suitable for a data processing method is provided as an embodiment of this application; such as Figure 4 As shown, the network architecture includes: terminal device 41, cloud server 42, and application server 43.

[0060] Cloud server 42 and application server 43 can be servers with data processing capabilities. These servers can be independent physical servers, server clusters or distributed systems composed of multiple physical servers, or cloud servers providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms. Terminal device 41 can be a smart terminal with data processing capabilities, such as smartphones, tablets, laptops, desktop computers, smart voice interaction devices, smart home appliances, in-vehicle terminals, payment devices, smart bracelets, smart door locks, etc.

[0061] A cloud application client is deployed on terminal device 41. A running container, a transport container, a management container, and an initialization container are deployed on cloud server 42, and these containers are configured within the same target container unit. The application server is the backend server corresponding to the cloud application client. Figure 4 The network architecture shown can implement the data processing method provided in the embodiments of this application. The implementation process of this method generally includes:

[0062] ① When cloud server 42 receives a request data packet sent by cloud application client 41, it changes the external network address of cloud server 42 in the request data packet to the internal network address of the transmission container to obtain the target data packet.

[0063] ②The cloud server 42 sends the target data packet to the transmission container according to the intranet address of the transmission container.

[0064] ③ The cloud server 42 determines the return data packet corresponding to the target data packet through the transmission container and adds a target route identifier to the return data packet; wherein, the return data packet carries application data, and the application data is multimedia data generated by the cloud application instance in the running container during runtime; the target route identifier is used to indicate that the transmission object is the cloud application client.

[0065] ④ The cloud server 42 sends the return data packet to the cloud application client 41 according to the target route identifier, so that the cloud application client 41 loads the application data.

[0066] In the above method, the target routing identifier can be used to return the return data packet to the cloud application client via the original route, ensuring that the cloud application client can load the application data. In addition, the running container and the transmission container are configured in the same target container unit, which can physically shorten the distance of application data transmission, reduce the data transmission delay, and improve the data transmission efficiency in the cloud application scenario.

[0067] It can be understood that the network architecture diagram described in the embodiments of the present application is used to more clearly illustrate the technical solutions of the embodiments of the present application, and does not constitute a limitation on the technical solutions provided by the embodiments of the present application. Those skilled in the art can know that, with the evolution of network architecture and the emergence of new business scenarios, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.

[0068] The data processing method provided by the embodiments of the present application is briefly introduced above, and the specific implementation mode of the data processing method is described in detail below.

[0069] Please refer to Figure 5 , Figure 5 Flowchart of a data transmission method provided by the embodiments of the present application Figure 1 . The method is applied to the cloud server 42 in the above Figure 4 , and the cloud server 42 includes a transmission container, a running container, an initialization container and a management container configured in the same target container unit. The method includes the following steps S501-S504:

[0070] S501, when receiving a request data packet sent by a cloud application client, changing the external network address of the cloud server in the request data packet to the internal network address of the transmission container to obtain a target data packet.

[0071] The processor carried by the cloud server can be compatible with the cloud application instance corresponding to the cloud application client. For example, when the cloud server carries an ARM processor, the cloud server is an ARM server, and can be compatible with the cloud application instance compiled based on the ARM architecture. The request data packet is used to request the transmission container to send the application data of the cloud application instance to the cloud application client, and the application data is multimedia data (i.e. audio and video code streams) encoded according to the application picture rendered when the cloud application instance runs.

[0072] The external network address of the cloud server refers to the external IP (Internet Protocol) address of the external network of the cloud server, and the external network of the cloud server (i.e., the network used by the cloud server) can be accessed through the external network address of the cloud server. The internal network address of the transmission container refers to the virtual IP address of the transmission container, and the transmission container uses the internal network of the cloud server (i.e., the network used by the target container unit). The transmission container can be accessed through the internal network address of the transmission container in the internal network. In an implementation manner, the virtual IP address of the transmission container can be allocated by an API Server (application program interface service) component of the k8s cluster, and the API Server component is the data bus and data center of the entire k8s cluster.

[0073] In an embodiment, when the internal network of the cloud server receives the request data packet sent by the cloud application client, it is determined that the request data packet sent by the cloud application client is received, specifically: the gateway device of the cloud server receives the request data packet sent by the cloud application client, the destination address (i.e., the external network address of the cloud server) in the request data packet is the external network address (IP address) of the gateway device, and the gateway device is the external network gateway of the cloud server, which can connect to the external Internet, for example, the gateway device can be a TGW (Tencent Gateway, multi-network access load balancing system). Further, the gateway device forwards the request data packet to the target network card device of the cloud server, and the target network card device is used to connect the internal network in which the target container unit is deployed, so as to forward the request data packet to the internal network of the cloud server, and break the network isolation between the external network and the internal network of the cloud server.

[0074] Since the tunnel transmission technology can transmit data between different networks, in an implementation manner, the gateway device can forward the request data packet to the target network card device of the cloud server based on the tunnel transmission technology to break the network isolation between the external network and the internal network of the cloud server, including: there is an auxiliary network card device in the gateway device, and the external network address (i.e., the IP address) of the auxiliary network card device and the internal network address (i.e., the IP address) of the target network card device can be used to perform tunnel encapsulation processing on the request data packet to obtain a tunnel data packet. For example, referring to Figure 6 , the tunnel transmission technology is an IPIP tunnel technology, the external network address of the auxiliary network card device (bond1 in the gateway device 1) is 9.181.245.98, and the internal network address of the target network card device (bond2 in the gateway device 1) is 10.10.10.10. Figure 6 Figure 6 ​The inner network address of the target network card device (indicated by tunl1+bond1) is 100.115.82.29, and the IPIP tunnel header includes a sending end address (9.181.245.98) and a destination address (100.115.82.29). The IPIP tunnel header is added to the request data packet to obtain a tunnel data packet. According to the destination address (i.e., the inner network address of the target network card device) in the tunnel data packet, the tunnel data packet is sent from the auxiliary network card device to the target network card device, and the IPIP tunnel header in the tunnel data packet is removed to unseal the tunnel data packet into the request data packet. At this time, it is determined that the request data packet sent by the cloud application client is received.

[0075] In an available embodiment, the startup mode of the auxiliary network card device and the target network card device is bond1. Bond is to bind multiple physical network cards into a logical network card, and use the same IP address to work, which can increase bandwidth and improve redundancy. In the bond1 startup mode, only one network card device is in an active state, and another network card device is switched to a main network card device as soon as one network card device is down, which can improve the reliability of network connection.

[0076] In an embodiment, the auxiliary network card device can send the request data packet to a firewall management device, which can be a packet filtering firewall (iptables). The firewall management device includes one or more address conversion rules, and the one or more address conversion rules can be set in a NAT table in the packet filtering firewall to modify the sending end address, the destination address, or the port in the data packet. Therefore, the firewall management device can determine a target address conversion rule from the one or more address conversion rules according to the gateway device outer network address in the request data packet, the target address conversion rule is used to map the cloud server outer network address and the port in the request data packet to the transmission container inner network address and the port, and the determined target address conversion rule is used to change the cloud server outer network address in the request data packet to the transmission container inner network address to obtain a target data packet. For example, the request data packet includes a sending end address (129.211.166.248.26384), a destination address (113.96.237.61.20081), and a request data, and the destination address (i.e., the cloud server outer network address) in the request data packet can be changed to the transmission container inner network address (192.168.147.93.28001).

[0077] It should be noted that when the cloud server outer network address is the gateway device outer network address, the target address conversion rule is used to map the gateway device outer network address and the port in the request data packet to the transmission container inner network address and the port.

[0078] S502, sending the target data packet to the transport container according to the internal network address of the transport container.

[0079] In an embodiment, the firewall management device can send the target data packet to the bridge device by looking up the routing table. The bridge device can be a cbr0 bridge, which is a layer 2 network device and can realize many-to-many communication similar to a switch. For example, according to the routing table shown in Table 1, when the destination address is the IP address (192.168.143.0) of the target container unit, the corresponding output interface is the Ethernet bridge (cbr0 bridge). Therefore, the target data packet can be sent to the Ethernet bridge according to the obtained output interface.

[0080] Table 1

[0081] Destination address 0.0.0.0. 172.16.0.0 192.168.143.0 10.0.0.0 Gateway address 0.0.0.0 9.181.245.65 0.0.0.0 9.181.245.65 Network mask 0.0.0.0 255.240.0.0 255.255.255.0 255.0.0.0 Tag U UG U UG Routing distance 0 0 0 0 Reference count 0 0 0 0 Lookup count 0 0 0 0 Output interface tuncat bond1 cbr0 bond1

[0082] Further, the bridge device includes a first data interface, and the target container unit includes a second data interface. The first data interface and the second data interface are a veth pair, which are respectively placed in the namespaces of the bridge device and the target container unit. The target data packet received by the bridge device is sent to the second data interface of the target container unit through the first data interface. The second data interface sends the target data packet to the transport container according to the internal network address of the transport container in the target data packet.

[0083] S503, determining a return data packet corresponding to the target data packet through the transport container, and adding a target routing identifier to the return data packet. The return data packet carries application data, which is multimedia data generated by a cloud application instance in a running container during runtime. The target routing identifier is used to indicate that the transmission object is a cloud application client.

[0084] In an implementation, when the management container performs signaling interaction between the transport container and the cloud application client and determines to establish a communication connection between the transport container and the cloud application client, the target data packet can carry indication information that the cloud application client is ready to receive an audio / video code stream. At this time, the transport container can generate application data by using multimedia data (i.e., an audio / video code stream) generated by a cloud application instance in a running container during runtime, and construct a return data packet by using the application data. The return data packet can be one or more. Therefore, the transport container can continuously send the constructed return data packet to the cloud application client until the cloud application client stops running. In addition, the target data packet can also include a codec standard supported by the cloud application client, so that the running container encodes the application picture according to the codec standard supported by the cloud application client to obtain the audio / video code stream.

[0085] In an embodiment, the target data packet carries operation information for the cloud application client, the transmission container can send the operation information to the running container, so that the running container operates the cloud application instance, and generates a new application screen, and the transmission container sends the audio and video stream corresponding to the new application screen to the running container, and the transmission container constructs a return data packet according to the audio and video stream corresponding to the new application screen.

[0086] Please refer to Figure 6 When the return data packet comes out of the target container unit and reaches the network bridge device (cbr0 network bridge), since the lookup routing table cannot distinguish whether the external IP address in the return data packet is the external IP address of the application server or the external IP address of the cloud application client, the return data packet will be returned to the application server through the tuncat network card according to the default setting. Therefore, the present application adds a target routing identifier in the return data packet, which can be an IP tos mark, that is, adding "tos" in the request data packet, for example Figure 6 The return data packet carries "tos" in the above example.

[0087] S504, according to the target routing identifier, sending the return data packet to the cloud application client, so that the cloud application client loads the application data.

[0088] In an embodiment, a target routing forwarding rule is set in the firewall management device, and the processing logic of the target routing forwarding rule is: when it is determined that the "tos" exists in the to-be-forwarded data packet and the to-be-forwarded data packet is sent by the target container unit, the to-be-forwarded data packet is determined as the return data packet, and the target network card device is sent to send the return data packet to the cloud application client by the target network card device. Therefore, when the firewall management device receives the return data packet, the target routing forwarding rule can be determined from one or more routing forwarding rules included in the firewall management device, for example, the target routing forwarding rule is configured in the following program code 1: from 192.168..0.0 / 16 tos lowdelay lookup1, wherein 192.168..0.0 / 16 is used to indicate the network segment associated with the target container unit, when it is determined that the sending end address of the to-be-forwarded data packet matches 192.168..0.0 / 16 and contains "tos", the running result is default dev tunl1 scope link, tunl1 represents the target network card device, and indicates that it is directed to the tunl1 network card.

[0089] Program code 1:

[0090] [root@TENCENT64~]# ip rule

[0091] 0: from all lookup local / / All packets must first be routed using the local table (254)

[0092] 32764: from 192.168..0.0 / 16 to lowdelay lookup 1

[0093] 32765: from 113.96.232.158 lookup 1

[0094] 32766: from all lookup main / / Route using table main

[0095] 32767: from all lookup default / / Route using table default

[0096] [root@TENCENT64 ~]# ip route list table 1

[0097] default dev tunl1 scope link

[0098] Further, the target network card device sends the return data packet to the auxiliary network card device of the gateway device, which can still be sent based on the tunnel transmission technology, and the gateway device sends the return data packet to the cloud application client to return the return data packet to the cloud application client.

[0099] In an available embodiment, the firewall management device obtains the to-be-forwarded data packet, and the firewall management device can detect whether the sending end address in the to-be-forwarded data packet is associated with the target container unit, that is, whether it is sent by the target container unit. When it is detected that the sending end address in the to-be-forwarded data packet is not associated with the target container unit, it is determined that the to-be-forwarded data packet is an application data packet, and the application data packet is sent to the application server, for example, Figure 6 In the embodiment, the running container can send the application data packet to the application server through the bridge device, the tuncat network card, and then the gateway device 2. The response data packet returned for the application data packet can also be returned to the running container through the gateway device 2, the tuncat network card, and then the bridge device. When it is detected that the sending end address in the to-be-forwarded data packet is associated with the target container unit, it is determined whether the target routing identifier exists in the to-be-forwarded data packet. When it is determined that the target routing identifier does not exist, the to-be-forwarded data packet is determined to be an application data packet, and the application data packet is sent to the application server. When it is determined that the target routing identifier exists, the to-be-forwarded data packet is determined to be a return data packet, and the return data packet is sent to the target network card device to send the return data packet to the cloud application client through the target network card device.

[0100] In the embodiment of the present application, when the cloud server receives the request data packet sent by the cloud application client, the external network address of the cloud server in the request data packet is changed to the internal network address of the transmission container to obtain a target data packet, and the target data packet is sent to the transmission container according to the internal network address of the transmission container, so as to determine the return data packet corresponding to the target data packet through the transmission container, wherein the return data packet carries application data, and the application data is multimedia data generated when the cloud application instance in the running container runs. By adding a target routing identifier to the return data packet, the return data packet can be sent to the cloud application client, so that the cloud application client loads the application data. The above method can reduce the data transmission delay and improve the data transmission efficiency in the cloud application scenario by configuring the running container and the transmission container in the same target container unit.

[0101] Please refer to Figure 7 , Figure 7 A flowchart of a data transmission method provided by the embodiment of the present application Figure 2 . The method is applied to the cloud server 42 in the above Figure 4 , and the cloud server 42 includes a transmission container, a running container, an initialization container and a management container configured in the same target container unit. The method includes the following steps S701-S706:

[0102] S701, receiving a request data packet sent by a cloud application client through a gateway device.

[0103] S702, performing tunnel encapsulation processing on the request data packet according to the external network address of the auxiliary network card device in the gateway device and the internal network address of the target network card device, to obtain a tunnel data packet, wherein the target network card device is used to connect the internal network in which the target container unit is deployed.

[0104] The detailed implementation process of S701-S702 is described in S501, and the embodiment will not be described here.

[0105] Considering that adding IP tos marks to the request data packet of the cloud application client cannot well meet the external requirements of multi-operator networks, this is mainly because cross-operator network communication will cause data transmission delay, and the cloud application client will also set IP tos marks during gray or function testing, causing network abnormalities of the cloud application client. In the present application, multiple virtual network card devices are bound to the target network card device, and the multiple virtual network card devices correspond to different operator networks respectively. Each virtual network card device binds the external network IP address of the operator network corresponding thereto, so as to solve the problem of cross-operator network communication. In addition, the start mode of the multiple virtual network card devices bound to the target network card device is bond1, which can ensure that only one virtual network card device is in an active state. The detailed implementation process is described in the following embodiment.

[0106] S703: Based on the target network card device's internal network address and the target operator's network accessed by the cloud application client, send the tunnel data packet to the reference network card device bound to the target network card device, and decapsulate the tunnel data packet into a request data packet.

[0107] In one embodiment, the target operator network accessed by the cloud application client can be determined. For example, the request data packet may carry a network identifier indicating the target operator network accessed by the cloud application client, or the target operator network accessed by the cloud application client can be determined based on the sender address carried in the request data packet. Further, based on the target operator network, a reference network interface card (NIC) device is determined from multiple virtual NIC devices, wherein the external IP address bound to the reference NIC device is the external IP address of the target operator network.

[0108] In one embodiment, the gateway device can use the external network address of the auxiliary network interface card (NIC) in the gateway device and the internal network address of the target NIC to perform tunnel encapsulation processing on the request data packet to obtain a tunnel data packet. For example, see... Figure 8 The tunnel transmission technology is IPIP tunneling technology, and the auxiliary network card device (NIC) Figure 8 In gateway device 1, the external network address of the network interface card (NIC) indicated by bond1 is 9.181.245.98, and the internal network address of the target NIC (i.e., the IP address of bond1) is 100.115.82.29. The IPIP tunnel header includes the sender address (9.181.245.98) and the destination address (100.115.82.29). An IPIP tunnel header is added to the request data packet to obtain a tunnel data packet. Further, based on the destination address in the tunnel data packet (i.e., the internal network address of the target NIC), and the reference NIC determined by the target operator's network accessed by the cloud application client, the tunnel data packet is sent from the auxiliary NIC to the reference NIC bound to the target NIC, and the IPIP tunnel header is removed from the tunnel data packet to decapsulate it into a request data packet.

[0109] S704. Add the routing identifier corresponding to the reference network interface device to the request data packet, and change the external network address of the gateway device in the request data packet to the internal network address of the transport container to obtain the target data packet.

[0110] In an embodiment, the reference network card device can send the request packet to the firewall management device, the firewall management device can include one or more identification adding rules, the one or more identification adding rules can be the mangle table of iptables, the target identification adding rule can be determined from the one or more identification adding rules, and the target identification adding rule is used to indicate that the route identification corresponding to the reference network card device is added in the target packet. Taking the mangle table configured as follows as an example, the route identification added for the virtual network card device 1 (tunl1 indicated by the IP address 113.96.237.51) is 0x1, the route identification added for the virtual network card device 2 (tunl2 indicated by the IP address 120.241.186.86) is 0x2, and the route identification added for the virtual network card device 3 (tunl3 indicated by the IP address 157.255.196.124) is 0x3. As shown in FIG. 8, when it is determined that the reference network card device is the virtual network card device 1, the route identification 0x1 is added in the packet indicated by 81. Figure 8 Figure 8

[0111] mangle table:

[0112] [root@TENCENT64~]# ip tables-t mangle-vnl

[0113] Chain PEREOUTING(policy ACCEPT 3668M packets,4585G bytes)

[0114]

[0115] Meanwhile, the firewall management device includes one or more address conversion rules, and the firewall management device can determine a target address conversion rule from the one or more address conversion rules according to the external network address of the gateway device in the request packet, and change the external network address of the gateway device in the request packet to the internal network address of the transmission container according to the target address conversion rule to obtain the target packet.

[0116] S705, according to the internal network address of the transmission container, the target packet is sent to the transmission container, and the return packet corresponding to the target packet is determined through the transmission container, and the target route identification is added to the return packet; wherein the target route identification is the route identification corresponding to the reference network card device.

[0117] ​​In an embodiment, the firewall management device can send the target packet to a bridge device by looking up the routing table, the bridge device can be a cbr0 bridge, which is a layer 2 network device and can realize many-to-many communication similar to a switch. The bridge device includes a first data interface, and the target container unit includes a second data interface, the first data interface and the second data interface are a veth pair, respectively placed in the namespace of the bridge device and the target container unit. The target packet received by the bridge device is sent to the second data interface of the target container unit through the first data interface, and then the second data interface sends the target packet to the transport container according to the intranet address of the transport container in the target packet.

[0118] Further, the transport container can determine a return packet for the target packet, and obtain the routing identifier corresponding to the reference network card device from the target packet, determine the routing identifier corresponding to the reference network card device as the target routing identifier, and add the target routing identifier in the return packet. For example Figure 8 The return packet carries "0x1" in the middle.

[0119] S706, according to the target routing identifier, send the return packet to the cloud application client, so that the cloud application client loads the application data.

[0120] In an embodiment, the target route forwarding rule is set in the firewall management device, and the processing logic of the target route forwarding rule is: when it is determined that the reference network card device corresponding route identifier exists in the to-be-forwarded data packet and the to-be-forwarded data packet is sent by the target container unit, the to-be-forwarded data packet is determined as a return data packet, and the return data packet is sent to the reference network card device, so as to send the return data packet to the cloud application client through the reference network card device. Therefore, when the firewall management device receives the return data packet, the target route forwarding rule can be determined from one or more route forwarding rules included in the firewall management device to send the return data packet to the reference network card device. For example, the target route forwarding rule is configured in the following program code 2: from all fwmark ox3 iif cbro lowdelay lookup3 (indicating that the direction is the tunl1 network card), from all fwmark ox2 iif cbro lowdelay lookup3 (indicating that the direction is the tunl2 network card), from all fwmark ox1 iif cbro lowdelay lookup3 (indicating that the direction is the tunl3 network card). When it is determined that the sending end address of the to-be-forwarded data packet is cbr0 and contains “ox1”, the running result is default dev tunl1 scope link, indicating that the direction is the tunl1 network card (virtual network card device 1); when it is determined that the sending end address of the to-be-forwarded data packet is cbr0 and contains “ox2”, the running result is default dev tunl2 scope link, indicating that the direction is the tunl2 network card (virtual network card device 2); and when it is determined that the sending end address of the to-be-forwarded data packet is cbr0 and contains “ox3”, the running result is default dev tunl1 scope link, indicating that the direction is the tunl3 network card (virtual network card device 3).

[0121] Program code 2: [root@TENCENT64~] # ip rule

[0122] 0: from all lookup local / / all packets must first use the local table (254) for routing

[0123] 32760: from all fwmark ox3 iif cbro lowdelay lookup3

[0124] 32761: from all fwmark ox2 iif cbro lowdelay lookup2

[0125] 32762: from all fwmark oxi iif cbro lowdelay lookupl

[0126] 32763: from 157.255.196.124 lookup3

[0127] 32764: from all lookup main / / route using table main

[0128] 32765: from all lookup default / / route using table default

[0129] [root@TENCENT64~]# ip route list table 1

[0130] default dev tunl1 scope link

[0131] [root@TENCENT64~]# ip route list table 2

[0132] default dev tunl2 scope link

[0133] [root@TENCENT64~]# ip route list table 3

[0134] default dev tunl3 scope link

[0135] Further, sending the return data packet from the reference network card device to the auxiliary network card device of the gateway device can still be based on the tunnel transmission technology, and then sending the return data packet from the gateway device to the cloud application client to return the return data packet to the cloud application client.

[0136] Through the embodiment, the virtual network card device can be determined for the operator network accessed by the cloud application client, the external network IP address of the operator network bound by the virtual network card device is used to avoid cross-operator network access, the time delay of data transmission can be reduced, the transmission container and the running container are run in the target container unit, the time delay of data transmission can be further reduced, and the data transmission efficiency in the cloud application scenario can be improved.

[0137] The above describes the method of the embodiment of the application in detail. In order to better implement the above method of the embodiment of the application, correspondingly, the device of the embodiment of the application is provided below. Please refer to Figure 9 , Figure 9Figure 1 is a structural schematic diagram of a data transmission device provided by an embodiment of the present application, which is applied to a cloud server, the cloud server comprising a transmission container and a running container, the transmission container and the running container being configured in a same target container unit, the data transmission device 90 can comprise:

[0138] a processing unit 901, configured to change an external network address of the cloud server in a request data packet sent by a cloud application client into an internal network address of the transmission container to obtain a target data packet when the request data packet is received;

[0139] a sending unit 902, configured to send the target data packet to the transmission container according to the internal network address of the transmission container;

[0140] the processing unit 901 is further configured to determine a return data packet corresponding to the target data packet through the transmission container, add a target routing identifier to the return data packet, wherein the return data packet carries application data, the application data being multimedia data generated when a cloud application instance in the running container runs, and the target routing identifier is used to indicate that a transmission object is the cloud application client;

[0141] the sending unit 902 is further configured to send the return data packet to the cloud application client according to the target routing identifier, so that the cloud application client loads the application data.

[0142] In an embodiment, the cloud server further comprises a gateway device, and the data transmission device comprises a receiving unit 903, the receiving unit 903 being configured to receive a request data packet sent by the cloud application client through the gateway device;

[0143] the processing unit 901 is specifically configured to perform tunnel encapsulation processing on the request data packet according to an external network address of an auxiliary network card device in the gateway device and an internal network address of a target network card device, to obtain a tunnel data packet, wherein the target network card device is used to connect an internal network in which the target container unit is deployed;

[0144] the sending unit 902 is specifically configured to send the tunnel data packet to the target network card device according to the internal network address of the target network card device, and decapsulate the tunnel data packet into the request data packet.

[0145] In an embodiment, the target network card device binds a plurality of virtual network card devices, and the processing unit 901 is specifically configured to determine a target operator network accessed by the cloud application client, and determine a reference network card device from the plurality of virtual network card devices according to the target operator network;

[0146] The sending unit 902 is specifically configured to send the tunnel data packet to the reference network card device.

[0147] In an embodiment, the processing unit 901 is specifically configured to determine a routing identifier corresponding to the reference network card device, and add the routing identifier corresponding to the reference network card device to the request data packet.

[0148] In an embodiment, the processing unit 901 is specifically configured to determine the routing identifier corresponding to the reference network card device in the target data packet as a target routing identifier, and add the target routing identifier to the return data packet.

[0149] In an embodiment, the receiving unit 903 is specifically configured to acquire the return data packet through the firewall management device.

[0150] The processing unit 901 is specifically configured to determine, through the firewall management device, a target routing forwarding rule in routing forwarding rules included in the firewall management device according to the target routing identifier.

[0151] The sending unit 902 is specifically configured to send, through the firewall management device, the return data packet to the reference network card device according to the target routing forwarding rule, so as to send the return data packet to the cloud application client through the reference network card device.

[0152] In an embodiment, the receiving unit 903 is specifically configured to acquire the request data packet through the firewall management device.

[0153] The processing unit 901 is specifically configured to determine, through the firewall management device, a target address conversion rule from address conversion rules included in the firewall management device according to the external network address of the gateway device in the request data packet, and change, through the firewall management device, the external network address of the gateway device in the request data packet to an internal network address of the transmission container according to the target address conversion rule, to obtain a target data packet.

[0154] In an embodiment, the cloud server further includes a bridge device, and the sending unit 902 is specifically configured to send the target data packet to the bridge device, and send the target data packet to a second data interface of the target container unit through a first data interface of the bridge device, and send the target data packet to the transmission container through the second data interface according to the internal network address of the transmission container in the target data packet.

[0155] In an embodiment, the receiving unit 903 is specifically configured to acquire a data packet to be forwarded.

[0156] The processing unit 901 is specifically configured to detect whether the target routing identifier exists in the to-be-forwarded data packet if the sending end address in the to-be-forwarded data packet is associated with the target container unit.

[0157] The processing unit 901 and the sending unit 902 are specifically configured to determine that the to-be-forwarded data packet is an application data packet if the target routing identifier does not exist in the to-be-forwarded data packet, and send the application data packet to an application server corresponding to the cloud application client.

[0158] It can be understood that the functions of each functional unit of the data transmission apparatus described in the embodiments of the present application can be specifically implemented according to the methods in the above method embodiments, and the specific implementation process can refer to the related description of the above method embodiments, which will not be repeated here.

[0159] In the embodiments of the present application, when the cloud server receives the request data packet sent by the cloud application client, the external network address of the cloud server in the request data packet is changed to the internal network address of the transmission container to obtain a target data packet, and the target data packet is sent to the transmission container according to the internal network address of the transmission container, so as to determine the return data packet corresponding to the target data packet through the transmission container, wherein the return data packet carries application data, and the application data is multimedia data generated when the cloud application instance in the running container runs. By adding the target routing identifier to the return data packet, the return data packet can be sent to the cloud application client, so that the cloud application client loads the application data. The above method can improve the data transmission efficiency in the cloud application scenario.

[0160] As shown in Figure 10 , as shown in Figure 10 , the computer device 100 is a computer device provided by an embodiment of the present application, and a structure schematic diagram of the computer device is shown in Figure 10 , which includes one or more processors 1001, a memory 1002, and a communication interface 1003. The above processor 1001, memory 1002 and communication interface 1003 can be connected through a bus 1004 or other means, and the embodiment of the present application takes the connection through the bus 1004 as an example.

[0161] The processor 1001 (or CPU (Central Processing Unit, central processor)) is the computing core and control core of the computer device 100, which can parse various instructions in the computer device 100 and process various data of the computer device 100, for example: the CPU can be used to parse the on-off instruction sent by the user to the computer device 100, and control the computer device 100 to perform the on-off operation; for example: the CPU can transmit various interactive data between the internal structures of the computer device 100, and the like. The communication interface 1003 can optionally include a standard wired interface, a wireless interface (such as Wi-Fi, a mobile communication interface, etc.), controlled by the processor 1001 for transmitting and receiving data. The memory 1002 (Memory) is a memory device in the computer device 100, used to store computer programs and data. It can be understood that the memory 1002 here can include the built-in memory of the computer device 100, and of course can also include the expansion memory supported by the computer device 100. The memory 1002 provides a storage space that stores the operating system of the computer device 100, which can include but is not limited to: Windows system, Linux system, Android system, iOS system, etc., and the present application does not make any limitation on this. In an embodiment, the computer device 100 is a cloud server, and the cloud server includes a transmission container and a running container, and the transmission container and the running container are configured in the same target container unit, then the processor 1001 executes the following operations by running the computer program stored in the memory 1002:

[0162] When receiving the request data packet sent by the cloud application client, the external network address of the cloud server in the request data packet is changed to the internal network address of the transmission container to obtain a target data packet;

[0163] According to the internal network address of the transmission container, the target data packet is sent to the transmission container;

[0164] The target data packet corresponding to the return data packet is determined through the transmission container, and a target routing identifier is added to the return data packet; wherein the return data packet carries application data, and the application data is multimedia data generated when a cloud application instance in the running container runs; the target routing identifier is used to indicate that the transmission object is the cloud application client;

[0165] According to the target routing identifier, the return data packet is sent to the cloud application client, so that the cloud application client loads the application data.

[0166] In an embodiment, the cloud server further comprises a gateway device, and the processor 1001 is specifically configured to: receive the request data packet sent by the cloud application client through the gateway device; perform tunnel encapsulation processing on the request data packet according to an external network address of an auxiliary network card device in the gateway device and an internal network address of a target network card device, to obtain a tunnel data packet; wherein the target network card device is configured to connect an internal network in which the target container unit is deployed; and send the tunnel data packet to the target network card device according to the internal network address of the target network card device, and decapsulate the tunnel data packet into the request data packet.

[0167] In an embodiment, the target network card device is bound with a plurality of virtual network card devices, and the processor 1001 is specifically configured to: determine a target operator network accessed by the cloud application client; determine a reference network card device from the plurality of virtual network card devices according to the target operator network; and send the tunnel data packet to the reference network card device.

[0168] In an embodiment, the processor 1001 is specifically configured to: determine a routing identifier corresponding to the reference network card device, and add the routing identifier corresponding to the reference network card device to the request data packet.

[0169] In an embodiment, the processor 1001 is specifically configured to: determine the routing identifier corresponding to the reference network card device in the target data packet as a target routing identifier, and add the target routing identifier to the return data packet.

[0170] In an embodiment, the cloud server further comprises a firewall management device, and the processor 1001 is specifically configured to: obtain the return data packet through the firewall management device; determine a target routing forwarding rule in routing forwarding rules included in the firewall management device according to the target routing identifier through the firewall management device; and send the return data packet to the reference network card device according to the target routing forwarding rule through the firewall management device, so as to send the return data packet to the cloud application client through the reference network card device.

[0171] In an embodiment, the cloud server further comprises a firewall management device, and the processor 1001 is specifically configured to: obtain the request data packet through the firewall management device; determine a target address conversion rule from address conversion rules included in the firewall management device according to the external network address of the gateway device in the request data packet through the firewall management device; and change the external network address of the gateway device in the request data packet to an internal network address of the transmission container according to the target address conversion rule through the firewall management device, to obtain a target data packet.

[0172] In an embodiment, the cloud server further comprises a bridge device, and the processor 1001 is specifically configured to: send the target data packet to the bridge device; send the target data packet to a second data interface of the target container unit through a first data interface of the bridge device; and send the target data packet to the transport container according to the intranet address of the transport container in the target data packet through the second data interface.

[0173] In an embodiment, the processor 1001 is specifically configured to: obtain a data packet to be forwarded; if a sending end address in the data packet to be forwarded is associated with the target container unit, detect whether the target routing identifier exists in the data packet to be forwarded; and if the target routing identifier does not exist in the data packet to be forwarded, determine that the data packet to be forwarded is an application data packet, and send the application data packet to an application server corresponding to the cloud application client.

[0174] In a specific implementation, the processor 1001, the memory 1002, and the communication interface 1003 described in the embodiments of the present application can perform the implementation manners described in the data transmission method provided by the embodiments of the present application, and can also perform the implementation manners described in the data transmission device provided by the embodiments of the present application, which will not be described here.

[0175] In the embodiments of the present application, when the cloud server receives a request data packet sent by the cloud application client, the cloud server changes an extranet address of the cloud server in the request data packet into an intranet address of a transport container to obtain a target data packet, and sends the target data packet to the transport container according to the intranet address of the transport container, so as to determine a return data packet corresponding to the target data packet through the transport container. The return data packet carries application data, and the application data is multimedia data generated when a cloud application instance in a running container runs. By adding a target routing identifier to the return data packet, the return data packet can be sent to the cloud application client, so that the cloud application client loads the application data. The above method can improve the data transmission efficiency in the cloud application scenario.

[0176] The embodiments of the present application further provide a computer readable storage medium, which stores a computer program. When the computer program is run on a computer device, the computer device executes the data transmission method of any possible implementation manner. The specific implementation manners can be referred to the foregoing description, and will not be described here.

[0177] The embodiments of the present application further provide a computer program product, which comprises a computer program or computer instructions. When the computer program or computer instructions are executed by a processor, the steps of the data transmission method provided by the embodiments of the present application are implemented. The specific implementation manners can be referred to the foregoing description, and will not be described here.

[0178] The embodiment of the present application further provides a computer program, the computer program comprising computer instructions stored in a computer readable storage medium, a processor of a computer device reading the computer instructions from the computer readable storage medium, and the processor executing the computer instructions, so that the computer device executes the data transmission method provided by the embodiment of the present application. The specific implementation manners can refer to the foregoing description, and will not be described here.

[0179] It should be noted that, for each of the foregoing method embodiments, in order to simply describe, each is described as a series of action combinations, but those skilled in the art should know that the present application is not limited to the action sequence described, because according to the present application, some steps can be performed in other sequences or simultaneously. Secondly, those skilled in the art should know that the embodiments described in the specification all belong to preferred embodiments, and the actions and modules involved are not necessarily necessary for the present application.

[0180] Those of ordinary skill in the art can understand that all or part of the steps of the various methods in the above embodiments can be completed by a program instructing relevant hardware, and the program can be stored in a computer readable storage medium, and the storage medium can include a flash disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.

[0181] The above only describes some embodiments of the present application, and of course cannot limit the scope of the rights of the present application, so equivalent changes made according to the claims of the present application are still within the scope of the present application.

Claims

1. A data transmission method applied to a cloud server, characterized in that, The cloud server comprises a transmission container and a running container, the transmission container and the running container are configured in a same target container unit, the cloud server further comprises a firewall management device, and the method comprises: Upon receiving a request data packet sent by a cloud application client, changing an external network address of the cloud server in the request data packet to an internal network address of the transmission container to obtain a target data packet; Sending the target data packet to the transmission container according to the internal network address of the transmission container; Determining a return data packet corresponding to the target data packet through the transmission container, and adding a target routing identifier to the return data packet; wherein the return data packet carries application data, the application data being multimedia data generated when a cloud application instance in the running container runs; the target routing identifier is used to indicate that a transmission object is the cloud application client; According to the target routing identifier, sending the return data packet to the cloud application client, so that the cloud application client loads the application data; The sending of the return data packet to the cloud application client according to the target routing identifier comprises: acquiring a data packet to be forwarded through a firewall management device, detecting whether a sending end address in the data packet to be forwarded is associated with the target container unit, when it is detected that the sending end address in the data packet to be forwarded is associated with the target container unit, determining whether a target routing identifier exists in the data packet to be forwarded, and when it is determined that the target routing identifier exists, determining that the data packet to be forwarded is the return data packet, and sending the return data packet to a target network card device, so that the return data packet is sent to the cloud application client through the target network card device.

2. The method of claim 1, wherein, The cloud server further comprises a gateway device, the external network address of the cloud server is an external network address of the gateway device, and the method further comprises: Receiving a request data packet sent by the cloud application client through the gateway device; According to an external network address of an auxiliary network card device in the gateway device and an internal network address of a target network card device, performing tunnel encapsulation processing on the request data packet to obtain a tunnel data packet; wherein the target network card device is used to connect an internal network in which the target container unit is deployed; According to the internal network address of the target network card device, sending the tunnel data packet to the target network card device, and decapsulating the tunnel data packet into the request data packet.

3. The method of claim 2, wherein, The target network card device is bound with a plurality of virtual network card devices, the plurality of virtual network card devices correspond to different operator networks respectively, and the sending of the tunnel data packet to the target network card device comprises: Determining a target operator network accessed by the cloud application client; According to the target operator network, determining a reference network card device from the plurality of virtual network card devices; Sending the tunnel data packet to the reference network card device.

4. The method of claim 3, wherein, The method further comprises: Determining a routing identifier corresponding to the reference network card device, and adding the routing identifier corresponding to the reference network card device to the request data packet; The adding of the target routing identifier to the return data packet comprises: The target route identifier is determined according to the reference network card device in the target data packet; The target route identifier is added to the return data packet.

5. The method of claim 4, wherein, The return data packet is sent to the cloud application client according to the target route identifier, including: The return data packet is obtained through the firewall management device; The target route forwarding rule in the route forwarding rule included in the firewall management device is determined according to the target route identifier through the firewall management device; The return data packet is sent to the reference network card device through the firewall management device according to the target route forwarding rule, so that the return data packet is sent to the cloud application client through the reference network card device.

6. The method of claim 2, wherein, The cloud server further includes a firewall management device, and the external network address of the cloud server in the request data packet is changed to the internal network address of the transmission container to obtain a target data packet, including: The request data packet is obtained through the firewall management device; The target address conversion rule is determined from the address conversion rule included in the firewall management device according to the external network address of the gateway device in the request data packet through the firewall management device; The external network address of the gateway device in the request data packet is changed to the internal network address of the transmission container to obtain a target data packet according to the target address conversion rule through the firewall management device.

7. The method of claim 6, wherein, The cloud server further includes a bridge device, and the target data packet is sent to the transmission container according to the internal network address of the transmission container, including: The target data packet is sent to the bridge device; The target data packet is sent to the second data interface of the target container unit through the first data interface of the bridge device; The target data packet is sent to the transmission container according to the internal network address of the transmission container in the target data packet through the second data interface.

8. The method of claim 1, wherein, The method further includes: Obtaining a data packet to be forwarded; If the sending end address in the data packet to be forwarded is associated with the target container unit, it is detected whether the target route identifier exists in the data packet to be forwarded; If the target route identifier does not exist in the data packet to be forwarded, the data packet to be forwarded is determined as an application data packet, and the application data packet is sent to the application server corresponding to the cloud application client. 9.A data transmission apparatus applied to a cloud server, characterized in that, The cloud server includes a transmission container and a running container, and the transmission container and the running container are configured in the same target container unit, and the device includes: A processing unit, configured to change the external network address of the cloud server in the request data packet to the internal network address of the transmission container to obtain a target data packet when receiving the request data packet sent by the cloud application client; A sending unit, configured to send the target data packet to the transmission container according to the internal network address of the transmission container; The processing unit is further configured to determine, by the transmission container, a return data packet corresponding to the target data packet, add a target routing identifier to the return data packet, wherein the return data packet carries application data, the application data being multimedia data generated by a cloud application instance in the running container during runtime, and the target routing identifier is used to indicate that the transmission object is the cloud application client. The processing unit is further configured to send the return data packet to the cloud application client according to the target routing identifier, so that the cloud application client loads the application data. When the processing unit sends the return data packet to the cloud application client according to the target routing identifier, the processing unit is specifically configured to: acquire, by a firewall management device, a data packet to be forwarded, detect whether a sending end address in the data packet to be forwarded is associated with a target container unit, when it is detected that the sending end address in the data packet to be forwarded is associated with the target container unit, determine whether a target routing identifier exists in the data packet to be forwarded, when it is determined that the target routing identifier exists, determine that the data packet to be forwarded is the return data packet, and send the return data packet to the target network card device, so as to send the return data packet to the cloud application client by the target network card device.

10. A computer device, comprising: The computer device includes a memory, a communication interface and a processor, the memory, the communication interface and the processor are connected with each other; the memory stores a computer program, and the processor invokes the computer program stored in the memory to implement the data transmission method in any one of claims 1 to 8.

11. A computer readable storage medium, characterized in that, The computer readable storage medium stores a computer program, and the computer program is executed by the processor to implement the data transmission method in any one of claims 1 to 8.

12. A computer program product, characterised in that, The computer program product includes a computer program or computer instructions, and the computer program or computer instructions are executed by the processor to implement the data transmission method in any one of claims 1 to 8.

Citation Information

Patent Citations

  • Data transmission method and device based on virtual gateway, medium and electronic equipment

    CN111131037A

  • Network address translation method and device, gateway equipment and storage medium

    CN111327720A