Sessions were limited to 256 for some reason.
For large scale operation it makes sense to allow more
open sessions (symmetric key sessions).
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
We do not need that many responses with FindNodeFast, since the
reposes can be ordered by distance
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
We really don't need this to be 4 seconds.
Later we should tune it better based on measurements
or estimates,
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Make dht compile with new new (0.14+) nimble.
Compilation with Nimble <0.14 can't work, as
the many of the libraries on the dependency
tree are not version tagged. As we can't change
that, two paths remain:
1, use nimbus-build-system (i.e. git submodules)
2, use lock files introduced in nimble 0.14+
First was already working, this fixes second
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
It seems lockfile was generated wrong or not updated,
broken in 76bff752a2
setting it to version used in nimbus build system based build
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
initialize wait for response before sending request.
This is needed in cases where the response arrives before
moving to the next instruction, such as a directly connected
test.
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
run e.g. as
```
nim c -r -d:debug -d:chronicles_enabled=on -d:chronicles_log_level=TRACE -d:chronicles_sinks=textlines[nocolors,stdout] tests/dht/test_providers.nim >err
```
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
* track nim-libp2p's unstable branch and nim-bearssl's master branch
refactor accordingly: mainly switching from `import bearssl` to
`import bearssl/rand`, `BrHmacDrbgContext` to `HmacDrbgContext`, and related
changes
* fix ambiguous identifier
* nim 1.4 is deprecated
Co-authored-by: Michael Bradley, Jr <michaelsbradleyjr@gmail.com>
* initial providers manager implementation
* misc license update
* spelling
* rename provider tests
* add provider tests
* reexport provider manager
* only update provider record if it changed
* small bug in getProvByKey
* pass providers to both constructors
* fix records retrieval
* disable cache during tests
* avoid redefining data
* adding back tests with cache
* use `.errorOption`
* proper err msg unpacking