PoA Leader Lock for Block Production (#3203)
## Linked Issues/PRs
<!-- List of related issues/PRs -->
## Description
<!-- List of detailed changes -->
The goal with this change is to allow multiple authority nodes to be
live without causing contention on who should produce the next block.
Introduced the `LeaderLeasePort`:
```rs
#[async_trait::async_trait]
pub trait LeaderLeasePort: Send + Sync {
async fn can_produce_block(&self, height: BlockHeight) -> anyhow::Result<bool>;
async fn release_lease(&self) -> anyhow::Result<()>;
}
```
Where each block producer can check if the lease is available before
producing a block. On shutdown, it will always release the lease as
well.
The implementation is `RedisLeaderLeaseAdapter`, where we use a lease on
a Redis server. The server can have its own ttl for the lease so if a
block producer dies before releasing the lease, it can still be grabbed
by the other producers :)
## Checklist
- [ ] Breaking changes are clearly marked as such in the PR description
and changelog
- [ ] New behavior is reflected in tests
- [ ] [The specification](https://github.com/FuelLabs/fuel-specs/)
matches the implemented behavior (link update PR if changes are needed)
### Before requesting review
- [ ] I have reviewed the code myself
- [ ] I have created follow-up issues caused by this PR and linked them
here
### After merging, notify other teams
[Add or remove entries as needed]
- [ ] [Rust SDK](https://github.com/FuelLabs/fuels-rs/)
- [ ] [Sway compiler](https://github.com/FuelLabs/sway/)
- [ ] [Platform
documentation](https://github.com/FuelLabs/devrel-requests/issues/new?assignees=&labels=new+request&projects=&template=NEW-REQUEST.yml&title=%5BRequest%5D%3A+)
(for out-of-organization contributors, the person merging the PR will do
this)
- [ ] Someone else?
---------
Co-authored-by: Green Baneling <XgreenX9999@gmail.com> M
Mitchell Turner committed
853d67d2687fe7f2482dd93ccdd7e99721ab76ed
Parent: 697e692
Committed by GitHub <noreply@github.com>
on 2/19/2026, 8:29:40 PM