Bluzelle has an all-important crypto-economic system baked into its blockchain. The economic system provides rewards, known as “block rewards”, to responsible suppliers to the network. Conversely, consumers of the network pay for its use by using “gas”, which is bought and then immediately expended in the form of a fee. More specifically, to do a certain operation that costs X gas, that much gas is bought at the time of the operation at the specified gas price (expressed in BLZ / gas), and then the gas is “used” by the network. The BLZ paid to buy this gas is called the fee.
These fees ultimately percolate into the system and most of the fees are paid to suppliers as block rewards. A small portion of the fees are collected as “taxes”, on every transaction. The proceeds of these taxes are put toward the network development fund, for managing and upgrading the network. Both gas fees and taxes are applied using unique formulae tailored for the Bluzelle environment.
Gas and taxes are only applicable for transactions. Queries are always free of any charges.
As mentioned above, gas is required to perform any transactions on a Bluzelle blockchain network. The gas can be compared to the amount of “energy” required to do a certain task. More complex or long-running tasks or tasks that take up more resources (in space and time) will require more gas. Gas is bought at the specified gas price, paid for with BLZ, and the gas is immediately used when the transaction is sent.
Since Bluzelle is a database at its heart, we will go through an example of how much gas is required to store data to the database, using a “create” function.
When you store data to Bluzelle, you need to specify the length of time that the data will persist for. Once that time has elapsed, the data is purged, unless the data was renewed or deleted already. The length of time is specified typically in the # of blocks, but we have interfaces to allow the time to be specified in other units like seconds, etc. This length of time is tied to the “lease” for the data.
The lease is a cryptographic contractual agreement between the user of the database, and the blockchain itself, that guarantees that in return for the gas expended to create that data, the data will be stored securely and be highly available to the user for the length of time of that lease.
The most important factor here is the “Gas per DayByte”. The “DayByte” refers to one byte being stored for one day. So, “Gas Per DayByte” refers to the amount of gas units for each DayByte. “Gas per DayByte” is a rate.
*Note: 1 BLZ = 1,000,000 µBLZ
Gas per DayByte: 2.5 gas / DayByte.
# of Bytes to Store: 1,000,000.
# of Days to Store for: 10 days.
Gas Price: 0.002 µBLZ / gas.
Total Gas Required: 2.5 x 1,000,000 x 10 = 25,000,000 gas
Cost: 25,000,000 x 0.002 = 50,000 µBLZ = 0.05 BLZ
Following is the general formula used for calculating the “Gas per DayByte”:
While the constants in this formula are only an example and can vary from what is used in practice, what is important to note is that “x” is the length of the lease. Shorter leases are more expensive in terms of Gas required, but there is a sudden drop in “cost” as the lease value “X” gets bigger. Super long leases will approach a certain absolute minimum (in the formula above, that minimum is 10). This formula has the following desirable qualities:
The marginal extra cost for longer leases is reducing. So it is highly desirable and attractive to store data for longer. This is a fundamental economic property that applies in real world economies, where there are cost advantages to buying “more”.
The gas cost tends downwards and approaches a certain minimum for super-long leases. This encourages and supports the idea of storing data for long periods of time, or even forever. Indeed, Bluzelle can be used as a permanent data archive.
Looking at the following graph, notice how the gas cost (Gas per DayByte) drops quickly and flattens out, when graphed against the length of the lease, in days. Bluzelle is architected to support leases of all lengths, but provides strong economic advantages to those who store for longer.
Tax rates are governed by the tax collector entity. Tax collection is baked into the blockchain, and applied automatically on every transaction processed by the blockchain. The tax collected is used to support the ongoing development and maintenance of the Bluzelle Network.
Bluzelle carries two forms of taxes: Fee Taxes and Transfer Taxes.
The fee tax is applicable directly on the total amount of fees (see previous section) charged for a transaction. The fee tax percentage is taken from the total fees, so the total fees do not increase due to fee taxes. After the fee tax is deducted, whatever remains is added to the total fee pool collected that is distributed as part of the block rewards (see our previous blog post on block rewards). Fee taxes are invisible and never seen by the user issuing the transaction (there is no extra fee charged for the tax). Rather, the amount of total fees that percolates down to the validators and delegators is reduced to account for the fee taxes deducted.
Example:
Let’s use the following assumptions:
*Note: 1 BLZ = 1,000,000 µBLZ
This is a non-transfer transaction, so no transfer taxes are applicable.
Fee Tax Rate: 10%.
Gas Price: 0.002 µBLZ / gas.
Total Gas for TX: 200,000 gas.
Total Fee: 200,000 gas x 0.002 µBLZ / gas = 400 µBLZ
Fee Tax Collected: 10% x 400 µBLZ = 40 µBLZ
Net Fees distributed as Block Rewards: 400 µBLZ — 40 µBLZ = 360 µBLZ = 0.00036 BLZ Net Debit of BLZ from transaction sender’s account: 400 µBLZ
The transfer tax is only applicable on transfers of BLZ tokens between accounts. For all other transactions, no transfer taxes are applicable (only fee taxes). Note that fee taxes are also applicable to transfers.
Transfer taxes are calculated based on the amount being transferred and are applied ON TOP of the total gas-related fees applicable for the transaction. Transfer taxes are not part of gas fee estimates, and are charged above and beyond the gas fees. As such, a transfer transaction will only succeed if the account it is sent from has sufficient BLZ for both the gas fees and the transfer tax. If there is not sufficient BLZ to cover both the gas fees and the transfer tax, the transfer will fail. The user is responsible to be aware of the transfer tax, ensure sufficient funds are available to cover it, and should expect it to be charged on all transfers.
Example: (for completeness, we will include the fees taxes here too)
Let’s use the following assumptions:
*Note: 1 BLZ = 1,000,000 µBLZ
Transfer Tax Rate: 0.1%
Fee Tax Rate: 10%.
Gas Price: 0.002 µBLZ / gas.
Total Gas for TX: 200,000 gas.
Total amount being transferred: 1,000,000 µBLZ
Total Fee: 200,000 gas x 0.002 µBLZ / gas = 400 µBLZ
Fee Tax Collected: 10% x 400 µBLZ = 40 µBLZ
Net Fees distributed as Block Rewards: 400 µBLZ — 40 µBLZ = 360 µBLZ = 0.00036 BLZ
Transfer Tax Collected: 0.1% x 1,000,000 µBLZ = 1,000 µBLZ
Total Taxes Collected: 40 µBLZ + 1,000 µBLZ = 1,040 µBLZ
Net Debit of BLZ from transaction sender’s account: 400 µBLZ + 1,000 µBLZ + 1,000,000 µBLZ = 1,001,400 µBLZ