Re: Need to know on network map

Mike Hearn
 

You could do this but note:

  1. The notary needs to see the entire network map because it dials back to the finalizing node based on identity. So you need those nodes to have the entire dataset.
  2. The node will still try to register with a network map, which is mandatory. So you'd need a custom network map server that serves the whole map to the notaries but only the notaries to other kinds of nodes. This is a protocol violation and wouldn't be a supported way to use Corda.
  3. "additional-node-infos" (I think this is the name) is a tool designed for operators in case of dispute with the network map operator. It's not an API and may be renamed, moved, deleted, or changed in arbitrary ways at any time. Apps aren't meant to use it and may break if they do.
  4. There's no way to block a flow on waiting for a peer to appear in the network map cache, as far as I know. It'd be more direct to just invoke internal code to directly insert fetched NodeInfos into the database so they're immediately available, but that (again) isn't supported and may/will break at some point in future.
  5. Future features may be designed on the assumption of a public network map, e.g. a mix network mode for anonymity.
As I said above, "You could of course fork the open source codebase and add support for this". It's essentially doing that, so you may as well fork it properly and add whatever new APIs you need to make it work well rather than [ab]using the additional-node-infos directory.

Join corda-dev@groups.io to automatically receive all group messages.