Skip to content

feat(github): add in-memory token cache for keychain reads and writes#11

Merged
mohammedhammoud merged 1 commit into
mainfrom
fix/keychain-token-cache
May 20, 2026
Merged

feat(github): add in-memory token cache for keychain reads and writes#11
mohammedhammoud merged 1 commit into
mainfrom
fix/keychain-token-cache

Conversation

@mohammedhammoud

Copy link
Copy Markdown
Owner

Changes

  • Added OnceLock<Mutex<Option<String>>> static token cache
  • Added cache_token() to write tokens into in-memory cache
  • Added cached_token() to read tokens from in-memory cache
  • Updated GitHubCredentials::write_token to store in cache after keychain write
  • Updated read_token to check cache before falling back to keychain
  • Updated keychain write path to persist to in-memory cache

Changes

@mohammedhammoud mohammedhammoud merged commit 8b7c713 into main May 20, 2026
1 check failed
@mohammedhammoud mohammedhammoud deleted the fix/keychain-token-cache branch May 20, 2026 19:45
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.

1 participant