Bitcoin Core  22.99.0
P2P Digital Currency
Variables
addrman.cpp File Reference
#include <addrman.h>
#include <addrman_impl.h>
#include <hash.h>
#include <logging.h>
#include <logging/timer.h>
#include <netaddress.h>
#include <protocol.h>
#include <random.h>
#include <serialize.h>
#include <streams.h>
#include <timedata.h>
#include <tinyformat.h>
#include <uint256.h>
#include <util/check.h>
#include <cmath>
#include <optional>
Include dependency graph for addrman.cpp:

Go to the source code of this file.

Variables

static constexpr uint32_t ADDRMAN_TRIED_BUCKETS_PER_GROUP {8}
 Over how many buckets entries with tried addresses from a single group (/16 for IPv4) are spread. More...
 
static constexpr uint32_t ADDRMAN_NEW_BUCKETS_PER_SOURCE_GROUP {64}
 Over how many buckets entries with new addresses originating from a single group are spread. More...
 
static constexpr int32_t ADDRMAN_NEW_BUCKETS_PER_ADDRESS {8}
 Maximum number of times an address can occur in the new table. More...
 
static constexpr int64_t ADDRMAN_HORIZON_DAYS {30}
 How old addresses can maximally be. More...
 
static constexpr int32_t ADDRMAN_RETRIES {3}
 After how many failed attempts we give up on a new node. More...
 
static constexpr int32_t ADDRMAN_MAX_FAILURES {10}
 How many successive failures are allowed ... More...
 
static constexpr int64_t ADDRMAN_MIN_FAIL_DAYS {7}
 ... More...
 
static constexpr int64_t ADDRMAN_REPLACEMENT_HOURS {4}
 How recent a successful connection should be before we allow an address to be evicted from tried. More...
 
static constexpr size_t ADDRMAN_SET_TRIED_COLLISION_SIZE {10}
 The maximum number of tried addr collisions to store. More...
 
static constexpr int64_t ADDRMAN_TEST_WINDOW {40*60}
 The maximum time we'll spend trying to resolve a tried table collision, in seconds. More...
 

Variable Documentation

◆ ADDRMAN_HORIZON_DAYS

constexpr int64_t ADDRMAN_HORIZON_DAYS {30}
staticconstexpr

How old addresses can maximally be.

Definition at line 32 of file addrman.cpp.

◆ ADDRMAN_MAX_FAILURES

constexpr int32_t ADDRMAN_MAX_FAILURES {10}
staticconstexpr

How many successive failures are allowed ...

Definition at line 36 of file addrman.cpp.

◆ ADDRMAN_MIN_FAIL_DAYS

constexpr int64_t ADDRMAN_MIN_FAIL_DAYS {7}
staticconstexpr

...

in at least this many days

Definition at line 38 of file addrman.cpp.

◆ ADDRMAN_NEW_BUCKETS_PER_ADDRESS

constexpr int32_t ADDRMAN_NEW_BUCKETS_PER_ADDRESS {8}
staticconstexpr

Maximum number of times an address can occur in the new table.

Definition at line 30 of file addrman.cpp.

◆ ADDRMAN_NEW_BUCKETS_PER_SOURCE_GROUP

constexpr uint32_t ADDRMAN_NEW_BUCKETS_PER_SOURCE_GROUP {64}
staticconstexpr

Over how many buckets entries with new addresses originating from a single group are spread.

Definition at line 28 of file addrman.cpp.

◆ ADDRMAN_REPLACEMENT_HOURS

constexpr int64_t ADDRMAN_REPLACEMENT_HOURS {4}
staticconstexpr

How recent a successful connection should be before we allow an address to be evicted from tried.

Definition at line 40 of file addrman.cpp.

◆ ADDRMAN_RETRIES

constexpr int32_t ADDRMAN_RETRIES {3}
staticconstexpr

After how many failed attempts we give up on a new node.

Definition at line 34 of file addrman.cpp.

◆ ADDRMAN_SET_TRIED_COLLISION_SIZE

constexpr size_t ADDRMAN_SET_TRIED_COLLISION_SIZE {10}
staticconstexpr

The maximum number of tried addr collisions to store.

Definition at line 42 of file addrman.cpp.

◆ ADDRMAN_TEST_WINDOW

constexpr int64_t ADDRMAN_TEST_WINDOW {40*60}
staticconstexpr

The maximum time we'll spend trying to resolve a tried table collision, in seconds.

Definition at line 44 of file addrman.cpp.

◆ ADDRMAN_TRIED_BUCKETS_PER_GROUP

constexpr uint32_t ADDRMAN_TRIED_BUCKETS_PER_GROUP {8}
staticconstexpr

Over how many buckets entries with tried addresses from a single group (/16 for IPv4) are spread.

Definition at line 26 of file addrman.cpp.