gotosocial/vendor/codeberg.org/gruf/go-structr
kim ff950e94bb [chore] update dependencies (#4468)
- github.com/ncruces/go-sqlite3
- codeberg.org/gruf/go-mempool
- codeberg.org/gruf/go-structr (changes related on the above) *
- codeberg.org/gruf/go-mutexes (changes related on the above) *

* this is largely just fiddling around with package internals in structr and mutexes to rely on changes in mempool, which added a new concurrency-safe pool

Reviewed-on: https://codeberg.org/superseriousbusiness/gotosocial/pulls/4468
Co-authored-by: kim <grufwub@gmail.com>
Co-committed-by: kim <grufwub@gmail.com>
2025-10-03 15:29:41 +02:00
..
cache.go [chore] update dependencies (#4386) 2025-08-21 16:41:50 +02:00
index.go [chore] update dependencies (#4468) 2025-10-03 15:29:41 +02:00
item.go [chore] update dependencies (#4468) 2025-10-03 15:29:41 +02:00
key.go [chore] update dependencies (#4386) 2025-08-21 16:41:50 +02:00
LICENSE [performance] overhaul struct (+ result) caching library for simplicity, performance and multiple-result lookups (#2535) 2024-01-19 12:57:29 +00:00
list.go [chore] update dependencies (#4468) 2025-10-03 15:29:41 +02:00
map.go update go-structr to v0.9.0 with new Timeline{} cache type (#3903) 2025-03-12 20:33:35 +00:00
queue.go [chore] update dependencies (#4386) 2025-08-21 16:41:50 +02:00
queue_ctx.go update go-structr to v0.9.0 with new Timeline{} cache type (#3903) 2025-03-12 20:33:35 +00:00
README.md [chore] bump go-structr to v0.9.9 (#4390) 2025-08-22 16:04:22 +02:00
runtime.go [chore] update dependencies (#4468) 2025-10-03 15:29:41 +02:00
timeline.go [chore] update dependencies (#4468) 2025-10-03 15:29:41 +02:00

go-structr

A library with a series of performant data types with automated struct value indexing. Indexing is supported via arbitrary combinations of fields, and in the case of the cache type, negative results (errors!) are also supported.

Under the hood, go-structr maintains a hashmap per index, where each hashmap is keyed by serialized input key. This is handled by the incredibly performant serialization library go-mangler/v2, which at this point in time supports all concrete types, so feel free to index by by almost anything!

See the docs for more API information.

Notes

This is a core underpinning of GoToSocial's performance.