Page MenuHomePhabricator

[Chronik] Add `GroupUtxoWriter` and `GroupUtxoReader`
ClosedPublic

Authored by tobias_ruck on Apr 14 2023, 13:03.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABC847774eeefd6: [Chronik] Add `GroupUtxoWriter` and `GroupUtxoReader`
Summary

Update UTXO set for each group member.

We store a list of ordered UTXOs (sorted by tx_num, then out_idx) for each group member.

We also also attach the value to each UTXO, which allows us to return the UTXO set for scripts very efficiently, without having to look up the spent tx from the node.

It's unclear at this point whether this is useful for other kinds of groups, but if it isn't, we can make UtxoEntry more generic in the future.

Depends on D13717.

Test Plan

ninja check-crates

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable