mirror of
https://github.com/bisq-network/bisq.git
synced 2025-03-01 09:40:15 +01:00
Add a 'LazyFields' static class and memoised supplier field to the base class TxConfidenceListItem, similar to that added to the classes DepositListItem & TransactionsListItem. This allows lazy loading of tooltips & tx confidence indicators, just as for those classes. This removes the current remaining bottleneck in the BSQ tx view load, revealed by JProfiler. (Note that there is still a quadratic time bug remaining due to the use of a confidence listener for each list item, since the BSQ wallet internally uses a CopyOnWriteArrayList, whose backing array is cloned for each listener addition or removal. However, it isn't clear that fixing this will give a noticable speedup unless there are an extremely large number of BSQ txs in the wallet.) Take care to add the tx confirmation count to LazyFields, to prevent issues when exporting the list as a CSV. Also add a volatile 'lazyFields' field to detect lazy initialisation of the supplier and short circuit confidence updates for uninitialised indicators. |
||
---|---|---|
.. | ||
main | ||
test |