-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Send raw transactions to explorer API for better redundancy at tx broadcast #4932
Comments
I think the broadcasting problems we had recently are not really broadcasting problems, but a consequence of a previous problem that made bisq to create invalid txs. In any case, it is good to be on the safe side. Broadcasting means exposing privacy to the server. Electrum seems a good trade-off.
I wrote a java API to communicate to an electrum server: https://github.com/electrumj/electrumj/ |
I discussed with @sqrrm the topic to use Eletrum or mempool.space and we got convinced its better to use mempool.space for now.
|
FYI the mempool.space backend can be configured to support the electrum RPC API as well as the REST API if necessary so you can have both, just let me know if you need it |
Thanks for the offer but I don't currently have the bandwidth to take this task. |
@jmacxx Really? should be easy, all you need to do is HTTP POST the TX in hex to a URL :) |
Description
As we have the unresolved issue that sometimes transactions does not get successfully broadcast and we have not managed to find out the issue which causes that (likely a bitcoinj problem as it does conceptual not support well multiple wallets as we use with BSQ and BTC) I suggest that we send the raw transcation to an explorer API for increasing the chances that the tx gets into the mempool.
A requirement is that the API is running as hidden service, so there are no privacy issues.
Bisq contributors run a few mempool space explorer nodes and we could use those as default nodes. We can add a setting that the user could define their own node as well (I guess its not needed for the first version).
Another option would be to use Electrum or send it to Bitcoin core nodes.
Requires a bit more thought and investigation whats the best option here.
We should also keep in mind that using external APIs for blockchain data can be used for further use cases like look up if a tx is in the mempool, look up if peers trade fee tx is in the mempool and confirmed, lookup miner fees used in peers txs,...
So the choosen model should be usable for those use cases as well.
@wiz Does mempool.space API support broadcast of raw txs?
@jmacxx Would you be interested to work on that?
The text was updated successfully, but these errors were encountered: