Skip to content
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

dev branch - mosquitto_pub to multiple topics #323

Open
phillamy opened this issue Nov 22, 2023 · 1 comment
Open

dev branch - mosquitto_pub to multiple topics #323

phillamy opened this issue Nov 22, 2023 · 1 comment

Comments

@phillamy
Copy link
Contributor

mosquitto_pub does not support publishing a message to multiple topics

See
cyphernode/cyphernodeconf_docker/templates/bitcoin/blocknotify.sh
cyphernode/cyphernodeconf_docker/templates/bitcoin/walletnotify.sh

A fix has to be made to invoke mosquitto_pub 2 times - on each topic:

  # Topic 'newblock' will be removed eventually
  echo "[blocknotify-$$] mosquitto_pub -h broker -t newblock -t bitcoinnode/newblock -m \"{\"blockhash\":\"${blockhash}\",\"blockheight\":${blockheight}}\""
  mosquitto_pub -h broker -t newblock -m "{\"blockhash\":\"${blockhash}\",\"blockheight\":${blockheight}}"
  mosquitto_pub -h broker -t bitcoinnode/newblock -m "{\"blockhash\":\"${blockhash}\",\"blockheight\":${blockheight}}"
@phillamy
Copy link
Contributor Author

#310 linked

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant