TCP-based data subcontracting and sticking processing method

A technology of protocol data and processing method, applied in the field of data transmission, can solve the problem that the receiver cannot restore the data packet, etc., and achieve the effect of wide application range

Active Publication Date: 2019-02-15
HAINAN YILE IOT TECH CO LTD
View PDF3 Cites 5 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

The combination of data packets has no dividing line in the TCP protocol, so this will cause the receiver to fail to restore its original data packets, which is sticky packets

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • TCP-based data subcontracting and sticking processing method
  • TCP-based data subcontracting and sticking processing method
  • TCP-based data subcontracting and sticking processing method

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0027] refer to figure 1 , the present invention provides a kind of processing method based on TCP protocol data packet, comprising the following steps:

[0028] S1. The TCP communication server receives the data from the client, and calculates the Length_every of the received data each time.

[0029] The TCP communication server performs real-time data transmission interaction with the client, and calculates the length Length_every of the received data each time it receives data.

[0030] S2. The TCP communication server acquires the standard complete length Length of the received data type.

[0031] The standard complete length Length of various data types transmitted by the TCP communication server and the client during data interaction is stored in advance according to the data type, and the TCP communication server obtains the received data from the database after receiving the data uploaded by the client The standard full length of the type Length.

[0032] S3. The TC...

Embodiment 2

[0040] refer to figure 2 The present embodiment provides a method for processing data packet stickiness based on the TCP protocol. The difference from Embodiment 1 is that it also solves the problem of sticky packets of data during data transmission through the TCP protocol, which specifically includes the following steps:

[0041] S1. The TCP communication server receives the data from the client, and calculates the Length_every of the received data each time.

[0042] S2. The TCP communication server acquires the standard complete length Length of the received data type.

[0043] S3. The TCP communication server obtains the cached data received last time. If the cached data is obtained, the Length_real of the actually read data length is calculated; if the cached data is not obtained, the Length_real is assigned a value of 0.

[0044] S4. Determine whether the actually read data length Length_real is equal to the standard complete length Length of the received data type. ...

Embodiment 3

[0050] refer to image 3 , a processing method based on TCP protocol data packet sticking provided by this embodiment is different from Embodiments 1 and 2 in that it can process the received packets and sticky packets of various data types of different lengths , including the following steps:

[0051] S1. The TCP communication server receives the data from the client, and calculates the Length_every of the received data each time.

[0052] S21. Set corresponding fixed identification bits for different types of data to identify their lengths. When the TCP communication server receives data from the client each time, it also identifies the identification bits of the acquired data to determine whether it is consistent with the corresponding data type. The identification bits are the same, if they are not the same, then step S22 is executed; if they are the same, then step S23 is executed.

[0053] S22. Obtain the full length of the buffer, Length, and determine whether the Len...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a TCP-based data subcontracting and sticking processing method. The TCP-based data subcontracting and sticking processing method comprises the steps of: when data is received,calculating the data length Length_every read every time; obtaining the full length Length of the received data type; obtaining the cache data received in the previous time, and calculating the actually read data length Length_real; and judging whether the actually read data length Length_real is the same as the standard full length Length of the received data type or not. According to the methodin the invention, when data transmission is carried out through a TCP, the data subcontracting and sticking problems in the transmission process can be effectively solved; the method is applied to transmitting different types of data; too much tedious calculation and judgement can be avoided; influence on the transmission speed can be avoided; and thus, the application range is wide.

Description

technical field [0001] The invention relates to the technical field of data transmission, in particular to a method for processing data packet sticking based on the TCP protocol. Background technique [0002] TCP is a commonly used network transmission protocol. Data flow analysis is a problem that network application developers can never avoid. During data transmission, packet splitting, sticky packets, and packet loss may occur. The reason for packet splitting may be because The data is too large and divided into two or more transmissions. It may also be caused by the loss of some packets during the transmission process, resulting in a half-packet, or it may be caused by IP fragmentation transmission. On the other hand, TCP needs to be as efficient and reliable as possible, so TCP uses the Nagle algorithm by default to combine connected data packets and send them at a time when a certain number is reached, so as to improve network transmission efficiency. The combination ...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): H04L29/06H04L29/08
CPCH04L69/16H04L67/568
Inventor 李小平
Owner HAINAN YILE IOT TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products