{"ref":"artifact:cds-caching","page":"/artifacts/cds-caching","json":"/artifacts/cds-caching.json","generated":"2026-10-26","drafted_with_ai":true,"entity":{"id":"cds-caching","name":"cds-caching","artifact_type":"cds-plugin","ecosystem":"cap","domain":"data-and-persistence","secondary_domains":["ai-and-agents"],"origin_ring":"independent","description":{"one_line":"A caching plugin for CAP covering queries, requests, function results and remote service responses, through a read-through API or @cache annotations, with HCQL and MCP support.","short":"CAP caching plugin for query results and remote service responses","what_it_solves":"Caches CQN queries, CAP requests and function results through a read-through API or @cache annotations. Stores include memory, SQLite, [Redis](external:redis), [PostgreSQL](external:postgresql), SAP HANA and the application’s CDS database. Tenant-aware keys are enabled automatically when MTX is detected unless explicitly disabled; user and locale awareness remain configurable. Memory is the default store. The optional store: \"cds\" mode reuses the application’s database connection; it is distinct from the direct HANA adapter.","when_not_to_use":"When user-dependent responses are cached without user-aware or explicit operation keys, or translated responses share keys across locales. These cases require key isolation; locale-aware keys are off by default."},"links":{"npm":"https://www.npmjs.com/package/cds-caching","repo":"https://github.com/mikezaschka/cds-caching"},"identity":{"author":"Mike Zaschka"},"compat":{"runtimes":["node"]},"type_properties":{"distribution":{"value":["npm"],"sources":[{"url":"https://github.com/mikezaschka/cds-caching","title":"cds-caching — README","checked":"2026-10-18","quote":"npm install cds-caching"}]}},"provides":[{"capability":"capability:caching","what_it_does":"Retains query, request and function results, with expiry and optional entity-write invalidation through @cache annotations.","sources":[{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — README","checked":"2026-09-17","quote":"Transparently cache CQN queries, CAP requests, or function calls"}],"facets":[{"key":"cache_layer","value":"Read-through results: queries, requests and functions","source":{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — README","checked":"2026-09-17","quote":"Transparently cache CQN queries, CAP requests, or function calls"},"applies_to":{"ecosystems":["cap"]}},{"key":"freshness_control","value":"TTL, tags and optional invalidateOnWrite","source":{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — README","checked":"2026-09-17","quote":"Time-based expiry and tag-based invalidation […] When `invalidateOnWrite` is set, the cache for that entity is automatically cleared after any CREATE, UPDATE, or DELETE operation, so subsequent reads always return fresh data."},"applies_to":{"ecosystems":["cap"]}},{"key":"tenant_partitioning","value":"Automatic tenant-aware keys in MTX; explicit opt-out available","source":{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — README","checked":"2026-09-17","quote":"`isTenantAware` is automatically set to `true` in MTX mode."},"applies_to":{"ecosystems":["cap"]}}]},{"capability":"capability:telemetry","what_it_does":"Exports distributed traces and metrics for its own cache operations through a dedicated OpenTelemetry integration.","sources":[{"url":"https://github.com/mikezaschka/cds-caching","title":"cds-caching README","checked":"2026-10-15","quote":"Distributed tracing and metrics export"}],"facets":[{"key":"signals","value":["Traces","Metrics"],"source":{"url":"https://github.com/mikezaschka/cds-caching","title":"cds-caching README","checked":"2026-10-15","quote":"Distributed tracing and metrics export"},"applies_to":{"ecosystems":["cap"]}}]}],"provenance":{"discovered_via":[{"source":"source:npm"},{"source":"source:maintainer"}],"first_seen":"2026-08-31","claimed_by":"actor:mike-zaschka"},"history":[{"date":"2026-09-06","field":"verdict_withheld","from":"curator-maintains-this","to":"retired","reason":"Withheld verdicts retired with the rings. Nothing is recused from: facts about an entry are facts whoever maintains it, and a starting-point is answered by description.to_build_on_it."},{"date":"2026-09-17","field":"description, compat.multitenancy, provides","from":"Unqualified safe flag; tenant awareness described as opt-in","to":"Removed the unconditional compat.multitenancy flag; recorded the MTX default and user/locale conditions in prose and sourced caching facets","reason":"The current README documents automatic MTX tenant keys and an explicit opt-out; the security guide qualifies user and locale separation."},{"date":"2026-09-17","field":"requires, description.what_it_solves","from":"Redis and CAP presented together as dependencies","to":"Required CAP runtime and conditional cache-store relationships; default memory and CDS reuse clarified","reason":"The maintainer Store Types table documents independently selectable storage modes and adapters."}],"maintainers":["actor:mike-zaschka"],"changed_in":[{"version":"1.0","date":"2025-07-10","what_changed":"The read-through API moved to a runtime namespace: cache.run(), cache.send(), cache.wrap() and cache.exec() were deprecated in favour of cache.rt.*, which returns the cache key and hit or miss metadata alongside the result.","invalidates":"Any code sample calling cache.run() or cache.send() directly. The calls still work but are deprecated, so a tutorial written before this shows the older shape.","source":{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching README — migration notes and upgrade guides","checked":"2026-09-07","quote":"cache.run(), cache.send(), cache.wrap(), cache.exec() are deprecated since v1.0. Use cache.rt.run(), cache.rt.send(), cache.rt.wrap(), cache.rt.exec() instead."}},{"version":"2.0","date":"2026-07-05","what_changed":"The metrics configuration changed shape, splitting into metrics and metrics.reuse.","invalidates":"Any configuration snippet setting metrics under the 1.x shape.","source":{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching README — migration notes and upgrade guides","checked":"2026-09-07","quote":"From 1.x, also see Upgrading to 2.0 for the metrics / metrics.reuse config shape."}},{"version":"3.0","date":"2026-08-17","what_changed":"The statistics and dashboard configuration was removed in favour of metrics and metrics.reuse, and the shape of keys and tags changed, so persistent caches have to be flushed after deploying.","invalidates":"Any configuration snippet using statistics or dashboard, and any advice that assumes a persistent cache survives an upgrade untouched.","source":{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching README — migration notes and upgrade guides","checked":"2026-09-07","quote":"statistics / dashboard — Removed in 3.0 — use metrics / metrics.reuse"}},{"version":"3.0.0","date":"2026-08-17","what_changed":"Cache operations time out after 2000 ms by default instead of waiting indefinitely; `operationTimeout` raises the limit, and `operationTimeout: 0` restores the unbounded behaviour. The dashboard loads UI5 from a CDN instead of bundling it.","invalidates":"The assumption that a slow store only delays a request: from 3.0.0 an operation past the timeout fails.","source":{"url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#300-2026-08-17","title":"cds-caching changelog, 3.0.0","checked":"2026-10-19","quote":"Cache operations now fail after 2000ms rather than waiting indefinitely."}}],"contributors":["actor:fabianberr","actor:maxi1555","actor:mike-zaschka"],"requires":[{"ref":"artifact:sap-cds","for":"Requires [@sap/cds](artifact:sap-cds) >= 8.","sources":[{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — Requirements","checked":"2026-09-17","quote":"SAP CAP (`@sap/cds`) | `>= 8` (including **cds 9** and **cds 10**)"}],"requirement":"required","role":"runtime"},{"ref":"external:redis","requirement":"conditional","role":"cache-store","condition":"When store: \"redis\" is selected.","for":"Cache storage through @keyv/redis; other store modes do not require this backend.","sources":[{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — Store Types","checked":"2026-09-17","quote":"Redis | `\"redis\"` | Production, distributed | `@keyv/redis`"}]},{"ref":"external:sqlite","requirement":"conditional","role":"cache-store","condition":"When store: \"sqlite\" is selected.","for":"Cache storage through @resolid/keyv-sqlite or @keyv/sqlite; other store modes do not require this backend.","sources":[{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — Store Types","checked":"2026-09-17","quote":"SQLite | `\"sqlite\"` | Medium-size, single instance | `@resolid/keyv-sqlite` or `@keyv/sqlite`"}]},{"ref":"external:postgresql","requirement":"conditional","role":"cache-store","condition":"When store: \"postgres\" is selected.","for":"Cache storage through @keyv/postgres; other store modes do not require this backend.","sources":[{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — Store Types","checked":"2026-09-17","quote":"PostgreSQL | `\"postgres\"` | Production, when Redis unavailable | `@keyv/postgres`"}]},{"ref":"artifact:sap-hana","requirement":"conditional","role":"cache-store","condition":"When store: \"hana\" is selected.","for":"Cache storage through keyv-hana; other store modes do not require this backend.","sources":[{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — Store Types","checked":"2026-09-17","quote":"SAP HANA | `\"hana\"` | Direct HANA connection | `keyv-hana`"}]},{"ref":"artifact:cap-js-sqlite","requirement":"conditional","role":"cache-adapter","condition":"When the SQLite store is selected.","for":"The README requirements table specifies ^1 with cds 8, ^2 with cds 9, and ^3 with cds 10.","sources":[{"url":"https://github.com/mikezaschka/cds-caching/blob/main/README.md","title":"cds-caching — Requirements","checked":"2026-09-17","quote":"`@cap-js/sqlite` (SQLite store) | `^1` on cds 8, `^2` on cds 9, `^3` on cds 10"}]}],"drafted_with_ai":true,"connects":[{"ref":"external:redis","kind":"data","for":"passing cache read and write operations through to the Redis store at runtime","sources":[{"url":"https://github.com/mikezaschka/cds-caching","title":"cds-caching README","checked":"2026-10-15","quote":"the `credentials` object is passed through to [`@keyv/redis`](https://keyv.org/docs/storage-adapters/redis/) / [`@redis/client`](https://github.com/redis/node-redis)."}]}]},"effective_normative_relations":[{"instrument":"instrument:sap-developer-license-3-2-cap","relation":"use-constrained-by","sections":["1","2","3"],"applies_when":"A cds-plugin is used with SAP CAP materials, or an artifact is explicitly identified as a CAP plugin or application.","note":"This is inherited applicability, not a licence verdict about the artifact itself. Review the agreement for the actual materials and use; an explicit artifact relationship to another revision takes precedence.","scope":{"kind":"artifact"},"sources":[{"url":"https://cap.cloud.sap/resources/license/developer-license-3_2_CAP.txt","title":"SAP Developer License Agreement 3.2 CAP","checked":"2026-09-16","quote":"documentation, plug-ins, templates, scripts and sample code, libraries, software development kits"}],"inherited_from":"cap-plugins-and-applications","relevant_capabilities":["agent-systems-access","async-processing","data-import-export","database-connectors","deployment","destinations","llm-integration","mcp-servers","plugin-authoring","replication","retrieval-augmented-generation","rfc-connectivity"]}],"readings":{"liveness":[{"label":"Maintenance","tier":"good","evidence":"1 month since release"},{"label":"Continuity","tier":"good","evidence":"5 contributors, 1 publisher"},{"label":"Repository","tier":"good","evidence":"pushed 2026-09, not archived"}],"compatibility":[{"label":"Declared for","tier":"good","evidence":">=8 — includes cds 10 and 9"},{"label":"Survived majors","tier":"good","evidence":"released before and after @sap/cds 10"},{"label":"Maintainer's CI","tier":"good","evidence":"Test green, 2026-09-20"}],"practice":[{"label":"Tests","tier":"good","evidence":"46 test files, npm test"},{"label":"Docs","tier":"good","evidence":"docs/ with 14 pages, README 20 KB"},{"label":"Changelog","tier":"good","evidence":"CHANGELOG in the repo"}],"reach":[{"value":302,"unit":"installs/week"},{"value":38,"unit":"watching"}]},"signals":{"crawled_at":"2026-10-24","latest_version":"3.1.1","majors":{"1":{"version":"1.0.0","date":"2025-07-10"},"2":{"version":"2.0.0","date":"2026-07-05"},"3":{"version":"3.0.0","date":"2026-08-17"},"0.1":{"version":"0.1.0","date":"2025-01-30"},"0.2":{"version":"0.2.0","date":"2025-02-07"},"0.3":{"version":"0.3.0","date":"2025-03-07"}},"license":"MIT","first_release":"2025-01-30","last_release":"2026-09-20","releases":22,"cadence_days":6,"maintainers":1,"repository":"git+https://github.com/mikezaschka/cds-caching.git","repository_directory":null,"peer_cds":">=8","test_script":true,"types":true,"downloads_weekly":302,"stars":38,"forks":9,"open_issues":7,"archived":false,"pushed_at":"2026-09-20","license_spdx":"MIT","org_owned":false,"default_branch":"main","contributors":5,"tree_truncated":false,"test_files":46,"workflows":1,"other_ci":false,"readme_bytes":20072,"docs_files":14,"changelog":true,"license_file":true,"dts_files":1,"ci_status":"success","ci_run_at":"2026-09-20","ci_workflow":"Test","ci_event":"push","readme_path":"README.md","readme_sha":"283b353dadac52d8b874deddb493d2a1e13addea","months_since_release":1,"dormant":false,"first_commit":"2025-01-29","last_commit":"2026-09-20","commits":198,"dependencies":1,"node_engine":">=22","downloads_monthly":1875,"created_at":"2025-01-29T12:34:11Z","open_prs":3,"repo_read":"2026-10-24"},"release_notes":{"license":"MIT","quotable":true,"source":{"kind":"repo","path":"CHANGELOG.md","ref":"main","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md"},"format":"conventional","releases":[{"version":"3.1.1","date":"2026-09-20","date_source":"heading","heading":"3.1.1 (2026-09-20)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#311-2026-09-20","sections":[{"kind":"fix","heading":"Bug Fixes","items":1}],"hash":"c1a0d7267c9ffc07"},{"version":"3.1.0","date":"2026-09-20","date_source":"heading","heading":"3.1.0 (2026-09-20)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#310-2026-09-20","sections":[{"kind":"feature","heading":"Features","items":1}],"hash":"5124d4561b338db7"},{"version":"3.0.1","date":"2026-09-20","date_source":"heading","heading":"3.0.1 (2026-09-20)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#301-2026-09-20","sections":[{"kind":"fix","heading":"Bug Fixes","items":3},{"kind":"docs","heading":"Documentation","items":1}],"hash":"7dffc6f25add218e"},{"version":"3.0.0","date":"2026-08-17","date_source":"heading","heading":"3.0.0 (2026-08-17)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#300-2026-08-17","sections":[{"kind":"breaking","heading":"⚠ BREAKING CHANGES","items":5},{"kind":"feature","heading":"Features","items":3},{"kind":"fix","heading":"Bug Fixes","items":10}],"hash":"a23bdf872d8e7f69","cited_by":[{"version":"3.0.0","date":"2026-08-17"}]},{"version":"2.1.0","date":"2026-08-16","date_source":"heading","heading":"2.1.0 (2026-08-16)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#210-2026-08-16","sections":[{"kind":"feature","heading":"Features","items":5},{"kind":"fix","heading":"Bug Fixes","items":3}],"hash":"02343e1d7c93404c"},{"version":"2.0.2","date":"2026-07-16","date_source":"heading","heading":"2.0.2 (2026-07-16)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#202-2026-07-16","sections":[{"kind":"fix","heading":"Bug Fixes","items":1}],"hash":"a425a844d2223276"},{"version":"2.0.1","date":"2026-07-10","date_source":"heading","heading":"2.0.1 (2026-07-10)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#201-2026-07-10","sections":[],"hash":"e3b0c44298fc1c14"},{"version":"2.0.0","date":"2026-07-05","date_source":"heading","heading":"2.0.0 (2026-07-05)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#200-2026-07-05","sections":[{"kind":"feature","heading":"Features","items":6},{"kind":"fix","heading":"Bug Fixes","items":4}],"hash":"774c7e69de72279c"},{"version":"1.3.2","date":"2026-04-24","date_source":"heading","heading":"1.3.2 (2026-04-24)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#132-2026-04-24","sections":[{"kind":"feature","heading":"Features","items":4},{"kind":"fix","heading":"Bug Fixes","items":1}],"hash":"ec3ef72ebf0d03e8"},{"version":"1.3.1","date":"2026-04-15","date_source":"heading","heading":"1.3.1 (2026-04-15)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#131-2026-04-15","sections":[{"kind":"feature","heading":"Features","items":2}],"hash":"bf1b120f7105a1e7"},{"version":"1.3.0","date":"2026-04-13","date_source":"heading","heading":"1.3.0 (2026-04-13)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#130-2026-04-13","sections":[{"kind":"feature","heading":"Features","items":7},{"kind":"fix","heading":"Bug Fixes","items":4}],"hash":"9f15d57934cfdb89"},{"version":"1.2.1","date":"2026-02-09","date_source":"heading","heading":"1.2.1 (2026-02-09)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#121-2026-02-09","sections":[],"hash":"e3b0c44298fc1c14"},{"version":"1.2.0","date":"2026-02-09","date_source":"heading","heading":"1.2.0 (2026-02-09)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#120-2026-02-09","sections":[{"kind":"fix","heading":"Bug Fixes","items":2}],"hash":"1ece92c462e8efdb"},{"version":"1.1.0","date":"2025-07-29","date_source":"heading","heading":"1.1.0 (2025-07-29)","url":"https://github.com/mikezaschka/cds-caching/blob/main/CHANGELOG.md#110-2025-07-29","sections":[],"hash":"e3b0c44298fc1c14"}],"versions":[{"version":"3.1.1","date":"2026-09-20"},{"version":"3.1.0","date":"2026-09-20"},{"version":"3.0.1","date":"2026-09-20"},{"version":"3.0.0","date":"2026-08-17"},{"version":"2.1.0","date":"2026-08-16"},{"version":"2.0.2","date":"2026-07-16"},{"version":"2.0.1","date":"2026-07-10"},{"version":"2.0.0","date":"2026-07-05"},{"version":"1.3.2","date":"2026-04-24"},{"version":"1.3.1","date":"2026-04-15"},{"version":"1.3.0","date":"2026-04-13"},{"version":"1.2.1","date":"2026-02-09"},{"version":"1.2.0","date":"2026-02-09"},{"version":"1.1.0","date":"2025-07-29"},{"version":"1.0.0","date":"2025-07-10"},{"version":"0.3.3","date":"2025-07-06"},{"version":"0.3.2","date":"2025-03-10"},{"version":"0.3.1","date":"2025-03-10"},{"version":"0.3.0","date":"2025-03-07"},{"version":"0.2.1","date":"2025-02-07"},{"version":"0.2.0","date":"2025-02-07"},{"version":"0.1.0","date":"2025-01-30"}],"crawled_at":"2026-10-25"},"edges":{"maintainers":[{"ref":"actor:mike-zaschka","name":"Mike Zaschka","json":"/actors/mike-zaschka.json"}],"contributors":[{"ref":"actor:fabianberr","name":"FabianBerr","json":"/actors/fabianberr.json"},{"ref":"actor:maxi1555","name":"maxi1555","json":"/actors/maxi1555.json"},{"ref":"actor:mike-zaschka","name":"Mike Zaschka","json":"/actors/mike-zaschka.json"}],"explained_by":[{"ref":"content:cap-just-got-faster-whats-new-in-cds-caching-1-0","name":"CAP just got faster: What's new in cds-caching 1.0","json":"/content/cap-just-got-faster-whats-new-in-cds-caching-1-0.json"},{"ref":"content:boosting-performance-in-cap-with-cds-caching","name":"Boosting performance in SAP Cloud Application Programming Model (CAP) applications with cds-caching","json":"/content/boosting-performance-in-cap-with-cds-caching.json"},{"ref":"content:performance-boost-and-caching-strategy-with-cds-caching","name":"Performance Boost and Caching Strategy for Faster Data Access using \"cds-caching\" in SAP CAP","json":"/content/performance-boost-and-caching-strategy-with-cds-caching.json"}],"alternative_to_this":[],"needed_by":[{"ref":"artifact:mikezaschka-cds-data-federation","name":"cds-data-federation","json":"/artifacts/mikezaschka-cds-data-federation.json"}],"available_via":[{"ref":"artifact:btp-postgresql-hyperscaler","name":"PostgreSQL on SAP BTP, hyperscaler option","json":"/artifacts/btp-postgresql-hyperscaler.json","derived":true,"through":{"ref":"external:postgresql","name":"PostgreSQL","json":"/externals/postgresql.json"},"path":[{"kind":"requires","source":"artifact:cds-caching","target":"external:postgresql"},{"kind":"delivers","source":"artifact:btp-postgresql-hyperscaler","target":"external:postgresql"}]},{"ref":"artifact:btp-redis","name":"Redis on SAP BTP, hyperscaler option","json":"/artifacts/btp-redis.json","derived":true,"through":{"ref":"external:redis","name":"Redis","json":"/externals/redis.json"},"path":[{"kind":"requires","source":"artifact:cds-caching","target":"external:redis"},{"kind":"delivers","source":"artifact:btp-redis","target":"external:redis"}]}],"parts":[],"add_ons":[],"answered_through_parts":[]}}