Closed mouselangelo closed 4 years ago
Merging #288 into master will decrease coverage by
1.26%
. The diff coverage is36.8%
.
@@ Coverage Diff @@
## master #288 +/- ##
==========================================
- Coverage 51.92% 50.66% -1.26%
==========================================
Files 87 91 +4
Lines 3168 3456 +288
==========================================
+ Hits 1645 1751 +106
- Misses 1523 1705 +182
Impacted Files | Coverage Δ | |
---|---|---|
Sources/TaskRegistry.swift | 0% <0%> (ø) |
|
Sources/URLSession+UrlCache.swift | 0% <0%> (ø) |
|
Sources/FlowkeyCachedURLResponse.swift | 0% <0%> (ø) |
|
Sources/FlowkeyURLCache.swift | 74.64% <74.64%> (ø) |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update 2f5ed04...f243845. Read the comment docs.
Closing this for now, but keeping the branch
Type of change: feature
Motivation (current vs expected behavior)
On iOS
URLSession
APIs automatically provide default In-memory and on-disk caching via theURLCache
API.The
URLCache
API has not been implemented in swift-corelibs-foundation - the version ofFoundation
that our Android build chain uses.This PR implements a basic
URLCache
that provides Disk caching for Android.Todos:
Nice-to-have:
The following are nice to haves and are open for discussion. These can be added later on a need-to basis:
Cache-control: max-age...
and remove stale caches. Currently only comparesEtag
StoragePolicy
forCachedURLResponse
objects.Not doing:
The following are not part of the scope of this PR.
Please check if the PR fulfills these requirements