Skip to main content

Welcome To Tech With Rahul :))

Hello, World!


Comments

Popular posts from this blog

Understanding Merkle Tree

A Merkle Tree is a cryptographic tree structure used in computer science and distributed systems to efficiently verify the integrity of large sets of data (accuracy and consistency of data over its lifecycle).  Merkle Tree, also known as Hash Tree is a tree of hash values.  It has a tree structure in which each leaf node is a hash of a small portion of the data, and each non-leaf node is a hash of its children. It is used in applications such as  NoSQL databases, Git, Cryptocurrencies,  File Systems, etc. Some key characteristics of Merkle Tree are: Binary Tree Structure:  The Merkle Tree is a binary tree, where each leaf node represents a hash of data. Leaf Nodes: The data set is divided into fixed-size blocks or "leaves". Each leaf node contains the hash of a specific data block or piece of information. Non-Leaf Nodes: Non-leaf nodes in the tree represent the hash of the concatenation of their child node's hashes.  If the number of leaves is odd...

Client-Server Communication Model (Part-2) - Server Sent Events

This is the second part of the Client-Server Communication Model. You can have a look at the first part  where we discussed Polling, Long Polling, and Webhooks. Here, we will focus on Server-Sent Events. 4. Server-Sent Events (SSE) Server-Sent Events (SSE) are based on server push technology enabling a client to receive automatic updates from a server via an HTTP connection. The clients make a persistent long-lived connection with the server. Then, the server uses this connection to send the data to the client. It is important to note that the client can’t send the data to the server using the SSE. It is a unidirectional way to flow data from the server to the client. The request-response flow of SSE is: The client issues an HTTP GET request to the server, with the request headers Accept: text/event-stream and   Connection: keep-alive . The inclusion of   Accept: text/event-stream  in the request informs the server that the client aims to initiate an SSE co...

HTTP Series - Part-1: (TCP, HTTP and HTTP/1.1)

Hypertext Transfer Protocol (HTTP) enables the transfer of data over the Internet. HTTP is an application-layer protocol that facilitates the transmission of hypermedia documents, such as HTML. It was designed for communication between web browsers and servers but can also be used for other purposes. I have discussed in detail about different  modes of communication between a client and a server. They all use HTTP under the hood. HTTP is a “stateless” protocol, which means each request is executed independently, without any knowledge of the requests that were executed before it. It uses the underlying transport protocol TCP (Transmission Control Protocol) to establish and manage connections between a client and a server.  Transmission Control Protocol (TCP): TCP is a connection-oriented transport layer protocol. It provides a fully duplex and reliable exchange of messages between different devices over a network. Some of the main features of TCP are: Reliability: TCP ens...