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
Raúl Kripalani
135471f291
add io.Closer interface and implementation to Peerstore.
2019-02-19 11:45:32 +00:00
Raúl Kripalani
53d45e9406
make gc operations run on cyclic batches.
2018-12-03 17:40:01 +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
bd80609ef6
adjust GC interval in tests.
2018-11-15 13:55:53 +00:00
Raúl Kripalani
e57f21a66c
Merge branch 'master' into feat/pstore-ds-gc
2018-11-15 13:44:13 +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
Adrian Lanzafame
c04ff2d27b
add keybook benchmarks
...
License: MIT
Signed-off-by: Adrian Lanzafame <adrianlanzafame92@gmail.com>
2018-11-07 15:48:31 +10:00
Adrian Lanzafame
ee43bc1951
prevent timeout by un-nesting tb.Runs
...
License: MIT
Signed-off-by: Adrian Lanzafame <adrianlanzafame92@gmail.com>
2018-11-07 15:48:31 +10:00
Raúl Kripalani
61b5355499
run tests against multiple datastores.
...
leveldb disabled for now, until TTL shim is implemented.
2018-10-04 10:50:45 +01:00
Raúl Kripalani
1b72b920ed
datastore-backed impls of KeyBook and PeerMetadata.
2018-09-28 14:04:52 +01:00
Raúl Kripalani
196ad55260
ds.NewTransaction() can now return an error.
2018-09-27 20:59:57 +01:00
Raúl Kripalani
5b9ad98cc2
remove noop Stop() in address book.
2018-09-18 19:00:07 +01:00
Raúl Kripalani
c7d99489fd
address review comments.
2018-09-12 13:53:10 +01:00
Raúl Kripalani
4037390c42
increase test coverage.
2018-09-11 18:17:27 +01:00
Raúl Kripalani
1b410c7294
Merge branch 'master' into txndatastore
2018-09-11 14:13:14 +01:00
Raúl Kripalani
ca6f050174
add baseline benchmarks.
2018-09-10 19:59:27 +01:00
Raúl Kripalani
1c25f160a1
normalise import aliases.
2018-09-07 18:46:23 +01:00
Raúl Kripalani
bc77b649dc
rename AddrMgr => AddrBook elsewhere.
2018-09-05 15:10:18 +01:00
Raúl Kripalani
7d8b6c9843
ttl manager: create transaction only when needed.
...
Also adjust test logic. Last changes were ticking the ttl manager
too often unnecessarily. This was skewing benchmarks.
2018-09-04 14:52:26 +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