CN117768417A - Data transmission method, device, computer equipment and storage medium - Google Patents

Data transmission method, device, computer equipment and storage medium Download PDF

Info

Publication number
CN117768417A
CN117768417A CN202311616104.0A CN202311616104A CN117768417A CN 117768417 A CN117768417 A CN 117768417A CN 202311616104 A CN202311616104 A CN 202311616104A CN 117768417 A CN117768417 A CN 117768417A
Authority
CN
China
Prior art keywords
data packet
transmitting
transmission
data
frequency
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311616104.0A
Other languages
Chinese (zh)
Inventor
陈迅
赖道宁
邓丽洁
黄晓莹
阮科
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Telecom Technology Innovation Center
China Telecom Corp Ltd
Original Assignee
China Telecom Technology Innovation Center
China Telecom Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Telecom Technology Innovation Center, China Telecom Corp Ltd filed Critical China Telecom Technology Innovation Center
Priority to CN202311616104.0A priority Critical patent/CN117768417A/en
Publication of CN117768417A publication Critical patent/CN117768417A/en
Pending legal-status Critical Current

Links

Landscapes

  • Optical Communication System (AREA)

Abstract

The present application relates to a data transmission method, apparatus, computer device, storage medium and computer program product. The method is applied to gateway equipment deployed with a colored light interface, and comprises the following steps: under the condition of receiving a first data packet sent by a first terminal, determining the occupation condition of a sending channel corresponding to a color light interface; switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to a first data packet according to the occupation condition of a transmitting channel; and transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency. The method can improve the utilization rate of the interface bandwidth resources.

Description

Data transmission method, device, computer equipment and storage medium
Technical Field
The present application relates to the field of communications technologies, and in particular, to a data transmission method, apparatus, computer device, storage medium, and computer program product.
Background
FlexE (Flexible Ethernet ) is an interface technology commonly used at present, which implements flexible and fine management of interface bandwidth resources through functions such as bundling, channeling, subrate, and the like.
While FlexE is no longer limited to the interface rates defined by existing IEEE802.3 (standard or protocol, the Institute of Electrical and Electronics Engineers, institute of electrical and electronics engineers) established and released by the IEEE802.3 working group, it is still a flexible allocation of bandwidth at a range of bandwidth granularity, for example, an integer multiple of 5GE (Gigabit Ethernet) granularity. Therefore, the data transmission method based on the FlexE technology has lower utilization rate of interface bandwidth resources.
Disclosure of Invention
In view of the foregoing, it is desirable to provide a data transmission method, apparatus, computer device, computer readable storage medium, and computer program product capable of improving the utilization of interface bandwidth resources, in response to the above-described technical problem of low utilization of interface bandwidth resources.
In a first aspect, the present application provides a data transmission method applied to a gateway device deployed with a color optical interface, where the method includes:
under the condition of receiving a first data packet sent by a first terminal, determining the occupation condition of a sending channel corresponding to the color light interface;
switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel;
And transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
In one embodiment, the switching the transmitting frequency of the color optical interface to the first transmitting frequency corresponding to the first data packet according to the occupation situation of the transmitting channel includes:
determining that the transmission channel is unoccupied in the case that there is no second data packet being transmitted in the transmission channel;
and under the condition that the transmission channel is unoccupied, switching the transmission frequency of the color light interface to a first transmission frequency corresponding to the first data packet.
In one embodiment, the switching, according to the occupation situation of the transmission channel, the transmitting frequency of the color optical interface to the first transmitting frequency corresponding to the first data packet further includes:
determining that the transmission channel is occupied under the condition that a second data packet which is being transmitted exists in the transmission channel;
determining a relation between a first data stream to which the first data packet belongs and a current time slot in the transmission channel under the condition that the transmission channel is occupied;
and switching the transmitting frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet according to the relation between the first data stream and the current time slot.
In one embodiment, the switching the transmitting frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet according to the relation between the first data stream and the current time slot includes:
transmitting the second data packet to a buffer area under the condition that the first data stream is the data stream corresponding to the current time slot;
and under the condition that the second data packet is cached in the buffer area, switching the transmitting frequency of the color light interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet.
In one embodiment, after the first data packet is transmitted to the second terminal corresponding to the first data packet according to the first transmission frequency, the method further includes:
fetching the second data packet from the buffer;
switching the emission frequency of the color light interface from the first emission frequency to the second emission frequency;
and transmitting the second data packet to a second terminal corresponding to the second data packet according to the second transmitting frequency.
In one embodiment, the switching the transmitting frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet according to the relationship between the first data stream and the current time slot further includes:
Transmitting the first data packet to a buffer area under the condition that the first data stream is not the data stream corresponding to the current time slot;
and after the transmission of the second data packet is finished, switching the transmitting frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet.
In one embodiment, the transmitting the first data packet to the second terminal corresponding to the first data packet according to the first transmission frequency includes:
fetching the first data packet from the buffer;
and transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
In one embodiment, before switching the transmission frequency of the color optical interface to the first transmission frequency corresponding to the first data packet, the method further includes:
determining a first data stream to which the first data packet belongs;
inquiring a pre-constructed data stream transmitting frequency mapping table, and determining the transmitting frequency corresponding to the first data stream as a first transmitting frequency corresponding to the first data packet; the pre-constructed data stream transmitting frequency mapping table is used for recording the mapping relation between each data stream transmitted by the color light interface and the transmitting frequency corresponding to each data stream.
In a second aspect, the present application further provides a data transmission apparatus, including:
the data receiving module is used for determining the occupation condition of a transmission channel corresponding to the color light interface under the condition that gateway equipment deployed with the color light interface receives a first data packet transmitted by a first terminal;
the frequency switching module is used for switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel;
and the data transmission module is used for transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
In a third aspect, the present application also provides a computer device comprising a memory and a processor, the memory storing a computer program, the processor implementing the following steps when executing the computer program:
under the condition that gateway equipment deployed with a color light interface receives a first data packet sent by a first terminal, determining the occupation condition of a sending channel corresponding to the color light interface;
switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel;
And transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
In a fourth aspect, the present application also provides a computer readable storage medium having stored thereon a computer program which when executed by a processor performs the steps of:
under the condition that gateway equipment deployed with a color light interface receives a first data packet sent by a first terminal, determining the occupation condition of a sending channel corresponding to the color light interface;
switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel;
and transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
In a fifth aspect, the present application also provides a computer program product comprising a computer program which, when executed by a processor, performs the steps of:
under the condition that gateway equipment deployed with a color light interface receives a first data packet sent by a first terminal, determining the occupation condition of a sending channel corresponding to the color light interface;
switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel;
And transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
The data transmission method, the device, the computer equipment, the storage medium and the computer program product firstly determine the occupation condition of a transmission channel corresponding to the color light interface under the condition that gateway equipment deployed with the color light interface receives a first data packet transmitted by a first terminal; switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel; and then transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency. Therefore, by utilizing the characteristic that the color light has standard frequency and the color light interface can switch the transmitting frequency, different data packets can be transmitted by adopting different transmitting frequencies according to the occupation condition of a transmitting channel corresponding to the color light interface; compared with a data transmission method based on the FlexE technology, the data transmission method based on the process can flexibly allocate bandwidth resources at a specific transmitting frequency, so that bandwidth granularity of bandwidth resource allocation is thinned, and the utilization rate of interface bandwidth resources is improved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the related art, the drawings that are required to be used in the embodiments or the related technical descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and other drawings may be obtained according to the drawings without inventive effort for a person having ordinary skill in the art.
FIG. 1 is a diagram of an application environment for a data transmission method in one embodiment;
FIG. 2 is a flow chart of a data transmission method in one embodiment;
FIG. 3 is a schematic diagram of time division multiplexing in one embodiment;
FIG. 4 is a schematic diagram of time division multiplexing in another embodiment;
FIG. 5 is a schematic diagram of time division multiplexing in yet another embodiment;
FIG. 6 is a schematic diagram of transmitting a first data packet in a current time slot corresponding to a transmission channel when the transmission channel is unoccupied in one embodiment;
fig. 7 is a flowchart illustrating a step of switching a transmitting frequency of a color optical interface to a first transmitting frequency corresponding to a first data packet according to an occupation situation of a transmitting channel in an embodiment;
fig. 8 is a schematic diagram of transmitting a first data packet in a current time slot in the case that the first data stream is a data stream corresponding to the current time slot in one embodiment;
FIG. 9 is a diagram illustrating the second packet being removed from the buffer and transmitted in one embodiment;
FIG. 10 is a schematic diagram of sending a first data packet to a buffer in a case where the first data stream is not the data stream corresponding to the current slot in one embodiment;
FIG. 11 is a schematic diagram illustrating the first data packet being fetched from the buffer and transmitted according to one embodiment;
FIG. 12 is a flow chart of a data transmission method in another embodiment;
FIG. 13 is a flow chart of a data transmission method according to yet another embodiment;
FIG. 14 is a flow diagram of a traffic preemption mode in accordance with an embodiment;
FIG. 15 is a block diagram of a data transmission device in one embodiment;
fig. 16 is an internal structural view of a computer device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
It should be noted that, the user information (including, but not limited to, user equipment information, user personal information, etc.) and the data (including, but not limited to, data for analysis, stored data, presented data, etc.) referred to in the present application are information and data authorized by the user or sufficiently authorized by each party, and the collection, use and processing of the related data are required to comply with the related laws and regulations and standards of the related countries and regions.
The data transmission method provided in the embodiment of the present application may be applied to an application environment as shown in fig. 1, where the application environment includes a gateway device 102 deployed with a color optical interface, a first terminal 104 for transmitting data through the gateway device 102, and a second terminal 106 for receiving data transmitted by the terminal 104, where the first terminal refers to a transmitting end in data transmission, and the second terminal refers to a receiving end in data transmission.
The gateway device 102 may be a router, a switch, a gateway server, etc.; the first terminal 104 and the second terminal 106 may be, but not limited to, various personal computers, notebook computers, smart phones, tablet computers, internet of things devices and portable wearable devices, and the internet of things devices may be smart speakers, smart televisions, smart air conditioners, smart vehicle devices, and the like. The portable wearable device may be a smart watch, smart bracelet, headset, etc., and may also be implemented with a server.
Specifically, when receiving the first data packet sent by the first terminal 104, the gateway device 102 determines an occupation condition of a sending channel corresponding to the color optical interface, then switches the sending frequency of the color optical interface to a first sending frequency corresponding to the first data packet according to the occupation condition of the sending channel, and then transmits the first data packet to the second terminal 106 corresponding to the first data packet according to the first sending frequency.
In an exemplary embodiment, as shown in fig. 2, a data transmission method is provided, which is illustrated by taking an example that the method is applied to the gateway device in fig. 1, and includes the following steps S202 to S206:
step S202, under the condition that a first data packet sent by a first terminal is received, determining the occupation condition of a sending channel corresponding to a color light interface.
The first terminal refers to a terminal for transmitting a first data packet, namely a transmitting end in a data transmission process.
The gateway equipment can be a router, a switch, a gateway server and the like, and a color light interface is deployed on the gateway equipment; in the field of communication technology, color light refers to light with a single frequency, and currently, gateway devices on the market mostly adopt white light interfaces, and white light refers to an indefinite wavelength in a certain range.
Wherein, the first data flow to which the first data packet belongs is a data flow of a first service; it will be appreciated that during data transmission, the data stream is discontinuous, and therefore the data stream of the service is transmitted in the form of a plurality of data packets. In the data transmission method provided by the application, different services are distinguished through the transmission frequency, for example, the transmission frequencies corresponding to the data streams of the different services are different.
Specifically, when the gateway device receives the first data packet sent by the first terminal, it first determines whether there is a data packet being transmitted on a transmission channel corresponding to the color optical interface, that is, an occupied condition of the transmission channel, if so, it indicates that the transmission channel is occupied, and if not, it indicates that the transmission channel is unoccupied.
Step S204, switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel.
The first transmitting frequency corresponding to the first data packet is the transmitting frequency corresponding to the first data stream to which the first data packet belongs.
Specifically, the gateway device switches the transmitting frequency of the color light interface to the first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel under the condition that the transmitting channel is idle.
For example, in the case that the transmission channel is unoccupied, that is, the transmission channel is idle, the gateway device directly switches the transmission frequency of the color optical interface to the first transmission frequency corresponding to the first data packet.
For example, when the transmission channel is occupied, the gateway device may determine the priority order between the second data packet and the first data packet being transmitted on the transmission channel, if the priority of the second data packet is greater than that of the first data packet, continue to transmit the second data packet, wait until the transmission of the second data packet is finished, i.e. the transmission channel is idle, switch the transmission frequency of the color optical interface to the first transmission frequency corresponding to the first data packet, and if the priority of the first data packet is greater than that of the second data packet, then need to transmit the first data packet preferentially, so as to suspend transmission of the second data packet, switch the transmission frequency of the color optical interface to the first transmission frequency corresponding to the first data packet when the transmission channel is in an idle state, wait until the transmission channel is idle after the transmission of the first data packet is finished, and continue to transmit the second data packet.
Step S206, according to the first transmitting frequency, the first data packet is transmitted to the second terminal corresponding to the first data packet.
The second terminal refers to a terminal that receives the first data packet, that is, a receiving end in a data transmission process.
Specifically, the gateway device transmits the first data packet to the second terminal corresponding to the first data packet through the color optical interface according to the first transmitting frequency, so as to realize data transmission.
In the data transmission method, a gateway device deployed with a color light interface determines the occupation condition of a transmission channel corresponding to the color light interface under the condition that a first data packet transmitted by a first terminal is received; switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel; and then transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency. In this way, the gateway equipment with the color light interface can transmit different data packets by adopting different transmission frequencies according to the occupation condition of the transmission channel corresponding to the color light interface by utilizing the characteristic that the color light has standard frequency and the color light interface can switch the transmission frequency; compared with a data transmission method based on the FlexE technology, the data transmission method based on the process can flexibly allocate bandwidth resources at a specific transmitting frequency, so that bandwidth granularity of bandwidth resource allocation is thinned, and the utilization rate of interface bandwidth resources is improved.
In an exemplary embodiment, the step S204 switches the transmitting frequency of the color optical interface to the first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel, which specifically includes the following steps: determining that the transmission channel is unoccupied in the case that there is no second data packet being transmitted in the transmission channel; and under the condition that the transmission channel is unoccupied, switching the transmission frequency of the color optical interface to a first transmission frequency corresponding to the first data packet.
It should be noted that in the field of communication technology, time division multiplexing is often adopted in current data transmission, that is, each data stream is allocated with a corresponding time slot, and the data stream can be transmitted only in the corresponding time slot, as shown in fig. 3, which is a schematic diagram of time division multiplexing. It can be understood that there is a waste of time slot resources in the time division multiplexing, on the one hand, the data packet corresponding to the data stream does not necessarily occupy the whole time slot in the transmission process, for example, in the further time division multiplexing diagram shown in fig. 4, the data packet of the data stream 1 does not occupy the whole time slot 1, and then the time slot resources of the unoccupied part of the time slot 1 are wasted; on the other hand, when the slot does not have a corresponding data stream to be transmitted, the gateway device cannot be used to transmit other data streams, for example, in the further time division multiplexing diagram shown in fig. 5, when reaching the slot 2, assuming that the gateway device does not receive the data packet to be transmitted of the data stream 2, even if the gateway device has already received the data packet to be transmitted of the data stream 3, the slot 2 cannot be used to transmit the data packet to be transmitted of the data stream 3, but the data packet to be transmitted of the data stream 3 cannot be transmitted until reaching the slot 3, and then the slot resource of the slot 2 is wasted; therefore, the data transmission method based on time division multiplexing may result in waste of time slot resources, lower utilization rate, and reduced data transmission efficiency.
In the data transmission method provided by the application, a preemption mode is adopted to transmit the data stream; specifically, the gateway device determines that the transmission channel is unoccupied and is in an idle state under the condition that no second data packet is being transmitted in the transmission channel, so that the transmission frequency of the color optical interface is switched to the transmission frequency corresponding to the first data packet, and the first data packet is transmitted to the second terminal corresponding to the first data packet according to the first transmission frequency through the color optical interface.
For example, fig. 6 is a schematic diagram of a gateway device transmitting a first data packet in a current time slot corresponding to a transmission channel when the transmission channel is unoccupied; referring to fig. 6, assuming that when the gateway device receives a data packet corresponding to a data stream 2, the current time slot corresponding to a transmission channel is time slot 1, and the data packet corresponding to the data stream 1 has been transmitted in time slot 1, and no other data packet is being transmitted in the current transmission channel, the gateway device determines that the transmission channel is unoccupied and is in an idle state, so that the transmission frequency of the color optical interface is switched to the transmission frequency corresponding to the data stream 2, and the data packet corresponding to the data stream 2 is transmitted in time slot 1.
For another example, referring to fig. 6, assuming that when the gateway device receives the data packet corresponding to the data stream 3, the current time slot corresponding to the transmission channel is time slot 2, and no other data packet is being transmitted in the current transmission channel, the gateway device determines that the transmission channel is unoccupied and is in an idle state, so that the transmitting frequency of the color optical interface is switched to the transmitting frequency corresponding to the data stream 3, and the data packet corresponding to the data stream 3 is transmitted in the time slot 2.
In this embodiment, the gateway device does not transmit the data packet corresponding to the data stream strictly according to the corresponding relationship between the data stream and the time slot, as in time division multiplexing, but flexibly allocates the time slot resource under the condition that the transmission channel is idle according to the occupation condition of the transmission channel, so that the data packet can be transmitted in any time slot, which not only avoids the time slot resource waste caused by that the data packet does not necessarily occupy the whole time slot in the transmission process, but also avoids the time slot resource waste caused by that the time slot cannot transmit the data packet of other data streams except the data stream corresponding to the gateway device, thereby improving the utilization rate of the time slot resource, further improving the utilization rate of the interface bandwidth resource, and improving the data transmission efficiency.
As shown in fig. 7, in an exemplary embodiment, the step S204 switches the transmitting frequency of the color optical interface to the first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel, and specifically further includes the following steps:
in step S702, in the case that there is a second packet being transmitted in the transmission channel, it is determined that the transmission channel is occupied.
Step S704, determining a relationship between the first data stream to which the first data packet belongs and the current time slot in the transmission channel in the case that the transmission channel is occupied.
Step S706, according to the relation between the first data stream and the current time slot, the transmitting frequency of the color light interface is switched from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet.
Specifically, the gateway device determines that the transmission channel is occupied when there is a second packet being transmitted in the transmission channel, so as to further determine a relationship between a first data stream to which the first packet belongs and a current time slot in the transmission channel, for example, determine whether the first data stream is a data stream corresponding to the current time slot (i.e., determine whether the current time slot is a time slot allocated to the first data stream in the original time division multiplexing); and then, the gateway equipment switches the frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet being transmitted to the first transmitting frequency corresponding to the first data packet according to the relation between the first data stream and the current time slot, so that the first data packet is conveniently transmitted to the second terminal corresponding to the first data packet according to the first transmitting frequency.
For example, when the first data stream is the data stream corresponding to the current time slot, it is indicated that in the current time slot, the priority of the first data packet is greater than that of the second data packet, so that the first data packet needs to be transmitted preferentially, and further the gateway device suspends the transmission of the second data packet, switches the transmission frequency of the color optical interface from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet, and transmits the first data packet according to the first transmission frequency.
For example, when the first data stream is not the data stream corresponding to the current time slot, since the second data packet is already in transmission at this time, the gateway device may consider that the priority of the second data packet is higher than that of the first data packet in the current time slot no matter whether the second data stream corresponding to the second data packet is the data stream corresponding to the current time slot, so the gateway device continues to transmit the second data packet, and switches the transmission frequency of the color optical interface from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet after the transmission of the second data packet is completed, and transmits the first data packet according to the first transmission frequency.
In this embodiment, when the transmission channel is occupied, the gateway device determines, according to whether the first data stream corresponding to the first data packet is the data stream corresponding to the current time slot, a priority order between the first data packet to be transmitted and the second data packet being transmitted, and stops transmission of the second data packet or continues transmission of the second data packet based on the priority order, so that the data transmission efficiency is improved, the maintenance of time division multiplexing is also considered, and the order of data transmission is ensured.
In an exemplary embodiment, the step S706 switches the transmission frequency of the color optical interface from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet according to the relationship between the first data stream and the current time slot, which specifically includes the following steps: transmitting the second data packet to the buffer area under the condition that the first data stream is the data stream corresponding to the current time slot; and under the condition that the second data packet is cached in the buffer area, switching the transmission frequency of the color optical interface from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet.
Wherein, the buffer is referred to as buffer.
Specifically, the gateway device determines that, when the first data stream is a data stream corresponding to the current time slot, the priority of the first data packet is higher than that of the second data packet in the current time slot, so that the first data packet needs to be transmitted preferentially, and then the gateway device suspends transmission of the second data packet, transfers the second data packet into the buffer area in order to prevent data loss of the second data packet, and switches the transmitting frequency of the color optical interface from the second transmitting frequency to the first transmitting frequency after the second data packet is transferred into the buffer area.
For example, fig. 8 is a schematic diagram illustrating transmission of the first data packet in the current time slot in the case that the first data stream is the data stream corresponding to the current time slot; assuming that when the gateway device receives the data packet corresponding to the data stream 1, the current time slot is the time slot 1 corresponding to the data stream 1, and the current transmission channel is transmitting the data packet corresponding to the data stream 2, the gateway device needs to transmit the data packet corresponding to the data stream 1 preferentially, so that the transmission of the data packet corresponding to the data stream 2 is stopped, the data packet is transferred into the buffer area, and then the transmitting frequency of the color optical interface is switched from the transmitting frequency corresponding to the data stream 2 to the transmitting frequency corresponding to the data stream 1.
In this embodiment, the gateway device determines whether the first data stream corresponding to the first data packet is a data stream corresponding to the current time slot, and when the first data stream corresponding to the first data packet is a data stream corresponding to the current time slot, by stopping data transmission of the second data packet and switching the transmitting frequency of the color optical interface, priority transmission of the first data packet is achieved, so that the data transmission efficiency is improved, maintenance of time division multiplexing is considered, and the order of data transmission is ensured; in addition, the gateway equipment also ensures that the second data packet cannot be lost by transferring the second data packet into the buffer area.
In an exemplary embodiment, after the first data packet is transmitted to the second terminal corresponding to the first data packet according to the first transmission frequency in step S206, the following is specifically included: fetching the second data packet from the buffer; switching the emission frequency of the color light interface from the first emission frequency to the second emission frequency; and transmitting the second data packet to a second terminal corresponding to the second data packet according to the second transmitting frequency.
Specifically, when the gateway device suspends transmission of the second data packet and preferentially transmits the first data packet, after the transmission of the first data packet is finished, the gateway device also needs to take out the second data packet from the buffer zone, and switch the transmitting frequency of the color optical interface from the first transmitting frequency corresponding to the first data packet to the second transmitting frequency corresponding to the second data packet.
For example, as shown in fig. 9, a schematic diagram of taking out a second data packet from a buffer and transmitting the second data packet is shown, where in the case that the data packet corresponding to the data stream 1 is the first data packet, the data packet corresponding to the data stream 2 is the second data packet, and the current time slot is the time slot 1 corresponding to the data stream 1, the gateway device suspends the data packet corresponding to the data stream 2 and transfers it into the buffer; after the transmission of the data packet corresponding to the data stream 1 is finished, the gateway device needs to take out the data packet corresponding to the data stream 2 from the buffer area, and switch the transmission frequency of the color optical interface from the transmission frequency corresponding to the data stream 1 to the transmission frequency corresponding to the data stream 2.
It should be noted that, when the second data packet is transmitted after the transmission of the first data packet is finished, it is not limited whether the second data packet is transmitted in the current time slot or in the next time slot of the current time slot, or is transmitted across time slots, and specifically may be determined according to the duration of the remaining part of the current time slot after the transmission of the first data packet is finished.
In this embodiment, after the transmission of the first data packet is finished, the gateway device takes out the second data packet from the buffer area, and can retransmit the second data packet through switching the transmitting frequency of the color optical interface, so as to ensure the integrity of the transmission of the second data packet.
In an exemplary embodiment, the step S706 switches the transmission frequency of the color optical interface from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet according to the relationship between the first data stream and the current time slot, and specifically further includes the following: transmitting the first data packet to a buffer area under the condition that the first data stream is not the data stream corresponding to the current time slot; and after the transmission of the second data packet is finished, switching the transmitting frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet.
Specifically, the gateway device determines that the priority of the second data packet in the current time slot is greater than that of the first data packet when the first data stream is not the data stream corresponding to the current time slot, so that the second data packet is continuously transmitted, and in order to prevent data loss of the first data packet, the first data packet is transferred into the buffer zone, and after the transmission of the second data packet is finished, the transmitting frequency of the color optical interface is switched from the second transmitting frequency to the first transmitting frequency.
For example, fig. 10 is a schematic diagram showing sending a first data packet to a buffer when the first data stream is not the data stream corresponding to the current time slot; assuming that when the gateway device receives the data packet corresponding to the data stream 2, the current time slot is the time slot 1 corresponding to the data stream 1, and the current transmission channel is transmitting the data packet corresponding to the data stream 1 (or any one of the data packets corresponding to the data stream), the gateway device will continue to transmit the data packet corresponding to the data stream 1 (or the data packet being transmitted), so that the data packet corresponding to the data stream 2 is transferred into the buffer, and after the data packet corresponding to the data stream 1 (or the data packet being transmitted) is transmitted, the transmitting frequency of the color optical interface is switched from the transmitting frequency corresponding to the data stream 1 (or the data packet being transmitted) to the transmitting frequency corresponding to the data stream 2, and then the data packet corresponding to the data stream 2 is transmitted according to the transmitting frequency corresponding to the data stream 2.
In this embodiment, the gateway device determines whether the first data stream corresponding to the first data packet is a data stream corresponding to the current time slot, preferentially completes data transmission of the second data packet when the first data stream corresponding to the first data packet is not the data stream corresponding to the current time slot, and then switches the transmitting frequency of the color optical interface after the transmission of the second data packet is completed, so as to realize the transmission of the first data packet and ensure the order of data transmission; in addition, the gateway equipment also ensures that the first data packet is not lost by transferring the first data packet into the buffer area.
In an exemplary embodiment, the step S206, according to the first transmission frequency, transmits the first data packet to the second terminal corresponding to the first data packet, specifically includes the following contents: fetching the first data packet from the buffer; and transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
Specifically, when the gateway device continues to transmit the second data packet, after the transmission of the second data packet is finished and the transmission frequency of the color optical interface is switched from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet, the gateway device also needs to take out the first data packet from the buffer area, and then transmits the first data packet to the second terminal corresponding to the first data packet according to the first transmission frequency.
For example, as shown in fig. 11, a schematic diagram of taking out a first data packet from a buffer and transmitting the first data packet is shown, where when a data packet corresponding to a data stream 2 is the first data packet, a data packet corresponding to a data stream 1 is the second data packet, and a current time slot is a time slot 1 corresponding to the data stream 1, the gateway device continues to transmit the data packet corresponding to the data stream 1, and transfers the data packet corresponding to the data stream 2 into the buffer; after the transmission of the data packet corresponding to the data stream 1 is finished, the gateway device needs to take out the data packet corresponding to the data stream 2 from the buffer area, switch the transmitting frequency of the color optical interface from the transmitting frequency corresponding to the data stream 1 to the transmitting frequency corresponding to the data stream 2, and then transmit the data packet corresponding to the data stream 2 according to the transmitting frequency corresponding to the data stream 2.
It should be noted that, when the first data packet is transmitted after the second data packet is transmitted, it is not limited whether the first data packet is transmitted in the current time slot or in the next time slot of the current time slot, or is transmitted across time slots, and may specifically be determined according to the duration of the remaining part of the current time slot after the second data packet is transmitted.
In this embodiment, after the second data packet is transmitted and the transmitting frequency of the color optical interface is switched from the second transmitting frequency to the first transmitting frequency, the gateway device can implement data transmission of the first data packet by taking out the first data packet from the buffer area.
In an exemplary embodiment, before the transmitting frequency of the color optical interface is switched to the first transmitting frequency corresponding to the first data packet in step S206, the method specifically further includes the following: determining a first data stream to which the first data packet belongs; and inquiring a pre-constructed data stream transmission frequency mapping table, and determining the transmission frequency corresponding to the first data stream as the first transmission frequency corresponding to the first data packet.
The pre-constructed data stream transmitting frequency mapping table is used for recording the mapping relation between each data stream transmitted by the color light interface and the transmitting frequency corresponding to each data stream.
Specifically, before switching the transmission frequency of the color optical interface, the gateway device needs to determine a first data stream to which the first data packet belongs, then query a pre-constructed data stream transmission frequency mapping table according to the first data stream, determine the transmission frequency corresponding to the first data stream, and determine the transmission frequency corresponding to the first data stream as the first transmission frequency corresponding to the first data packet.
It can be appreciated that each time the gateway device switches the transmission frequency corresponding to the data stream, a table look-up is required to determine the corresponding transmission frequency, for example, when the gateway device switches the transmission frequency from the first transmission frequency to the second transmission frequency, the gateway device also needs to determine the second transmission frequency corresponding to the second data packet through the table look-up.
For example, assuming that the data stream transmission frequency mapping table is shown in table 1, if the first data stream corresponding to the first data packet is data stream 2, the gateway device may determine that the first transmission frequency corresponding to the first data packet is 194.100THz according to the data stream transmission frequency mapping table.
Table 1 data stream transmit frequency mapping table
Service data flow Transmission frequency
Data stream 1 193.100THz
Data stream 2 194.100THz
Data stream 3 195.100THz
Data stream 4 193.200THz
…… ……
Further, the construction process of the pre-constructed data stream transmission frequency mapping table is as follows: the gateway equipment acquires the respective corresponding transmitting frequencies of the data streams transmitted by the gateway equipment; and the gateway equipment constructs a data stream transmitting frequency mapping table according to each data stream and the transmitting frequency corresponding to each data stream.
In this embodiment, the gateway device can quickly and accurately determine the first transmission frequency corresponding to the first data packet through the first data stream to which the first data packet belongs and the pre-constructed data stream transmission frequency mapping table, so that the first data packet can be conveniently and subsequently transmitted according to the first transmission frequency, and further bandwidth resources can be flexibly allocated according to the specific transmission frequency, thereby refining the bandwidth granularity of bandwidth resource allocation and improving the utilization rate of interface bandwidth resources.
In an exemplary embodiment, as shown in fig. 12, another data transmission method is provided, and the method is applied to a gateway device with a color optical interface, for example, and includes the following steps:
in step S1201, under the condition that the first data packet sent by the first terminal is received, an occupation condition of a sending channel corresponding to the color light interface is determined.
Step S1202, in the case where there is no second data packet being transmitted in the transmission channel, it is determined that the transmission channel is unoccupied.
Step S1203, when the transmission channel is unoccupied, switching the transmission frequency of the color optical interface to the first transmission frequency corresponding to the first data packet.
Step S1204, transmitting the first data packet to the second terminal corresponding to the first data packet according to the first transmission frequency.
The above steps S1202 to S1204 may also be implemented by the following steps S1205 to S1214:
in step S1205, in the case that there is the second packet being transmitted in the transmission channel, it is determined that the transmission channel is occupied.
In step S1206, in the case where the transmission channel is occupied, a relationship between the first data stream to which the first data packet belongs and the current slot in the transmission channel is determined.
In step S1207, if the first data stream is the data stream corresponding to the current slot, the second data packet is sent to the buffer.
In step S1208, when the second data packet is buffered in the buffer, the transmitting frequency of the color optical interface is switched from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet.
Step S1209, transmitting the first data packet to the second terminal corresponding to the first data packet according to the first transmission frequency.
In step S1210, the second data packet is fetched from the buffer, and the transmission frequency of the color optical interface is switched from the first transmission frequency to the second transmission frequency.
Step S1211, transmitting the second data packet to the second terminal corresponding to the second data packet according to the second transmission frequency.
The above steps S1207 to S1211 may also be implemented by the following steps S1212 to S1214:
in step S1212, the first data packet is sent to the buffer if the first data stream is not the data stream corresponding to the current slot.
In step S1213, after the transmission of the second data packet is completed, the transmission frequency of the color optical interface is switched from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet.
In step S1214, the first data packet is fetched from the buffer, and is transmitted to the second terminal corresponding to the first data packet according to the first transmission frequency.
The data transmission method provided in this embodiment may also be represented by a flowchart shown in fig. 13, that is, if the first data packet arrives, it is first determined whether the transmission channel is occupied by the second data packet, if not, the first data packet is directly transmitted, and if occupied by the second data packet, it is further determined whether the first data packet is a data packet corresponding to the current time slot; and if the first data packet is not the data packet corresponding to the current time slot, transferring the first data packet into the buffer area for queuing.
In this embodiment, first, the gateway device does not transmit the data packet corresponding to the data stream strictly according to the corresponding relationship between the data stream and the time slot, as in time division multiplexing, but flexibly allocates the time slot resource under the condition that the transmission channel is idle according to the occupation condition of the transmission channel, so that the data packet can be transmitted in any time slot, which not only avoids the time slot resource waste caused by that the data packet does not necessarily occupy the whole time slot in the transmission process, but also avoids the time slot resource waste caused by that the time slot cannot transmit the data packet of other data streams except the data stream corresponding to the gateway device, thereby improving the utilization rate of the time slot resource and the efficiency of data transmission. Second, the gateway device determines the priority order between the first data packet to be transmitted and the second data packet being transmitted according to whether the first data stream corresponding to the first data packet is the data stream corresponding to the current time slot or not under the condition that the transmission channel is occupied, and stops the transmission of the second data packet or continues the transmission of the second data packet based on the priority order, so that the data transmission efficiency is improved, the maintenance of time division multiplexing is also considered, and the order of data transmission is ensured. Third, the network optical equipment can transmit different data packets by adopting different transmitting frequencies according to the occupation condition of a transmitting channel corresponding to the color optical interface by utilizing the characteristic that the color optical has standard frequency and the color optical interface can switch transmitting frequency; compared with a data transmission method based on the FlexE technology, the data transmission method based on the process can flexibly allocate bandwidth resources at a specific transmitting frequency, so that bandwidth granularity of bandwidth resource allocation is thinned, and the utilization rate of interface bandwidth resources is improved.
In order to more clearly illustrate the data transmission method provided in the embodiments of the present application, a specific embodiment will be described below specifically, but it should be understood that the embodiments of the present application are not limited thereto. In an exemplary embodiment, the present application further provides a method for implementing service isolation based on a color optical interface of a router, which specifically includes the following contents:
1. a mapping table of service flows and color light emission frequencies is added, different service flows are sent through emission frequency switching of a color light interface, so that service collision is avoided, and service hard isolation and Qos (Quality of Service ) guarantee are realized; compared with the FlexE technology, the FlexE Slim layer is not required to be added, and the overhead of a data packet header is reduced.
2. And the transmission efficiency is improved by adopting a service preemption mode. The router does not need to transmit data strictly according to the mapping relation between the data stream and the time slot, and can transmit data packets of other streams in advance in the current time slot when a transmission channel is idle through switching of the transmitting frequency, so that the overall transmission efficiency is improved. And if the arrival of the data packet corresponding to the current time slot is monitored, transferring the data packets of other streams into a buffer area, and after the data packets are transmitted, immediately transmitting the data packet corresponding to the current time slot. The specific flow of the service preemption mode is shown in fig. 14:
(1) Monitoring the arrived first data packet;
(2) If the first data packet is the data packet corresponding to the current time slot, judging whether the channel is occupied or not:
(1) if not, normally transmitting the first data packet;
(2) if the first data packet is occupied, transferring the second data packet which is being transmitted into a buffer area for queuing, and transmitting the first data packet;
(3) If the first data packet is not the data packet corresponding to the current time slot, judging whether the channel is occupied or not:
(1) if not, a first data packet is sent;
(2) and if the first data packet is occupied, transferring the first data packet into a buffer area for queuing.
In this embodiment, by increasing the mapping between the traffic flow and the color light emission frequency, different traffic flows are transmitted by using color lights with different emission frequencies, and different data flows are carried by different color light wavelengths to realize traffic isolation. Meanwhile, a mode of flexibly switching the transmitting frequency is provided, so that the resource waste of idle time slots is reduced, and the forwarding efficiency is improved. Compared with the slice technology such as FlexE, the network overhead for dividing the sub-channel ports can be reduced, and the idle time slots of links can be reduced.
It should be understood that, although the steps in the flowcharts related to the above embodiments are sequentially shown as indicated by arrows, these steps are not necessarily sequentially performed in the order indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in the flowcharts described in the above embodiments may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of the steps or stages is not necessarily performed sequentially, but may be performed alternately or alternately with at least some of the other steps or stages.
Based on the same inventive concept, the embodiment of the application also provides a data transmission device for realizing the above related data transmission method. The implementation of the solution provided by the device is similar to the implementation described in the above method, so the specific limitation in one or more embodiments of the data transmission device provided below may refer to the limitation of the data transmission method hereinabove, and will not be repeated herein.
In an exemplary embodiment, as shown in fig. 15, there is provided a data transmission apparatus including: a data receiving module 1502, a frequency switching module 1504, and a data transmitting module 1506, wherein:
the data receiving module 1502 is configured to determine an occupancy condition of a transmission channel corresponding to a color optical interface when the gateway device deployed with the color optical interface receives a first data packet sent by a first terminal.
The frequency switching module 1504 is configured to switch the transmitting frequency of the color optical interface to a first transmitting frequency corresponding to the first data packet according to the occupation situation of the transmitting channel.
The data transmission module 1506 is configured to transmit the first data packet to a second terminal corresponding to the first data packet according to the first transmission frequency.
In an exemplary embodiment, the frequency switching module 1504 is further configured to determine that the transmission channel is unoccupied in a case where there is no second data packet being transmitted in the transmission channel; and under the condition that the transmission channel is unoccupied, switching the transmission frequency of the color optical interface to a first transmission frequency corresponding to the first data packet.
In an exemplary embodiment, the frequency switching module 1504 is further configured to determine that the transmission channel is occupied if there is a second data packet being transmitted in the transmission channel; determining a relation between a first data stream to which a first data packet belongs and a current time slot in a transmission channel under the condition that the transmission channel is occupied; and switching the transmitting frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet according to the relation between the first data stream and the current time slot.
In an exemplary embodiment, the frequency switching module 1504 is further configured to send the second data packet to the buffer when the first data stream is a data stream corresponding to the current time slot; and under the condition that the second data packet is cached in the buffer area, switching the transmission frequency of the color optical interface from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet.
In an exemplary embodiment, the frequency switching module 1504 is further configured to fetch the second data packet from the buffer; the emission frequency of the color light interface is switched from the first emission frequency to the second emission frequency.
The data transmission module 1506 is further configured to transmit the second data packet to a second terminal corresponding to the second data packet according to the second transmission frequency.
In an exemplary embodiment, the frequency switching module 1504 is further configured to send the first data packet to the buffer when the first data stream is not the data stream corresponding to the current time slot; and after the transmission of the second data packet is finished, switching the transmitting frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet.
In an exemplary embodiment, the data transmission module 1506 is further configured to fetch the first data packet from the buffer; and transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
In an exemplary embodiment, the data transmission device further includes a frequency determining module, configured to determine a first data stream to which the first data packet belongs; inquiring a pre-constructed data stream transmitting frequency mapping table, and determining the transmitting frequency corresponding to the first data stream as a first transmitting frequency corresponding to the first data packet; the pre-constructed data stream transmitting frequency mapping table is used for recording the mapping relation between each data stream transmitted by the color light interface and the transmitting frequency corresponding to each data stream.
The respective modules in the above-described data transmission apparatus may be implemented in whole or in part by software, hardware, and combinations thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one exemplary embodiment, a computer device is provided, which may be a server, and the internal structure thereof may be as shown in fig. 16. The computer device includes a processor, a memory, an Input/Output interface (I/O) and a communication interface. The processor, the memory and the input/output interface are connected through a system bus, and the communication interface is connected to the system bus through the input/output interface. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The database of the computer device is used for storing the transmission frequencies corresponding to the data streams of different services. The input/output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a data transmission method.
It will be appreciated by those skilled in the art that the structure shown in fig. 16 is merely a block diagram of a portion of the structure associated with the present application and is not limiting of the computer device to which the present application is applied, and that a particular computer device may include more or fewer components than shown, or may combine certain components, or have a different arrangement of components.
In an exemplary embodiment, a computer device is also provided, comprising a memory and a processor, the memory having stored therein a computer program, the processor implementing the steps of the method embodiments described above when the computer program is executed.
In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored which, when executed by a processor, carries out the steps of the method embodiments described above.
In an embodiment, a computer program product is provided, comprising a computer program which, when executed by a processor, implements the steps of the method embodiments described above.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, database, or other medium used in the various embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high density embedded nonvolatile Memory, resistive random access Memory (ReRAM), magnetic random access Memory (Magnetoresistive Random Access Memory, MRAM), ferroelectric Memory (Ferroelectric Random Access Memory, FRAM), phase change Memory (Phase Change Memory, PCM), graphene Memory, and the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory, and the like. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), and the like. The databases referred to in the various embodiments provided herein may include at least one of relational databases and non-relational databases. The non-relational database may include, but is not limited to, a blockchain-based distributed database, and the like. The processors referred to in the embodiments provided herein may be general purpose processors, central processing units, graphics processors, digital signal processors, programmable logic units, quantum computing-based data processing logic units, etc., without being limited thereto.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples only represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the present application. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application shall be subject to the appended claims.

Claims (12)

1. A data transmission method, applied to a gateway device deployed with a color optical interface, the method comprising:
under the condition of receiving a first data packet sent by a first terminal, determining the occupation condition of a sending channel corresponding to the color light interface;
switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel;
And transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
2. The method of claim 1, wherein switching the transmission frequency of the color optical interface to the first transmission frequency corresponding to the first data packet according to the occupancy of the transmission channel comprises:
determining that the transmission channel is unoccupied in the case that there is no second data packet being transmitted in the transmission channel;
and under the condition that the transmission channel is unoccupied, switching the transmission frequency of the color light interface to a first transmission frequency corresponding to the first data packet.
3. The method of claim 1, wherein the switching the transmission frequency of the color optical interface to the first transmission frequency corresponding to the first data packet according to the occupation situation of the transmission channel further comprises:
determining that the transmission channel is occupied under the condition that a second data packet which is being transmitted exists in the transmission channel;
determining a relation between a first data stream to which the first data packet belongs and a current time slot in the transmission channel under the condition that the transmission channel is occupied;
And switching the transmitting frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet according to the relation between the first data stream and the current time slot.
4. A method according to claim 3, wherein said switching the transmission frequency of the color optical interface from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet according to the relation between the first data stream and the current time slot comprises:
transmitting the second data packet to a buffer area under the condition that the first data stream is the data stream corresponding to the current time slot;
and under the condition that the second data packet is cached in the buffer area, switching the transmitting frequency of the color light interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet.
5. The method of claim 4, further comprising, after transmitting the first data packet to a second terminal corresponding to the first data packet at the first transmission frequency:
Fetching the second data packet from the buffer;
switching the emission frequency of the color light interface from the first emission frequency to the second emission frequency;
and transmitting the second data packet to a second terminal corresponding to the second data packet according to the second transmitting frequency.
6. The method of claim 3, wherein switching the transmission frequency of the color optical interface from the second transmission frequency corresponding to the second data packet to the first transmission frequency corresponding to the first data packet according to the relationship between the first data stream and the current time slot, further comprises:
transmitting the first data packet to a buffer area under the condition that the first data stream is not the data stream corresponding to the current time slot;
and after the transmission of the second data packet is finished, switching the transmitting frequency of the color optical interface from the second transmitting frequency corresponding to the second data packet to the first transmitting frequency corresponding to the first data packet.
7. The method of claim 6, wherein transmitting the first data packet to the second terminal corresponding to the first data packet according to the first transmission frequency comprises:
Fetching the first data packet from the buffer;
and transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
8. The method according to any one of claims 1 to 7, further comprising, before switching the transmission frequency of the color optical interface to the first transmission frequency corresponding to the first data packet:
determining a first data stream to which the first data packet belongs;
inquiring a pre-constructed data stream transmitting frequency mapping table, and determining the transmitting frequency corresponding to the first data stream as a first transmitting frequency corresponding to the first data packet; the pre-constructed data stream transmitting frequency mapping table is used for recording the mapping relation between each data stream transmitted by the color light interface and the transmitting frequency corresponding to each data stream.
9. A data transmission apparatus, the apparatus comprising:
the data receiving module is used for determining the occupation condition of a transmission channel corresponding to the color light interface under the condition that gateway equipment deployed with the color light interface receives a first data packet transmitted by a first terminal;
the frequency switching module is used for switching the transmitting frequency of the color light interface to a first transmitting frequency corresponding to the first data packet according to the occupation condition of the transmitting channel;
And the data transmission module is used for transmitting the first data packet to a second terminal corresponding to the first data packet according to the first transmitting frequency.
10. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any one of claims 1 to 8 when the computer program is executed.
11. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 8.
12. A computer program product comprising a computer program, characterized in that the computer program, when executed by a processor, implements the steps of the method of any one of claims 1 to 8.
CN202311616104.0A 2023-11-29 2023-11-29 Data transmission method, device, computer equipment and storage medium Pending CN117768417A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311616104.0A CN117768417A (en) 2023-11-29 2023-11-29 Data transmission method, device, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311616104.0A CN117768417A (en) 2023-11-29 2023-11-29 Data transmission method, device, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
CN117768417A true CN117768417A (en) 2024-03-26

