This introduces several options for public node operators to limit their
nodes usage by 3rd parties, this is aimed at usage of resource-hungry
areas.
We allow limiting the amount of connections any single IP can keep open
with us.
We limit the amount of reconnects we allow in a short number of seconds.
We allow limiting the number of addresses (or scriptHashes) a peer can
register for the node to scan.
The last one is for both the addressMonitorService as well as for the
getBlock filters.
For node operators these items become available using command line
options or config-file options. By default these limits are unlimited as
we assume default usage to be private.
This implements two TODOs, we now unset the services in our registry
when they disconnect.
This allows us to run with multiple backends as failover more stable.
We only have the option for `--debug` when it is regarding a client (as
oppossed to a server) and when we build a debug build.
Only add the option for users to set when we actually process it.
We calculate the needed space for the network buffers before we fill them,
as new features are added guestimating ended up short.
Lets do the real calculation.
When the transaction offset is wrong and doesn't parse we turn the
generic runtime_exception into one that goes back to the API caller.
Also catch those generic exceptions on the server level to avoid this
kind of error from disconnecting a peer.
When getting data from the mempool based on address, we also want to call
the addressUsedInOutput() callback, in order to be consistent.
We pass in the blockheight and offset in block being -1, though.
Memmapping can use any filesize, but the pages are allocated in a power
of two amount.
Assuming 4K pages we now aim to have 65536 pages to map a big file.