●。 Connectionless servers o Access multiple hosts from a single socket o No problem of resource depletion o No reliable delivery o Need to take care of the reliability Usually, clients take care of retransmitting request Server may retransmit as well o achieving reliability can be difficult ● Timeout retransmission SIE NTUT. Taiwan
11 CSIE, NTUT, Taiwan Connectionless Servers Access multiple hosts from a single socket No problem of resource depletion No reliable delivery ⚫ Need to take care of the reliability ⚫ Usually, clients take care of retransmitting request ⚫ Server may retransmit as well Achieving reliability can be difficult ⚫ Timeout ⚫ retransmission
●。 Connectionless servers o tcP does not allow multicast or broadcast o Multicast and broadcast services require UDP o any server that accepts or responds to multicast and broadcast communication must be connectionless SIE NTUT. Taiwan
12 CSIE, NTUT, Taiwan Connectionless Servers TCP does not allow multicast or broadcast Multicast and broadcast services require UDP Any server that accepts or responds to multicast and broadcast communication must be connectionless
oo. Stateful or Stateless o The issue of stateless arises from a need to ensure reliabilit o For a service using connectionless transport, like UDP, the application protocols need to ensure the reliability 13 SIE, NTUT, Taiwan
13 CSIE, NTUT, Taiwan Stateful or Stateless The issue of stateless arises from a need to ensure reliability For a service using connectionless transport, like UDP, the application protocols need to ensure the reliability
●。 Stateless servers o Consider a connectionless server that allows clients to read information from es o Clients need to specify Filename Position in the file amount to read o Straightforward method is to handle each request independently 14 SIE NTUT. Taiwan
14 CSIE, NTUT, Taiwan Stateless Servers Consider a connectionless server that allows clients to read information from files ⚫ Clients need to specify • Filename • Position in the file • Amount to read ⚫ Straightforward method is to handle each request independently
●° Optimizing Stateless Servers o Observe that o The overhead to open and close files is high ● Data read may be few o Sequentially read files o Using buffers to assist reading files o This may be similar to the stateful servers ● Hashing table is used o The ip address and the port number form the index 15 SIE, NTUT, Taiwan
15 CSIE, NTUT, Taiwan Optimizing Stateless Servers Observe that ⚫ The overhead to open and close files is high ⚫ Data read may be few ⚫ Sequentially read files Using buffers to assist reading files ⚫ This may be similar to the stateful servers ⚫ Hashing table is used ⚫ The IP address and the port number form the index