>_
.issue.db
/highway-workflow-engine
Dashboard
Issues
Memory
Lessons
Audit Log
New Issue
Edit Issue #526
Update issue details
Title *
Description
**File:** api/oauth_handlers/oauth2.py:115-133 **Problem:** `verify_jwt_token()` calls `get_oauth2_config()` which fetches 4 secrets from Vault on EVERY authenticated request. At 1000 req/sec = 4000 Vault reads/sec. **Fix:** Add TTL cache: ```python _JWT_CONFIG_CACHE = None _JWT_CONFIG_CACHE_TIME = 0 JWT_CONFIG_TTL = 300 # 5 minutes def get_oauth2_config() -> dict[str, Any]: global _JWT_CONFIG_CACHE, _JWT_CONFIG_CACHE_TIME now = time.time() if _JWT_CONFIG_CACHE and (now - _JWT_CONFIG_CACHE_TIME) < JWT_CONFIG_TTL: return _JWT_CONFIG_CACHE # ... fetch from Vault ... ``` **Impact:** 50-100ms saved per request (Vault latency).
Priority
Low
Medium
High
Critical
Status
Open
In Progress
Closed
Won't Do
Due Date (YYYY-MM-DD)
Tags (comma separated)
Related Issues (IDs)
Enter IDs of issues related to this one. They will be linked as 'related'.
Update Issue
Cancel