Marten Seemann
048b94159f
remove the pstoremanager (will be moved to the Host)
2021-12-08 18:44:20 +04:00
Marten Seemann
51974ae06e
when passed an event bus, automatically clean up disconnected peers
2021-12-02 12:07:58 +04:00
Marten Seemann
a3a997d014
implement RemovePeer
2021-12-02 11:57:28 +04:00
Marten Seemann
9749083212
Merge pull request #172 from libp2p/limit-protocols
...
limit the number of protocols we store per peer
2021-10-29 18:43:53 +02:00
Gus Eggert
566ed64074
feat: plumb through datastore contexts ( #176 )
2021-10-28 16:32:18 -04:00
Marten Seemann
5eae6d6caf
limit the number of protocols we store per peer
2021-10-22 18:01:08 +02:00
Steven Allen
9aa80d7506
fix: avoid copying locks/waitgroups
2021-07-15 17:16:22 -07:00
Yusef Napora
59abcf549d
Certified addresses ( #98 )
2020-03-06 12:07:36 +00:00
Steven Allen
0b5b389640
dep: switch to core ( #80 )
...
* dep: switch to core
Specifically, remove go-libp2p-{crypto,peer} deps.
* catch a few more usages of deprecated packages.
2019-05-31 14:51:16 +01:00
vyzo
3140aaa2c3
implement protobook for pstoreds
2019-05-17 13:13:18 +03:00
Raúl Kripalani
2c5bc31271
migrate to multiformats/go-base32.
2019-02-28 18:34:51 +00:00
Raúl Kripalani
25e4df45aa
change default purge interval to 2 hours.
2019-02-06 14:43:10 +00:00
Raúl Kripalani
fec786e9ef
pstore ds: make gc lookahead window optional.
2019-02-06 09:35:10 +00:00
Raúl Kripalani
53d45e9406
make gc operations run on cyclic batches.
2018-12-03 17:40:01 +00:00
Raúl Kripalani
e43a2fc519
drop the need for a transactional datastore; introduce buffer pool.
2018-12-03 15:43:37 +00:00
Raúl Kripalani
c3c24b227a
rename GCPruneInterval to GCPurgeInterval for consistency.
2018-11-28 01:29:09 +00:00
Raúl Kripalani
35444fbc6a
implement two-tiered lookahead-based GC procedure.
...
The GC procedure consists of two tiers: lookahead and purge. The
lookahead tier runs less frequently (default 12 hours) than the purge
tier (default 5 minutes).
A lookahead round traverses the entire store and picks entries that
need to be visited in the current lookahead window, pinning those
entries in a separate region in the KV store, indexed by the next visit
timestamp.
A purge round iterates over the lookahead window only, and refreshes
the entries that require a visit. It removes them from the lookahead
region unless the entry requires another visit within the current
window.
2018-11-28 00:13:02 +00:00
Raúl Kripalani
c423e9e997
pstoreds: migrate from strict TTL to GC-based expiry.
...
Each entry in the address book KV store now represents a full peer
with all its addresses. Expiries and TTLs are kept inline. Records are
serialised with Protobuf.
Housekeeping is performed on retrieve, and via a periodic GC routine.
The architecture mimics a write-through cache, although not strictly.
2018-11-13 16:57:51 +00:00
Raúl Kripalani
4e2e2de65f
ds key encoding: b58 => b32 (no padding).
2018-10-04 10:51:57 +01:00
Raúl Kripalani
3e80eb1873
review comments.
2018-09-28 18:47:41 +01:00
Raúl Kripalani
dd3cb20421
add explicit import aliases.
2018-09-28 14:18:05 +01:00
Raúl Kripalani
1b72b920ed
datastore-backed impls of KeyBook and PeerMetadata.
2018-09-28 14:04:52 +01:00
Raúl Kripalani
c7d99489fd
address review comments.
2018-09-12 13:53:10 +01:00
Raúl Kripalani
1b410c7294
Merge branch 'master' into txndatastore
2018-09-11 14:13:14 +01:00
Raúl Kripalani
1c25f160a1
normalise import aliases.
2018-09-07 18:46:23 +01:00
Raúl Kripalani
d79386365e
rename NewPeerstoreWith(...) => NewPeerstore(...); adjust godoc.
2018-09-05 15:14:57 +01:00
Raúl Kripalani
7f4288fab1
rename package mem => pstoremem.
2018-09-04 18:07:44 +01:00
Raúl Kripalani
1b57c62e3d
increase benchmark coverage; introduce config struct.
...
* benchmark caching and cacheless variants of DS addrbook.
* benchmark peers with 1, 10, 100 addrs.
2018-09-07 17:45:29 +01:00
Raúl Kripalani
f8aeb5476e
another perf improvement iteration.
2018-09-07 17:45:25 +01:00
Raúl Kripalani
e200f3a5c1
gx-go unrewrite.
2018-09-02 12:10:55 +01:00
Raúl Kripalani
d0c3d2b341
rename ds package to pstoreds.
2018-09-02 12:03:02 +01:00