Understanding Latency and Throughput in Embedded, Computer, and Blockchain Networks
Understand the critical roles of latency and throughput in embedded, computer and blockchain networks. Learn how they impact network...
Understand the critical roles of latency and throughput in embedded, computer and blockchain networks. Learn how they impact network...
Latency and throughput are two terms frequently found in discussions of computers, distributed, and embedded systems. The time taken to process and transmit data from one point to another is reflected in the use of these terms when describing the speed of a system.
This blog will investigate the meaning of latency and throughput and how they affect the rate at which data is transferred and processed within the context of blockchain, computer, and embedded systems (considering we use both computer and embedded systems in our day-to-day lives and hence it will be easier for you to understand how latency and throughput impacts a linearly scalable blockchain like Shardeum)
Whenever there is a lag in an instruction or signal, we say that there is latency. There may be a lag in either the transmission or processing of data. One form of latency is disk latency, and another is network delay. Latency in a network is the amount of time it takes for data to travel from its origin to its final destination.
To illustrate network delay, let’s say a computer in one network establishes a connection with a computer in another network located far away. There will be a delay in setting up the connection due to the numerous nodes in between the origin and the final destination.
The other kind of delay is disk latency. This is the amount of time that passes between when data is requested from a storage device and the data begins to be received. Additionally, seek time and rotational latency are two aspects related to disk delay. Solid-state drives (SSDs) don’t rotate like regular hard drives (HDD). Because of this, SSDs have less latency.
Latency is fundamentally common for embedded, computer, and distributed systems with minor iterations. Latency in a blockchain typically means the total turnaround time between submitting a valid transaction to the network and the time network has committed to/confirmed the transaction. On Shardeum for instance, both the latency and finality time will just a few seconds as a result of its linear scalability through transaction level consensus and dynamic state sharding.
Data throughput measures how quickly information can move from one point to another. It’s useful for monitoring the speed of RAM, hard drives, and even network connections.
System throughput, also known as aggregate throughput, is the total data rate that is transmitted to all network terminals simultaneously. The actual data transfer speed, however, may be less than the theoretical maximum due to factors including connection speed and network traffic.
Network throughput, especially in the context of communication networks, is the proportion of attempted messages that are successfully delivered.
Communication network throughput is often measured in bits per second (bit/s or bps) and data packets per second (pps) or data packets per time slot. Moreover, the throughput of a communication system is affected by the analog physical medium (say your data provider), the available computing power of the system components (your PC/laptop), and the actions of the end users.
Throughput fundamentals and limitations are also common for embedded, computer, and distributed systems/blockchains with few nuances which we will take a look at here. Throughput in blockchains typically means transactions per second (TPS) processed by a blockchain network. Transactions, here, refer to those submitted by end users. Throughput ideally should not include failed transactions or internal operational transactions processed by the network. Unlike Web2 platforms, public blockchain platforms secure their network by adding a couple of resource-intensive protocols – consensus mechanism and block size/rate limit and hence TPS of blockchain networks vary depending on how they use these protocols.
For instance, networks that use proof-of-stake consensus would be much faster than networks that used proof-of-work since the node’s processing power is not being used up by proof-of-work computation. Ideally, the rate at which the network processes transactions should be proportional to the number of nodes in the network. But that barely happens in a blockchain network due to network congestion, and vertical scaling as opposed to horizontal or linear scaling. As a result, most blockchain networks in reality process between 5 and 400 TPS at the maximum while the web2 peers like Mastercard and Paypal process up to 5000 TPS! Shardeum, which scales linearly, is aiming to achieve 1 million TPS or more.
The throughput and latency of a network are its two key performance indicators. Both throughput and latency can be affected by a number of external variables.
High throughput indicates better performance, as more data can be transmitted in a shorter amount of time or more transactions processed per second in the case of a blockchain. Low latency indicates better performance, as data can be transmitted more quickly or in the case of blockchain, the time taken to validate and confirm a transaction on the network is quick.
Throughput is considered important for applications that require high data transfer rates, such as video streaming, file transfers, online gaming, and blockchain dapps. Latency is important for applications that require real-time communication, such as video conferencing, online gaming, voice over IP (VoIP) calls and blockchain dapps.
The performance of a network, or computer system relies heavily on latency and throughput. They can both speed up or slow down a system in their own unique ways as we saw in the above paras. They are also very crucial for distributed ledgers like blockchains which are now put to use 24x7x365 by products and services rendered in a peer-to-peer model by dapps/Web3 projects while removing intermediaries.
Edits: Latency/Finality time is updated for clarity and accuracy on 16th Sept 2023.
Best Blockchain Bridge | Pros and Cons of Blockchain Technology | Blockchain Features and Benefits | Blockchain Scalability | What is a Governance Token | Benefits of Blockchain | Physical Layer in OSI Model | What is Proof of Stake in Sharding | Cryptocurrency Faucet | Blockchain Vs Quantum Computing | What is a Cross-Chain Bridge | How to Connect EVM Network to Metamask | What is Consortium Blockchain | Decentralized Identifiers | EVM Wallet Types | What are Blockchain Layers | Advantages and Disadvantages of Decentralization | Best Crypto Faucets | Best Blockchain Explorers | Best Crypto Exchanges | Defi Hacks | Difference Between Cryptocurrency and Blockchain | Layer 1 Blockchain | NFT Tracking Tools