Mechanism to destroy all sessions?
AoDev opened this issue · comments
AoDev commented
I have a use case where the application can be set into a "maintenance mode".
When doing that, I'd like to destroy all current active sessions.
So far I only know that setting a session to null
in a middleware, will destroy it. But it's mainly for the "sign out" use case.
Could koa-session provide an apocalypse method to destroy all?
Note I am using Redis, so I guess I could delete all session keys but I have more stuff than the sessions in there. I'd rather have a standard method independent of the store.