Salesforce

How does a TCP session work

« Go Back

Information

 
TitleHow does a TCP session work
URL NameP73431
Article Number000156845
EnvironmentProduct: Progress OpenEdge
Version: All supported versions
OS: All supported platforms
Question/Problem Description
How does a TCP session work
What is the round trip of a typical TCP Session
Steps to Reproduce
Clarifying Information
Error Message
Defect Number
Enhancement Number
Cause
Resolution
When a client needs to connect with a remote server using TCP/IP: Refer to Article  What is TCP (Transmission Control Protocol)   
  1. First, the client must contact the server and request a connection. 
  2. After the connection is established, various control parameters for the connection are negotiated. 
  3. After data transmission begins, a sliding window flow-control scheme is used to manage data transfer.
A connection is established via a three-way handshake

This handshake helps define the start of a new TCP connection, and prevents a host from being confused by duplicate packets generated by a previous connection that arrives late.
  1. Host A (the sender) sends a TCP segment to Host B with the SYN flag set to 1 and the ACK flag set to 0.
  2. Host B returns a segment to Host A in which both the SYN and ACK flags are set to 1.
  3. Host A can now acknowledge to Host B that it received its ACK. It sends a segment in which ACK=1 and SYN=0.
Included these steps, is a negotiation of an initial sequence number for the client and for the server (each uses its own sequence number scheme).  Host A sends its starting number to Host B and Host B acknowledges that number by incrementing it and returning the number to Host A. The same process is used to negotiate host B's starting sequence number.

After data is transmitted, the session is terminated:
  1. Host A sends a FIN=1 to host B. 
  2. Host B then responds with ACK=1 and FIN=1 and host A responds to that with ACK=1.
TCP uses a keep-alive feature to keep connections open and manage connections. Keep-alive verifies that the computer at the other end of a connection is still available. Refer to Article  How does the TCP KeepAlive mechanism work?  

A single host can set up multiple connections over the TCP/IP network at any time. This is called multiplexing. If multiple applications or network processes are running, each may set up a connection to a different computer. 
For example, you can simultaneously open multiple Web Browsers and connect to multiple sites.

TCP uses flow controls, sliding windows, and various other mechanisms to manage sessions. 
These are discussed further under the following general headings:
  • "Connection Establishment"
  • "Flow-Control Mechanisms"
  • "Congestion Control Mechanism"
The topic congestion control discusses techniques that TCP uses to control congestion. Specifically, TCP relies on dropped packets as a signal that the receiver or network is overloaded.  Much work has gone into improving this technique. A number of IETF Working Groups are developing extensions to TCP or working on updates. 
Refer to the IETF Web site (https://www.ietf.org/) , specifically the Transport Area Working Group https://datatracker.ietf.org/wg/tsvwg/documents
 
Workaround
Notes
Keyword Phrase
Last Modified Date11/20/2020 7:39 AM

Powered by