do not extend arbitrator timeout awaiting deposit txs

This commit is contained in:
woodser 2024-05-23 20:18:00 -04:00
parent 796603f82b
commit 3b1961fb05

View file

@ -334,7 +334,7 @@ public abstract class TradeProtocol implements DecryptedDirectMessageListener, D
public void handleSignContractRequest(SignContractRequest message, NodeAddress sender) {
System.out.println(getClass().getSimpleName() + ".handleSignContractRequest() " + trade.getId());
trade.addInitProgressStep();
if (!trade.isArbitrator()) trade.addInitProgressStep(); // extend timeout unless arbitrator
ThreadUtils.execute(() -> {
synchronized (trade) {
@ -358,13 +358,11 @@ public abstract class TradeProtocol implements DecryptedDirectMessageListener, D
ProcessSignContractRequest.class)
.using(new TradeTaskRunner(trade,
() -> {
startTimeout();
handleTaskRunnerSuccess(sender, message);
},
errorMessage -> {
handleTaskRunnerFault(sender, message, errorMessage);
}))
.withTimeout(TRADE_STEP_TIMEOUT_SECONDS)) // extend timeout
})))
.executeTasks(true);
awaitTradeLatch();
} else {