Merge pull request #4886 from jmacxx/hotfix/v1.5.1

add logging of Tx hex
This commit is contained in:
Christoph Atteneder 2020-12-03 19:18:50 +01:00 committed by GitHub
commit baa038aa39
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -25,6 +25,7 @@ import bisq.common.UserThread;
import org.bitcoinj.core.PeerGroup;
import org.bitcoinj.core.Transaction;
import org.bitcoinj.core.Utils;
import org.bitcoinj.wallet.Wallet;
import com.google.common.util.concurrent.FutureCallback;
@ -90,6 +91,7 @@ public class TxBroadcaster {
public static void broadcastTx(Wallet wallet, PeerGroup peerGroup, Transaction tx, Callback callback, int timeOut) {
Timer timeoutTimer;
final String txId = tx.getTxId().toString();
log.info("Txid: {} hex: {}", txId, Utils.HEX.encode(tx.bitcoinSerialize()));
if (!broadcastTimerMap.containsKey(txId)) {
timeoutTimer = UserThread.runAfter(() -> {
log.warn("Broadcast of tx {} not completed after {} sec.", txId, timeOut);