Versioned Transactions of Solana

in hpl •  last year 

Versioned Transactions is a new feature on the Solana blockchain that allows for more flexibility and functionality in transactions. It was introduced in October 2022, and is still under development.

dda_v2.png
Image: Versioned Transaction of Raydium

https://docs.solana.com/developing/versioned-transactions

Versioned Transactions works by adding a new version number to each transaction. This version number indicates which version of the Solana runtime the transaction is compatible with. This allows for new features and functionality to be added to the Solana runtime without breaking existing transactions.

Versioned Transactions also allows for developers to create custom transaction formats. This can be useful for applications that require specialized transactions, such as NFT transactions or DEX transactions.

There are two main benefits to Versioned Transactions.

  • Flexibility: Versioned Transactions allows for more flexibility in transaction development and deployment. Developers can now create custom transaction formats and add new features and functionality to the Solana runtime without breaking existing transactions.
  • Scalability: Versioned Transactions can help to improve the scalability of the Solana blockchain. By allowing for custom transaction formats, developers can optimize transactions for specific applications. This can help to reduce the size and complexity of transactions, which can lead to faster transaction processing and lower fees.

Here are some examples of how Versioned Transactions can be used.

  • NFT transactions: Versioned Transactions can be used to create custom NFT transaction formats. This can be useful for applications that require specialized NFT transactions, such as fractionalized NFT transactions or NFT lending transactions.
  • DEX transactions: Versioned Transactions can be used to create custom DEX transaction formats. This can be useful for applications that require specialized DEX transactions, such as multi-leg DEX orders or DEX swaps with multiple tokens.
  • Game transactions: Versioned Transactions can be used to create custom game transaction formats. This can be useful for applications that require specialized game transactions, such as in-game item transactions or in-game currency transactions.

Versioned Transactions is a promising new feature that can help to improve the flexibility, scalability, and functionality of the Solana blockchain.

Two Types of Transactions that The Solana Runtime Supports

  • “legacy” - the older transaction format with no additional benefit
  • “0” - this version added support for Address Lookup Tables

Developers will need to update their client-side code to prevent errors due to different transaction versions.
All RPC requests that return a transaction should specify the highest version of transactions they will support in their application using the 'maxSupportedTransactionVersion' option.

An RPC request will fail if a Versioned Transaction is returned that is higher than the set 'maxSupportedTransactionVersion'.

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE BLURT!