1 A message is a logical unit of information and can be of any length.
- In message switching, if a station wishes to send a message to another station, it first adds the destination address to the message.
- Message switching does not establish a dedicated path between the two communicating devices i.e. no direct link is established between sender and receiver.
- Each message is treated as an independent unit.
- In message switching, each complete message is then transmitted from device to device through the internetwork i.e. message is transmitted from the source node to intermediate node.
- The intermediate node stores the complete message temporarily, inspects it for errors and transmits the message to the next node based on an available free channel and its routing information. Because of this reason message switched networks are called store and forward network as shown in fig.
- The actual path taken by the message to its destination is dynamic as the path is established as it travels along.
- When the message reaches a node, the channel on which it came is released for use by another message.
- As shown in Figure message Ml is transmitted from A to D and M2 is transmitted C to B. Message Ml follows the route A –> I –> II –> III –> D and M2 follows the route C –> IV –> II –> B depending upon the availability of free path at that particular moment.
- The first electromechanical telecommunication system used message switching for telegrams. The message was punched on paper tape off-line at the sending office and then read in and transmitted over a communication line to the next office along the way, where it was punched out on paper tape. An operator there tore the tape off and read it in on tape readers.
Advantages of Message Switching
The various advantages of message switching are:
1. It provides efficient traffic management by assigning priorities to the messages to be switched.
2. No physical connection is required between the source & destination as it is in circuit switching.
3. It reduces the traffic congestion on network because of store & forward facility. Each node can store the message until communication channel becomes available.
4. Channels are used effectively and network devices share the data channels.
5. It supports the message length of unlimited size.
Disadvantages of Message Switching
The various disadvantages of message switching are:
1. As message length is unlimited, each switching node must have sufficient storage to buffer message.
2. Storing & forwarding facility introduces delay thus making message switching unsuitable for real time applications like voice and video.
Delay in message switching:
• A message switched network consists of store-and-forward switches interconnected by trunks. A single trunk is usually sufficient between a pair of switches.
• Multiple trunks can be provided to increase reliability. Each switch is equipped with a storage device wherein all incoming messages are temporarily stored for onward transmission.
• The basic operation of the store-and-forward service is similar to the telegram service. A message along with the destination address is sent from switch to switch till it reaches the destination.
• Let us say end system A wants to send a message to end system B as shown in Fig. A sends its message along with the address of the destination and its own address to entry switch 1. The addresses are included in the header of the message.
• Switch 1 accepts the message and analyzes the destination address. A routing table is maintained at each node.
• It contains entries indicating destination nodes and the corresponding outgoing trunks from the switch. There is a separate queue for each trunk.
• Since the destination node may be accessible via more than one route, decision to send the message to a particular next switch depends on the expected delay in its queue. Let us say, the message from A is put in the queue for node 2.
• The message received at switch 2 is again put in a queue of messages awaiting transmission to switch 4. When its turn comes, the message is sent to switch 4 which delivers it to the destination.
• Some of the basic features of store- and-forward message switching are:
• The store-and-forward service is unidirectional. After delivery of the message, the network does not send back any confirmation to the source. If end system B is required to send an acknowledgement to the message received from A, the acknowledgement is treated like any other message by the network and carries the addresses of the destination and the source.
• For switch -to- switch transfer of the message, the network may employ some error control mechanism. The message may be appended with error-checking bits and if any error is detected by the receiving switch, it may request the sending switch for retransmission of the message. Therefore, the sending switch is required to keep a copy of the message till an acknowledgement is received.
• Since the message is stored in a buffer at the switch at each stage of transmission, each switch-to-switch transfer is an independent operation. The trunks can operate at different data rates. Even the source and destination end systems can operate at different data rates.
• In message switching every message is treated as an independent entity by the network and, therefore, destination and source addresses are repeated on each message.
• Delay in Delivery. Fig shows the timing diagram for routing a message through a message switched network. The message passes through the entry switch, two transit switches and finally through the exit switch to arrive at the destination.
Message delivery time is the sum of the following components:
• Time required sending the message to the entry switch
• Switch delay
• Transmission time at each switch.
• The time required to send a message to the entry switch IS determined by the transmission data rate and the message size.
• Propagation time to the entry switch is usually negligible. Switch delay is due to two factors :
1. Message processing at each switch (time required for error checking, routing etc.)
2. Waiting time in the queues at each switch.
• The transmission time at each switch is determined by the transmission data rate and propagation p time for transmission across the trunk.
• The total time required to deliver the message is the linear sum of all these components of time as they occur in a sequential manner.
• The delivery time varies from message to message because of random waiting times in queues and alternate routes between the same pair of entry and exit switches.
• Therefore, time relationship of the messages and their sequence are not guaranteed in a message switched network.
• As traffic increases there is increase in message delivery time; because the queues get longer and there may be congestion on the route.