https://github.com/althk/dmap
A generics-based simple, vertically distrubuted map structure.
https://github.com/althk/dmap
distributed-map golang golang-generics
Last synced: 4 months ago
JSON representation
A generics-based simple, vertically distrubuted map structure.
- Host: GitHub
- URL: https://github.com/althk/dmap
- Owner: althk
- License: unlicense
- Created: 2022-07-07T11:10:54.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-06-22T07:19:11.000Z (over 2 years ago)
- Last Synced: 2025-01-12T07:09:28.439Z (about 1 year ago)
- Topics: distributed-map, golang, golang-generics
- Language: Go
- Homepage:
- Size: 8.79 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
#
## DMap
A generics-based simple, horizontally distrubuted (sharded) map structure.
Supports keys of types that implement a `String()` method (`fmt.Stringer` interface), and any values.
### Benchmarks
```bash
go test -bench=Benchmark -benchmem -benchtime=100x .
goos: linux
goarch: amd64
pkg: github.com/althk/dmap
cpu: Intel(R) Core(TM) i7-1065G7 CPU @ 1.30GHz
BenchmarkSet/100000_keys-8 100 608383 ns/op 200617 B/op 5024 allocs/op
BenchmarkSet/1000000_keys-8 100 6633708 ns/op 1959989 B/op 50347 allocs/op
BenchmarkGet-8 100 1492 ns/op 40 B/op 2 allocs/op
BenchmarkKeys-8 100 5445090 ns/op 8944281 B/op 56 allocs/op
BenchmarkCount-8 100 109.7 ns/op 0 B/op 0 allocs/op
PASS
ok github.com/althk/dmap 3.770s
```