summaryrefslogtreecommitdiff
path: root/Hutch/Networking/SRHTClient.swift
Commit message (Collapse)AuthorAgeFilesLines
* feat: add persistent stale-while-revalidate API cacheChristian Cleberg2026-05-061-1/+298
| | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce an actor-backed persistent cache layer at the SRHTClient boundary for read-only SourceHut data. Cache entries now store stable metadata including key, resource type, fetched/expires/access timestamps, payload hash, schema version, and payload size, with bounded memory and disk usage. Add centralized cache key builders and TTL defaults for repository, file, ticket, build, log, profile, status, and list-style resources. Support networkOnly, cacheOnly, cacheFirstThenRefresh, and refreshIgnoringCache policies, plus request coalescing for duplicate in-flight cache keys. Integrate first-pass caching into high-value low-risk read paths: - build detail and completed/active build logs - ticket detail - README lookup - repository tree, blob, and linked file reads Keep mutation paths network-only and add simple prefix invalidation after ticket and build mutations. Add compact cached/stale UI status rows and a Settings action to clear the persistent cache. Add focused cache tests covering round trips, expiration, stale fallback, policy behavior, request coalescing, prefix invalidation, size limits, LRU pruning, expired pruning, and mutation bypass behavior. Document storage, key, TTL, invalidation, limitations, and next recommended targets.
* feat: add custom hutch user-agent to api callsChristian Cleberg2026-04-151-0/+5
| | | | Implements: https://todo.sr.ht/~ccleberg/hutch/64
* fix: more sonarqube quality fixesv3.1.5Christian Cleberg2026-04-131-12/+13
|
* fix: sonarqube code smell fixesv3.1.4Christian Cleberg2026-04-131-29/+19
|
* fix: mercurial parity and graphql handlingv3.0.4Christian Cleberg2026-04-131-17/+16
| | | | | | | | | | - implements consistent UX between repo types - ensures centralized services and routes are used between repo types - graphql error handling is centralized - error messages are consistent Implements: https://todo.sr.ht/~ccleberg/hutch/58 Implements: https://todo.sr.ht/~ccleberg/hutch/59
* feat: add Look Up screen and restrict management actions to ownersv2.8.0Christian Cleberg2026-04-011-0/+10
| | | | Implements: https://todo.sr.ht/~ccleberg/Hutch/4
* fix copy throughout repoChristian Cleberg2026-04-011-4/+4
|
* feat: implement support for projects, lists, and pastesChristian Cleberg2026-03-191-0/+101
|
* Guard authenticated text fetches to sr.ht hosts and add regression testChristian Cleberg2026-03-181-0/+14
|
* v1.0Christian Cleberg2026-03-171-0/+521