mirror of
https://github.com/haveno-dex/haveno.git
synced 2025-08-12 16:35:37 -04:00
Move log message closer to actual sending
This commit is contained in:
parent
e4ce976bab
commit
b814eff5f1
1 changed files with 1 additions and 2 deletions
|
@ -88,8 +88,6 @@ public class RequestDataHandler implements MessageListener {
|
||||||
else
|
else
|
||||||
getDataRequest = new GetUpdatedDataRequest(networkNode.getNodeAddress(), nonce);
|
getDataRequest = new GetUpdatedDataRequest(networkNode.getNodeAddress(), nonce);
|
||||||
|
|
||||||
log.info("We send a {} to peer {}. ", getDataRequest.getClass().getSimpleName(), nodeAddress);
|
|
||||||
|
|
||||||
if (timeoutTimer == null) { // setup before sending to avoid race conditions
|
if (timeoutTimer == null) { // setup before sending to avoid race conditions
|
||||||
timeoutTimer = UserThread.runAfter(() -> {
|
timeoutTimer = UserThread.runAfter(() -> {
|
||||||
if (!stopped) {
|
if (!stopped) {
|
||||||
|
@ -105,6 +103,7 @@ public class RequestDataHandler implements MessageListener {
|
||||||
TIME_OUT_SEC);
|
TIME_OUT_SEC);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
log.info("We send a {} to peer {}. ", getDataRequest.getClass().getSimpleName(), nodeAddress);
|
||||||
SettableFuture<Connection> future = networkNode.sendMessage(nodeAddress, getDataRequest);
|
SettableFuture<Connection> future = networkNode.sendMessage(nodeAddress, getDataRequest);
|
||||||
Futures.addCallback(future, new FutureCallback<Connection>() {
|
Futures.addCallback(future, new FutureCallback<Connection>() {
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue