Skip to content

NET-1329 simplify cache TTL to module const and per-call override#112

Open
AkhileshNair2201 wants to merge 3 commits into
feat/sdk-cachingfrom
NET-1329-simplify-cache-ttl
Open

NET-1329 simplify cache TTL to module const and per-call override#112
AkhileshNair2201 wants to merge 3 commits into
feat/sdk-cachingfrom
NET-1329-simplify-cache-ttl

Conversation

@AkhileshNair2201

@AkhileshNair2201 AkhileshNair2201 commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

TICKET (https://getnetra.atlassian.net/browse/NET-1329)

Summary

  • Drop cacheTtlSeconds init config and NETRA_CACHE_TTL_SECONDS env — they were unused; callers only ever hit the default.
  • Prompts now use module constant PROMPT_CACHE_TTL_SECONDS (60); override only via per-call cacheTtl (same pattern as models’ MODEL_PRICING_CACHE_TTL_SECONDS).
  • Update README and CHANGELOG to match.

Why

Init/env TTL added config surface without real usage. Aligning prompts with the Phase 2 models pattern keeps one clear rule: module default + per-call override.

Test plan

  • vitest prompts/models/shutdown/cache suites
  • Confirm no callers rely on cacheTtlSeconds / NETRA_CACHE_TTL_SECONDS

Made with Cursor

AkhileshNair2201 and others added 3 commits July 10, 2026 18:57
Co-authored-by: Cursor <cursoragent@cursor.com>
…/netra-sdk-js into NET-1329-simplify-cache-ttl
Assert PROMPT_CACHE_TTL_SECONDS expiry when cacheTtl is omitted, and stop passing the removed Config option in models client tests.

Co-authored-by: Cursor <cursoragent@cursor.com>
akash-vijay-kv
akash-vijay-kv approved these changes Jul 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants