@@ -133,48 +133,16 @@ class CAddrInfo : public CAddress
133
133
134
134
// ! total number of buckets for tried addresses
135
135
static constexpr int32_t ADDRMAN_TRIED_BUCKET_COUNT_LOG2{8 };
136
+ static constexpr int ADDRMAN_TRIED_BUCKET_COUNT{1 << ADDRMAN_TRIED_BUCKET_COUNT_LOG2};
136
137
137
138
// ! total number of buckets for new addresses
138
139
static constexpr int32_t ADDRMAN_NEW_BUCKET_COUNT_LOG2{10 };
140
+ static constexpr int ADDRMAN_NEW_BUCKET_COUNT{1 << ADDRMAN_NEW_BUCKET_COUNT_LOG2};
139
141
140
142
// ! maximum allowed number of entries in buckets for new and tried addresses
141
143
static constexpr int32_t ADDRMAN_BUCKET_SIZE_LOG2{6 };
142
-
143
- // ! over how many buckets entries with tried addresses from a single group (/16 for IPv4) are spread
144
- static constexpr uint32_t ADDRMAN_TRIED_BUCKETS_PER_GROUP{8 };
145
-
146
- // ! over how many buckets entries with new addresses originating from a single group are spread
147
- static constexpr uint32_t ADDRMAN_NEW_BUCKETS_PER_SOURCE_GROUP{64 };
148
-
149
- // ! in how many buckets for entries with new addresses a single address may occur
150
- static constexpr int32_t ADDRMAN_NEW_BUCKETS_PER_ADDRESS{8 };
151
-
152
- // ! how old addresses can maximally be
153
- static constexpr int64_t ADDRMAN_HORIZON_DAYS{30 };
154
-
155
- // ! after how many failed attempts we give up on a new node
156
- static constexpr int32_t ADDRMAN_RETRIES{3 };
157
-
158
- // ! how many successive failures are allowed ...
159
- static constexpr int32_t ADDRMAN_MAX_FAILURES{10 };
160
-
161
- // ! ... in at least this many days
162
- static constexpr int64_t ADDRMAN_MIN_FAIL_DAYS{7 };
163
-
164
- // ! how recent a successful connection should be before we allow an address to be evicted from tried
165
- static constexpr int64_t ADDRMAN_REPLACEMENT_HOURS{4 };
166
-
167
- // ! Convenience
168
- static constexpr int ADDRMAN_TRIED_BUCKET_COUNT{1 << ADDRMAN_TRIED_BUCKET_COUNT_LOG2};
169
- static constexpr int ADDRMAN_NEW_BUCKET_COUNT{1 << ADDRMAN_NEW_BUCKET_COUNT_LOG2};
170
144
static constexpr int ADDRMAN_BUCKET_SIZE{1 << ADDRMAN_BUCKET_SIZE_LOG2};
171
145
172
- // ! the maximum number of tried addr collisions to store
173
- static constexpr size_t ADDRMAN_SET_TRIED_COLLISION_SIZE{10 };
174
-
175
- // ! the maximum time we'll spend trying to resolve a tried table collision, in seconds
176
- static constexpr int64_t ADDRMAN_TEST_WINDOW{40 *60 }; // 40 minutes
177
-
178
146
/* *
179
147
* Stochastical (IP) address manager
180
148
*/
0 commit comments