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

RPC: add 'getnetstats' op, to return data on messages and peers #1510

Closed
wants to merge 1 commit into from

Conversation

jgarzik
Copy link
Contributor

@jgarzik jgarzik commented Jun 24, 2012

The returned data is

  1. Per-message arrays.

    Index 0 is total number of $ThisType messages
    received since program start (or uint64 counter wrap).

    Index 1 is total byte count since program start (or uint64
    counter wrap).

    They are returned as strings due to unfortunate JSON implementations
    in the field that do not handle unquoted uint64 numbers correctly.

  2. Peer information. Returns number of inbound, outbound and total peers.
    Total peer count is equivalent to RPC 'getconnectioncount'.

The returned data is

1. Per-message arrays.

   Index 0 is total number of $ThisType messages
   received since program start (or uint64 counter wrap).

   Index 1 is total byte count since program start (or uint64
   counter wrap).

   They are returned as strings due to unfortunate JSON implementations
   in the field that do not handle unquoted uint64 numbers correctly.

2. Peer information.  Returns number of inbound, outbound and total peers.
   Total peer count is equivalent to RPC 'getconnectioncount'.
@jgarzik
Copy link
Contributor Author

jgarzik commented Jun 24, 2012

Sample output here: https://gist.github.com/2980975

@gavinandresen
Copy link
Contributor

Design doesn't feel quite right to me.

How about something like:

getpeerinfo : returns list of peers (ip address, inbound/outbound, etc)

getstat "which_stat_to_get" : generic RPC call for getting internal state of bitcoin...

@gmaxwell
Copy link
Contributor

getstat "which_stat_to_get" would make it easier to wrap up in a snmp style poller, e.g. for graphing with an rrd tool frontend.

@jgarzik
Copy link
Contributor Author

jgarzik commented Jun 27, 2012

@gmaxwell all the kernel interfaces that SNMP uses tend to return groups of statistics that the kernel finds easy to generate together (tx pkts, rx pkts, rx bytes, tx bytes, collisions, ...) I see the same pattern elsewhere. So perhaps 'getstat $STAT' can return complex objects, if it is natural to do so internally.

Regardless... closing. will work on 'getpeerinfo' and then see what's left.

@jgarzik jgarzik closed this Jun 27, 2012
@jgarzik jgarzik deleted the stats branch August 24, 2014 04:23
suprnurd pushed a commit to chaincoin-legacy/chaincoin that referenced this pull request Dec 5, 2017
… tx (bitcoin#1510)

* Make sure mixing tx follows bip69 before signing it

* bump MIN_PRIVATESEND_PEER_PROTO_VERSION to 70208
lateminer pushed a commit to lateminer/bitcoin that referenced this pull request May 6, 2020
82ef311 Fix text cut-off in sendchangeaddressdialog (JSKitty)

Pull request description:

  The text in the Change Address dialog is cut-off, this PR simply increases the minimum height of labelMessage to give the text enough room without clipping.

  **Before:**

  ![image](https://user-images.githubusercontent.com/42538664/78942361-7c36fd00-7ab1-11ea-812b-9fae7df3d6e7.png)

  **After:**

  ![image](https://user-images.githubusercontent.com/42538664/78942432-a38dca00-7ab1-11ea-8c55-898b57b7b207.png)

ACKs for top commit:
  random-zebra:
    ACK 82ef311
  Fuzzbawls:
    ACK 82ef311

Tree-SHA512: dadfedc5d313796065e52d340b2bd5bc24ccda13902c5f6b26487d610403586fa05a17333a738de47bbdeaa9f222379384fae838a69c8272578c8ea559f34e48
@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
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants