WO2024119837A1 - Service processing method and apparatus, and electronic device - Google Patents

Service processing method and apparatus, and electronic device Download PDF

Info

Publication number
WO2024119837A1
WO2024119837A1 PCT/CN2023/108425 CN2023108425W WO2024119837A1 WO 2024119837 A1 WO2024119837 A1 WO 2024119837A1 CN 2023108425 W CN2023108425 W CN 2023108425W WO 2024119837 A1 WO2024119837 A1 WO 2024119837A1
Authority
WO
WIPO (PCT)
Prior art keywords
service container
frame header
osu
detected
service
Prior art date
Application number
PCT/CN2023/108425
Other languages
French (fr)
Chinese (zh)
Inventor
张源斌
苑岩
Original Assignee
中兴通讯股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2024119837A1 publication Critical patent/WO2024119837A1/en

Links

Definitions

  • the present application relates to the field of communication technology, and in particular to a service processing method, device and electronic device.
  • Optical Service Unit is a service container used to carry small-grained services in the optical transmission network. Low-speed customer services can be efficiently carried through OSU.
  • the OSU service container is a fixed-length frame structure, a sudden change in the frame length will cause the service container to fail to be framed. This requires that when the service container is recovered from the OPU, the frame length of the service container cannot change due to incorrect identification of the service container data and padding, otherwise it will cause the service container to fail to be framed, resulting in data loss. How to ensure that the service container recovered from the OPU maintains a fixed length is a technical problem that needs to be solved urgently in related technologies.
  • the purpose of the embodiments of the present application is to provide a service processing method, device and electronic device, which can solve the problem that the service container recovered from the OPU cannot maintain a fixed length, resulting in failure of service container framing, and further causing data loss.
  • an embodiment of the present application provides a service processing method, including: performing service container frame header detection processing on a service container; performing a first operation on the service container according to an expected position and an actual position of the detected service container frame header, wherein the expected position is a position that is one service container length away from a previous service container frame header, and the first operation includes adding or deleting a fixed number of bits.
  • an embodiment of the present application provides a service processing device, including: a frame header detection module, used to perform service container frame header detection processing on a service container; an operation module, used to perform a first operation on the service container according to an expected position and an actual position of the detected service container frame header, wherein the expected position is a position that is one service container length away from the previous service container frame header, and the first operation includes adding or deleting a fixed number of bits.
  • an embodiment of the present application provides an electronic device comprising: a memory, a processor, and computer executable instructions stored in the memory and executable on the processor, wherein the computer executable instructions, when executed by the processor, implement the steps of executing the method described in the first aspect.
  • an embodiment of the present application provides a computer-readable storage medium, which is used to store computer-executable instructions.
  • the computer-executable instructions are executed by a processor, the steps of the method described in the first aspect are implemented.
  • FIG1 is a schematic diagram showing a flow chart of a service processing method provided by an embodiment of the present application.
  • FIG2 is a schematic diagram of an OSU frame structure provided in an embodiment of the present application.
  • FIG3 is a schematic diagram of a time slot structure provided in an embodiment of the present application.
  • FIG4 is a schematic diagram of an OSU data flow at the receiving side according to an embodiment of the present application.
  • FIG5 is a schematic diagram of an output OSU data flow according to an embodiment of the present application.
  • FIG6 is a schematic diagram of an OSU data flow at the receiving side of the second embodiment of the present application.
  • FIG7 is a schematic diagram of an output OSU data flow according to Embodiment 2 of the present application.
  • FIG8 is a schematic diagram of an OSU data flow on the receiving side of Embodiment 3 of the present application.
  • FIG9 is a schematic diagram of the OSU data flow after the first processing in Example 3 of the present application.
  • FIG10 is a schematic diagram of an output OSU data flow of Embodiment 3.
  • FIG11 is a schematic diagram showing the structure of a service processing device provided in an embodiment of the present application.
  • FIG. 12 is a schematic diagram of the hardware structure of an electronic device that executes the service processing method provided in an embodiment of the present application.
  • FIG1 shows a flow chart of a business processing method provided by an embodiment of the present application, which can be executed by an electronic device, such as a terminal device or a server device.
  • the method can be executed by software or hardware installed in a terminal device or a server device.
  • the server includes but is not limited to: a single server, a server cluster, a cloud server or a cloud server cluster, etc. As shown in the figure, the method may include the following steps.
  • Step S102 performing service container frame header detection processing on the service container.
  • the service container frame header detection processing for the service container includes the following steps: 1) determining an offset range; wherein the offset range includes: the M-Nth L-bit block to the M+N+1th L-bit block starting from the counting starting point; the counting starting point is the L-bit block where the previous service container frame header is located; N is a predefined value, and N is used to determine the offset range; 2) detecting the service container frame header within the offset range.
  • the length of the service container may be M L-bit blocks, where M is a positive integer.
  • the service container i.e., the OSU frame
  • the overhead area includes a frame header overhead, i.e., the overhead of the frame header indication signal in FIG2
  • the overhead of the payload area may be 12 16-byte blocks.
  • Step S104 The service container is detected based on the expected position and the actual position of the service container frame header.
  • the device performs a first operation, the expected position is a position that is separated from a previous service container frame header by a service container length, and the first operation includes adding or deleting a fixed number of bits.
  • the actual position is the position of the M1th L-bit block starting from the counting starting point
  • the first operation on the service container based on the expected position and the actual position of the detected service container frame header includes: adding M+1-M1 L-bit blocks to the service container, and taking the actual position as the counting starting point, where M1 ⁇ M, M-M1 ⁇ N.
  • the actual position is the position of the M2th L-bit block starting from the counting starting point
  • the first operation on the service container based on the expected position and the actual position of the detected service container frame header includes: deleting M2-M-1 L-bit blocks of the service container, and taking the actual position as the counting starting point, where M2>M+1, M2 ⁇ M+N.
  • N may be determined by at least one of the following: burst error length, service container rate.
  • burst error length When the service container rate is low (such as lower than a certain threshold), the value of N is set to a smaller value to ensure latency; when the service container rate is high (such as higher than a certain threshold), the value of N is set to a relatively larger value to ensure burst error resistance.
  • This embodiment is generally applicable to the scenario where the service container frame header is not detected at the expected position.
  • the expected position is used as the next counting starting point. It can be understood that if the service container frame header is detected at the expected position, it indicates that the length of the service container is fixed and there is no need to add or delete bits.
  • the method provided by each embodiment of the present application further includes the following steps: if the service container frame header is not detected within the offset range, the expected position is used as the next counting starting point, and the service container frame header is inserted into the L-bit block at the expected position.
  • the method before performing the first operation on the service container according to the expected position and the actual position of the detected service container frame header, the method further includes: if the service container frame header is detected and the next service container frame header is detected after an interval of a service container length, entering a service container locked state.
  • the method further includes: if the service container frame header is not detected at the expected position for K consecutive times, entering a service container unlocked state, where K is a positive integer greater than 1.
  • the service processing method provided in the embodiment of the present application performs service container frame header detection processing on the service container; performs a first operation on the service container according to the expected position and the actual position of the detected service container frame header, wherein the expected position is a position separated from the previous service container frame header by a service container length, and the first operation includes adding or deleting a fixed number of bits.
  • adding or deleting a fixed number of bits is helpful to keep the service container at a fixed length, avoid service container framing failure, and thus avoid data loss.
  • the number and position of the timeslots carrying the OSU are obtained. From the corresponding timeslots, the timeslots carrying the fill are first deleted according to the indication overhead, and then the OSU frames are demapped according to the following rules:
  • OSU frame header indication signal If the OSU frame header indication signal is detected and the next OSU frame header indication signal is detected after the M*L fixed length, enter the OSU frame locking state.
  • the L-bit block containing the OSU frame header indication signal is used as the counting starting point.
  • the counting starting point is used to calculate the expected position of the frame header of this OSU frame.
  • the position separated by M L-bit blocks from the counting starting point is the expected position.
  • the corresponding position of the subsequent L-bit blocks is detected to see whether it contains the OSU frame header indication signal:
  • the M1th L-bit block is used as a new counting starting point, and (M+1-M1)*L fixed format sequences are added to the previous OSU frame, where M1 ⁇ M, M-M1 ⁇ N, and N is a preset value depending on parameters such as the burst error length and the OSU rate.
  • N is a preset value, which depends on parameters such as the burst error length and the OSU rate.
  • the OSU rate is low, the value of N is set to a smaller value to ensure the delay.
  • the OSU rate is high, the value of N is set to a relatively large value to ensure the ability to resist burst errors.
  • the M+1th L-bit block is used as a new counting starting point, and the frame header indication signal of the OSU frame is inserted at the corresponding position of the L-bit block.
  • the OSU frame header indication signal is not detected at the position corresponding to the L-bit block at the expected position for a fixed number of consecutive K times, the OSU frame is entered into an OSU frame unlocked state.
  • the service processing method provided by the embodiment of the application pre-sets an offset and performs positioning processing on the OSU frame header within the offset range based on the expected position.
  • the position of the OSU frame header indication signal actually positioned is used as a new counting starting point, and a first operation is performed on the OSU frame based on a comparison between the actual position of the positioned OSU frame header and the expected position.
  • the first operation includes adding a fixed number of fixed sequences and deleting a fixed number of L-bit blocks of the OSU frame. This method ensures that the OSU frame is of fixed length and that the OSU frame header appears every fixed number of byte blocks, and that the OSU frame length will not change due to the influence of bit errors, thereby causing a large amount of data to be lost.
  • the source node and the sink node transmit the OSU service through OPU0.
  • the embodiment includes the following steps:
  • Step 1 At the source node, the OPU0 payload area is divided into 119 time slots, each time slot is 130 bits long, of which the first 2 bits are indication overhead and the following 128 bits are payload area, as shown in Figure 3.
  • the indication overhead 01
  • the time slot payload area carries OSU data
  • the indication overhead 10
  • the time slot payload area carries padding
  • the length of the OSU frame is 192 bytes, that is, 12 16-byte blocks
  • the OSU frame header indication overhead is located in the first 4 bytes of the first 16-byte block, as shown in Figure 2.
  • Step 2 Map OSU to the time slot corresponding to OPU0. Since the OSU rate is lower than the time slot rate that carries it, padding needs to be inserted for rate adaptation. If the time slot payload area carries OSU data, the indication overhead is set to 01. If the time slot payload area carries padding, the indication overhead is set to 10, as shown in Figure 3.
  • Step 3 Assume that due to bit errors during the transmission process, the indication overhead of a time slot changes from 01 to 10, that is, the OSU data is mistakenly turned into padding, resulting in the loss of a 16-byte block in a certain OSU frame.
  • Step 4 At the receiving side, determine the time slot carrying the OSU, and output the OSU data stream from the time slot payload area indicating the overhead as 01, as shown in FIG4 .
  • Step 5 The receiving side searches for the OSU frame header indication signal from the OSU data stream, and enters the OSU frame lock state when two consecutive OSU frame header indication signals are found and are separated by 12 16-byte blocks.
  • the source node and the sink node transmit the OSU service through OPU0.
  • the embodiment includes the following steps:
  • Step 1 At the source node, the OPU0 payload area is divided into 119 time slots, each time slot is 130 bits long, of which the first 2 bits are indication overhead and the following 128 bits are payload area.
  • the indication overhead 01
  • the indication overhead 10
  • the length of the OSU frame is 192 bytes, that is, 12 16-byte blocks.
  • the OSU frame header indication overhead is located in the first 4 bytes of the first 16-byte block, as shown in Figure 2.
  • Step 2 Map OSU to the time slot corresponding to OPU0. Since the OSU rate is lower than the time slot rate that carries it, padding needs to be inserted for rate adaptation. If the time slot payload area carries OSU data, the indication overhead is set to 01. If the time slot payload area carries padding, the indication overhead is set to 10, as shown in Figure 3.
  • Step 3 Assume that due to bit errors during the transmission process, the indication overhead of two time slots changes from 10 to 01, that is, the padding is mistakenly replaced with OSU data, resulting in an OSU frame adding two 16-byte blocks.
  • Step 4 At the receiving side, determine the time slot carrying the OSU, and output the OSU data stream from the time slot payload area indicating the overhead as 01, as shown in FIG6 .
  • Step 5 The receiving side searches for the OSU frame header indication signal from the OSU data stream and finds two consecutive When an OSU frame header indication signal is received and there are 12 16-byte blocks between them, the OSU frame lock state is entered.
  • the source node and the sink node transmit the OSU service through OPU0.
  • the embodiment includes the following steps:
  • Step 1 At the source node, the OPU0 payload area is divided into 119 time slots, each time slot is 130 bits long, of which the first 2 bits are indication overhead and the following 128 bits are payload area.
  • the indication overhead 01
  • the indication overhead 10
  • the length of the OSU frame is 192 bytes, that is, 12 16-byte blocks.
  • the OSU frame header indication overhead is located in the first 4 bytes of the first 16-byte block, as shown in Figure 2.
  • Step 2 Map OSU to the time slot corresponding to OPU0. Since the OSU rate is lower than the time slot rate that carries it, padding needs to be inserted for rate adaptation. If the time slot payload area carries OSU data, the indication overhead is set to 01. If the time slot payload area carries padding, the indication overhead is set to 10, as shown in Figure 3.
  • Step 3 Assume that due to bit errors during the transmission process, the indication overhead of a time slot changes from 10 to 01, that is, it is filled with OSU data; at the same time, the frame header indication signal of an OSU frame is polluted, resulting in an additional 16-byte block in an OSU frame, and the next OSU frame header is polluted and cannot be correctly identified.
  • Step 4 At the receiving side, determine the time slot carrying the OSU, and output the OSU data stream from the time slot payload area indicating the overhead as 01, as shown in FIG8 .
  • Step 5 The receiving side searches for the OSU frame header indication signal from the OSU data stream, and enters the OSU frame lock state when two consecutive OSU frame header indication signals are found and are separated by 12 16-byte blocks.
  • the 2 consecutive 16-byte blocks following the 13th 16-byte block are detected. Since one byte block is added and the next OSU frame header indication signal is contaminated, it is impossible to detect that the first 4 bytes of the subsequent 2 consecutive byte blocks are the OSU frame header indication signal.
  • Step 7 On the basis of setting a new starting point in step 6, starting from the 10th 16-byte block, detect whether its first 4 bytes are the OSU frame header indication signal.
  • Detect the 2 consecutive 16-byte blocks following the 13th 16-byte block. Since the newly added 16-byte block is not deleted in step 6, the first 4 bytes of the 14th (i.e., M2 14) byte block are detected as the OSU frame header indication signal. Since the length of the previous OSU frame is 13, delete the last 16-byte block to keep the length of the OSU frame at 12 16-byte blocks, as shown in Figure 10.
  • FIG. 11 shows a schematic diagram of the structure of a service processing device provided in an embodiment of the present application.
  • the device 1100 may include: a frame header detection module 1102 and an operation module 1104 .
  • the frame header detection module 1102 is used to perform a service container frame header detection process on the service container.
  • the operation module 1104 is used to perform a first operation on the service container according to the expected position and the actual position of the detected service container frame header, the expected position is a position separated from the previous service container frame header by a service container length, and the first operation includes adding or deleting a fixed number of bits.
  • a service container is subjected to a service container frame header detection process; a first operation is performed on the service container according to an expected position and an actual position where the service container frame header is detected, the expected position being a position separated from a previous service container frame header by a service container length, and the first operation includes adding or deleting a fixed number of bits.
  • adding or deleting a fixed number of bits is beneficial to keeping the service container at a fixed length, avoiding service container framing failure, and thus avoiding data loss.
  • the frame header detection module 1102 is used to: determine an offset range; wherein the offset range includes: from the MNth L-bit block starting from the counting start point to The M+N+1th L-bit block; the counting starting point is the L-bit block where the previous service container frame header is located; N is a predefined value, and N is used to determine the offset range; the service container frame header is detected within the offset range.
  • the actual position is the position of the M1th L-bit block starting from the counting starting point
  • the operation module 1104 is used to add M+1-M1 L-bit blocks to the business container, taking the actual position as the counting starting point, where M1 ⁇ M, M-M1 ⁇ N.
  • the actual position is the position of the M2th L-bit block starting from the counting starting point
  • the operation module 1104 is used to delete the M2-M-1 L-bit blocks of the business container and take the actual position as the counting starting point, where M2>M+1, M2 ⁇ M+N.
  • the device 1100 provided in the embodiment of the present application can execute the various methods described in the foregoing method embodiments, and realize the functions and beneficial effects of the various methods described in the foregoing method embodiments, which will not be repeated here.
  • FIG12 shows a schematic diagram of the hardware structure of an electronic device that implements the embodiment of the present application.
  • the electronic device includes a processor, and optionally, an internal bus, a network interface, and a memory.
  • the memory may include a memory, such as a high-speed random access memory (RAM), and may also include a non-volatile memory (non-volatile memory), such as at least one disk storage, etc.
  • RAM high-speed random access memory
  • non-volatile memory such as at least one disk storage, etc.
  • the electronic device may also include hardware required for other services.
  • the processor, the network interface and the memory may be interconnected through an internal bus, which may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc.
  • ISA Industry Standard Architecture
  • PCI Peripheral Component Interconnect
  • EISA Extended Industry Standard Architecture
  • the bus may be divided into an address bus, a data bus, a control bus, etc.
  • ISA Industry Standard Architecture
  • PCI Peripheral Component Interconnect
  • EISA Extended Industry Standard Architecture
  • the memory is used to store the program.
  • the program may include a program code, and the program code includes a computer operation instruction.
  • the memory may include a memory and a non-volatile memory, and provides instructions and data to the processor.
  • the processor reads the corresponding computer program from the non-volatile memory into the memory and then runs it, forming a device for locating the target user at the logical level.
  • the processor executes the program stored in the memory and is specifically used to execute: the method disclosed in the embodiment shown in Figures 1-10 and implement the method described in the above method embodiment The functions and beneficial effects of the above methods will not be repeated here.
  • the method disclosed in the above-mentioned embodiment as shown in Figures 1-10 of the present application can be applied to a processor or implemented by a processor.
  • the processor may be an integrated circuit chip with signal processing capabilities.
  • each step of the above-mentioned method can be completed by an integrated logic circuit of hardware in the processor or an instruction in the form of software.
  • the above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.
  • the methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed.
  • the general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc.
  • the steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware decoding processor for execution, or a combination of hardware and software modules in the decoding processor for execution.
  • the software module can be located in a mature storage medium in the field such as random access memory, flash memory, read-only memory, programmable read-only memory or electrically erasable programmable memory, register, etc.
  • the storage medium is located in the memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware.
  • the electronic device can also execute the methods described in the foregoing method embodiments, and realize the functions and beneficial effects of the methods described in the foregoing method embodiments, which will not be described in detail here.
  • the electronic device of the present application does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc., that is to say, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.
  • An embodiment of the present application also proposes a computer-readable storage medium, which stores one or more programs.
  • the one or more programs are executed by an electronic device including multiple application programs, the electronic device executes the methods disclosed in the embodiments shown in Figures 1-10 and realizes the functions and beneficial effects of the various methods described in the previous method embodiments, which are not repeated here.
  • the computer readable storage medium includes read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM), a disk or an optical disk, etc.
  • ROM read-only memory
  • RAM random access memory
  • disk or an optical disk etc.
  • an embodiment of the present application also provides a computer program product, the computer program product comprising a computer program stored on a non-transitory computer-readable storage medium.
  • the program includes program instructions.
  • a typical implementation device is a computer.
  • the computer may be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
  • Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase-change RAM (PRAM), static RAM (SRAM), dynamic RAM (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable ROM (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined in this article, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.
  • PRAM phase-change RAM
  • SRAM static RAM
  • DRAM dynamic RAM
  • RAM random access memory
  • ROM read-only

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Communication Control (AREA)
  • Signal Processing (AREA)

Abstract

Embodiments of the present application provide a service processing method and apparatus, and an electronic device. The method comprises: performing service container frame header detection on a service container; and performing a first operation on the service container according to an expected position and a detected actual position of a service container frame header, the expected position being a position spaced apart from the previous service container frame header by one service container length, and the first operation comprising increasing or deleting a fixed number of bits.

Description

业务处理方法、装置和电子设备Business processing method, device and electronic equipment
交叉引用cross reference
本申请要求在2022年12月09日提交中国专利局、申请号为202211582514.3、名称为“业务处理方法、装置和电子设备”的中国专利申请的优先权,该申请的全部内容通过引用结合在本申请中。This application claims priority to a Chinese patent application filed with the Chinese Patent Office on December 9, 2022, with application number 202211582514.3 and title “Business Processing Method, Device and Electronic Device”, the entire contents of which are incorporated by reference into this application.
技术领域Technical Field
本申请涉及通信技术领域,尤其涉及一种业务处理方法、装置和电子设备。The present application relates to the field of communication technology, and in particular to a service processing method, device and electronic device.
背景技术Background technique
光业务单元(Optical Service Unit,OSU)是光传送网中用来承载小颗粒业务的业务容器,低速客户业务通过OSU可以实现高效承载。Optical Service Unit (OSU) is a service container used to carry small-grained services in the optical transmission network. Low-speed customer services can be efficiently carried through OSU.
在从OSU到光净荷单元(Optical Payload Unit,OPU)的映射复用过程中,由于OSU和服务层中用来承载OSU的时隙之间具有速率上的偏差,在映射过程中需要***填充进行速率适配,在解映射的过程中需要去掉填充恢复出OSU。In the mapping and multiplexing process from OSU to Optical Payload Unit (OPU), due to the rate deviation between OSU and the time slot used to carry OSU in the service layer, padding needs to be inserted for rate adaptation during the mapping process, and the padding needs to be removed to restore OSU during the demapping process.
由于OSU业务容器是定长帧结构,帧长的突然变化会导致业务容器定帧失败,这就要求从OPU恢复出业务容器的时候,不能因为业务容器数据和填充的错误识别导致业务容器的帧长发生变化,否则会导致业务容器定帧失败,进而导致数据丢失。如何保证从OPU恢复出的业务容器保持固定长度,是相关技术中亟需解决的技术问题。Since the OSU service container is a fixed-length frame structure, a sudden change in the frame length will cause the service container to fail to be framed. This requires that when the service container is recovered from the OPU, the frame length of the service container cannot change due to incorrect identification of the service container data and padding, otherwise it will cause the service container to fail to be framed, resulting in data loss. How to ensure that the service container recovered from the OPU maintains a fixed length is a technical problem that needs to be solved urgently in related technologies.
发明内容Summary of the invention
本申请实施例的目的是提供一种业务处理方法、装置和电子设备,能够解决从OPU恢复出的业务容器无法保持固定长度,导致业务容器定帧失败,进而导致数据丢失的问题。 The purpose of the embodiments of the present application is to provide a service processing method, device and electronic device, which can solve the problem that the service container recovered from the OPU cannot maintain a fixed length, resulting in failure of service container framing, and further causing data loss.
为解决上述技术问题,本申请实施例是通过以下各方面实现的。To solve the above technical problems, the embodiments of the present application are implemented through the following aspects.
第一方面,本申请实施例提供了一种业务处理方法,包括:对业务容器进行业务容器帧头检测处理;根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作,所述期望位置为与上一个业务容器帧头相隔一个业务容器长度的位置,所述第一操作包括增加或删除固定数量的比特。In a first aspect, an embodiment of the present application provides a service processing method, including: performing service container frame header detection processing on a service container; performing a first operation on the service container according to an expected position and an actual position of the detected service container frame header, wherein the expected position is a position that is one service container length away from a previous service container frame header, and the first operation includes adding or deleting a fixed number of bits.
第二方面,本申请实施例提供了一种业务处理装置,包括:帧头检测模块,用于对业务容器进行业务容器帧头检测处理;操作模块,用于根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作,所述期望位置为与上一个业务容器帧头相隔一个业务容器长度的位置,所述第一操作包括增加或删除固定数量的比特。In a second aspect, an embodiment of the present application provides a service processing device, including: a frame header detection module, used to perform service container frame header detection processing on a service container; an operation module, used to perform a first operation on the service container according to an expected position and an actual position of the detected service container frame header, wherein the expected position is a position that is one service container length away from the previous service container frame header, and the first operation includes adding or deleting a fixed number of bits.
第三方面,本申请实施例提供了一种电子设备,包括:存储器、处理器和存储在所述存储器上并可在所述处理器上运行的计算机可执行指令,所述计算机可执行指令被所述处理器执行时实现执行第一方面所述的方法的步骤。In a third aspect, an embodiment of the present application provides an electronic device comprising: a memory, a processor, and computer executable instructions stored in the memory and executable on the processor, wherein the computer executable instructions, when executed by the processor, implement the steps of executing the method described in the first aspect.
第四方面,本申请实施例提供了一种计算机可读存储介质,所述计算机可读存储介质用于存储计算机可执行指令,所述计算机可执行指令被处理器执行时实现第一方面所述的方法的步骤。In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, which is used to store computer-executable instructions. When the computer-executable instructions are executed by a processor, the steps of the method described in the first aspect are implemented.
附图说明BRIEF DESCRIPTION OF THE DRAWINGS
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请中记载的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
图1示出本申请实施例提供的业务处理方法的一种流程示意图;FIG1 is a schematic diagram showing a flow chart of a service processing method provided by an embodiment of the present application;
图2是本申请实施例提供的OSU帧结构示意图;FIG2 is a schematic diagram of an OSU frame structure provided in an embodiment of the present application;
图3是本申请实施例提供的时隙结构示意图;FIG3 is a schematic diagram of a time slot structure provided in an embodiment of the present application;
图4是本申请实施例一接收侧OSU数据流示意图;FIG4 is a schematic diagram of an OSU data flow at the receiving side according to an embodiment of the present application;
图5是本申请实施例一输出OSU数据流示意图;FIG5 is a schematic diagram of an output OSU data flow according to an embodiment of the present application;
图6是本申请实施例二接收侧OSU数据流示意图; FIG6 is a schematic diagram of an OSU data flow at the receiving side of the second embodiment of the present application;
图7是本申请实施例二输出OSU数据流示意图;FIG7 is a schematic diagram of an output OSU data flow according to Embodiment 2 of the present application;
图8是本申请实施例三接收侧OSU数据流示意图;FIG8 is a schematic diagram of an OSU data flow on the receiving side of Embodiment 3 of the present application;
图9是本申请实施例三第一次处理后OSU数据流示意图;FIG9 is a schematic diagram of the OSU data flow after the first processing in Example 3 of the present application;
图10是实施例三输出OSU数据流示意图;FIG10 is a schematic diagram of an output OSU data flow of Embodiment 3;
图11示出本申请实施例提供的业务处理装置的结构示意图;FIG11 is a schematic diagram showing the structure of a service processing device provided in an embodiment of the present application;
图12为执行本申请实施例提供的业务处理方法的电子设备的硬件结构示意图。FIG. 12 is a schematic diagram of the hardware structure of an electronic device that executes the service processing method provided in an embodiment of the present application.
具体实施方式Detailed ways
为了使本技术领域的人员更好地理解本申请中的技术方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都应当属于本申请保护的范围。In order to enable those skilled in the art to better understand the technical solutions in the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this application.
图1示出本申请实施例提供的业务处理方法的一种流程示意图,该方法可以由电子设备执行,例如终端设备或服务端设备。换言之,所述方法可以由安装在终端设备或服务端设备的软件或硬件来执行。所述服务端包括但不限于:单台服务器、服务器集群、云端服务器或云端服务器集群等。如图所示,该方法可以包括以下步骤。FIG1 shows a flow chart of a business processing method provided by an embodiment of the present application, which can be executed by an electronic device, such as a terminal device or a server device. In other words, the method can be executed by software or hardware installed in a terminal device or a server device. The server includes but is not limited to: a single server, a server cluster, a cloud server or a cloud server cluster, etc. As shown in the figure, the method may include the following steps.
步骤S102:对业务容器进行业务容器帧头检测处理。Step S102: performing service container frame header detection processing on the service container.
可选地,所述对业务容器进行业务容器帧头检测处理包括如下步骤:1)确定偏移量范围;其中,所述偏移量范围包括:从计数起点开始的第M-N个L比特块至第M+N+1个L比特块;所述计数起点为上一个业务容器帧头所在的L比特块;N为预定义的值,N用于确定所述偏移量范围;2)在所述偏移量范围内检测业务容器帧头。Optionally, the service container frame header detection processing for the service container includes the following steps: 1) determining an offset range; wherein the offset range includes: the M-Nth L-bit block to the M+N+1th L-bit block starting from the counting starting point; the counting starting point is the L-bit block where the previous service container frame header is located; N is a predefined value, and N is used to determine the offset range; 2) detecting the service container frame header within the offset range.
该实施例中,所述业务容器的长度可以为M个L比特块,M为正整数。如图2所示,所述业务容器(即OSU帧)包括开销区域和净荷区域。所述开销区域包括帧头开销,即图2中帧头指示信号的开销,所述净荷区域的开销可以是12个16字节块。In this embodiment, the length of the service container may be M L-bit blocks, where M is a positive integer. As shown in FIG2 , the service container (i.e., the OSU frame) includes an overhead area and a payload area. The overhead area includes a frame header overhead, i.e., the overhead of the frame header indication signal in FIG2 , and the overhead of the payload area may be 12 16-byte blocks.
步骤S104:根据期望位置以及检测到业务容器帧头的实际位置对业务容 器进行第一操作,所述期望位置为与上一个业务容器帧头相隔一个业务容器长度的位置,所述第一操作包括增加或删除固定数量的比特。Step S104: The service container is detected based on the expected position and the actual position of the service container frame header. The device performs a first operation, the expected position is a position that is separated from a previous service container frame header by a service container length, and the first operation includes adding or deleting a fixed number of bits.
在一个例子中,所述实际位置为从所述计数起点开始的第M1个L比特块的位置,所述根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作包括:添加M+1-M1个L比特块到所述业务容器,将所述实际位置作为计数起点,其中,M1≤M,M-M1≤N。In an example, the actual position is the position of the M1th L-bit block starting from the counting starting point, and the first operation on the service container based on the expected position and the actual position of the detected service container frame header includes: adding M+1-M1 L-bit blocks to the service container, and taking the actual position as the counting starting point, where M1≤M, M-M1≤N.
在一个例子中,所述实际位置为从所述计数起点开始的第M2个L比特块的位置,所述根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作包括:删除所述业务容器的M2-M-1个L比特块,将所述实际位置作为计数起点,其中,M2>M+1,M2≤M+N。In an example, the actual position is the position of the M2th L-bit block starting from the counting starting point, and the first operation on the service container based on the expected position and the actual position of the detected service container frame header includes: deleting M2-M-1 L-bit blocks of the service container, and taking the actual position as the counting starting point, where M2>M+1, M2≤M+N.
本申请各个实施例中的N可以由如下至少之一确定:突发误码长度,业务容器速率。业务容器速率低(如低于一定阈值)的时候,N的取值设置较小的值,从而保证时延;业务容器速率高(如高于一定阈值)的时候,N的取值设置相对较大的值,从而保证抗突发误码能力。In each embodiment of the present application, N may be determined by at least one of the following: burst error length, service container rate. When the service container rate is low (such as lower than a certain threshold), the value of N is set to a smaller value to ensure latency; when the service container rate is high (such as higher than a certain threshold), the value of N is set to a relatively larger value to ensure burst error resistance.
该实施例通常适用于在所述期望位置没有检测到业务容器帧头的场景中,在其他的实施例中:如果在所述期望位置检测到业务容器帧头,则将所述期望位置作为下一个计数起点。可以理解,如果在所述期望位置检测到业务容器帧头,则表明业务容器的长度为定长,无需增加或删除比特。This embodiment is generally applicable to the scenario where the service container frame header is not detected at the expected position. In other embodiments: if the service container frame header is detected at the expected position, the expected position is used as the next counting starting point. It can be understood that if the service container frame header is detected at the expected position, it indicates that the length of the service container is fixed and there is no need to add or delete bits.
可选地,本申请各个实施例提供的方法还包括如下步骤:如果在所述偏移量范围内没有检测到业务容器帧头,则将所述期望位置作为下一个计数起点,并在所述期望位置的L比特块中***业务容器帧头。Optionally, the method provided by each embodiment of the present application further includes the following steps: if the service container frame header is not detected within the offset range, the expected position is used as the next counting starting point, and the service container frame header is inserted into the L-bit block at the expected position.
可选地,所述根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作之前,所述方法还包括:如果检测到业务容器帧头,且在间隔一个业务容器长度后检测到下一个业务容器帧头,则进入到业务容器锁定状态。Optionally, before performing the first operation on the service container according to the expected position and the actual position of the detected service container frame header, the method further includes: if the service container frame header is detected and the next service container frame header is detected after an interval of a service container length, entering a service container locked state.
可选地,所述方法还包括:如果连续K次在所述期望位置都没有检测到业务容器帧头,则进入到业务容器失锁状态,K为大于1的正整数。Optionally, the method further includes: if the service container frame header is not detected at the expected position for K consecutive times, entering a service container unlocked state, where K is a positive integer greater than 1.
本申请实施例提供的业务处理方法,对业务容器进行业务容器帧头检测处理;根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作,所述期望位置为与上一个业务容器帧头相隔一个业务容器长度的位置,所述第一操作包括增加或删除固定数量的比特。本申请实施例中,在期 望位置没有检测到业务容器帧头的情况下,通过增加或删除固定数量的比特,有利于使业务容器保持固定长度,避免业务容器定帧失败,从而可以避免数据丢失。The service processing method provided in the embodiment of the present application performs service container frame header detection processing on the service container; performs a first operation on the service container according to the expected position and the actual position of the detected service container frame header, wherein the expected position is a position separated from the previous service container frame header by a service container length, and the first operation includes adding or deleting a fixed number of bits. In the embodiment of the present application, in the period When the service container frame header is not detected at the desired position, adding or deleting a fixed number of bits is helpful to keep the service container at a fixed length, avoid service container framing failure, and thus avoid data loss.
为详细说明本申请实施例提供的业务处理方法,以下将结合一个具体的实施例进行说明,该实施例以业务容器是OSU为例进行说明。To explain the service processing method provided by the embodiment of the present application in detail, a specific embodiment will be described below. The embodiment is described by taking the service container being OSU as an example.
该实施例将小颗粒业务映射到OSU中,将OSU映射复用到OPU中,其中,OPU的净荷区域划分为固定数量的时隙,每个时隙包括指示开销和净荷区域,指示开销用来指示时隙净荷区域中承载的数据类型,如图3所示,所述数据类型包括OSU数据和填充,其中OSU帧的长度为M*L,L为时隙净荷区域的大小。在图2所示的例子中,M=12,L=16。This embodiment maps small-granular services into OSUs, and maps OSUs into OPUs, wherein the payload area of the OPU is divided into a fixed number of time slots, each time slot includes an indication overhead and a payload area, and the indication overhead is used to indicate the type of data carried in the time slot payload area, as shown in FIG3 , the data type includes OSU data and padding, wherein the length of the OSU frame is M*L, and L is the size of the time slot payload area. In the example shown in FIG2 , M=12, L=16.
在接收侧,获取承载OSU的时隙数量和位置,从对应的时隙中,首先根据指示开销删除承载填充的时隙,然后根据如下规则解映射出OSU帧:On the receiving side, the number and position of the timeslots carrying the OSU are obtained. From the corresponding timeslots, the timeslots carrying the fill are first deleted according to the indication overhead, and then the OSU frames are demapped according to the following rules:
检测OSU的帧头指示信号,如果检测到OSU的帧头指示信号,并且在M*L固定长度后检测到下一个OSU帧头指示信号,则进入到OSU帧锁定状态。Detect the OSU frame header indication signal. If the OSU frame header indication signal is detected and the next OSU frame header indication signal is detected after the M*L fixed length, enter the OSU frame locking state.
在OSU帧锁定状态下,以包含OSU帧帧头指示信号的L比特块为计数起点,计数起点用于计算此OSU帧的帧头期望位置,与计数起点相隔M个L比特块的位置即为期望位置,从第(M-N)个L比特块开始,检测后续的L比特块对应位置是否包含OSU帧的帧头指示信号:In the OSU frame locked state, the L-bit block containing the OSU frame header indication signal is used as the counting starting point. The counting starting point is used to calculate the expected position of the frame header of this OSU frame. The position separated by M L-bit blocks from the counting starting point is the expected position. Starting from the (M-N)th L-bit block, the corresponding position of the subsequent L-bit blocks is detected to see whether it contains the OSU frame header indication signal:
(1)如果在第M1个L比特块对应位置检测到OSU帧头指示信号,且在期望位置第(M+1)个L比特块对应位置未检测到OSU帧头指示信号,则将第M1个L比特块作为一个新的计数起点,并补充(M+1-M1)*L个固定格式的序列到上一个OSU帧,其中M1≤M,M-M1≤N,N为预先设定的值,取决于突发误码长度以及OSU速率等参数。(1) If the OSU frame header indication signal is detected at the position corresponding to the M1th L-bit block, and the OSU frame header indication signal is not detected at the position corresponding to the (M+1)th L-bit block at the expected position, the M1th L-bit block is used as a new counting starting point, and (M+1-M1)*L fixed format sequences are added to the previous OSU frame, where M1≤M, M-M1≤N, and N is a preset value depending on parameters such as the burst error length and the OSU rate.
(2)如果在期望位置第(M+1)个L比特块对应位置检测到OSU帧头指示信号,则将第(M+1)个L比特块作为一个新的计数起点。(2) If the OSU frame header indication signal is detected at the position corresponding to the (M+1)th L-bit block at the expected position, the (M+1)th L-bit block is used as a new counting starting point.
(3)如果在期望位置第(M+1)个L比特块对应位置未检测到OSU帧头指示信号,则检测第(M+1)个L比特块后续的连续N个L比特块对应位置是否包含OSU帧的帧头指示信号。(3) If the OSU frame header indication signal is not detected at the position corresponding to the (M+1)th L-bit block at the expected position, detect whether the corresponding positions of the N consecutive L-bit blocks following the (M+1)th L-bit block contain the frame header indication signal of the OSU frame.
若在第M2个L比特块对应位置检测到OSU帧头指示信号,则将第M2个L比特块作为一个新的计数起点,并删除上一个OSU帧的(M2-M-1)*L 个数据,其中M2≤(M+N),N为预先设定的值,取决于突发误码长度以及OSU速率等参数,OSU速率低的时候,N的取值设置较小的值,从而保证时延,OSU速率高的时候,N的取值设置相对较大的值,从而保证抗突发误码能力。If the OSU frame header indication signal is detected at the position corresponding to the M2th L-bit block, the M2th L-bit block is used as a new counting starting point, and the (M2-M-1)*L of the previous OSU frame is deleted. data, where M2≤(M+N), N is a preset value, which depends on parameters such as the burst error length and the OSU rate. When the OSU rate is low, the value of N is set to a smaller value to ensure the delay. When the OSU rate is high, the value of N is set to a relatively large value to ensure the ability to resist burst errors.
若在第(M+1)个L比特块后续连续N个L比特块对应位置未检测到OSU帧的帧头指示信号,则将第M+1个L比特块作为一个新的计数起点,并在该L比特块对应位置***OSU帧的帧头指示信号。If the frame header indication signal of the OSU frame is not detected at the corresponding position of N consecutive L-bit blocks following the (M+1)th L-bit block, the M+1th L-bit block is used as a new counting starting point, and the frame header indication signal of the OSU frame is inserted at the corresponding position of the L-bit block.
如果连续固定数量K次在期望位置的L比特块对应位置都未检测到OSU帧头指示信号,则进入到OSU帧失锁状态。If the OSU frame header indication signal is not detected at the position corresponding to the L-bit block at the expected position for a fixed number of consecutive K times, the OSU frame is entered into an OSU frame unlocked state.
该申请实施例提供的业务处理方法,通过预先设置一个偏移量,在以期望位置为准的偏移量范围内进行OSU帧头的定位处理,对于未在期望位置定位到OSU帧头的情况,将实际定位到OSU帧头指示信号的位置作为新的计数起点,并根据定位到OSU帧头的实际位置与期望位置的比较对OSU帧进行第一操作,所述第一操作包括增加固定个数的固定序列,删除OSU帧固定数量的L比特块,通过此方法保证OSU帧为固定长度且每隔固定数量字节块会出现OSU的帧头,不会因为误码的影响导致OSU帧长度发生变化,从而导致丢失大量数据。The service processing method provided by the embodiment of the application pre-sets an offset and performs positioning processing on the OSU frame header within the offset range based on the expected position. In the case where the OSU frame header is not positioned at the expected position, the position of the OSU frame header indication signal actually positioned is used as a new counting starting point, and a first operation is performed on the OSU frame based on a comparison between the actual position of the positioned OSU frame header and the expected position. The first operation includes adding a fixed number of fixed sequences and deleting a fixed number of L-bit blocks of the OSU frame. This method ensures that the OSU frame is of fixed length and that the OSU frame header appears every fixed number of byte blocks, and that the OSU frame length will not change due to the influence of bit errors, thereby causing a large amount of data to be lost.
下面结合附图对本申请实施例提供的业务处理方法进行详细说明。The business processing method provided in the embodiment of the present application is described in detail below with reference to the accompanying drawings.
实施例一Embodiment 1
该实施例中,源节点和宿节点通过OPU0进行OSU业务的传递,该实施例包括如下步骤:In this embodiment, the source node and the sink node transmit the OSU service through OPU0. The embodiment includes the following steps:
步骤1:在源节点,OPU0净荷区划分为119个时隙,每个时隙长度为130比特,其中前2比特为指示开销,后面128比特为净荷区域,如图3所示。指示开销为01时,表示时隙净荷区域承载的为OSU数据,指示开销为10时,表示时隙净荷区域承载的为填充;OSU帧的长度为192字节,即为12个16字节块,OSU的帧头指示开销位于第一个16字节块的前4字节,如图2所示。Step 1: At the source node, the OPU0 payload area is divided into 119 time slots, each time slot is 130 bits long, of which the first 2 bits are indication overhead and the following 128 bits are payload area, as shown in Figure 3. When the indication overhead is 01, it indicates that the time slot payload area carries OSU data, and when the indication overhead is 10, it indicates that the time slot payload area carries padding; the length of the OSU frame is 192 bytes, that is, 12 16-byte blocks, and the OSU frame header indication overhead is located in the first 4 bytes of the first 16-byte block, as shown in Figure 2.
步骤2:将OSU映射到OPU0对应的时隙当中,由于OSU速率低于承载其的时隙速率,需要***填充进行速率适配,如果时隙净荷区域承载OSU数据,则将指示开销设置为01,如果时隙净荷区域承载填充,则将指示开销设置为10,如图3所示。 Step 2: Map OSU to the time slot corresponding to OPU0. Since the OSU rate is lower than the time slot rate that carries it, padding needs to be inserted for rate adaptation. If the time slot payload area carries OSU data, the indication overhead is set to 01. If the time slot payload area carries padding, the indication overhead is set to 10, as shown in Figure 3.
步骤3:假设在传输过程中因为误码影响,导致一个时隙的指示开销由01变为10,即OSU数据错成了填充,导致某个OSU帧丢失1个16字节块。Step 3: Assume that due to bit errors during the transmission process, the indication overhead of a time slot changes from 01 to 10, that is, the OSU data is mistakenly turned into padding, resulting in the loss of a 16-byte block in a certain OSU frame.
步骤4:在接收侧,确定承载OSU的时隙,并从指示开销为01的时隙净荷区域中输出OSU数据流,如图4所示。Step 4: At the receiving side, determine the time slot carrying the OSU, and output the OSU data stream from the time slot payload area indicating the overhead as 01, as shown in FIG4 .
步骤5:接收侧从OSU数据流中寻找OSU帧头指示信号,找到连续两个OSU帧头指示信号且相隔12个16字节块时,进入到OSU帧锁定状态。Step 5: The receiving side searches for the OSU frame header indication signal from the OSU data stream, and enters the OSU frame lock state when two consecutive OSU frame header indication signals are found and are separated by 12 16-byte blocks.
步骤6:在OSU帧锁定状态下,设置偏移量N=2,将当前16字节块作为计数起点,从第10(即M-N=10)个16字节块开始检测其前4个字节是否为OSU帧头指示信号,在第12(即M1=12)个16字节块检测到其前4字节为OSU帧头指示信号,由于12=12,即上一个OSU帧仅包括11个16字节块,并不完整,需要补充12+1-12(即M+1-M1)=1个固定序列到上一个OSU帧,使其长度保持为12个16字节块,如图5所示。Step 6: In the OSU frame locked state, set the offset N=2, take the current 16-byte block as the counting starting point, and start from the 10th (i.e., M-N=10) 16-byte block to detect whether its first 4 bytes are the OSU frame header indication signal. When the first 4 bytes of the 12th (i.e., M1=12) 16-byte block are detected as the OSU frame header indication signal, since 12=12, that is, the previous OSU frame only includes 11 16-byte blocks and is incomplete, it is necessary to add 12+1-12 (i.e., M+1-M1)=1 fixed sequence to the previous OSU frame to keep its length at 12 16-byte blocks, as shown in Figure 5.
步骤7:将步骤6中第12(即M1=12)个16字节块作为起点,继续下一轮的寻找。Step 7: Take the 12th (ie, M1=12) 16-byte block in step 6 as the starting point and continue the next round of searching.
实施例二Embodiment 2
该实施例中,源节点和宿节点通过OPU0进行OSU业务的传递,该实施例包括如下步骤:In this embodiment, the source node and the sink node transmit the OSU service through OPU0. The embodiment includes the following steps:
步骤1:在源节点,OPU0净荷区划分为119个时隙,每个时隙长度为130比特,其中前2比特为指示开销,后面128比特为净荷区域,指示开销为01时,表示时隙净荷区域承载的为OSU数据,指示开销为10时,表示时隙净荷区域承载的为填充;OSU帧的长度为192字节,即为12个16字节块,OSU的帧头指示开销位于第一个16字节块的前4字节,如图2所示。Step 1: At the source node, the OPU0 payload area is divided into 119 time slots, each time slot is 130 bits long, of which the first 2 bits are indication overhead and the following 128 bits are payload area. When the indication overhead is 01, it indicates that the time slot payload area carries OSU data, and when the indication overhead is 10, it indicates that the time slot payload area carries padding. The length of the OSU frame is 192 bytes, that is, 12 16-byte blocks. The OSU frame header indication overhead is located in the first 4 bytes of the first 16-byte block, as shown in Figure 2.
步骤2:将OSU映射到OPU0对应的时隙当中,由于OSU速率低于承载其的时隙速率,需要***填充进行速率适配,如果时隙净荷区域承载OSU数据,则将指示开销设置为01,如果时隙净荷区域承载填充,则将指示开销设置为10,如图3所示。Step 2: Map OSU to the time slot corresponding to OPU0. Since the OSU rate is lower than the time slot rate that carries it, padding needs to be inserted for rate adaptation. If the time slot payload area carries OSU data, the indication overhead is set to 01. If the time slot payload area carries padding, the indication overhead is set to 10, as shown in Figure 3.
步骤3:假设在传输过程中因为误码影响,导致两个时隙的指示开销由10变为01,即填充错成了OSU数据,导致某个OSU帧增加2个16字节块。Step 3: Assume that due to bit errors during the transmission process, the indication overhead of two time slots changes from 10 to 01, that is, the padding is mistakenly replaced with OSU data, resulting in an OSU frame adding two 16-byte blocks.
步骤4:在接收侧,确定承载OSU的时隙,并从指示开销为01的时隙净荷区域中输出OSU数据流,如图6所示。Step 4: At the receiving side, determine the time slot carrying the OSU, and output the OSU data stream from the time slot payload area indicating the overhead as 01, as shown in FIG6 .
步骤5:接收侧从OSU数据流中寻找OSU帧头指示信号,找到连续两 个OSU帧头指示信号且相隔12个16字节块时,进入到OSU帧锁定状态。Step 5: The receiving side searches for the OSU frame header indication signal from the OSU data stream and finds two consecutive When an OSU frame header indication signal is received and there are 12 16-byte blocks between them, the OSU frame lock state is entered.
步骤6:在OSU帧锁定状态下,设置偏移量N=4,将当前16字节块作为计数起点,从第8(即M-N=8)个16字节块开始检测其前4个字节是否为OSU帧头指示信号,在第13(即M+1=13)个16字节块未检测到其前4字节为OSU帧头指示信号,检测第13个16字节块后续连续4个16字节块,由于新增了2个字节块,会在第15(即M2=15)个字节块检测到其前4字节为OSU帧头指示信号,由于上一个OSU帧的长度为14,删除最后2个16字节块,使OSU帧的长度保持为12个16字节块,如图7所示。Step 6: In the OSU frame locked state, set the offset N=4, take the current 16-byte block as the counting starting point, and start from the 8th (i.e., M-N=8) 16-byte block to detect whether its first 4 bytes are the OSU frame header indication signal. The first 4 bytes of the 13th (i.e., M+1=13) 16-byte block are not detected as the OSU frame header indication signal, and detect the 13th 16-byte block and the subsequent 4 consecutive 16-byte blocks. Since 2 byte blocks are added, the first 4 bytes of the 15th (i.e., M2=15) byte block are detected as the OSU frame header indication signal. Since the length of the previous OSU frame is 14, delete the last 2 16-byte blocks to keep the length of the OSU frame at 12 16-byte blocks, as shown in Figure 7.
步骤7:将步骤6中第15(即M2=15)个16字节块作为起点,继续下一轮的寻找。Step 7: Take the 15th (ie, M2=15) 16-byte block in step 6 as the starting point and continue the next round of searching.
实施例三Embodiment 3
该实施例中,源节点和宿节点通过OPU0进行OSU业务的传递,该实施例包括如下步骤:In this embodiment, the source node and the sink node transmit the OSU service through OPU0. The embodiment includes the following steps:
步骤1:在源节点,OPU0净荷区划分为119个时隙,每个时隙长度为130比特,其中前2比特为指示开销,后面128比特为净荷区域,指示开销为01时,表示时隙净荷区域承载的为OSU数据,指示开销为10时,表示时隙净荷区域承载的为填充;OSU帧的长度为192字节,即为12个16字节块,OSU的帧头指示开销位于第一个16字节块的前4字节,如图2所示。Step 1: At the source node, the OPU0 payload area is divided into 119 time slots, each time slot is 130 bits long, of which the first 2 bits are indication overhead and the following 128 bits are payload area. When the indication overhead is 01, it indicates that the time slot payload area carries OSU data, and when the indication overhead is 10, it indicates that the time slot payload area carries padding. The length of the OSU frame is 192 bytes, that is, 12 16-byte blocks. The OSU frame header indication overhead is located in the first 4 bytes of the first 16-byte block, as shown in Figure 2.
步骤2:将OSU映射到OPU0对应的时隙当中,由于OSU速率低于承载其的时隙速率,需要***填充进行速率适配,如果时隙净荷区域承载OSU数据,则将指示开销设置为01,如果时隙净荷区域承载填充,则将指示开销设置为10,如图3所示。Step 2: Map OSU to the time slot corresponding to OPU0. Since the OSU rate is lower than the time slot rate that carries it, padding needs to be inserted for rate adaptation. If the time slot payload area carries OSU data, the indication overhead is set to 01. If the time slot payload area carries padding, the indication overhead is set to 10, as shown in Figure 3.
步骤3:假设在传输过程中因为误码影响,导致一个时隙的指示开销由10变为01,即填充错成了OSU数据;同时,一个OSU帧的帧头指示信号被污染,导致某个OSU帧增加1个16字节块,下一个OSU帧头被污染无法正确识别。Step 3: Assume that due to bit errors during the transmission process, the indication overhead of a time slot changes from 10 to 01, that is, it is filled with OSU data; at the same time, the frame header indication signal of an OSU frame is polluted, resulting in an additional 16-byte block in an OSU frame, and the next OSU frame header is polluted and cannot be correctly identified.
步骤4:在接收侧,确定承载OSU的时隙,并从指示开销为01的时隙净荷区域中输出OSU数据流,如图8所示。Step 4: At the receiving side, determine the time slot carrying the OSU, and output the OSU data stream from the time slot payload area indicating the overhead as 01, as shown in FIG8 .
步骤5:接收侧从OSU数据流中寻找OSU帧头指示信号,找到连续两个OSU帧头指示信号且相隔12个16字节块时,进入到OSU帧锁定状态。Step 5: The receiving side searches for the OSU frame header indication signal from the OSU data stream, and enters the OSU frame lock state when two consecutive OSU frame header indication signals are found and are separated by 12 16-byte blocks.
步骤6:在OSU帧锁定状态下,设置偏移量N=2,将当前16字节块作 为计数起点,从第10(即M-N=10)个16字节块开始检测其前4个字节是否为OSU帧头指示信号,在第13(即M+1=13)个16字节块未检测到其前4字节为OSU帧头指示信号,检测第13个16字节块后续连续2个16字节块,由于新增了1个字节块且下一个OSU帧头指示信号被污染,无法在后续连续2个字节块检测到其前4字节为OSU帧头指示信号,将第13(即M+1=13)个16字节块作为新的起点,并在其前4字节***OSU帧帧头指示信号,如图9所示,并继续下一轮的寻找。Step 6: In the OSU frame lock state, set the offset N = 2 and use the current 16-byte block as As the counting starting point, the first 4 bytes of the 10th (i.e., MN=10) 16-byte block are detected to see if they are the OSU frame header indication signal. The first 4 bytes of the 13th (i.e., M+1=13) 16-byte block are not detected to be the OSU frame header indication signal. The 2 consecutive 16-byte blocks following the 13th 16-byte block are detected. Since one byte block is added and the next OSU frame header indication signal is contaminated, it is impossible to detect that the first 4 bytes of the subsequent 2 consecutive byte blocks are the OSU frame header indication signal. The 13th (i.e., M+1=13) 16-byte block is taken as the new starting point, and the OSU frame header indication signal is inserted into its first 4 bytes, as shown in FIG9 , and the next round of searching is continued.
步骤7:在步骤6设置新的起点基础上,从第10个16字节块开始检测其前4个字节是否为OSU帧头指示信号,在第13(即M+1=13)个16字节块未检测到其前4字节为OSU帧头指示信号,检测第13个16字节块后续连续2个16字节块,由于步骤6没有删除新增的16字节块,在第14(即M2=14)个字节块检测到其前4字节为OSU帧头指示信号,由于上一个OSU帧的长度为13,删除最后1个16字节块,使OSU帧的长度保持为12个16字节块,如图10所示。Step 7: On the basis of setting a new starting point in step 6, starting from the 10th 16-byte block, detect whether its first 4 bytes are the OSU frame header indication signal. The first 4 bytes of the 13th (i.e., M+1=13) 16-byte block are not detected as the OSU frame header indication signal. Detect the 2 consecutive 16-byte blocks following the 13th 16-byte block. Since the newly added 16-byte block is not deleted in step 6, the first 4 bytes of the 14th (i.e., M2=14) byte block are detected as the OSU frame header indication signal. Since the length of the previous OSU frame is 13, delete the last 16-byte block to keep the length of the OSU frame at 12 16-byte blocks, as shown in Figure 10.
步骤8:将步骤7中第14(即M2=14)个16字节块作为起点,继续下一轮的寻找。Step 8: Take the 14th (ie, M2=14) 16-byte block in step 7 as the starting point and continue the next round of searching.
图11示出本申请实施例提供的业务处理装置的结构示意图,该装置1100可以包括:帧头检测模块1102和操作模块1104。FIG. 11 shows a schematic diagram of the structure of a service processing device provided in an embodiment of the present application. The device 1100 may include: a frame header detection module 1102 and an operation module 1104 .
在一种可能的实现方式中,帧头检测模块1102,用于对业务容器进行业务容器帧头检测处理。操作模块1104,用于根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作,所述期望位置为与上一个业务容器帧头相隔一个业务容器长度的位置,所述第一操作包括增加或删除固定数量的比特。In a possible implementation, the frame header detection module 1102 is used to perform a service container frame header detection process on the service container. The operation module 1104 is used to perform a first operation on the service container according to the expected position and the actual position of the detected service container frame header, the expected position is a position separated from the previous service container frame header by a service container length, and the first operation includes adding or deleting a fixed number of bits.
本申请实施例中,对业务容器进行业务容器帧头检测处理;根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作,所述期望位置为与上一个业务容器帧头相隔一个业务容器长度的位置,所述第一操作包括增加或删除固定数量的比特。本申请实施例中,在期望位置没有检测到业务容器帧头的情况下,通过增加或删除固定数量的比特,有利于使业务容器保持固定长度,避免业务容器定帧失败,从而可以避免数据丢失。In the embodiment of the present application, a service container is subjected to a service container frame header detection process; a first operation is performed on the service container according to an expected position and an actual position where the service container frame header is detected, the expected position being a position separated from a previous service container frame header by a service container length, and the first operation includes adding or deleting a fixed number of bits. In the embodiment of the present application, when a service container frame header is not detected at the expected position, adding or deleting a fixed number of bits is beneficial to keeping the service container at a fixed length, avoiding service container framing failure, and thus avoiding data loss.
可选地,作为一个实施例,所述帧头检测模块1102,用于:确定偏移量范围;其中,所述偏移量范围包括:从计数起点开始的第M-N个L比特块至 第M+N+1个L比特块;所述计数起点为上一个业务容器帧头所在的L比特块;N为预定义的值,N用于确定所述偏移量范围;在所述偏移量范围内检测业务容器帧头。Optionally, as an embodiment, the frame header detection module 1102 is used to: determine an offset range; wherein the offset range includes: from the MNth L-bit block starting from the counting start point to The M+N+1th L-bit block; the counting starting point is the L-bit block where the previous service container frame header is located; N is a predefined value, and N is used to determine the offset range; the service container frame header is detected within the offset range.
可选地,作为一个实施例,所述实际位置为从所述计数起点开始的第M1个L比特块的位置,所述操作模块1104,用于添加M+1-M1个L比特块到所述业务容器,将所述实际位置作为计数起点,其中,M1≤M,M-M1≤N。Optionally, as an embodiment, the actual position is the position of the M1th L-bit block starting from the counting starting point, and the operation module 1104 is used to add M+1-M1 L-bit blocks to the business container, taking the actual position as the counting starting point, where M1≤M, M-M1≤N.
可选地,作为一个实施例,所述实际位置为从所述计数起点开始的第M2个L比特块的位置,所述操作模块1104,用于删除所述业务容器的M2-M-1个L比特块,将所述实际位置作为计数起点,其中,M2>M+1,M2≤M+N。Optionally, as an embodiment, the actual position is the position of the M2th L-bit block starting from the counting starting point, and the operation module 1104 is used to delete the M2-M-1 L-bit blocks of the business container and take the actual position as the counting starting point, where M2>M+1, M2≤M+N.
本申请实施例提供的该装置1100,可执行前文方法实施例中所述的各方法,并实现前文方法实施例中所述的各方法的功能和有益效果,在此不再赘述。The device 1100 provided in the embodiment of the present application can execute the various methods described in the foregoing method embodiments, and realize the functions and beneficial effects of the various methods described in the foregoing method embodiments, which will not be repeated here.
图12示出执行本申请实施例提供的电子设备的硬件结构示意图,参考该图,在硬件层面,电子设备包括处理器,可选地,包括内部总线、网络接口、存储器。其中,存储器可能包含内存,例如高速随机存取存储器(Random-Access Memory,RAM),也可能还包括非易失性存储器(non-volatile memo ry),例如至少1个磁盘存储器等。当然,该电子设备还可能包括其他业务所需要的硬件。FIG12 shows a schematic diagram of the hardware structure of an electronic device that implements the embodiment of the present application. Referring to the figure, at the hardware level, the electronic device includes a processor, and optionally, an internal bus, a network interface, and a memory. The memory may include a memory, such as a high-speed random access memory (RAM), and may also include a non-volatile memory (non-volatile memory), such as at least one disk storage, etc. Of course, the electronic device may also include hardware required for other services.
处理器、网络接口和存储器可以通过内部总线相互连接,该内部总线可以是工业标准体系结构(Industry Standard Architecture,ISA)总线、外设部件互连标准(Peripheral Component Interconnect,PCI)总线或扩展工业标准结构(Extended Industry Standard Architecture,EISA)总线等。所述总线可以分为地址总线、数据总线、控制总线等。为便于表示,该图中仅用一个双向箭头表示,但并不表示仅有一根总线或一种类型的总线。The processor, the network interface and the memory may be interconnected through an internal bus, which may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one bidirectional arrow is used in the figure, but it does not mean that there is only one bus or one type of bus.
存储器,用于存放程序。具体地,程序可以包括程序代码,所述程序代码包括计算机操作指令。存储器可以包括内存和非易失性存储器,并向处理器提供指令和数据。The memory is used to store the program. Specifically, the program may include a program code, and the program code includes a computer operation instruction. The memory may include a memory and a non-volatile memory, and provides instructions and data to the processor.
处理器从非易失性存储器中读取对应的计算机程序到内存中然后运行,在逻辑层面上形成定位目标用户的装置。处理器,执行存储器所存放的程序,并具体用于执行:图1-10所示实施例揭示的方法并实现前文方法实施例中所 述的各方法的功能和有益效果,在此不再赘述。The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs it, forming a device for locating the target user at the logical level. The processor executes the program stored in the memory and is specifically used to execute: the method disclosed in the embodiment shown in Figures 1-10 and implement the method described in the above method embodiment The functions and beneficial effects of the above methods will not be repeated here.
上述如本申请图1-10所示实施例揭示的方法可以应用于处理器中,或者由处理器实现。处理器可能是一种集成电路芯片,具有信号的处理能力。在实现过程中,上述方法的各步骤可以通过处理器中的硬件的集成逻辑电路或者软件形式的指令完成。上述的处理器可以是通用处理器,包括中央处理器(Central Processing Unit,CPU)、网络处理器(Network Processor,NP)等;还可以是数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。可以实现或者执行本申请实施例中的公开的各方法、步骤及逻辑框图。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。结合本申请实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成,或者用译码处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器,闪存、只读存储器,可编程只读存储器或者电可擦写可编程存储器、寄存器等本领域成熟的存储介质中。该存储介质位于存储器,处理器读取存储器中的信息,结合其硬件完成上述方法的步骤。The method disclosed in the above-mentioned embodiment as shown in Figures 1-10 of the present application can be applied to a processor or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above-mentioned method can be completed by an integrated logic circuit of hardware in the processor or an instruction in the form of software. The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware decoding processor for execution, or a combination of hardware and software modules in the decoding processor for execution. The software module can be located in a mature storage medium in the field such as random access memory, flash memory, read-only memory, programmable read-only memory or electrically erasable programmable memory, register, etc. The storage medium is located in the memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware.
该电子设备还可执行前文方法实施例中所述的各方法,并实现前文方法实施例中所述的各方法的功能和有益效果,在此不再赘述。The electronic device can also execute the methods described in the foregoing method embodiments, and realize the functions and beneficial effects of the methods described in the foregoing method embodiments, which will not be described in detail here.
当然,除了软件实现方式之外,本申请的电子设备并不排除其他实现方式,比如逻辑器件抑或软硬件结合的方式等等,也就是说以下处理流程的执行主体并不限定于各个逻辑单元,也可以是硬件或逻辑器件。Of course, in addition to software implementation methods, the electronic device of the present application does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc., that is to say, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.
本申请实施例还提出了一种计算机可读存储介质,所述计算机可读介质存储一个或多个程序,所述一个或多个程序当被包括多个应用程序的电子设备执行时,使得所述电子设备执行图1-10所示实施例揭示的方法并实现前文方法实施例中所述的各方法的功能和有益效果,在此不再赘述。An embodiment of the present application also proposes a computer-readable storage medium, which stores one or more programs. When the one or more programs are executed by an electronic device including multiple application programs, the electronic device executes the methods disclosed in the embodiments shown in Figures 1-10 and realizes the functions and beneficial effects of the various methods described in the previous method embodiments, which are not repeated here.
其中,所述的计算机可读存储介质包括只读存储器(Read-Only Memor y,简称ROM)、随机存取存储器(Random Access Memory,简称RAM)、磁碟或者光盘等。Among them, the computer readable storage medium includes read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM), a disk or an optical disk, etc.
进一步地,本申请实施例还提供了一种计算机程序产品,所述计算机程序产品包括存储在非暂态计算机可读存储介质上的计算机程序,所述计算机 程序包括程序指令,当所述程序指令被计算机执行时,实现以下流程:图1-10所示实施例揭示的方法并实现前文方法实施例中所述的各方法的功能和有益效果,在此不再赘述。Furthermore, an embodiment of the present application also provides a computer program product, the computer program product comprising a computer program stored on a non-transitory computer-readable storage medium. The program includes program instructions. When the program instructions are executed by a computer, the following process is implemented: the method disclosed in the embodiments shown in Figures 1-10 and the functions and beneficial effects of each method described in the previous method embodiments are implemented, which will not be repeated here.
总之,以上所述仅为本申请的较佳实施例,并非用于限定本申请的保护范围。凡在本申请的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本申请的保护范围之内。In short, the above description is only a preferred embodiment of the present application and is not intended to limit the protection scope of the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.
上述实施例阐明的***、装置、模块或单元,具体可以由计算机芯片或实体实现,或者由具有某种功能的产品来实现。一种典型的实现设备为计算机。具体的,计算机例如可以为个人计算机、膝上型计算机、蜂窝电话、相机电话、智能电话、个人数字助理、媒体播放器、导航设备、电子邮件设备、游戏控制台、平板计算机、可穿戴设备或者这些设备中的任何设备的组合。The systems, devices, modules or units described in the above embodiments may be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
计算机可读介质包括永久性和非永久性、可移动和非可移动媒体可以由任何方法或技术来实现信息存储。信息可以是计算机可读指令、数据结构、程序的模块或其他数据。计算机的存储介质的例子包括,但不限于相变内存(Phase-change RAM,PRAM)、静态随机存取存储器(Static RAM,SRA M)、动态随机存取存储器(Dynamic RAM,DRAM)、其他类型的随机存取存储器(RAM)、只读存储器(ROM)、电可擦除可编程只读存储器(Electri cally Erasable Programmable ROM,EEPROM)、快闪记忆体或其他内存技术、只读光盘只读存储器(CD-ROM)、数字多功能光盘(DVD)或其他光学存储、磁盒式磁带,磁带磁磁盘存储或其他磁性存储设备或任何其他非传输介质,可用于存储可以被计算设备访问的信息。按照本文中的界定,计算机可读介质不包括暂存电脑可读媒体(Transitory Media),如调制的数据信号和载波。Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase-change RAM (PRAM), static RAM (SRAM), dynamic RAM (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable ROM (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined in this article, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.
还需要说明的是,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、商品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、商品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、商品或者设备中还存在另外的相同要素。It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
本说明书中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同 之处。尤其,对于***实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。 The various embodiments in this specification are described in a progressive manner. The same or similar parts between the various embodiments can be referred to each other. Each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

Claims (12)

  1. 一种业务处理方法,包括:A business processing method, comprising:
    对业务容器进行业务容器帧头检测处理;Performing service container frame header detection processing on the service container;
    根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作,所述期望位置为与上一个业务容器帧头相隔一个业务容器长度的位置,所述第一操作包括增加或删除固定数量的比特。A first operation is performed on the service container according to an expected position and an actual position of a detected service container frame header, wherein the expected position is a position separated from a previous service container frame header by a service container length, and the first operation includes adding or deleting a fixed number of bits.
  2. 根据权利要求1所述的方法,其中,所述对业务容器进行业务容器帧头检测处理包括:The method according to claim 1, wherein the performing service container frame header detection processing on the service container comprises:
    确定偏移量范围;其中,所述偏移量范围包括:从计数起点开始的第M-N个L比特块至第M+N+1个L比特块;所述计数起点为上一个业务容器帧头所在的L比特块;N为预定义的值,N用于确定所述偏移量范围;Determine an offset range; wherein the offset range includes: the M-Nth L-bit block to the M+N+1th L-bit block starting from the counting start point; the counting start point is the L-bit block where the previous service container frame header is located; N is a predefined value, and N is used to determine the offset range;
    在所述偏移量范围内检测业务容器帧头。The service container frame header is detected within the offset range.
  3. 根据权利要求1所述的方法,其中,所述业务容器的长度为M个L比特块,所述业务容器包括开销区域和净荷区域,所述开销区域包括帧头开销,M为正整数。The method according to claim 1, wherein the length of the service container is M L-bit blocks, the service container includes an overhead area and a payload area, the overhead area includes a frame header overhead, and M is a positive integer.
  4. 根据权利要求2所述的方法,其中,所述实际位置为从所述计数起点开始的第M1个L比特块的位置,所述根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作包括:The method according to claim 2, wherein the actual position is the position of the M1th L-bit block starting from the counting start point, and the performing a first operation on the service container according to the expected position and the actual position of the detected service container frame header comprises:
    添加M+1-M1个L比特块到所述业务容器,将所述实际位置作为计数起点,其中,M1≤M,M-M1≤N。Add M+1-M1 L-bit blocks to the service container, and use the actual position as the counting starting point, where M1≤M, M-M1≤N.
  5. 根据权利要求2所述的方法,其中,所述实际位置为从所述计数起点开始的第M2个L比特块的位置,所述根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作包括:The method according to claim 2, wherein the actual position is the position of the M2th L-bit block starting from the counting start point, and the performing a first operation on the service container according to the expected position and the actual position of the detected service container frame header comprises:
    删除所述业务容器的M2-M-1个L比特块,将所述实际位置作为计数起点,其中,M2>M+1,M2≤M+N。 Delete M2-M-1 L-bit blocks of the service container, and use the actual position as the counting starting point, where M2>M+1 and M2≤M+N.
  6. 根据权利要求4或5所述的方法,其中,N由如下至少之一确定:突发误码长度,业务容器速率。The method according to claim 4 or 5, wherein N is determined by at least one of the following: burst error length, service container rate.
  7. 根据权利要求1至6任一项所述的方法,其中,所述方法还包括:The method according to any one of claims 1 to 6, wherein the method further comprises:
    如果在所述期望位置检测到业务容器帧头,则将所述期望位置作为计数起点。If the service container frame header is detected at the expected position, the expected position is used as the counting starting point.
  8. 根据权利要求2至6任一项所述的方法,其中,所述方法还包括:The method according to any one of claims 2 to 6, wherein the method further comprises:
    如果在所述偏移量范围内没有检测到业务容器帧头,则将所述期望位置作为计数起点,并在所述期望位置的L比特块中***业务容器帧头。If the service container frame header is not detected within the offset range, the expected position is used as the counting starting point, and the service container frame header is inserted into the L-bit block at the expected position.
  9. 根据权利要求1所述的方法,其中,所述根据期望位置以及检测到业务容器帧头的实际位置对业务容器进行第一操作之前,所述方法还包括:The method according to claim 1, wherein before performing a first operation on the service container according to the expected position and the actual position of the detected service container frame header, the method further comprises:
    如果检测到业务容器帧头,且在间隔一个业务容器长度后检测到下一个业务容器帧头,则进入到业务容器锁定状态。If a service container frame header is detected, and the next service container frame header is detected after an interval of a service container length, the service container locking state is entered.
  10. 根据权利要求1所述的方法,其中,所述方法还包括:The method according to claim 1, wherein the method further comprises:
    如果连续K次在所述期望位置都没有检测到业务容器帧头,则进入到业务容器失锁状态,K为大于1的正整数。If the service container frame header is not detected at the expected position for K consecutive times, the service container enters a locked state, where K is a positive integer greater than 1.
  11. 一种电子设备,包括:An electronic device, comprising:
    处理器;以及Processor; and
    被安排成存储计算机可执行指令的存储器,所述可执行指令在被执行时使用所述处理器执行权利要求1-10任一项所述的业务处理方法的步骤。A memory arranged to store computer executable instructions, wherein when the executable instructions are executed, the processor is used to perform the steps of the business processing method according to any one of claims 1 to 10.
  12. 一种计算机可读介质,所述计算机可读介质存储一个或多个程序,所述一个或多个程序当被包括多个应用程序的电子设备执行时,使得所述电子设备执行权利要求1-10任一项所述的业务处理方法的步骤。 A computer-readable medium storing one or more programs, which, when executed by an electronic device including a plurality of application programs, enables the electronic device to execute the steps of the business processing method according to any one of claims 1 to 10.
PCT/CN2023/108425 2022-12-09 2023-07-20 Service processing method and apparatus, and electronic device WO2024119837A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202211582514.3A CN118174821A (en) 2022-12-09 2022-12-09 Service processing method and device and electronic equipment
CN202211582514.3 2022-12-09

Publications (1)

Publication Number Publication Date
WO2024119837A1 true WO2024119837A1 (en) 2024-06-13

Family

ID=91349235

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/108425 WO2024119837A1 (en) 2022-12-09 2023-07-20 Service processing method and apparatus, and electronic device

Country Status (2)

Country Link
CN (1) CN118174821A (en)
WO (1) WO2024119837A1 (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111490845A (en) * 2019-01-28 2020-08-04 中兴通讯股份有限公司 Method, device and system for transmitting customer service
US20210073158A1 (en) * 2019-09-10 2021-03-11 GigaIO Networks, Inc. Methods and apparatus for network interface fabric send/receive operations
CN112511260A (en) * 2020-02-28 2021-03-16 中兴通讯股份有限公司 Service processing method and device in optical transport network and electronic equipment
CN113395613A (en) * 2020-03-11 2021-09-14 华为技术有限公司 Method, device and system for carrying service

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111490845A (en) * 2019-01-28 2020-08-04 中兴通讯股份有限公司 Method, device and system for transmitting customer service
US20210073158A1 (en) * 2019-09-10 2021-03-11 GigaIO Networks, Inc. Methods and apparatus for network interface fabric send/receive operations
CN112511260A (en) * 2020-02-28 2021-03-16 中兴通讯股份有限公司 Service processing method and device in optical transport network and electronic equipment
CN113395613A (en) * 2020-03-11 2021-09-14 华为技术有限公司 Method, device and system for carrying service

Also Published As

Publication number Publication date
CN118174821A (en) 2024-06-11

Similar Documents

Publication Publication Date Title
KR102099544B1 (en) Method and device for processing distribution of streaming data
CN108846749B (en) Partitioned transaction execution system and method based on block chain technology
CN108881120B (en) Data processing method and device based on block chain
CN108062235B (en) Data processing method and device
US10884862B2 (en) Method and apparatus for processing failure of cipher change of ciphertext in database
CN101833513B (en) Device and reading method for data frame
CN110851113A (en) Method and device for detecting randomness of byte sequence, storage medium and electronic equipment
WO2024119837A1 (en) Service processing method and apparatus, and electronic device
CN110071923A (en) Packet identification method, device, electronic equipment and machine readable storage medium
CN113126879B (en) Data storage method and device and electronic equipment
CN107590160B (en) Method and device for monitoring internal structure of radix tree to realize test
CN114466087B (en) Data transmission method, device, equipment and storage medium
CN111835599B (en) SketchLearn-based hybrid network measurement method, device and medium
CN117294771A (en) Redundant frame message processing method and device and electronic equipment
CN111464312B (en) Method and device for processing account addresses in blockchain and electronic equipment
US10564877B1 (en) Methods and apparatus to store and enable a transfer protocol for new file formats for distributed processing and preserve data integrity through distributed storage blocks
CN112286966A (en) Data stream processing method, data stream recovery method, data stream processing device, data stream recovery device and storage medium
US7161950B2 (en) Systematic memory location selection in Ethernet switches
CN114095386A (en) Data stream statistical method, device and storage medium
WO2015090081A1 (en) Routing information aging method and device, and computer storage medium
CN116610485B (en) Isolation gateway data verification method, electronic equipment and storage medium
CN109446226B (en) Method and equipment for determining data set
CN113452614B (en) Message processing method and device
CN112203280B (en) Data trusted transmission mechanism oriented to edge gateway
CN111884809B (en) Method and device for preventing branch chain transaction replay and electronic equipment