How a Client-Server relation works


To explain a Client-Server relation at its core, think of the client as the user and the server as some kind of provider. The client asks the provider to provide. This guy, I have summed up the entire client-server relation. But to go into depth, there is a lot more than just the client asking and the provider providing. In today's article, we are going to make sure that you (the reader) can grasp the absolute basics of a client-server relation. Then we will build on that knowledge and will explore the networks in ever more depth. Now I would ask you, the readers, to hold my hand and embark on this journey of exploration, knowledge, and technology. The reality is that the concepts we are going to be exploring today are completely abstract, and to grasp abstract concepts we have to sit with a clear mind and a clear conscience; only then can you expect to comprehend abstract concepts. Now, with a clear mind and a clear conscious lets embark on this journey!

Who is a client?

A client could be you, your browser, or anything that requests something from a server. Suppose you want to search for something or open a website on Google. You write the domain of that website, for example, topicgems.com, now our browser-client, " Chrome " will send a request to the server to fetch this website's homepage. The website will appear, and we will be able to see its homepage. This is how a client speaks with a server (not going into depth here because, in depth, the concept differs slightly from what I said).

What is a server?

The entity that responds to a client's request is what we call a server. A server, you can say, is a warehouse of data; it's filled with websites- a whole sea of them. A server knows everything about a website being hosted on it. You use your browser client to search for something; it opens up but a whole background process occurs where your browser client speaks to the server and requests it to fetch the required information. Also, a server can talk to many other servers this is how modern websites work.

How do they speak with each other?

See, clients and servers do not speak like typical people. It is not a conversation to be specific. It is more like requesting something and providing it if it is there. There is not a detailed conversation like " how you doing mate! " and the server being like " yo I'm good homie ". They do not speak like normal individuals, but beware: a language is used; that language is the medium of their conversation. That language is what we call a protocol. The protocols you can expect over the World Wide Web are " HTTP " or "HTTPS ". This is the language that is used in the conversation between the client and the server. But over the next articles you will realize that the language they speak is just so intuitive, and in exploration it is just wonderful. I, writing this, can not wait to reach that part where I explain the conversation through methods! Oh wait! I dropped a spoiler; I must beg your forgiveness.

HTTP/HTTPS

See, HTTP stands for Hypertext Transfer Protocol. As I explained above, this protocol is followed when a client speaks with a server. To further explain it, HTTP is a collection of commands that every client uses to communicate with the server. HTTPS, on the other hand, provides a secure way of communication between a client and a server. I kind of tried to shift this into cybersecurity; well, do not worry about that. Articles about cybersecurity will also keep on coming. As I explained before, we are going to keep on uploading articles on multiple topics.


Explaining the communication

We are going to explain this by an example of a person ordering a Pizza from a Pizza place.

We have a guy named Bob and another guy named Hash.
Bob asks Hash to bring him a Pepperoni Pizza from Chopper's Pizza place. Hash drives there and arrives at the takeaway section, orders the pizza, and brings it back to Bob.
This is called a client-server interaction.

In this, Bob is a Client
Hash is a Client-Browser
Choppers Pizza is the server
The takeaway section is the port
And the location of the Choppers Pizza Place is the DNS.

Request and Response

Now the thing to be emphasized is the fact that Bob did not actually ask Hash for the Pizza. He asked Hash to bring the Pizza from " Choppers Pizza Place". If Bob had asked Hash for a pizza, Hash would have been confused, and no one would have gotten in. And if the flavour it told Hash was not a part of the menu, then we have another error.

In Client-Server terms.

A Client needs to make a proper request for a proper response and to the right server. If the request is not proper or if the address is not proper, then we will be shown an error.

Conclusion

See once again, these are very abstract and hard-hitting concepts. If I were to explain even more core concepts, most of the readers would have lost interest due to confusion. So let's not rush it; give it its proper time, and then we can expect the best results. In the next article, you can expect terminologies like DNS, IP, ports, and more to be brought up. I will also explain the domain name of the server and multiple other concepts. But trust me, if you were able to grasp the concepts above, you will be able to grasp those in the next article as well. This is going to be our starting article for this new " Networking series ". Along with Cloud Computing and Cybersecurity, this will be the third category I am going to write on. I am Abdullah Zahid, a technology enthusiast, and this was my take on CLIENT-SERVER RELATIONS.


Post a Comment

Previous Post Next Post