Skip to main content

Module store

Module store 

Source

Structs§

LoginPoint
一次登录的位置快照,用于异地检测与不可能旅行。
MemoryStore
内存后端。无后台线程 —— 过期判定归 guard,内存回收靠 purge_expired。
SessionRecord
会话记录 —— 这张表就是「token 会话」。

Constants§

LOGIN_HISTORY_KEEP_SECS
登录历史的保留时长(秒):超过这段时间没有新登录点的 subject, 其登录历史会在 SessionStore::purge_expired 时整条删除。
MAX_LOGINS_PER_SUBJECT
每个 subject 保留的登录历史条数上限。

Traits§

SessionStore
会话存储后端。