2. List the Hypothetical primitives in transport layer and using a diagram explain connection establishment and connection release for the same
Answer:
There are five types of service primitives:
- LISTEN: When a server is ready to accept an incoming connection, it executes the LISTEN
primitive. It blocks waiting for an incoming connection. - CONNECT: It connects the server by establishing a connection. Response is awaited.
- RECIEVE: Then the RECIEVE call blocks the server.
- SEND: Then the client executes SEND primitive to transmit its request followed by the
execution of RECIEVE to get the reply. Send the message. - DISCONNECT: This primitive is used for terminating the connection. After this primitive
one can’t send any message. When the client sends DISCONNECT packet then the server
also sends the DISCONNECT packet to acknowledge the client. When the server package is
received by client then the process is terminated