Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: ota_proxy: use simple-sqlite3-orm instead of vendoring an o…
…rm inside otaproxy package (#363) This PR introduces to use simple-sqlite3-orm package(which is also implemented by me) instead. This package is feature-rich, well-implemented and well-tested replacement for the vendored sqlite3 ORM inside the otaproxy package. Also this PR fixes a potential race condition, which the database entry being committed before the cache file being finalized, resulting small chance of cache file not found on database lookup hit. Other major changes * split cache_streaming related logic intocache_streaming module. * split lru_cache_helper from ota_cache module into lru_cache_helper module. * in lru_cache_helper, now we limit the max steps to walk down the bucket list when rotating the cache. * in db, now we use RETURNING statement when rotating cache on supported platform. * in ota_cache, now we also check db integrity to determine whether to force init.
- Loading branch information
4ee5c29
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Coverage Report