The Top Most Layer : Application Layer

computer networking in application layer

The Application Layer is the 1st layer in the TCP/IP stack according to Top-Down Approach. The Computer Applications are the main reason behind the existence of the computer networks. If there wouldn’t have been any Application, then there was no need of any transport or networking protocol, that support these applications. After the Internet came into existence , number of useful , entertaining and applications have been developed and still the procedure is on.

Beginning from the text based applications, such as text mails, file transfers, further e-commerce websites and the world wide web. Now from the last couple of years , number of voice and video conferencing applications are developed. Such as , For android, there are two voice chat applications , We-chat and LINE. Video applications like Skype, Gmail video conferencing etc. are being developed.

There has been no slowing down of dashing and super applications to be developed. And I hope, you can also create a killer application for your future generation.

Application Layer and its applicationTo begin with the further discussion , I want to tell you one more thing. Before developing an application, you should have a basic understanding that how the programs on the different hosts communicate with each other. In computer networks, its not the programs but the the processes that communicate with each other. A process can be termed as the subset of a program, that is running within a system.

Processes on two different hosts communicate with each other by exchanging messages across the computer network. A sending process creates and sends messages into the network a receiving process receives these messages and responds by sending messages back. So you remember this, throughout your network study, that processes communicate. Two processes on same hosts communicate via Inter-process Communication. So now you are ready and we should move on.

Aspects of Network Applications:

 Now you must also be thinking of developing a new application. Either the application is good for your country or is a video game for children. Whatever may be the reason or motivation behind your development. But there are many principles that you have to learn, in order to convert your idea into a real world application.
 

You have to develop an application that should run on different hosts and can interact with each other over the network. For Example: In Web applications, there are two processes that interact with each other. A Web Browser process running on the Client or user’s side(can be a desktop, laptop or ipad) and a Web Browser process running on the on the Server side. 

 Therefore, while developing a new application , you should always take into consideration, that it must be capable of running on multiple different hosts or end systems.
 

Architecture:

 There are basically two Application architecture that you can use for communication between hosts. These are: Client-Server Architecture and Peer-to-Peer Architecture (P2P).
 

                  1. Client-Server Architecture

 There is a always a server, which responds to requests from other hosts, called clients. For Example: The Web Application. In this this is a Web Sever that is always ON, that responds to request from browsers running on client systems. 

 Briefly we can say that, a process that initiates the communication is Client. The process that waits to be contacted is a Server.

introduction to application layer

 

Characteristics of Client-Server Architecture

1. Two clients never communicate directly with each other. For Example: Two browsers never communicate directly.

 2. The Server has a well known address that is known as IP address in networking. The IP address of Server is always fixed. Because of this feature, the client can any-time contact the server by sending a packet to its IP address.
 

Some Examples of Client-Server Architecture Applications are E-mail, FTP, Telnet etc.

 
Problems with Client-Server Architecture

Many times, a single server is incapable of responding to all he requests of the clients. For Example: A Google server gets millions of requests every second, So its impossible for it to respond from a single system. To overcome this problem, the Data Center, combination of large number of hosts, is formed. Data Center is a virtual Server that is a combination of 1000’s of servers that works as a single host. That’s why they are called virtual server. Companies such as Yahoo, Google, Facebook have one or more data centres.

 

                  2. Peer-to-Peer Architecture (P2P)

In P2P Architecture, the end systems directly communicate with each other known as peers. Much of the Peers are not owned by the Service provide but, infact owned by the users. These peers can be at houses, offices or universities. Since the users communicate without passing by a dedicated sever, this called as P2P sharing. Examples of such Applications is Bit Torrent, that relies on the peers. Another example is Skype.

peer 2 peer architecture in computer networks

 

Characteristics of P2P Architecture

It is self-scalable. As the users are directly communicating , so they don’t have to depend on the server for space scalability and bandwidth. This is the most promising feature of P2P Architecture.

Problems with P2P Architecture

Security is the major drawback of this architecture. As there is no dedicated server for communications.

******* There is also a 3rd type of Architecture that is a combination of both Client-Server Architecture and P2P  Architecture. This is known as Hybrid Architecture. It is used in the cases, where you need the address of the two communicating hosts but after that, both the host will communicate each other. A very good example of this is Instant Messaging.********


What you do in Instant Messaging is that you register yourself with a server. Like you register yourself with a website named Facebook. But after registering, you directly chat with your your friends and relatives. And they can reply you back. In such applications, the use of Hybrid Architecture is essential.******

  • Interaction Between Processes and Computer Networks

There are always two processes that are communicating with each other. Every process that wants to send message to other process has to send through the underlying network and underlying networking layers. A process sends and receive a message from the network through a device or a software, called as socket.


Let me give you an example , so you clearly understand what a socket is. 

Suppose you want to send a message to your friend ( say James). Here you are the process. Now what will you do. You will write a message and put into an envelope and will go and open the door, so that you should give this envelope to the postman who can deliver your envelope to your friend. Here your house door is the socket and the postman and the post-office are the underlying network and the networking layers. In the same way, the network will deliver the envelope to your friend , through his house door. There your friend is process and the door is socket.


Let us now try to explain it by drawing a figure.

process communication socket

As it is shown in the figure, the two processes communicating over the Internet. The Socket is the Interface between the Application Layer and the Underlying Transport layer, so it is also called as Application Programming Interface (API) . Since Socket is the API software with which the network applications are built. The Application developer has full control over the application side socket. But he doesn’t have control over the transport layer side socket. On Transport Layer side socket, he can only control 2 things , that are

1. He can chose the type of protocol to be used, if choice is available and 2. He can set the maximum size of buffer or queue. And after choosing the protocol by the Application Developer, the Application is developed using the services provided by transport layer protocols.

Ques : How to Determine the Address of the Processes ??

 If you want to send a parcel to someone, than that parcel should have your as well as the destination Address. In the same way, in computer networks, to send a packet to a host, the address of the destination host should be known. For identification of the receiving process, two things should be known. 1. Address of the host. 2. An identifier that specifies the receiving process in the destination host.
 

In Computer Networks, Inspite of having alphabetical addresses, hosts have IP address. I will tell you about IP address in detail in the coming posts. Till now, you should only remember that IP address is a 32-bit quantity that is a address of a host.Except the address of the host, the sending process should also know about the receiving process. Because in reality, there are many processes or applications running on a single host. For example, you could be running an email application , a Web application, a FTP application on your system. So to serve this purpose, PORT NUMBER is used. A particular port number is given to every application.

For a Web application , port number 80 is assigned, for an email application , port number 25 is there. So these are the two basic things that a sender process should know about the receiver process.

 You can found port numbers of different Internet Protocols by visiting this link. IANA
                                       

Thank you for reading this article.

This was from us on Application Layer. Do you have something to put spotlight on ?

Raman Deep Singh Chawla

Raman Deep Singh Chawla

Raman is the founder of FitnyTech . He is a fitness App Developer and a Blogger. He is fond of his fitness and sports. He has great passion for Cricket , Tennis , Soccer and Table Tennis. In his free time , he loves to learn about technology , write about it , share his thoughts with others. His passion for technology can be seen at his blogs.

More Posts

Leave a Reply

Your email address will not be published. Required fields are marked *