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

/api/network/nodes information #17

Open
rocket-pig opened this issue May 4, 2019 · 2 comments
Open

/api/network/nodes information #17

rocket-pig opened this issue May 4, 2019 · 2 comments

Comments

@rocket-pig
Copy link

After doing a little fiddling with this data, I have some questions if I could.

  • How is this information collected? I cant make sense of external ElasticSearch.
  • Are there only 140 ish navcoin nodes in total, or is this just a count of nodes yours has seen?
  • What does 'good' imply? Are roughly half of these nodes 'misbehaving'?
  • are the 'percent1d' etc stats = node uptime?
  • How does one decode the 'services' (svcs) data?

Thank you for your work, I'll happily send you some Nav if you would like a tip.

@dantudor
Copy link
Contributor

dantudor commented May 4, 2019

It exposes data that is collected from the seeder. https://github.com/NAVCoin/navcoin-seeder

It only contains data regarding nodes that have listen=1 in their config setup.

There may be more explanation of the data services in that repository.

It wasn't integrated into the explorer as it needs to be combined with data directly from the explorers active connections.

@rocket-pig
Copy link
Author

rocket-pig commented May 5, 2019

(I'm a self-taught amateur in c++ so forgive me but here's what I came up with)

  • 'good' (bool) is literally just the retval of calling Cnode.Run() in navcoin.cpp:215. good=true if node is up, not if not.
  • 'percent1d' et al are indeed uptime.
  • 'svcs' = Caddr.nServices which i finally traced back to
    void CAddress::Init() { nServices = NODE_NETWORK;
    and another search led me to find that this is defined as:
    NODE_NETWORK = (1 << 0)
    ..and a google led me to finding out this is a 'bit shifter'. Every node has 0000000d, which would be what, 13 in hex. No idea what that means.

It's been fun poking around. Thanks for linking me to the seeder.

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

2 participants