-
Notifications
You must be signed in to change notification settings - Fork 0
Labels
enhancementNew feature or requestNew feature or request
Description
Overview
Implement a robust, layered caching strategy for the whurl client, with clear separation of responsibilities and interfaces for each layer.
Caching layers (sub-issues):
- Domain-layer cache (canonical data):
- Caches raw, unfiltered site and measurement lists in memory (and optionally disk).
- API examples:
client.list_sites(refresh=False),client.check_for_site(name, refresh=False). - Handles normalization, index building, refresh logic.
- First to implement (see sub-issue).
- HTTP-layer cache (transport-level cache):
- Intercepts GET/HEAD requests, uses ETag/Last-Modified and Cache-Control to serve fresh or revalidated responses.
- Respects server cache headers and conditional requests.
- Pluggable backend (memory/disk), with a size-limited LRU.
- Sub-issue details to follow.
- Query memoization layer (hot filtered queries):
- Small, short-lived cache for expensive filtered queries (e.g., measurement filters).
- Built atop domain-layer cache; optional, not persisted.
- Sub-issue details to follow.
Each layer should be modular, well-documented, and testable. Sub-issues will cover detailed API, implementation, and acceptance criteria for each layer.
Sub-issues
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request