`go-cache` is a storage-agnostic, JSON-based caching library for Go. Module path: `dappco.re/go/core/cache`. The entire package is two files: `cache.go` and `cache_test.go`.
- All I/O is delegated to the `io.Medium` interface from `dappco.re/go/core/io` — the cache never reads/writes files directly. This makes it backend-swappable (local FS, SQLite, S3, in-memory mock).
-`Cache.Path()` enforces path-traversal protection on every public method — keys like `../../etc/passwd` are rejected before any I/O occurs.
- Expired entries are not eagerly deleted; they remain on disk until overwritten or explicitly removed.
- The struct has no mutex. Concurrent reads are safe, but concurrent writes to the same key need external synchronization.
## Testing Conventions
- Use `io.NewMockMedium()` for all tests — no real filesystem access.
- Use `testing.T` directly, not testify.
- Use short TTLs (milliseconds) for expiry tests.
## Commit Conventions
Conventional commits: `feat(cache):`, `fix(cache):`, `refactor:`, etc. The release config (`.core/release.yaml`) includes `feat`, `fix`, `perf`, `refactor` in changelogs.