The Heap package contains simple binary heap implementation, using Golang generics. There are several heap implementations Details.
The ShardedLockMap package contains implementation of sharded lock map. Interface is similar to sync.map, but sharded lock map is faster on scenarios with huge read load with rare updates, and uses less memory, doing less allocations. Details
Minimal Golang version is 1.18. Generics and fuzz testing are used.
To install package, run:
go get github.com/lispad/go-generics-tools/binheap
or
go get github.com/lispad/go-generics-tools/smap
The binheap package is licensed under the MIT license. Please see the LICENSE file for details.