Digital Currency News >FLOW > Upgrading Flow’s developer experience and network flexibility

Related Articles

ViewFLOWAll Articles
0
FLOW
0
Step 1: Enter the FLOW/USDT spot trading page
0
Step 2: Enter the order unit and quantity, then click Buy/Sell

Upgrading Flow’s developer experience and network flexibility

2024-09-18 22:12:32

The Flow network recently underwent an important upgrade aimed at enhancing its Byzantine Fault Tolerance (BFT) capabilities and providing a more efficient data exchange format, a new streaming API to improve the developer experience, and a significant increase in future transaction throughput. Lay the foundation. This article takes an in-depth look at each of the key updates in this upgrade.


Improve the resilience and performance of non-consensus nodes

The Flow network adopts a multi-role architecture, in which the consensus node is responsible for running the consensus algorithm and expanding the chain. However, non-consensus nodes (such as access, execution, collection, verification, observers, etc.) also need to track the progress of the chain to perform their respective responsibilities. To this end, Flow introduces the consensus follower module, which allows non-consensus nodes to follow the chain by receiving the latest blocks finalized by the consensus nodes.

In this upgrade, the consensus follower architecture has been transformed to become more efficient and have stronger BFT capabilities. Renovation content includes:

Instantly verify incoming block headers: only valid extensions on the chain are accepted for processing to ensure the reliability of the data.

Optimized synchronicity of block ranges: Improved cryptographic proof of consensus progress by validating QCs (Quorum Certificates) of only the blocks at the top of the range.

Optimize disk usage: avoid persisting potentially invalid blocks to disk and ensure that all stored blocks are valid state extensions.

Parallel processing of certified and uncertified blocks: improved processing efficiency.

Through these improvements, each node has significantly improved the core functions of consensus, bringing Flow closer to the ability to autonomously handle and respond to attack scenarios. Additionally, this provides a basis for building lightweight clients such as those running on smartphones.


Faster, more efficient Cadence data exchange

Currently, decentralized applications (dApps), wallets, and other clients use the JSON-Cadence Data Interchange Format (JSON-CDC) when conducting transactions, executing scripts, and reading on-chain data. However, JSON-CDC has some shortcomings, including data redundancy and lack of deterministic encoding methods.

To address these issues, Flow introduces Cadence Compact Format (CCF), a new data format designed to provide compact, efficient, and deterministic encoding. CCF uses CBOR (RFC 8949) for serialization and deserialization, which significantly reduces the burden of data transmission.

For example, a FeesDucted event takes 298 bytes when encoded in JSON-CDC, but only 118 bytes in CCF fully self-describing mode, and about 20 bytes in partially self-describing mode. The introduction of CCF not only improves the efficiency of data exchange, but also reduces memory usage and increases encoding and decoding speed.


Improve the way chain data is consumed

This network upgrade also introduces beta implementations of access nodes and the FLIP event streaming API. The Event Streaming API provides a new, ergonomic way to allow dApps to consume execution data (such as transaction events and account updates) through a push-based streaming model instead of continuously polling. This method effectively reduces resource consumption and improves data processing efficiency.

Support for parallel transaction execution: In the last mainnet upgrade, Flow mentioned the concept of parallel transaction execution, allowing execution nodes to process multiple transactions at the same time. This upgrade includes nearly 90 updates to the execution node, bringing it closer to fully supporting parallel transaction execution and further improving the network's processing capabilities.


New upgrade schedule

The Flow network is now on a new upgrade schedule, with only one scheduled spork per season, avoiding the frequent downtime it once required every two months. The new schedule ensures that the network will not be down for more than 7 minutes without a scheduled spork, while allowing new features and bug fixes to be pushed to all nodes more frequently.


Conclusion

This major upgrade of the Flow network marks a further improvement in its security, performance and developer friendliness. With the launch of these new features, Flow will accelerate mainstream Web3 adoption and drive the development of decentralized applications. We look forward to the positive impact of these updates and hope to provide developers with better tools and experiences.

Disclaimer:

1. The information does not constitute investment advice, and investors should make independent decisions and bear the risks themselves

2. The copyright of this article belongs to the original author, and it only represents the author's own views, not the views or positions of HiBT