The communication between the nodes in a packet data network must be precisely defined to ensure correct interpretation of the packets by the receiving intermediate and the end systems. The packets exchanged between nodes are defined by a protocol – or communications language.
There are many functions which may be need to be performed by a protocol. These range from the specification of connectors, addresses of the communications nodes, identification of interfaces, options, flow control, reliability, error reporting, synchronization, etc. In practice there are so many different functions, that a set (also known as suite or stack) of protocols are usually defined. Each protocol in the suite handles one specific aspect of the communication.
The protocols are usually structured together to form a layered design (also known as a “protocol stack”). All major telecommunication network architectures currently used or being developed use layered protocol architectures. The precise functions in each layer vary. In each case, however, there is a distinction between the functions of the lower (network) layers, which are primarily designed to provide a connection or path between users to hide details of underlying communications facilities, and the upper (or higher) layers, which ensure data exchanged are in correct and understandable form. The upper layers are sometimes known as “middleware” because they provide software in the computer which convert data between what the applications programs expect, and what the network can transport. The transport layer provides the connection between the upper (applications-oriented) layers and the lower (or network-oriented) layers.
The basic idea of a layered architecture is to divide the design into small pieces. Each layer adds to the services provided by the lower layers in such a manner that the highest layer is provided a full set of services to manage communications and run distributed applications. A basic principle is to ensure independence of layer by defining services provided by each layer to the next higher layer without defining how the services are to be performed. This permits changes in a layer without affecting other layers. Prior to the use of layered protocol architectures, simple changes such as adding one terminal type to the list of those supported by an architecture often required changes to essentially all communications software at a site.