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

Fix ZMQ docs - Improve logging #7058

Merged
merged 3 commits into from
Nov 27, 2015
Merged

Fix ZMQ docs - Improve logging #7058

merged 3 commits into from
Nov 27, 2015

Conversation

dcousens
Copy link
Contributor

This PR fixes the -zmq* flags (in -h) to coincide with what they actually are in the code and the docs.
It also prepends the logging messages for zmq with zmq:, and adds it to the debug categories in -h.

Docs reference: https://github.com/bitcoin/bitcoin/blob/master/doc/zmq.md#usage

Currently, the following notifications are supported:

-zmqpubhashtx=address
-zmqpubhashblock=address
-zmqpubrawblock=address
-zmqpubrawtx=address

Code reference: https://github.com/bitcoin/bitcoin/blob/master/src/zmq/zmqnotificationinterface.cpp#L38-L41

@dcousens dcousens changed the title init: amend ZMQ flag names init: amend ZMQ flag names (and add zmq to debug categories) Nov 19, 2015
@dcousens dcousens changed the title init: amend ZMQ flag names (and add zmq to debug categories) Improve ZMQ logging Nov 19, 2015
@dcousens dcousens changed the title Improve ZMQ logging Fix ZMQ docs - Imrpve logging Nov 19, 2015
@dcousens dcousens changed the title Fix ZMQ docs - Imrpve logging Fix ZMQ docs - Improve logging Nov 19, 2015
@@ -72,7 +72,7 @@ CZMQNotificationInterface* CZMQNotificationInterface::CreateWithArguments(const
// Called at startup to conditionally set up ZMQ socket(s)
bool CZMQNotificationInterface::Initialize()
{
LogPrint("zmq", "Initialize notification interface\n");
LogPrint("zmq", "zmq: Initialize notification interface\n");
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@laanwj maybe this should be done by LogPrint? Automatically prepend the category to the message?
Thoughts?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, this could be done by LogPrint (autoprint the category). But until then, it is probably best if we keep it consistent with other LogPrint's.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree to get this done in the LogPrint method.

@jmcorgan
Copy link
Contributor

@dcousens No worries. utACK.

@jonasschnelli
Copy link
Contributor

Nice catch with the wrong help message!
utACK.

@laanwj laanwj added the Docs label Nov 19, 2015
@dcousens
Copy link
Contributor Author

Anything holding this up @laanwj ?

@maflcko
Copy link
Member

maflcko commented Nov 24, 2015

utACK ffacd27

@laanwj laanwj merged commit ffacd27 into bitcoin:master Nov 27, 2015
laanwj added a commit that referenced this pull request Nov 27, 2015
ffacd27 zmq: prepend zmq to debug messages (Daniel Cousens)
14075b1 init: add zmq to debug categories (Daniel Cousens)
cdcd816 init: amend ZMQ flag names (Daniel Cousens)
@dcousens dcousens deleted the zmqdoc branch November 27, 2015 09:15
luke-jr pushed a commit to luke-jr/bitcoin that referenced this pull request Dec 1, 2015
luke-jr pushed a commit to luke-jr/bitcoin that referenced this pull request Dec 1, 2015
luke-jr pushed a commit to luke-jr/bitcoin that referenced this pull request Dec 1, 2015
zkbot added a commit to zcash/zcash that referenced this pull request Feb 9, 2017
zkbot added a commit to zcash/zcash that referenced this pull request Feb 9, 2017
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants