Popularity
1.6
Declining
Activity
0.0
Stable
12
4
2
Programming language: Go
License: MIT License
Tags:
Database
mpath alternatives and similar packages
Based on the "Database" category.
Alternatively, view mpath alternatives based on common mentions on social networks and blogs.
-
cockroach
CockroachDB - the open source, cloud-native distributed SQL database. -
tidb
TiDB is an open-source, cloud-native, distributed, MySQL-Compatible database for elastic scale and real-time analytics. Try AI-powered Chat2Query free at : https://tidbcloud.com/free-trial -
Milvus
A cloud-native vector database, storage for next generation AI applications -
vitess
Vitess is a database clustering system for horizontal scaling of MySQL. -
groupcache
groupcache is a caching and cache-filling library, intended as a replacement for memcached in many cases. -
TinyGo
Go compiler for small places. Microcontrollers, WebAssembly (WASM/WASI), and command-line tools. Based on LLVM. -
VictoriaMetrics
VictoriaMetrics: fast, cost-effective monitoring solution and time series database -
immudb
immudb - immutable database based on zero trust, SQL/Key-Value/Document model, tamperproof, data change history -
go-cache
An in-memory key:value store/cache (similar to Memcached) library for Go, suitable for single-machine applications. -
bytebase
Database DevOps and CI/CD for Developer, DBA and Platform Engineering team. -
rosedb
Lightweight, fast and reliable key/value storage engine based on Bitcask. -
pREST
PostgreSQL ➕ REST, low-code, simplify and accelerate development, ⚡ instant, realtime, high-performance on any Postgres application, existing or new -
buntdb
BuntDB is an embeddable, in-memory key/value database for Go with custom indexing and geospatial support -
xo
Command line tool to generate idiomatic Go code for SQL databases supporting PostgreSQL, MySQL, SQLite, Oracle, and Microsoft SQL Server -
tiedot
A rudimentary implementation of a basic document (NoSQL) database in Go -
nutsdb
A simple, fast, embeddable, persistent key/value store written in pure Go. It supports fully serializable transactions and many data structures such as list, set, sorted set. -
LinDB
LinDB is a scalable, high performance, high availability distributed time series database. -
cache2go
Concurrency-safe Go caching library with expiration capabilities and access counters -
GCache
An in-memory cache library for golang. It supports multiple eviction policies: LRU, LFU, ARC -
fastcache
Fast thread-safe inmemory cache for big number of entries in Go. Minimizes GC overhead -
gocraft/dbr (database records)
Additions to Go's database/sql for super fast performance and convenience. -
CovenantSQL
A decentralized, trusted, high performance, SQL database with blockchain features -
lotusdb
Most advanced key-value store written in Go, extremely fast, compatible with LSM tree and B+ tree, optimization of badger and bbolt.
Collect and Analyze Billions of Data Points in Real Time
Manage all types of time series data in a single, purpose-built database. Run at any scale in any environment in the cloud, on-premises, or at the edge.
Promo
www.influxdata.com
Do you think we are missing an alternative of mpath or a related project?
README
mpath-go
Golang realisation of MPTT (or modified preorder tree traversal) in materialized path way.
About
It provides interfaces which yor database object should implement.
Your database object should store:
path
property as slice of uint64 IDs of materialized path to this object in traversal tree;position
property as integer for determine the order of leafs in tree
Usage
Implementation example and tests are in test file.
package main
import (
"fmt"
"github.com/spacetab-io/mpath"
)
type TestItems []*TestItem
type TestItem struct {
ID uint64
Path []uint64
Position int
Siblings TestItems
Name string
}
// Leaf interface implementation for TestItem
// ...
// Leafs interface implementation for TestItems
// ...
func main() {
flatItemsSlice := getTestItems()
var parent = TestItem{}
if err := mpath.InitTree(&parent, flatItemsSlice); err != nil {
panic("error tree init")
}
fmt.Print(parent)
}
func getTestItems() *TestItems {
return &TestItems{
{ID: 1, Position: 0, Name: "item 1", Path: []uint64{1}},
{ID: 2, Position: 0, Name: "item 2", Path: []uint64{1, 2}},
{ID: 3, Position: 1, Name: "item 3", Path: []uint64{1, 3}},
{ID: 4, Position: 0, Name: "item 4", Path: []uint64{1, 2, 4}},
{ID: 5, Position: 1, Name: "item 5", Path: []uint64{1, 2, 5}},
{ID: 6, Position: 0, Name: "item 6", Path: []uint64{1, 3, 6}},
}
}
Tests
go test ./... -v -race