MCPcopy Create free account
hub / github.com/adcontextprotocol/adcp / invalidateSessionCache

Function invalidateSessionCache

server/src/middleware/auth.ts:177–182  ·  view source on GitHub ↗
(sessionCookie: string)

Source from the content-addressed store, hash-verified

175 * Invalidate session cache for a specific cookie (e.g., on logout)
176 */
177export function invalidateSessionCache(sessionCookie: string): void {
178 const cacheKey = hashSessionCookie(sessionCookie);
179 sessionCache.delete(cacheKey);
180 deadSessionCache.delete(cacheKey);
181 logger.debug({ cacheKey }, 'Session cache invalidated');
182}
183
184/**
185 * Invalidate ban cache for a specific entity (e.g., after creating or removing a ban).

Callers 1

setupAuthRoutesMethod · 0.85

Calls 2

hashSessionCookieFunction · 0.85
deleteMethod · 0.80

Tested by

no test coverage detected