Title: Updated Base Fees
Summary
I had written an article about base fees and how the base fees should look depending on the cluster size.
I want to hear from the community about their opinion. There are multiple approaches to change the base fees.
→ Constant base fees
→ Linear base fees
→ Brackets based base fees
→ Exponential base fees
I will explain the pros and cons of each in a few words.
Why change base fees ?
Currently, base fees are constant 5000 lamports / signature. So cost of executing transaction on the cluster is measured in SOL than in USDC. If SOL becomes more expensive, then it will be more expensive to execute transactions for the user, while if SOL becomes less expensive, then it will be harder for the validator to keep running the cluster.
The base fee is constant and is not based on the block space used by the transaction. So user pays the same base fee if they execute transactions consuming 10K CUs, 100K CUs or a million CUs. Base fees should consider the resources used to execute the transaction on the cluster. This makes everyone send transactions requesting the maximum CU possible of 1.4 million CU. If transactions are not correctly estimated for consumed CU, the scheduler finds it difficult to schedule the transactions and fill the block completely, wasting some of the block space.
By changing the base fees based on CU requests, we can calculate the resource usage in CU appropriately and charge the user based on resource utilization.
Who will control the base fees
The base fees could be controlled by DAO or Multisig, giving them control over one or multiple variables. Various communities, validators, and developers can be part of the DAO. The current proposition does not consider this part, as it could be figured out later.
Requirement of new base fees
-
Should be based on resources used by the transaction.
-
Optionally discourage spamming.
-
Optionally encourage optimization of code by the programs.
-
Should be in interest of “most” of the community. (i.e should not be too expensive for user nor punitive to run a validator)
In general we have to find a middle ground to encourage dapp devs to write optimized programs, for users to send transactions with better estimates for resource use at the same time not discourage existing users to use Solana. It should also encourage validators to pack the block the fullest i.e consuming 48 M CU.
Impact
This proposal Validators, Dapps and everyone who uses Solana cluster to send and execute transactions.
New Base Fees
Constant base fee
Formula:
Base Fee = constant value
Pros:
- Easy to calculate fee for transaction.
- Already implemented just need to update the constant value.
Cons:
- Does not discourage spamming of network.
- Does not discourage large transactions consuming lot of CUs.
- Does not encourage optimization of the programs.
- Does not represent resource utilization.
Linear base fee
In this model base fee will be linearly dependent on the CU requested with a minimum floor value of the base fees. The rate at which base fee will increase will be called rate of change of base fees or just Rate
.
Formula:
Base Fee = round(max( Minimum Base fee value, Rate * CU requested ))
Pros:
- Relatively easy to calculate.
- Encourages optimization of programs.
- Encourages sending transactions with proper CU estimates.
- Rate can be controlled by DAO or MultiSig.
- Rate can be changed according to SOL/USD oracle price.
- Depending on MinValue, can incentivize validator to prioritize smaller transactions.
Cons:
- Hard to find correct Rate which will please everyone.
- Lower value of rate will not discourage sending of large transactions nor encourage program optimization.
- Higher value of rate may discourage users away from solana.
Bracketed base fee
Formula:
Base Fee = (0 to bracket_1) * rate 1 + (bracket_1 to bracket_2) * rate 2 …..
Pros:
- Relatively easy to calculate.
- Encourages optimization of programs.
- Encourages sending transactions with proper CU estimates.
- Can disincentives sending of large transactions.
Cons:
- Any multisig or DAO will have multiple parameters to set.
- Can have some weird behaviors.
- May need some different burning rates for different rates.
Exponential base fee
Consider a multiplier multiplier
that has to applied to a certain CU CU multiplier
(i.e we want transaction requesting 1 million CU pay 5 times the minimum value then multiplier is 5 and CU multiplier is 1 million).
Formula:
Base Fee = round( Minimum Value * multiplier ^ (CU requested / CU multiplier) )
Pros:
- Encourages optimization of programs.
- Encourages sending transactions with proper CU estimates.
- Rate can be controlled by DAO or MultiSig with 3 params.
- Rate can be changed according to SOL/USD oracle price.
- Will disincentivize spamming and heavy transactions.
- Incentivizes sending of smaller transactions.
Cons:
- Relatively hard to calculate.
- Will make users to split transactions doing multiple instructions into multiple transactions.
- Need to update burn rate so that validators do prefer executing heavy transactions.
- Relatively hard to get consenseus over the variables.
As a community I would like to have your opinion .