Posts

Single Page Application VS Multi Page Applications

Image
There are a lot of ways to render a webpage and they each have their own advantages and disadvantages. You might have heard of React, a popular framework for designing front-end web applications. But what you may not know, is why it is adopted by many developers. Before React, Multi-Page applications (MPAs) were commonly built using traditional server-side technologies and frameworks like PHP, ASP.NET, Java Servlets, and Ruby on Rails. These technologies allowed developers to create web applications where each page request resulted in a full reload of the entire page from the server. A prime example of such a website is Amazon where you get a page refresh on every link you click. MPAs consist of multiple unique HTML pages, where each interaction triggers a request to the server for a full page reload. While MPAs can offer a satisfactory user experience, they typically involve more page reloads and are more suitable for content-focused websites that don't require complex real-time...

Understanding Client and Server Communications

Image
Network communication plays a vital role in facilitating the exchange of data and resources between devices. But who are we communicating with? Communication is supposed to be between two people, so who’s on the other side?   When we fire up a browser or connect to a website, we establish a connection with a server, which is hosted somewhere and allows us to communicate with it. The server then sends data to the incoming receivers, illustrating the fundamental workings of a web server. This is known as the Client-Server architecture. Here a Client initiates a connection which the server then responds to . Note: A server can never initiate a connection. It ONLY listens. But communication on the internet can’t happen without some predefined rules. One of the protocols that define how data is supposed to transfer between clients and servers is called the TCP (Transmission Control Protocol). TCP ensures reliable, ordered, and error-checked delivery of data between applications runni...

Packet Switching

Image
We often don’t wonder how the data that we send to the internet is transferred from one location to the other without any errors. Suppose you’re transferring a 100MB file and during the process, you lose your connection. Now the file that you’re sending, would it have to be sent all over again? What happens if one byte of data gets corrupted during file transfer? All these scenarios are dealt with by a process called packet switching . As previously discussed,   Packets are bundles of divided data from a file that can be simultaneously sent through different routes on the internet . Different routes can transmit data at different rates, with the transmission rate of a link measured in bits/second. Packet switching is the fundamental way of transferring data on the internet. Most packet switches use store-and-forward transmission at the inputs to the links. Store-and-forward transmission means that the packet switch must receive the entire packet before it can begin to transmit...

How does the Internet work?

Image
In today's world, it's almost impossible to imagine life without the internet's constant presence. Whether it’s for work, education, or personal use, the internet has become the go-to tool for everyone everywhere. But have we ever stopped and wondered, how the internet actually works? When I send a msg to my friend asking him when he’s going to pay me back for the lunch we had yesterday, he instantly receives the message if we’re connected to the internet (although he may choose to ignore it). The internet is a vast web of networks that allows signals or data to travel. Let’s use an analogy; think of a railway network and the trains are the messages/data that we send and each destination is a user. In the same way, all of us are connected to each other through the internet and all of us can communicate with each other via the “train track”. AND there are multiple ways to reach a destination and figuring out which way is efficient is the fundamentals of Computer Networks...