Skip to content

Commit

Permalink
Update changes from
Browse files Browse the repository at this point in the history
bisq-network#7069 and bisq-network#7070 as well as more recent resource data

Signed-off-by: HenrikJannsen <boilingfrog@gmx.com>
  • Loading branch information
HenrikJannsen committed Apr 1, 2024
1 parent 8b381bf commit 909a0fb
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -400,7 +400,7 @@ public long getDateAsLong() {

@Override
public int maxItems() {
return 3000;
return 15000;
}

public void pruneOptionalData() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ public class RequestDataManager implements MessageListener, ConnectionListener,
private static int NUM_SEEDS_FOR_PRELIMINARY_REQUEST = 2;
// how many seeds additional to the first responding PreliminaryGetDataRequest seed we request the GetUpdatedDataRequest from
private static int NUM_ADDITIONAL_SEEDS_FOR_UPDATE_REQUEST = 1;
private static int MAX_REPEATED_REQUESTS = 30;
private boolean isPreliminaryDataRequest = true;


Expand Down Expand Up @@ -140,6 +141,7 @@ public RequestDataManager(NetworkNode networkNode,
if (seedNodeRepository.isSeedNode(myAddress)) {
NUM_SEEDS_FOR_PRELIMINARY_REQUEST = 3;
NUM_ADDITIONAL_SEEDS_FOR_UPDATE_REQUEST = 2;
MAX_REPEATED_REQUESTS = 100;
}
}
});
Expand Down Expand Up @@ -361,7 +363,7 @@ public void onComplete(boolean wasTruncated) {
}

if (wasTruncated) {
if (numRepeatedRequests < 20) {
if (numRepeatedRequests < MAX_REPEATED_REQUESTS) {
// If we had allDataReceived already set to true but get a response with truncated flag,
// we still repeat the request to that node for higher redundancy. Otherwise, one seed node
// providing incomplete data would stop others to fill the gaps.
Expand Down
Binary file not shown.
Binary file modified p2p/src/main/resources/TradeStatistics3Store_1.9.15_BTC_MAINNET
Binary file not shown.

0 comments on commit 909a0fb

Please sign in to comment.