Collateral and emission
Driving the collateral queue, and putting your own ERG and LIT into it.
The emission block covers two different jobs that share a timer. The first is driving the queue,
which every client does and which costs only transaction fees. The second is joining the queue with
your own funds, which locks ERG and LIT until a miner spends the box, and which ships off.
This is maintenance that runs whether or not you ever mine a block.
Driving the queue#
| Setting | Default | Range | What it does |
|---|---|---|---|
emission.enabled | true | true or false | Drive the collateral queue at all |
emission.queueInterval | 240000 | 1000 to 3600000 ms | How often to look at the head of the queue |
emission.maxQueueSpends | 4 | 1 to 128 | Emission spends chained in one pass, which is how deep into the queue a pass reaches |
emission.queueScanLimit | 500 | 1 to 100000 | Queue boxes paged through when looking for the head |
emission.txFee | 1000000 | The network minimum fee to 1000000000 nanoERG | Fee on emission transactions |
Activating the head of the queue turns a waiting position into a live collateral box, which is what keeps collateral boxes available for everyone to mine against. Clearing removes a box whose lender key is already active and which would otherwise hold the whole queue still.
Both are permissionless, and clients are encouraged to keep this on so that pool liveness is mainained.
txFee is floored at the network minimum because a transaction below it will not relay.
Queue work in your own blocks#
When you mine with inserted transactions on, your block also carries queue spends without a fee, built from the confirmed chain. The following setting caps them:
| Setting | Default | Range | What it does |
|---|---|---|---|
emission.candidateActivates | 5 | 0 to 100 | Activates your block carries when there is no Clear to take |
What your block carries depends on what is already waiting in the mempool, as the following table shows:
| Waiting in the mempool | Your block carries |
|---|---|
| No queue spend | Activates up to candidateActivates, for one block. A block later the queue pass sends them with a fee instead |
| Anything, with a Clear within reach | Every queue spend up to the emissions source's maxTxs, replacing what is waiting |
| Only joins | Nothing. The queue pass runs straight away, so its Activates follow the joins |
| Other queue spends | Nothing. Your node adds the waiting ones to the block itself |
A Clear pays whoever builds it the forfeited queue box, about 2.9 ERG plus its permit. That is why your block takes one even when another client has already sent theirs. Joins waiting in the mempool are left out of that block, and their clients send them again. Nobody's principal is at risk.
While the active set is still filling, each Activate takes about 7 KB of your block. That is why
candidateActivates sits below the emissions source's maxTxs of 20, which Clears may fill.
Chaining off the mempool#
The following setting decides how far a queue pass looks into the mempool:
| Setting | Default | Range | What it does |
|---|---|---|---|
emission.maxChainDepth | 16 | 0 to 4096 | Unconfirmed spends of the emission box to follow |
Queue passes always build on the newest emission box, confirmed or not. Following the unconfirmed spends behind it is what lets a pass activate queue boxes that joins still in the mempool created. Boxes further along the chain are not seen until they confirm.
The unconfirmed spends being chained onto belong to other lenders. A queue pass chains onto them and never replaces them in the mempool.
Lending your own funds#
| Setting | Default | Range | What it does |
|---|---|---|---|
emission.autoCollateralize | false | true or false | Put your own ERG and LIT into the queue |
emission.collateralizeInterval | 900000 | 1000 to 86400000 ms | How often to check whether more collateral is wanted |
emission.maxJoinsPerRun | 5 | 1 to 128 | Queue boxes created in one pass |
emission.maxOwnCollateral | 10 | 0 to 2000 | Your boxes live at once, across the queue, live collateral and the active set |
emission.maxLenderKeys | 32 | 1 to 1000, and at most node.numAddresses | Wallet addresses dedicated to lending |
emission.maxPermitPerJoin | 40000000000000 | Any positive value, in LIT base units | The most LIT to post as a permit on one box |
emission.priorityFeeNanoErgs | 0 | 0, or 1000000 to 3000000000 nanoERG | ERG each position adds above the 2.915 ERG floor, to be spent sooner |
What a position costs#
Each live box locks 2.915 ERG plus its permit until a miner spends it. So maxOwnCollateral is
your total exposure ceiling, not a throughput setting: at the default of 10 you can have about 29 ERG
plus ten permits committed at once.
maxPermitPerJoin is a price you are willing to pay, not a fee. The permit rises with the queue
backlog, from a floor of 2,000 LIT toward a ceiling of 40,000. When the thermostat passes your cap, the
run stops rather than paying it. The default is the protocol ceiling itself, so out of the box price
never blocks a join.
The value is in base units at 9 decimals, so 40,000 LIT is 40000000000000.
Paying for priority#
A miner who finds a block spends the collateral box that pays them most, so a position that offers
more is spent ahead of the ones that offer nothing. priorityFeeNanoErgs is that offer, for the
positions autoCollateralize creates. A join from the web panel sets its own. Each position then locks
2.915 ERG + priorityFeeNanoErgs, and when a miner spends it the fee divides as follows:
| Share | Goes to |
|---|---|
| One fifth | The miner who spends the box |
| Four fifths | The rollup that block opens, paid to every miner who submits to it |
Because transaction fees in a Lithos block go to the lender, paying for priority works like a fee future: you pay to be spent sooner, for example when you expect the blocks ahead to carry high fees.
A position that offers nothing is still spent eventually. Miners running this client draw any box
that has been live for 7200 blocks, about 10 days on mainnet, ahead of every priority fee. Each miner
can change that age with
stratum.candidate.clearanceAge, so treat it as
typical rather than guaranteed.
0 posts at the floor and offers nothing. Any other value must be at least 1000000 (0.001 ERG), so
the miner's fifth is worth more than the output it arrives in.
One key per box, and why it matters#
The active set holds distinct keys. One live box needs one address, and a key already in the set produces a box nobody can activate.
Startup checks the pair and names the value to raise:
emission.maxLenderKeys
64 exceeds node.numAddresses (32). Addresses past index 31 would receive funds this
client cannot sign for. Raise node.numAddresses to at least 64Next steps#
- Wallet and consolidation: where the ERG for these transactions comes from.
- Node connection and security:
node.numAddresses, which caps your lender keys.