Closed xxo1shine closed 1 year ago
The decoupling of assets in the account model will certainly be a big step forward for the Tron network which will make possible the processing of many more transactions by blocks in the time interval of 3s used by the validators on the network.
Let's push forward!
A good enhancement. Happy to proceed 👍🏻
Seems like a good enhancement, but I'm curious if it will have any affect on the trongrid or tron web APIs? I use both extensively, so would just like to know if I'll have to make some changes to my code (which is fine).
Seems like a good enhancement, but I'm curious if it will have any affect on the trongrid or tron web APIs? I use both extensively, so would just like to know if I'll have to make some changes to my code (which is fine).
Compatibility processing has been done and will not affect any api interface.
If the data availability is assured, why not? It possesses considerable system performance now for the assets tx. This definitely would help. Need more detail about the new structure that the assets data goes to.
All the data provided shows that this is a step in the right direction. Have any negative consequences been observed?
Thanks to everyone's contribution to this proposal. This issue will be closed as it is already going to effect, check detail at: https://tronscan.org/#/proposal/74
Simple Summary
Remove assets from account data structure and store them separately to improve system performance. For more details, please refer to: TIP-382.
Motivation
In the process of executing the transaction, most of the time is spent in the deserialization operation of the account. It is caused by the account asset list being too large. Some accounts have thousands of assets. During the deserialization process, it takes a lot of time.
In order to improve the performance of the blockchain, increase the TPS, it is necessary to reduce the transaction execution time, so it is necessary to optimize the data structure of account assets.
Timeline
Any opinions or discussions about this proposal are welcomed in the next two weeks.
The estimated timeline
Hi @TronSpark @fbsobreira, would you please help to raise a proposal to activate it. Thanks a lot.
How to Initialize the Voting Request
Background
According to the latest online statistics, there are currently 79,185,490 accounts and 6,595 assets. The statistics of the number of account assets are as follows.
Through the performance analysis of the flame graph, it can be seen that the deserialization of the account takes a lot of time. Randomly select a batch of accounts, and perform 10,000 deserialization of complete data and clear asset data respectively. The analysis results are as follows:
It can be seen that the performance of the deserialization operation of the account data is improved by more than ten times after the assets are cleared.
Performance Test
Tested under 3 different pressure models and got the results of the performance test
Pressure Model 1
Test Results:
Pressure Model 2
Test Results:
Pressure Model 3
Test Results: