Skip to content

Update to Swift 2 - #10

Closed
3lvis wants to merge 1 commit into
masterfrom
swift-2
Closed

Update to Swift 2#10
3lvis wants to merge 1 commit into
masterfrom
swift-2

Conversation

@3lvis

@3lvis3lvis commented Sep 7, 2015

Copy link
Copy Markdown
Owner

No description provided.

@3lvis3lvis closed this Sep 7, 2015
@3lvis
3lvis deleted the swift-2 branch September 7, 2015 09:42
3lvis added a commit that referenced this pull request Jun 17, 2026
…long-URL fix
Implements roadmap #10. One PR covering the whole cache surface.
- Consistency: clearCache() empties both the in-memory NSCache and the on-disk files; reset() = clearCache() + wipe credentials/headers/fakes. The disk-only static deleteCachedFiles() (which left memory serving deleted data) is gone.
- Warm/cold TTL: on-disk entries carry a sliding TTL (cacheTTL, default 7 days) whose persisted clock is the file's modification date — re-warmed on a disk read/write, no in-memory map, no manifest. NSCache absorbs repeat reads (the debounce).
- Sharded from the start: files live under domain/<shard>/<file>; the startup sweep does one shard per launch via a cursor, so per-launch work is O(N/16) and never spikes. Sweep and clears serialize on a lock.
- Long-URL fix: destinationURL hashes the filename component past the 255-byte limit (red-first).
Breaking vs 7.0.0 (v8). Backed by the mtime-vs-SQLite benchmark in #320. README, repo notes, CHANGELOG, roadmap updated. 176 tests green.
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@3lvis