Family

ID=90309642

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311616104.0A Pending CN117768417A (en) 2023-11-29 2023-11-29 Data transmission method, device, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN117768417A (en)

Similar Documents

Publication Publication Date Title
WO2019128467A1 (en) Flexible ethernet (flexe)-based service flow transmission method and apparatus
KR20200037405A (en) Packet control method and network device
US11785113B2 (en) Client service transmission method and apparatus
KR20190112804A (en) Packet processing method and apparatus
CN108521343B (en) OAM message processing method and device
WO2020155185A1 (en) Message scheduling method, scheduler, network device and network system
WO2017148446A1 (en) Network resource scheduling method, device and system, and network node
CN101848168B (en) Target MAC (Media Access Control) address based flow control method, system and equipment
US10911364B2 (en) Packet processing method and router
CN108811140A (en) A kind of data business transmission method and system
CN106411872A (en) Method and device for compressing messages based on data message classification
CN107786464B (en) Method and device for realizing communication between nodes
WO2016150020A1 (en) Scheduling flow identifier-based packet scheduling method and device
WO2016095142A1 (en) Data forwarding method, device and system in software-defined networking (sdn)
CN117793583A (en) Message forwarding method and device, electronic equipment and computer readable storage medium
CN112615789A (en) Out-of-band flow control method and device
CN117768417A (en) Data transmission method, device, computer equipment and storage medium
WO2019232694A1 (en) Queue control method, device and storage medium
US11516145B2 (en) Packet control method, flow table update method, and node device
CN110943919A (en) Link aggregation transmission method, device, terminal and storage medium
CN112804166B (en) Message receiving and sending method, device and storage medium
CN110493822B (en) Point-to-multipoint communication device and system
JP2024519555A (en) Packet transmission method and network device
CN111586880A (en) Dynamic hybrid access method and system suitable for TDMA
CN205265697U (en) Grouping optical transmission terminal chip based on tag switching

Legal Events

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