mirror of
https://github.com/pnpm/pnpm.git
synced 2026-04-06 00:06:06 -04:00
Replace the per-package JSON file cache (metadata-v1.4/, metadata-ff-v1.4/) with a single SQLite database (metadata.db) for registry metadata caching. Benefits: - Cheap conditional request header lookups (etag/modified) without parsing the full metadata JSON — enables If-None-Match/If-Modified-Since with minimal I/O overhead - Full metadata can serve abbreviated requests — if a package was previously fetched as full (e.g., for trustPolicy or resolutionMode), the resolver reuses it instead of making another registry request - Eliminates hundreds of individual file read/write/rename operations per install, replaced by SQLite WAL-mode transactions - Removes the runLimited/metafileOperationLimits concurrency machinery — SQLite handles concurrent access natively New package: @pnpm/cache.metadata — SQLite-backed MetadataCache class modeled after @pnpm/store.index, with getHeaders() for cheap lookups, get() with abbreviated→full fallback, and set()/updateCachedAt().
13 lines
197 B
JSON
13 lines
197 B
JSON
{
|
|
"extends": "@pnpm/tsconfig",
|
|
"compilerOptions": {
|
|
"outDir": "lib",
|
|
"rootDir": "src"
|
|
},
|
|
"include": [
|
|
"src/**/*.ts",
|
|
"../../__typings__/**/*.d.ts"
|
|
],
|
|
"references": []
|
|
}
|