@clonegod/ttd-sol-common 1.0.133 → 1.0.134
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -583,14 +583,24 @@ class RpcClient {
|
|
|
583
583
|
const serializedTransaction = transaction.serialize({ verifySignatures: false }).toString(encoding);
|
|
584
584
|
let jito_region = process.env.JITO_REGION || region;
|
|
585
585
|
let jitoApiUrl = `${types_1.JITO_API_URLS[jito_region]}/api/v1/bundles`;
|
|
586
|
-
const
|
|
586
|
+
const send_tx_jito_url = process.env.SEND_TX_JITO_URL;
|
|
587
|
+
const send_tx_jito_stratgy = process.env.SEND_TX_JITO_STRATEGY;
|
|
588
|
+
if (send_tx_jito_url && send_tx_jito_stratgy === 'mul_ips') {
|
|
589
|
+
(0, dist_1.postJSON)(send_tx_jito_url, {
|
|
590
|
+
encoding,
|
|
591
|
+
encoded_tx: serializedTransaction,
|
|
592
|
+
txid,
|
|
593
|
+
trace_id: ''
|
|
594
|
+
});
|
|
595
|
+
return;
|
|
596
|
+
}
|
|
597
|
+
let bundleId = yield this.sendJitoBundle([serializedTransaction], encoding, jitoApiUrl);
|
|
587
598
|
(0, dist_1.log_info)(`sendJitoBundle`, {
|
|
588
599
|
txid,
|
|
589
600
|
jitoApiUrl,
|
|
590
601
|
encoding,
|
|
591
602
|
bundleId
|
|
592
603
|
});
|
|
593
|
-
this.try_get_bundle_failed_result(txid, bundleId);
|
|
594
604
|
}), 0);
|
|
595
605
|
return txid;
|
|
596
606
|
});
|