A decentralized bitcoin exchange network
Go to file
Steven Barclay 97ef9c1308
Place filter in front of 'isRelatedToTransaction' for speedup
Use a crude Bloom filter (of sorts) to cut down the quadratic number of
calls to 'TransactionAwareTradable.isRelatedToTransaction' (that is, one
for each tx-tradable pair) during the Transactions view load. In this
way, we may reduce the number of calls roughly 40-fold, for a Bisq
instance with similar numbers of BSQ swap trades and escrow trades.

(Sadly, profiling does not show a 40-fold reduction in the size of the
'isRelatedToTransaction' hotspot, likely due to the remaining calls
being expensive ones involving disputed trades or unusual txs with
nonzero locktime, e.g. dust attacks or funds from Electrum wallets.)

To this end, partition the wallet transactions into 64 pseudo-randomly
chosen buckets (with a dedicated bucket for txs which might be delayed
payouts, namely those with nonzero locktime). Add an interface method,
'TransactionAwareTradable.getRelatedTransactionFilter', which returns an
IntStream of all the indices of buckets where a related tx may plausibly
be found. Where this is unclear, e.g. for trades involved in a dispute,
just return everything (that is, the range 0..63 inclusive).

Add a class, 'RelatedTransactionFilterSlices', that holds a provided
list of TransactionAwareTradable instances and 64 bitsets of all the
slices through their respective filters (each realised as 64-bit word
instead of a streams of integers). In this way, a list of tradables
plausibly related to any given tx may be quickly found by simply
selecting the appropriate bitset of the 64 (by the tx bucket index).
2023-02-11 07:55:36 +08:00
.github Merge pull request #6566 from alvasw/ci_use_gradle_build_action 2023-02-05 19:04:03 +00:00
.idea Rename :protodefintion subproject to :proto 2020-03-26 17:37:37 +01:00
apitest Gradle: Apply bisq.java-conventions to all projects 2023-02-05 22:02:13 +01:00
assets Gradle: Apply bisq.java-conventions to all projects 2023-02-05 22:02:13 +01:00
build-logic Gradle: Create bisq.java-conventions precompiled script 2023-02-05 21:58:46 +01:00
cli Gradle: Apply bisq.java-conventions to all projects 2023-02-05 22:02:13 +01:00
common Merge pull request #6568 from alvasw/gradle_apply_central_bisq_java_conventions 2023-02-05 22:43:48 +00:00
core Merge pull request #6568 from alvasw/gradle_apply_central_bisq_java_conventions 2023-02-05 22:43:48 +00:00
daemon Merge pull request #6568 from alvasw/gradle_apply_central_bisq_java_conventions 2023-02-05 22:43:48 +00:00
desktop Place filter in front of 'isRelatedToTransaction' for speedup 2023-02-11 07:55:36 +08:00
docs Update app signatures 2022-12-01 12:21:46 +01:00
gradle Gradle: Create bisq.java-conventions precompiled script 2023-02-05 21:58:46 +01:00
p2p Merge pull request #6568 from alvasw/gradle_apply_central_bisq_java_conventions 2023-02-05 22:43:48 +00:00
proto Gradle: Apply bisq.java-conventions to all projects 2023-02-05 22:02:13 +01:00
scripts Re-add original install script 2022-07-08 21:31:50 +02:00
seednode Merge pull request #6568 from alvasw/gradle_apply_central_bisq_java_conventions 2023-02-05 22:43:48 +00:00
statsnode Gradle: Apply bisq.java-conventions to all projects 2023-02-05 22:02:13 +01:00
.editorconfig Do not strip trailing whitespace in Git diffs 2020-01-10 19:48:26 +01:00
.gitattributes Not use git lfs anymore 2022-09-15 09:21:37 +02:00
.gitignore Remove monitor module 2022-11-24 16:30:34 -05:00
.travis.yml Not use git lfs anymore 2022-09-15 09:21:37 +02:00
build.gradle Gradle: Apply bisq.java-conventions to all projects 2023-02-05 22:02:13 +01:00
CODEOWNERS Remove @cbeams as build and pricenode code owner 2020-06-28 11:23:36 +02:00
CONTRIBUTING.md Remove references to keybase and switch to Matrix 2022-02-02 16:57:06 +01:00
gradle.properties Enforce Gradle Dependency Verification 2022-12-06 21:21:39 +02:00
gradlew Update gradle wrapper to 7.3.3 2021-12-25 13:03:14 +01:00
gradlew.bat Upgraded Gradle to v6.6.1 2020-09-17 01:59:51 +02:00
LICENSE
Makefile Merge pull request #6430 from HenrikJannsen/remove-unused-modules 2022-11-29 14:45:37 +02:00
pull_request_template.md Added a Pull Request template 2019-11-27 13:46:54 +01:00
README.md Replace Travis build icon with the Github Actions svg 2022-04-12 17:57:12 +02:00
settings.gradle Gradle: Create bisq.java-conventions precompiled script 2023-02-05 21:58:46 +01:00

Actions Status

What is Bisq?

Bisq is a safe, private and decentralized way to exchange bitcoin for national currencies and other digital assets. Bisq uses peer-to-peer networking and multi-signature escrow to facilitate trading without a third party. Bisq is non-custodial and incorporates a human arbitration system to resolve disputes.

To learn more, see the doc and video at https://bisq.network/intro.

Get started using Bisq

Follow the step-by-step instructions at https://bisq.network/get-started.

Contribute to Bisq

See CONTRIBUTING.md and the developer docs.